-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
What determines the resolution hash value? Seeing differences on CI vs locally for local package #4598
Comments
Can you provide a reproduction? |
I'm experiencing a similar issue.
Why are those hashes and checksums different just by running |
Came to ask this question too. I recently upgraded from yarn 1 to 3 and I'm running into this. I'm using yarn workspaces but not the PnP yet.
Things I've tried:
I'm at a loss! Anyone figure this out yet? I can remove the immutable flag and the build works but I'd like to get it back in there. |
It seems like your CI is using a different version of Yarn than what you're using locally, are you running |
@merceyz my local is
Looks like berry is 3.2.3. Should that be 'stable' instead? Or just set the specific version?
|
That will resolve to the latest version which at the time of writing is v3.2.4.
Ideally you would copy the CLI into the container but specifying the same version would also work. |
Setting the version explicitly fixed my issue, so thank you! As for copying the CLI, right now I'm doing this:
What would I need to copy the CLI? |
That should do it, I do something similar in my Dockerfile's combined with the following
|
Hi! 👋 It seems like this issue as been marked as probably resolved, or missing important information blocking its progression. As a result, it'll be closed in a few days unless a maintainer explicitly vouches for it. |
I have the same problem, but with 3.3.1 on local macOS and on Netlify. @RDIL @merceyz Looks like it was caused by .DS_Store files that are in .gitignore (well, globally defined in Reproduction is quite easy. Have a local package, open it in Finder, do some clicking like open folders in tree view and run |
Patches (created with In my case the whole |
With Yarn 3 there seem to be hash/checksum mismatches for the vendor libraries (opensans, angular 1.0.8) that are stored locally, presumably some issue with the git or file system permissions. Lowish risk as we don't produce official builds from Windows agents, and it's not such a common setup. Additionally, --immutable wasn't used with Yarn 1, so this is still a step forward. Perhaps related to yarnpkg/berry#5136 or yarnpkg/berry#4598 or yarnpkg/berry#2774
One workaround I found for this issue was to use
With this, yarn stops checking the checksum when you do a |
Discussed in #2605
Originally posted by ercgrat March 16, 2021
Created a package within a package to create a custom eslint plugin. Added it like so:
yarn add --dev ./eslint
. The resultingyarn.lock
entry contains a checksum. Whenyarn
is run on CI and on GitHub actions, there is no checksum and the hash value inresolution
is also different. What's accounting for this and can I control it? I realize creating a true repo and publishing this eslint package would be a workaround, but seems silly for a one-liner.The actual error I see is:
YN0028: │ The lockfile would have been modified by this install, which is explicitly forbidden.
These are the only two resources I have found that seem relevant:
yarnpkg/yarn#1916
https://stackoverflow.com/questions/49501749/is-it-possible-to-ignore-the-dependency-hash-validation-of-just-one-module-or-r
The text was updated successfully, but these errors were encountered: