无法解析远程名称:'api.nuget.org' [英] The remote name could not be resolved: 'api.nuget.org'

查看:46
本文介绍了无法解析远程名称:'api.nuget.org'的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 Visual Studio 2017 中使用包管理器控制台安装 Nuget 包时遇到问题.以下是错误的完整详细信息:

I am having problem installing a Nuget package using the Package Manager Console in Visual Studio 2017. The following if the full details of the error:

install-package : Unable to load the service index for source https://api.nuget.org/v3/index.json.
  An error occurred while sending the request.
  The remote name could not be resolved: 'api.nuget.org'
At line:1 char:1
+ install-package selenium.webdriver -version 3.0.0
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    + FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand

我已经在此处检查了每个 Nuget 服务器的状态,并且所有服务器似乎都可以正常运行.我也发现了类似的帖子,但大多数帖子都够老了.我什至尝试重置我的路由器,但还是一样.

I already checked the status of each Nuget servers here and all seem operational. I also found similar posts but most them are old enough. I even tried to reset my router but still the same.

希望有人帮助我.我已经通过电子邮件向他们的支持人员发送了电子邮件,但尚未收到回复.

Hope someone helps me. I already emailed their support but did not get a reply yet.

推荐答案

我前段时间遇到过这个问题,但还是想贴出原因来帮助别人.似乎错误详细信息是正确的:

I encountered this issue some time ago but I still want to post the reason to help others. It seems the error details were correct:

The remote name could not be resolved: 'api.nuget.org'

第二天我才发现当时我的互联网提供商遇到了问题.那天我再次尝试安装该软件包,它无需做任何调整即可工作.

I just found out the next day that my internet provider was having issues at that time. I tried installing the package again that day and it works without doing any adjustments.

这篇关于无法解析远程名称:'api.nuget.org'的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆