In my project i used the library Newtonsoft.Json version 11.0.2, and i need use Google.Api and Google.Core, but when install this two library i receive the next error:
System.IO.FileLoadException: 'Could not load file or assembly 'Newtonsoft.Json, Version=18.104.22.168, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)'
The error is because Google.Core use the version of newtonsoft.json 12.0.3 and in my project i have the version 11.0.2.
When made the build in output i can see the next error:
NU1605: Detected package downgrade: Newtonsoft.Json from 12.0.3 to 11.0.2. Reference the package directly from the project to select a different version. MyProject -> Google.Apis.Oauth2.v2 22.214.171.1249 -> Google.Apis.Auth 1.48.0 -> Google.Apis.Core 1.48.0 -> Newtonsoft.Json (>= 12.0.3) MyProject -> Newtonsoft.Json (>= 11.0.2)
How should to fix this error?
User contributions licensed under CC BY-SA 3.0