Repository navigation
test: pin the e2e npm CLI install to an explicit major (#438) - #439
Merged
Merged
Conversation
Red phase. npm's latest dist-tag moved to 12.0.0 between the last green e2e run (2026-07-05) and 2026-07-09, and npm 12.0.0's bundle ships libnpmpublish (which requires the unscoped 'sigstore' package) with no unscoped sigstore on its resolution path — so e2e-fixture-job.yml's `npm install -g npm@latest` step now breaks every fixture publish on every PR with MODULE_NOT_FOUND, no commit to blame. The new workflow-contract test asserts the step installs an explicitly- majored, Trusted-Publishing-capable npm (npm@<major>, major >= 11) and never `npm@latest`. Expected red: both assertions fail against the current step. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx
Green phase. npm 12.0.0 (the current `latest`) ships a bundle whose libnpmpublish requires the unscoped 'sigstore' package with no such package on its resolution path, so every provenance publish dies at module load. Pinning the major keeps the Trusted-Publishing-capable CLI (TP landed in 11.5.1) while making an upstream release unable to change CI's npm without a reviewed version-bump commit here. skip-changelog: CI-harness-internal pin in the e2e fixture job; no consumer-observable surface. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx
Collaborator
Author
|
Red→green complete, fully green CI.
This PR unblocks every other PR's e2e suite (currently #437), so it should merge first; #437's branch then updates and its e2e reruns green. Generated by Claude Code |
skip-changelog: comment-only edit. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx
thekevinbot
enabled auto-merge (squash)
July 9, 2026 15:00
github-actions Bot
added a commit
that referenced
this pull request
Jul 9, 2026
test: pin the e2e npm CLI install to an explicit major (#438) (#439) * test: pin the e2e npm CLI install to an explicit major (#438) Red phase. npm's latest dist-tag moved to 12.0.0 between the last green e2e run (2026-07-05) and 2026-07-09, and npm 12.0.0's bundle ships libnpmpublish (which requires the unscoped 'sigstore' package) with no unscoped sigstore on its resolution path — so e2e-fixture-job.yml's `npm install -g npm@latest` step now breaks every fixture publish on every PR with MODULE_NOT_FOUND, no commit to blame. The new workflow-contract test asserts the step installs an explicitly- majored, Trusted-Publishing-capable npm (npm@<major>, major >= 11) and never `npm@latest`. Expected red: both assertions fail against the current step. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx * fix: pin the e2e npm CLI install to npm@11 (#438) Green phase. npm 12.0.0 (the current `latest`) ships a bundle whose libnpmpublish requires the unscoped 'sigstore' package with no such package on its resolution path, so every provenance publish dies at module load. Pinning the major keeps the Trusted-Publishing-capable CLI (TP landed in 11.5.1) while making an upstream release unable to change CI's npm without a reviewed version-bump commit here. skip-changelog: CI-harness-internal pin in the e2e fixture job; no consumer-observable surface. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx * chore: drop the npm-pin contract test; cite npm/cli#9722 in the pin comment A test asserting the literal text of a dependency pin restates the reviewed diff and taxes every future bump without guarding anything a review can't see. The pin itself stays; the upstream bug reference in the workflow comment now documents when to lift it. skip-changelog: CI-internal test removal, no consumer surface. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx * chore: date the npm pin's revisit (#440, 2026-08-09) skip-changelog: comment-only edit. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx --------- Co-authored-by: Claude <[email protected]>
github-actions Bot
added a commit
that referenced
this pull request
Jul 9, 2026
test: pin the e2e npm CLI install to an explicit major (#438) (#439) * test: pin the e2e npm CLI install to an explicit major (#438) Red phase. npm's latest dist-tag moved to 12.0.0 between the last green e2e run (2026-07-05) and 2026-07-09, and npm 12.0.0's bundle ships libnpmpublish (which requires the unscoped 'sigstore' package) with no unscoped sigstore on its resolution path — so e2e-fixture-job.yml's `npm install -g npm@latest` step now breaks every fixture publish on every PR with MODULE_NOT_FOUND, no commit to blame. The new workflow-contract test asserts the step installs an explicitly- majored, Trusted-Publishing-capable npm (npm@<major>, major >= 11) and never `npm@latest`. Expected red: both assertions fail against the current step. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx * fix: pin the e2e npm CLI install to npm@11 (#438) Green phase. npm 12.0.0 (the current `latest`) ships a bundle whose libnpmpublish requires the unscoped 'sigstore' package with no such package on its resolution path, so every provenance publish dies at module load. Pinning the major keeps the Trusted-Publishing-capable CLI (TP landed in 11.5.1) while making an upstream release unable to change CI's npm without a reviewed version-bump commit here. skip-changelog: CI-harness-internal pin in the e2e fixture job; no consumer-observable surface. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx * chore: drop the npm-pin contract test; cite npm/cli#9722 in the pin comment A test asserting the literal text of a dependency pin restates the reviewed diff and taxes every future bump without guarding anything a review can't see. The pin itself stays; the upstream bug reference in the workflow comment now documents when to lift it. skip-changelog: CI-internal test removal, no consumer surface. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx * chore: date the npm pin's revisit (#440, 2026-08-09) skip-changelog: comment-only edit. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx --------- Co-authored-by: Claude <[email protected]>
thekevinbot
added a commit
that referenced
this pull request
Jul 9, 2026
…ound-trip (#441) From the #439 retrospective: a one-line npm CLI pin (routing around the npm 12.0.0 sigstore bundle breakage, npm/cli#9722) arrived with a workflow-contract test asserting the pin's literal text and a full red/green two-push round-trip — ceremony disproportionate to a reviewed one-line dependency bump, cut in review. Two clarifications, keeping the core thrust intact: - Workflow-contract tests are earned: test/workflows/ guards invariants whose regression is silent in review and behavior-affecting in production (install fallback, missing env, race-dependent ordering) — never the literal text of a version pin, runner label, or timeout, where the diff review is the gate and the test is a standing tax. - The red/green skip clause names CI toolchain/dependency pins explicitly, including pins that fix an outage: the suite going green on the PR is the evidence. skip-changelog: agent-workflow docs, no consumer surface. Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx Co-authored-by: Claude <[email protected]>
github-actions Bot
added a commit
that referenced
this pull request
Jul 9, 2026
docs: workflow-contract tests are earned; CI pins skip the red-test round-trip (#441) From the #439 retrospective: a one-line npm CLI pin (routing around the npm 12.0.0 sigstore bundle breakage, npm/cli#9722) arrived with a workflow-contract test asserting the pin's literal text and a full red/green two-push round-trip — ceremony disproportionate to a reviewed one-line dependency bump, cut in review. Two clarifications, keeping the core thrust intact: - Workflow-contract tests are earned: test/workflows/ guards invariants whose regression is silent in review and behavior-affecting in production (install fallback, missing env, race-dependent ordering) — never the literal text of a version pin, runner label, or timeout, where the diff review is the gate and the test is a standing tax. - The red/green skip clause names CI toolchain/dependency pins explicitly, including pins that fix an outage: the suite going green on the PR is the evidence. skip-changelog: agent-workflow docs, no consumer surface. Claude-Session: https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx Co-authored-by: Claude <[email protected]>
thekevinbot
added a commit
that referenced
this pull request
Jul 16, 2026
npm 12.0.0's published bundle omitted libnpmpublish's unscoped `sigstore` dependency, so every `npm publish --provenance` in the e2e fixture job died at module load (npm/cli#9722). #438/#439 pinned `npm install -g npm@11` as a workaround, with #440 tracking the unpin. npm/cli#9740 fixed the packing bug and shipped in npm 12.0.1 (2026-07-10); the packed tarball again contains `node_modules/sigstore`. `latest` now resolves to 12.0.1. Verified locally with a fresh `npm install -g npm@latest` (→ 12.0.1) that `require.resolve('sigstore', { paths: [libnpmpublish/lib] })` resolves — the exact check that failed on 12.0.0. Kept as an explicit major (npm@12), never floating `npm@latest`, per the #438/#439 contract. The e2e fixture suite going green on this PR is the end-to-end verification. skip-changelog: CI-internal harness pin; no consumer surface Claude-Session: https://claude.ai/code/session_0131HkmhYCFEQCJ4wZcGWABJ Co-authored-by: Claude <[email protected]>
github-actions Bot
added a commit
that referenced
this pull request
Jul 16, 2026
ci: unpin e2e npm CLI from npm@11 to npm@12 (closes #440) (#535) npm 12.0.0's published bundle omitted libnpmpublish's unscoped `sigstore` dependency, so every `npm publish --provenance` in the e2e fixture job died at module load (npm/cli#9722). #438/#439 pinned `npm install -g npm@11` as a workaround, with #440 tracking the unpin. npm/cli#9740 fixed the packing bug and shipped in npm 12.0.1 (2026-07-10); the packed tarball again contains `node_modules/sigstore`. `latest` now resolves to 12.0.1. Verified locally with a fresh `npm install -g npm@latest` (→ 12.0.1) that `require.resolve('sigstore', { paths: [libnpmpublish/lib] })` resolves — the exact check that failed on 12.0.0. Kept as an explicit major (npm@12), never floating `npm@latest`, per the #438/#439 contract. The e2e fixture suite going green on this PR is the end-to-end verification. skip-changelog: CI-internal harness pin; no consumer surface Claude-Session: https://claude.ai/code/session_0131HkmhYCFEQCJ4wZcGWABJ Co-authored-by: Claude <[email protected]>
This branch was previously deployed
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.
Red phase for #438, per the red/green TDD workflow (test-only commit pushed alone; the one-line fix follows after red CI is witnessed).
The bug
Every e2e fixture
publishjob is red on every PR since npm'slatestdist-tag moved to 12.0.0 (between the last green e2e run on July 5 and today).e2e-fixture-job.yml's "Pin npm to a Trusted-Publishing-capable version" step runsnpm install -g npm@latest, and npm 12.0.0's published bundle shipslibnpmpublish— which declares andrequires the unscopedsigstorepackage — with no unscopedsigstoreon its resolution path (only@sigstore/*scoped packages and a nested copy underpacote/node_modules). Every provenance publish dies at module load:Reproduced outside CI with a fresh
npm install -g npm@latestand a failingrequire.resolve('sigstore', { paths: [<libnpmpublish>/lib] }). Full investigation in #438. The real consumer release path (release.yml/_matrix.yml) uses setup-node's bundled npm and is not exposed — this is CI-harness-only, but it blocks every PR, including #437.The contract this test pins
The step installs an explicitly-majored, Trusted-Publishing-capable npm (
npm install -g npm@<major>, major ≥ 11 — TP landed in 11.5.1) and never a floatingnpm@latest, so an upstream release can only change CI's npm via a reviewed version-bump commit. Same mutable-external failure class as #436's tag race: CI went red with no commit to blame.Expected red
unit (*)should fail on exactly the two assertions oftest/workflows/e2e-npm-pin.test.ts. Local run against this commit:(The e2e fixture jobs on this red commit will also fail — that's #438 itself, still unfixed at this commit.)
The follow-up green commit changes
npm@latest→npm@11ine2e-fixture-job.yml; the e2e suite going green on it is the end-to-end proof.Closes #438.
🤖 Generated with Claude Code
https://claude.ai/code/session_016dGfhcExpMzjQLnRU5aYyx
Generated by Claude Code