dotnet / roslyn

The Roslyn .NET compiler provides C# and Visual Basic languages with rich code analysis APIs.
https://docs.microsoft.com/dotnet/csharp/roslyn-sdk/
MIT License
18.71k stars 3.98k forks source link

An instance of analyzer System.Text.Json.SourceGeneration.JsonSourceGenerator cannot be created from C:\ Users\sacsharm\.nuget\packages\system.text.json\6.0.0\analyzers\dotnet\roslyn3.11\cs\System.Text.Json.SourceGeneration.dll #74252

Open ssachin872 opened 5 days ago

ssachin872 commented 5 days ago

Brief description: Getting this error while adding "Microsoft.Identity.ServiceEssentials.SDK" this package in project Describe your code style rule here.

Languages applicable:

Is your analyzer C# only? VB Only? Or Both?

Code example that the analyzer should report:

A small code snippet that describes a case that the analyzer should report.

Additional information:

Any more additional information you would like to add.

Documentation requirements:

When this analyzer is implemented, it must be documented by following the steps at Documentation for IDE CodeStyle analyzers.

ssachin872 commented 5 days ago

CSC : error CS8032: An instance of analyzer System.Text.Json.SourceGeneration.JsonSourceGenerator cannot be created from C:\ Users\sacsharm.nuget\packages\system.text.json\6.0.0\analyzers\dotnet\roslyn3.11\cs\System.Text.Json.SourceGeneration.dll : C ould not load file or assembly 'Microsoft.CodeAnalysis, Version=3.11.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.. [C:\SCOM\SystemCenter-SCOMMIService\src\Service\RestApi\ RestApi.Controllers\Microsoft.Scom.RestApi.Controllers.csproj]

Complete error is this