I am using EF Core v 1.2
, In my project I have a method when I debug it or when I run it in local machine It works fine and return data , but when I publish project in production mode it returns an exception :
System.ArgumentNullException: Value cannot be null. Parameter name: source , {State:l}
Exactly this code without any changes work properly .
Note : the Code executed form an background Service .