简体   繁体   中英

Missing Nuget packages error in ,NET core 3.1 app

I am using VS code and not Visual Studio to run my .NET core 3.1 web app.

I have a .NET core 3.1 app. As I am using an Client VDI machine ( It is using Win 7 SP1 operating system) which is blocking the Nuget.Org URL currently. so as a work around, I have copied over all the Nuget package into an folder in my VDI and updated the path in the Nuget.Config. But still I am getting below Missing Package" error. My App do not DIRECTLY depends on these packages.

在此处输入图像描述

following is my Nuget.Config file,

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <packageSources>
    <!-- add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" / -->
    <add key="nuget.org" value="C:\NugetPackageDownloadLocation" / >
  </packageSources>
</configuration>

any help will be appriciated.

I am using VS code and not Visual Studio to run my .NET core 3.1 web app.

I have a .NET core 3.1 app. As I am using an Client VDI machine ( It is using Win 7 SP1 operating system) which is blocking the Nuget.Org URL currently. so as a work around, I have copied over all the Nuget package into an folder in my VDI and updated the path in the Nuget.Config. But still I am getting below Missing Package" error. My App do not DIRECTLY depends on these packages.

在此处输入图像描述

following is my Nuget.Config file,

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <packageSources>
    <!-- add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" / -->
    <add key="nuget.org" value="C:\NugetPackageDownloadLocation" / >
  </packageSources>
</configuration>

any help will be appriciated.

Have you tried adding a package source via the CLI? Given how .NET Core handles transitive dependencies getting all the packages required for a relatively complex solution might be tricky.

nuget sources Add -Name "MyServer" -Source \\myserver\packages

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM