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

Analyzer references relative Nuget.packages path cause build failure #1602

Open
rcocks-hl opened this issue Sep 20, 2024 · 0 comments
Open

Comments

@rcocks-hl
Copy link

Describe the bug

After upgrading from an old non-SDK project to SDK project, the new project has <Analyzer> elements which refer via relative path to Nuget.packages.

However the upgrade also moves references to PackageReference format, which means that Nuget.packages is no longer populated with the analyzer package after the conversion of the last project.

This causes error messages when building with msbuild about the dll not being found:

CSC : error CS0006: Metadata file '..\..\NuGet.packages\SonarAnalyzer.CSharp.9.32.0.97167\analyzers\SonarAnalyzer.dll' could not be found

Further technical details

.Net framework (net48) project

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

No branches or pull requests

1 participant