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

How to discard error NETSDK1004 , and automate nuget restore on F5

$
0
0

I created vsix. It creates a .net core 3.1 project as output project. Now on F5, it is suppose to build, restore nuget packages and open the browser with output, But I get below error on F5,

Error NETSDK1004 Assets file 'C:\Users\v-dekot\source\repos\Template\Template1\Bot\obj\project.assets.json' not found. Run a NuGet package restore to generate this file.C:\Program Files\dotnet\sdk\3.1.300\Sdks\Microsoft.NET.Sdk\targets\Microsoft.PackageDependencyResolution.targets

Note : It works fine when I open the project next time when I open the solution. Why is it not working first time? I need to manually do "dotnet restore" to make it work for the first time as said here Assets file project.assets.json not found. Run a NuGet package restore. Can I automate it?

The similar issue is addressed here but no solution provided,https://developercommunity.visualstudio.com/content/problem/557306/nuget-restore-doesnt-work-the-first-time-but-the-s.html


Viewing all articles
Browse latest Browse all 3116

Trending Articles



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