Repository navigation
chore: migrate from yarn to pnpm - #1711
Closed
johnnyreilly wants to merge 2 commits into
Closed
johnnyreilly wants to merge 2 commits into
johnnyreilly wants to merge 2 commits into
Conversation
- replace yarn.lock with pnpm-lock.yaml (via `pnpm import`) and pin pnpm through `packageManager` - use the hoisted node linker at the root so karma can find its plugins and the test packs resolve shared deps as before - convert execution-test pack lockfiles and install them with pnpm (hoisted, except the pnpm pack, which keeps the symlinked layout) - replace `npm link` of testLib with a symlink script that leaves pnpm's node_modules alone - CI: add pnpm/action-setup, cache pnpm, swap yarn commands - update Dockerfile, devcontainer and docs Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- regenerate execution-test pack lockfiles so they resolve exactly the versions in their old yarn.lock: `pnpm import` had ignored them and resolved fresh, giving the react packs a second @types/react; also restores basic-happypack's lockfile, lost to the harness's git clean - install packs with auto-install-peers=false (yarn never installed peers; babel packs were pulling in webpack@3) and --frozen-lockfile - Windows: pin the pnpm store so setup-node's cache step finds it, as installs run on C: while the checkout is on D: - benchmark: import the base branch's yarn.lock when it has no pnpm-lock.yaml instead of resolving fresh, which pulled newer typings that break its build and tripped ERR_PNPM_IGNORED_BUILDS Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Benchmark (Ubuntu)
PR branch = |
Benchmark (Windows)
PR branch = |
Benchmark (macOS)
PR branch = |
Member
Author
|
Closed in favour of #1712 |
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.
Summary
Moves ts-loader's development tooling from yarn to pnpm. #1712 is the npm alternative, for comparison.
yarn.lockis replaced bypnpm-lock.yaml(converted withpnpm import; versions match yarn's), and pnpm is pinned through"packageManager": "pnpm@12.11.2".pnpm-workspace.yamlsetsnodeLinker: hoisted. Karma only findskarma-*plugins installed next to it, and the test packs resolve shared deps (webpack, babel presets) from the rootnode_modules.pnpm importignored the packs'yarn.lockfiles and resolved fresh, which gave the react packs a second@types/reactand failed CI. The pack lockfiles are therefore imported from chore: migrate from yarn to npm #1712'spackage-lock.jsonfiles, which were checked to resolve exactly the versions in eachyarn.lock. The same check passes here.run-tests.jsinstalls packs withpnpm install --ignore-workspace --frozen-lockfile, so any lockfile drift now fails loudly. Packs use the hoisted layout, because some git-track copies of theirfile:deps innode_modules.auto-install-peers=false: yarn never installed peers, and pnpm was pullingwebpack@3into the babel packs throughbabel-loader@7's peer range.strict-dep-buildsis off, because pnpm 12 otherwise fails on the skipped install scripts offsevents@1/core-js@2.pnpmpack keeps pnpm's defaults, since that's what it tests.npm link ./test/comparison-tests/testLibis replaced bytest/comparison-tests/link-test-lib.js, which just creates the symlink.npm linkwould rewrite pnpm'snode_modules.release.yml) runspnpm/action-setup@v6beforesetup-nodewithcache: pnpm, and yarn commands become pnpm commands.pnpm_config_store_dir=C:\pnpm-store. Installs run underC:\source\ts-loaderwhile the checkout is onD:, so setup-node's cache step was looking for the store on the wrong drive.yarn.lockwhen it has nopnpm-lock.yaml. Resolving fresh pulled newer typings that break main's build.Dockerfile, devcontainer,.vscode/settings.json,AGENTS.md,CONTRIBUTING.mdand the test-pack READMEs are updated.Not changed: the README's install instructions for ts-loader users (including Yarn PnP),
REFERENCES.md,examples/,CHANGELOG.md, and the yarn hint insrc/compilerSetup.ts.Testing
Run locally on macOS with Node 24:
pnpm buildandpnpm lintpass, andpnpm comparison-testspasses in full.pnpm execution-tests: 28/29 suites pass.3.6.0_projectReferencesToBeBuiltalso fails locally onmainwith yarn (karma temp-path issue on macOS), and it passes in CI.main, and the benchmark ran end to end.🤖 Generated with Claude Code