c# - 无法在 VS Mac 上更新 asp.net 核心项目中的包
问题描述
执行 Project-> Update NuGet Packages 时出现以下错误。
为源“ https://api.nuget.org/v3-flatcontainer/buildbundlerminifier/index.json ”重试“FindPackagesByIdAsync” 。无法建立 SSL 连接,请参阅内部异常。无法将数据写入传输连接:套接字未连接。套接字未连接重试源“ https://api.nuget.org/v3-flatcontainer/microsoft.aspnetcore.all/index.json ”的“FindPackagesByIdAsync” 。无法建立 SSL 连接,请参阅内部异常。无法将数据写入传输连接:套接字未连接。套接字未连接 GET https://api.nuget.org/v3-flatcontainer/buildbundlerminifier/index.json GET https://api.nuget.org/v3-flatcontainer/microsoft.aspnetcore。无法从远程源“ https://api.nuget.org/v3-flatcontainer/microsoft.aspnetcore.all/index.json ” 检索有关“Microsoft.AspNetCore.All”的信息。
我尝试通过 Project->Manage NuGet Packages 添加包。但是得到同样的错误!
解决方案
刚刚想出了一个解决方法。
当我从 CLI 运行 #dotnet restore 时,它可以工作!
推荐阅读
- c++ - 执行 C++ 代码时快速且频繁地访问文件
- mysql - Laravel 在获得许多 count() 后返回错误最大准备语句
- vue.js - 如何在 for 循环中将背景颜色作为 Prop 传递?
- python - 训练后如何保存 MASK RCNN 模型?
- c++ - 将加密对象解密为 char[] for memcpy
- excel - 整列为空时如何退出for循环?
- excel - 在excel的“主页”选项卡下添加一个新按钮
- java - 关闭应用程序时如何保存活动状态?即“网络视图”
- mysql - 执行时的 SQL Case 表达式
- mongodb - 猫鼬 findByIdAndRemove 无法按预期工作