I am trying to restore the missing nuget packages and it keeps giving me this Error:
An error occurred while trying to restore packages. Please try again.
Any experience solving this? How can I find out what exactly is causing the error?
Enable package restore by choosing Tools > Options > NuGet Package Manager. Under Package Restore options, select Allow NuGet to download missing packages. In Solution Explorer, right click the solution and select Restore NuGet Packages.
Menu Tools → Options → Package Manager Click OK. Drop your NuGet package files in that folder. Go to your Project in Solution Explorer, right click and select "Manage NuGet Packages". Select your new package source.
Put simply, a NuGet package is a single ZIP file with the . nupkg extension that contains compiled code (DLLs), other files related to that code, and a descriptive manifest that includes information like the package's version number.
This is how I fix my issue:
First, I clear my Package Cache:
Second, I make sure I have the right path source and click the available package source:
That should resolve the issue.
If you don't want the package, just double-click your packages.config, find the line which refers to the package you want to get rid of, and delete that line.
Then, if you do want the package you could probably just redownload it using nuget and it'd probably resolve itself.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With