Pin publish workflow to npm 11 to fix broken npm publishing#2903
Merged
Conversation
npm@latest moved to 12.0.0, which requires Node ^22.22.2 || ^24.15.0 || >=26; the publish job runs the .nvmrc-pinned Node v22.14.0, so 'npm install -g npm@latest' fails with EBADENGINE and every npm publish since July 10 has failed. Trusted Publishing only needs npm >= 11.5.1, so pin to major 11 (currently 11.18.0), which supports Node ^20.17.0 || >=22.9.0 — the exact configuration of the last successful publish. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Root cause
Every
Publish npm packagesrun since 2026-07-10 fails (last success: 2026-07-07, #2891). The failing step isnpm install -g npm@latest:Upstream npm released 12.0.0 to the
latestdist-tag between Jul 7 and Jul 10; it requires Node^22.22.2 || ^24.15.0 || >=26, but the workflow runs the.nvmrc-pinned Node v22.14.0 → EBADENGINE. Today's dependabot merges only triggered the master pushes that exposed this — the failure is upstream, and theirnpm ci+npm run buildsteps all passed on master.Fix
Pin the upgrade to
npm@11(currently 11.18.0):^20.17.0 || >=22.9.0, compatible with v22.14.0 ✓latestengine bumps.The alternative (bumping
.nvmrcto ≥ 22.22.2) touches every CI job and still leaves publishes exposed to the next npm engines change. (PR #2892 modernizes Node across the repo; when it lands it can revisit this pin.)Not fixed here (needs maintainer action)
Publish VS Code extensionfails for an unrelated reason: theVSCE_TOKENPersonal Access Token has expired ("Access Denied: The Personal Access Token used has expired"). A new Azure DevOps marketplace PAT needs to be generated and the repo secret updated — that cannot be fixed from a PR.Note: more dependabot lockfile PRs are still landing (2893, 2839); they don't affect this workflow-only change.
🤖 Generated with Claude Code