Repository navigation
fix(deps): dedupe yarn.lock to shrink installed size @W-24460137@ - #693
Merged
Merged
Conversation
Stale yarn.lock entries kept many ^7.x @babel ranges on older versions, so yarn nested a separate copy per dependent and npm shrinkwrap shipped that layout. Deduping cuts the installed plugin from 678 MB to 472 MB. CI now fails if yarn.lock has duplicates again. typescript is excluded: dedupe bumps the dev-only 5.5.4 to 5.9.3, which breaks type-checking of @inquirer/select imports. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…24460137@ The previous yarn.lock was rewritten by npm during local packing (npmjs URLs without hashes, invalid peer entries). Regenerated from main with yarn-deduplicate. yarn-deduplicate is now a devDependency so CI uses the locked version: - yarn dedupe-lockfile: fix duplicates - yarn dedupe-lockfile:check: CI guard Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
rax-it
marked this pull request as ready for review
October 9, 2026 20:03
Dependabot doesn't run yarn-deduplicate, so its PRs would fail dedupe-lockfile:check. This workflow dedupes the PR's yarn.lock and pushes it back with the bot token so CI reruns. It uses pull_request_target and only runs tooling from the base checkout. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
wjhsf
approved these changes
Oct 9, 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.
@W-24460137@
Problem
sf plugins installinstalls this JIT plugin from itsnpm-shrinkwrap.json.sf-prepackgenerates that shrinkwrap from the yarnnode_moduleslayout, so yarn.lock duplicates ship to users.yarn.lockhad never been deduped.^7.x@babel/*ranges were split across 7.28.5, 7.28.6 and 7.29.8, and yarn v1 nests a separate copy for each dependent that can't use the hoisted version. The result was 44 copies of@babel/typesand 34 of@babel/parser.Fix
yarn.lockwithyarn-deduplicate, excludingtypescript.typescriptis excluded because deduping bumps the dev-only 5.5.4 to 5.9.3, which breaks type-checking.yarn-deduplicateas a devDependency, with scriptsyarn dedupe-lockfile(fix) andyarn dedupe-lockfile:check(CI guard incheck-versions).dependabot-dedupeworkflow dedupesyarn.lockon Dependabot PRs and pushes the fix back. It usespull_request_targetand runs only base-branch code.Result
Installed size, with the shrinkwrap honored (as in
sf plugins install):@babel/typescopiesThe remaining
@babelduplication comes from exact pins in the LWC compilers and needs upstream changes.Testing
yarn buildandyarn testpass after a clean install.🤖 Generated with Claude Code