PMF
PMF

Reputation: 17185

"The package does not support any target frameworks" for a package that is certainly ok

I'm getting this error on a custom package:

error NU1202: Das Paket MyCompany.Lib 24.5.4-alpha0000114 ist nicht mit net48 (.NETFramework,Version=v4.8) kompatibel. Das Paket MyCompany.Lib 24.5.4-alpha0000114 unterstützt keine Zielframeworks. [C:\....sln]

(The package does not support any target frameworks).

The error happens after I had to reinstall Windows and VS2019 (16.10.0) on this computer. The package and the build work just fine on all other computers and in CI and this version of the package is about two months old. I have attempted to delete the nuget cache several times (to rule out a download error), but no luck. NugetPackageExplorer is showing the package correctly as well.

This is the only package I'm seeing this error, although the project uses several hundred different packages. This package is one of the few that cross-target netcoreapp2.1 and net48, though.

Any ideas?

Upvotes: 1

Views: 2437

Answers (1)

PMF
PMF

Reputation: 17185

All good things come in threes, it seems. After deleting the nuget cache once more and making sure that all folders listed with

nuget locals all -list

are truly empty, the error is gone. It seems some cache metadata was corrupted.

Upvotes: 2

Related Questions