Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CS8032: An instance of analyzer Roslynator.CSharp.Analysis.UnnecessaryRawStringLiteralAnalyzer cannot be created #1406

Closed
khellang opened this issue Feb 19, 2024 · 2 comments · Fixed by #1407
Assignees

Comments

@khellang
Copy link
Member

khellang commented Feb 19, 2024

Product and Version Used:

  • Roslynator.Analyzers 4.10.0
  • Visual Studio 2022 17.8.7

Steps to Reproduce:

We have a sln with two .NET 8, three .NET Standard 2.0 projects and a single non-SDK-based csproj, targeting .NET Framework 4.8. When updating Roslynator.Analyzers to version 4.10.0 in our Directory.Build.props file across the entire solution, we're now getting this build error for the .NET Framework project.

Actual Behavior:

Getting a build error:

CS8032: An instance of analyzer Roslynator.CSharp.Analysis.UnnecessaryRawStringLiteralAnalyzer cannot be created from E:\PackageCache\NuGet\roslynator.analyzers\4.10.0\analyzers\dotnet\roslyn4.7\cs\Roslynator.CSharp.Analyzers.dll : Could not load type 'Roslynator.CSharp.Analysis.UnnecessaryRawStringLiteralAnalyzer' from assembly 'Roslynator.CSharp.Analyzers, Version=4.10.0.0, Culture=neutral, PublicKeyToken=926ea54d246a765e'..

Expected Behavior:

No build error?

@josefpihrt
Copy link
Collaborator

@khellang Could you use nugets from PR and load it from local nuget to see if it helps?

@khellang
Copy link
Member Author

I can confirm that does indeed fix the error we're seeing, @josefpihrt. Thank you 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants