Fix CI build: move pnpm overrides to pnpm-workspace.yaml (pnpm v10+) - #180
Merged
Merged
Conversation
pnpm v10+ no longer reads the pnpm.overrides field from package.json; it moved to pnpm-workspace.yaml (see https://pnpm.io/settings). The CI workflow installs pnpm@latest, so the frozen install failed with ERR_PNPM_LOCKFILE_CONFIG_MISMATCH because the effective overrides config no longer matched the lockfile. Moving the override to pnpm-workspace.yaml restores the match; the value is unchanged so pnpm-lock.yaml stays valid and no relock is needed.
Owner
|
lgtm |
Flake Review Results for #180Available systems: aarch64-darwin, aarch64-linux, armv6l-linux, armv7l-linux, i686-linux, powerpc64le-linux, riscv64-linux, x86_64-darwin, x86_64-freebsd, x86_64-linux 🔄 Modified (2)
Generated by flake-review |
This was referenced Jul 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The
[master] Releaseworkflow fails at Install dependencies with:Cause
pnpm v10+ no longer reads the
pnpm.overridesfield frompackage.json- it moved topnpm-workspace.yaml(https://pnpm.io/settings). The CI installspnpm@latestviapnpm/action-setup@v4and there is nopackageManagerpin, so the new pnpm ignores the override. The lockfile still recordsoverrides: { yaml@<1.10.3: '>=1.10.3' }, so the frozen install aborts with a config mismatch.Fix
Move the single override from
package.jsontopnpm-workspace.yaml. The value is unchanged, so it matches what the lockfile already records - no relock needed.Verification
Reproduced the failure on the current master commit with pnpm 10/11, then confirmed
CI=true pnpm install --frozen-lockfilecompletes with exit 0 after the change.