Can't install packages with NuGet - 500 internal server error

自古美人都是妖i 提交于 2019-12-30 06:50:57

问题


This makes no sense to me. NuGet was working fine before but now it is throwing a server error when I try to install packages. I've uninstall and reinstall NuGet with the latest, but still no luck.

PM> Install-Package EntityFramework
Install-Package : The remote server returned an error: (500) Internal Server Error.
At line:1 char:16
+ Install-Package <<<<  EntityFramework
    + CategoryInfo          : NotSpecified: (:) [Install-Package], WebException
    + FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PowerShell.Commands.InstallPackageCommand

Has anyone seen anything like this? Thanks.

I'm pointed at https://nuget.org/api/v2/ which seems to be live...


回答1:


From NuGetTeam (@nuget) on Twitter https://twitter.com/#!/nuget

We are investigating an issue on the NuGet Gallery servers. We will provide an update shortly. We apologize for the inconvenience.




回答2:


Happened to me too.

Try this:

  1. Run VS in admin mode.
  2. Uninstall NuGet from Tools->Extension Manager (Extensions and Updates in VS 2015)
  3. Delete everything in short %AppData%\NuGet or full-named C:\Users\[YourUsername]\AppData\Roaming\NuGet
  4. Reinstall NuGet



回答3:


Retry, it works now over here.




回答4:


Visual Studio has this error sometimes. Try restarting your visual studio (I have 2019). If it still doesn't fix, repair your VS installation. This is certainly for future viewers as I also had this problem and fixed by restarting VS



来源:https://stackoverflow.com/questions/10130333/cant-install-packages-with-nuget-500-internal-server-error

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!