-
Notifications
You must be signed in to change notification settings - Fork 258
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Analyze the user gestures that defeat no-op, specifically clean-build & rebuild #6987
Comments
There's a couple of things going on here. NuGet has a caching mechanism to improve the performance of restore. Now on the second thing. In Visual Studio there are 3 ways to invoke restore.
This basically means that the slower performance of restore during rebuild is by design currently. Now normally I'd close this as by design, but this is useful feedback for whether we need the on Rebuild restore should defeat the restore noop. //cc @anangaur Useful feedback for the repeatable builds design. |
Thank you for clarifying the difference between Build and Rebuild, good to know! |
@alex-belikov |
@nkolev92 |
If you have scenarios where you consistently run into issues with incremental build, and you can provide a repro, I'd suggest filling an issue with MSBuild. The team there will be happy to help. |
Is this the same for those who do Clean, Build ? |
In Visual Studio, clean - build will have the same NuGet behavior as rebuild, meaning it will defeat the cache. This is not the case on the commandline (msbuild). |
perf triage: Assigning to @JonDouglas to understand whether we should be forcing a real restore upon rebuild. |
Context from @nkolev92
Analyze changing the user gestures that defeat no-op. Specifically the lack of a specific gesture to reevaluate the packages lock file and floating versions. Rebuild as a gesture seems counterintuitive.
The users probably never care about defeat no-op as gesture, rather think in terms of reevaluate floating or don't. They need a single way to force NuGet to throw away what it think it has and do it again (specifically, throw away cache file and reevaluate the assets file as necessary).
Original name: NuGet restore takes time on Rebuild when all packages are already restored
I have a solution with ASP.NET Core 2.0 proj, netstandard 2.0 lib, xamarin C# android app and several winforms projects. When I rebuild any of them I see "NuGet restore took 200ms-1.5seconds" in status bar. It happens even if all packages are already restored and package versions were not changed.
This issue has been moved from https://developercommunity.visualstudio.com/content/problem/261222/nuget-restore-takes-time-on-rebuild-when-all-packa.html
VSTS ticketId: 622567
These are the original issue comments:
(no comments)
These are the original issue solutions:
(no solutions)
The text was updated successfully, but these errors were encountered: