Reputation: 861
We have a Yarn-based monorepo with the latest Yarn version 3.2.0. We are getting yarn install
failures with zero debug logs on our GitHub Workflow:
Run yarn install
➤ YN0000: ┌ Resolution step
Resolution step
➤ YN0000: └ Completed in 1s
➤ YN0000: ┌ Post-resolution validation
Post-resolution validation
➤ YN0000: └ Completed in 0s 226ms
➤ YN0000: Failed with errors in 1s 236ms
This happens when most of our team generates the yarn.lock
file, except one team member is able to generate a working yarn.lock
that works in the Workflow. The strange part is he is running a very similar setup to most other devs (MBP, Node 16).
Any idea what could be causing this and how we can find out more information?
Upvotes: 7
Views: 9513
Reputation: 1446
To resolve this issue, upgrade Yarn to version 3.2.4
or later.
Background:
There were a couple of issues in older versions of Yarn 3 that caused the checksum check to fail — upgrading will resolve this issue.
Upvotes: 4
Reputation: 323
By default, Yarn will throw an exception on yarn install
if it detects that a package doesn't match the checksum stored within the lockfile. To fix:
.yarnrc.yml
.checksumBehavior: "update"
Upvotes: 8