Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Package 'dotnet-sonarscanner 5.0.4' has a package type 'DotnetTool' that is not supported by project 'Project.xyz'

Error occured while installing dotnet-sonarscanner in .net core

There is a total of 6 projects in a solution. dotnet-sonarscanner package is only working in 4 of them. I am getting the following error that this package is not supported by the project 'project.xyz' All the projects have as netcoreapp3.1 but still, the package is supported in only 4 projects of mine in the solution.

like image 800
Bhavya Shah Avatar asked Oct 18 '25 06:10

Bhavya Shah


1 Answers

You cannot install tools package into a project.

They are not supposed to work like that. Refer to the troubleshooting guide.

If you try to install a NuGet package that is a regular NuGet package and not a .NET tool, you'll see an error similar to the following:

NU1212: Invalid project-package combination for . DotnetToolReference project style can only contain references of the DotnetTool type.

The reverse also applies.

like image 72
imps Avatar answered Oct 21 '25 03:10

imps



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!