Repository navigation
ci(renovate): dedupe the pnpm lockfile after updates - #441
Merged
Merged
Conversation
For lockfile-only updates Renovate runs `pnpm update --no-save ... --recursive`. That rewrites the importers' specifiers to the raw package.json ranges and drops the ones pnpm-workspace.yaml overrides (react, react-dom, @types/react, @sentry/bun), so `pnpm install --frozen-lockfile` fails in CI (#438). `pnpm dedupe` re-resolves with the overrides applied and also drops duplicates the update leaves behind. Prettier no longer formats pnpm-lock.yaml. lint-staged re-quoted it on every commit that touched it, so each Renovate PR rewrote the whole file back to pnpm's own style.
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
There was a problem hiding this comment.
✅ No new issues found.
Reviewed changes
Mode: standard. Both config changes look correct, and they target the two failure modes described for #438.
pnpmDedupepost-update option — Renovate now runspnpm dedupeafter updating the lockfile. Dedupe re-resolves the lockfile with thepnpm-workspace.yamloverrides applied, which fixes the override specifiers thatpnpm update --no-savedrops. Runningpnpm dedupe --checkagainst the currentmainlockfile shows only the duplicate collapses the description lists (es-toolkit,picomatch,tinyexec, plusyaml2.9.0 → 2.9.1). It shows no unexpected re-resolutions.pnpm-lock.yamlin.prettierignore— lint-staged runsprettier --write --ignore-unknownon every staged file, and Prettier 3 respects.prettierignoreeven for files passed to it by name. Human commits will no longer re-quote the lockfile, so Renovate PRs stop showing about 5k lines of quote churn.
Overall: ready to merge, with no findings that meet the admission rules. The committed lockfile on main is still in Prettier's double-quoted style. The first pnpm-native rewrite after this merges (most likely the rebased #438) will carry the requote diff once, and after that the churn stops.
claude-opus-5-5 | 𝕏
This was referenced Nov 4, 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.

Why
#438 (packages minor and patch) fails every CI job at
pnpm install --frozen-lockfile:For lockfile-only updates Renovate runs:
With pnpm 12.3.4 that
pnpm update --no-savecall writes the rawpackage.jsonranges back into the importers. It drops the specifiers that thepnpm-workspace.yamloverrides set (react,react-dom,@types/react,@types/react-dom,@sentry/bun), even for packages that are not being updated.Changes
.github/renovate.json:postUpdateOptions: ["pnpmDedupe"]. Renovate runspnpm dedupeafter it updates the lockfile. Dedupe re-resolves with the overrides applied and also drops the duplicates the update leaves behind..prettierignore: addpnpm-lock.yaml. The lint-stagedprettier --writehook re-quoted the lockfile ("instead of pnpm's') on every commit that touched it. Each Renovate PR then rewrote the whole file back, so chore(deps): update packages minor and patch dependencies #438 shows +2659/−5143 lines when the real change is about a dozen.Verification
Done locally from
mainwith pnpm 12.3.4, replaying #438's override bump and Renovate's two commands:pnpm update --no-save:pnpm install --frozen-lockfile --lockfile-onlyfails with the sameERR_PNPM_OUTDATED_LOCKFILEas CI. This reproduces the bug.pnpm dedupe: the frozen install passes. The result matches a plainpnpm install --lockfile-only, minus the now-unused duplicates ([email protected],[email protected],[email protected],[email protected]).renovate-config-validator --strict(renovate 44) passes.prettier --check pnpm-lock.yamlnow skips the file.Self-hosted Renovate reads its config from
main. After this merges, #438 needs a rebase via its checkbox (or the next run) so the branch is regenerated with dedupe.