I have a Visual Studio 2015 C# project consuming packages from NuGet. The solution contains several C# projects and is checked out on drive C.
Problem: I cannot compile the solution or restore nuget packages since several hours. I get the following error:
NuGet Package restore failed for project ...: The file or directory is corrupted and unreadable.
The Package Manager Console reports the following error after startup:
The file or directory is corrupted and unreadable.
Restarting Visual Studio does not fix the issue. Accessing the files with File Explorer and Notepad++ works. I don't experience any internet connectivity issues. Nuget seems to be online.
There is no private nuget registry in use, the default package source https://api.nuget.org/v3/index.json is used.
Visual Studio 2015 Professional 14.0.25431.01 Update 3 Package Manager Console Host Version 3.6.0.2511
VS 2015: C# NuGet Package restore failed. The file or directory is corrupted and unreadable
Please try the following troubleshootings to fix this issue:
\packages folder, then go to the solution in Visual Studio and press "Restore Nuget Packages", rebuild your solution.Hope this helps.
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