Quantcast
Channel: Active questions tagged nuget-package - Stack Overflow
Viewing all articles
Browse latest Browse all 3067

Visual Studio Code using wrong NuGet package when building

$
0
0

I am trying build a .NET app in Visual Studio Code (VS Code) and am getting this error:

Logic.csproj : error NU1301: Unable to load the service index for source https://pkgs.dev.azure.com/XXXX/_packaging/XXXnuget/nuget/v3/index.json. [C:\Logic.sln]

Where XXX is a previous client's NuGet package I want to ignore.

Trying dotnet nuget locals --clear all in the PowerShell terminal has no effect. Doing it on the command line does do something, but I still get a build failure in VS Code.

The only way I found to disable the NuGet package was to go to Visual Studio 2022 and turn off/uncheck the package in Tools -> Options -> Package Sources in an empty Visual Studio environment (no solution or project) and then go back and build in VS Code.

Is there a way to remove package sources in VS Code? How can I resolve the issue?


Viewing all articles
Browse latest Browse all 3067

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>