I have created a basic template Class library (see image below) and added just one reference system.text.json (version 6.0.2) through manage nuggets
Created a Console application with the above Class library as reference. (basic template just added reference to the class library)
Is throws error starting version 6.0.2 and tested 6.0.3 and 6.0.4 as well same issue whenever this code is existing JsonSerializer.Deserialize
Am I missing prerequisite reference to make this work ? Have tried the binding redirect with no success either. Please Advise
Below are the version of the framework used
You need to upgrade "system.text.json" version in console application. Root cause : In class library some of the reference have dependency with "system.text.json" versions that you have in class library project but not console application.