-
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
Packages.lock.json different hashes on different machines #8604
Comments
That's strange. Thanks for the bug report. I have a question: Does this still happen if you upgrade Machine B to the same dotnet/nuget version as Machine A? |
I can check tomorrow, but as a sidetrack I tested to install SDK 2.2.108 on Machine A. I then created a global.json to select 2.2.108 for my project and ran
Even if I delete the global.json afterwards (or switch it to use 2.2.402), the hashes still remain the new ones, so it seems like the mere act of installing an SDK (or perhaps running a single install once) has caused the hashes to somehow be permanently changed. Also, I am on Windows, in case it matters |
This is possibly a duplicate of #7921. Could you try the steps in #7921 (comment) to see if that helps, as well? |
I followed the steps, and now it is working. Note that, contrary to what #7921 (comment) seems to say, Also, that issue is closed, but I think this issue should still be open. Needing to find these comments and adding secret .csproj properties is not a good experience, so my vote is that the issue needs to be fixed so it works by default. |
We run into the exact same issue, with different dependencies on every machine. |
I was able to resolve this by following the steps exactly as outlined in NuGet/Home #7921. Hope this helps! |
Yeah, already saw that entry. We have the exact same settings - no success. |
Closing as a duplicate of #7921. |
We have a very simple project, whose content looks like
As seen in the project, we have enabled a lock file.
Now to the problem: We have two machines, and neither of them can restore using the package.lock.json generated by the other due to content hash differences. When running
dotnet restore --force-evaluate
Machine A produces:On Machine B,
dotnet restore --force-evaluate
instead producesAs you can see, the content hashes for packages are different, although the versions are the same.
We have seen #7682, and we have cleared both
C:\Users\User\.nuget\packages
andC:\Program Files\dotnet\sdk\NuGetFallbackFolder
, as instructed in that issue. We also (as seen below) have NuGet versions later than 4.9.3 (which is the version where #7682 is fixed). And finally, we do not see all hashes changing, just the three mentioned above.Machine A info:
Machine B info:
Verbose Logs
The output from
dotnet restore --force-evaluate --verbosity diag
are attached as MachineA.txt and MachineB.txtMachineA.txt
MachineB.txt
The text was updated successfully, but these errors were encountered: