Closed Miaopus closed 1 year ago
When I import PlasticSCM to my project with srcnalt.openAI-Unity, it caused the bug that "The type 'JsonSerializerSettings' exists in both 'Newtonsoft.Json.Net20, Version=3.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' and 'Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed'"
Hi @Miaopus, does this also happen when you run or build the project? This package contains com.unity.nuget.newtonsoft-json
version 3.0.2
as a dependency, maybe another package or the project itself has another version of newtonsoft in it and that is causing problem in PlasticSCM.
Yes, it happens when I open my unity project.
But actually, before I imported PlasticSCM, the project works well.
You can import PlasticSCM via Version Control
package of Unity, it comes as a dependency. I suppose you import it via a unity package which brings newtonsoft DLLs along with it and causes the issue. Or you can go to PlasticSCM folder where youimported it and remove newtonsoft related libraries.
Here is the bug report in detail.
\Library/PackageCache/com.srcnalt.openai-unity@ef49d3baf3/Runtime/Configuration.cs(14,26): error CS0433: The type 'JsonSerializerSettings' exists in both 'Newtonsoft.Json.Net20, Version=3.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' and 'Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed'
Library/PackageCache/com.srcnalt.openai-unity@ef49d3baf3/Runtime/OpenAIApi.cs(45,26): error CS0433: The type 'JsonSerializerSettings' exists in both 'Newtonsoft.Json.Net20, Version=3.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' and 'Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed'