json.net - Why is .Net trying to load the wrong version of Newtonsoft.Json? -


in project have following packages installed:

when program runs, throws exception

system.io.fileloadexception  not load file or assembly 'newtonsoft.json, version=10.0.0.0, culture=neutral, publickeytoken=30ad4fe6b2a6aeed' or 1 of dependencies. located assembly's manifest definition not match assembly reference. (exception hresult: 0x80131040)    @ jwt.serializers.jsonnetserializer.serialize(object obj)    @ jwt.jwtencoder.encode(idictionary`2 extraheaders, object payload, byte[] key)    ... 

why .net attempting load version of newtonsoft.json. jwt requires v6.0.4 or greater have satisfied. both of these packages installed , working before newtonsoft.json had v10. how runtime know v10 exists?

i solved immediate problem adding binding redirect down v9 find root of problem.

i ran update-package newtonsoft.json -reinstall , looked @ pending changes see if of projects had reference v10 couldn't find anything.

check .*csproj file right click -> unload project -> right click -> edit .*csproj in visual studio or open text editor.

some times save reference old version of package


Comments

Popular posts from this blog

node.js - Node js - Trying to send POST request, but it is not loading javascript content -

javascript - Replicate keyboard event with html button -

javascript - Web audio api 5.1 surround example not working in firefox -