You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Enable pruning by setting <RestoreEnablePackagePruning>true</RestoreEnablePackagePruning>
dotnet restore --locked-mode
The missing package detection logic should be able to detect that a package was pruned, or at the minimum report that pruning has been enable and provide remediation.
Currently for a failure you can get something like:
error NU1004: The package reference NuGet.Commands version has changed from [6.9.1, ) to [6.8.1, ).The packages lock file is inconsistent with the project dependencies so restore can't be run in locked mode. Disable the RestoreLockedMode MSBuild property or pass an explicit --force-evaluate option to run restore to update the lock file.
We should be able to do something along the lines of
error NU1004: A new package reference was found System.Formats.Asn1 for the project target framework. This is due to package pruning being enabled .The packages lock file is inconsistent with the project dependencies so restore can't be run in locked mode. Disable the RestoreLockedMode MSBuild property or pass an explicit --force-evaluate option to run restore to update the lock file.
The text was updated successfully, but these errors were encountered:
Start with
dotnet restore --use-lock-file
<RestoreEnablePackagePruning>true</RestoreEnablePackagePruning>
dotnet restore --locked-mode
The missing package detection logic should be able to detect that a package was pruned, or at the minimum report that pruning has been enable and provide remediation.
Currently for a failure you can get something like:
We should be able to do something along the lines of
The text was updated successfully, but these errors were encountered: