.Net Core 2
We're using the Nexus OSS repository to provider our internal packages using paket. When we're publishing a new package version and after that execute paket update the packet updates the package to the correct version (it properly see the newest version).
When we open the project in Visual Studio the package (library) is marked with an yellow triangle and the following error occurs in the console:
Error NU1102: Unable to find package X with version (>= 3.1.0.5989790)
I was trying the "paket clear-cache" and/or delete obj folder and it sometimes helps, but sometimes not :/
Create a package with a version 1.0
Install it in the project with paket.exe install
Create a package with a version 1.1
Update a package
The problem doesn't arise always :/
Package can bee seen in the Visual Studio project
Sometimes a package cannot bee seen by the Visual Studio
nuget locals http-cache -clear
dotnet restore ...
Best Regards,
MiloszeS
which VS version? latest paket is automatically deleting project.assets.json which should trigger MSBuild background restore. /cc @davkean
VS: 14.4.5
I've found a workaround:
nuget locals http-cache -clear
So it looks like http-cache in the nuget is out of sync for a while. We've noticed the problem mostly (I had the problem only with young packages, but my collegues don't remember which packages was problematic for them) for packages quite yound (deployed a few minutes before).
I've been hit by this multiple times. Thanks for the workaround @miloszes
To save some time for some. I had to do dotnet nuget locals http-cache --clear.
I have a build process that builds/packages/pushes a package that is used by the next solution. The restore on the second solution would fail because the new package was not found, and so the build would fail. Adding another task after the push that cleared the cache fixed it right up.
@miloszes Thank you very much!
Most helpful comment
VS: 14.4.5
I've found a workaround:
nuget locals http-cache -clear
So it looks like http-cache in the nuget is out of sync for a while. We've noticed the problem mostly (I had the problem only with young packages, but my collegues don't remember which packages was problematic for them) for packages quite yound (deployed a few minutes before).