Skip to content

fix(ci): upgrade npm publish jobs to Node.js LTS - #139

Merged
wyattjoh merged 2 commits into
mainfrom
fix/ci-release-node-lts
Apr 9, 2026
Merged

fix(ci): upgrade npm publish jobs to Node.js LTS#139
wyattjoh merged 2 commits into
mainfrom
fix/ci-release-node-lts

Conversation

@wyattjoh

@wyattjoh wyattjoh commented Apr 9, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Switch node-version from "22" to "lts/*" in both publish-npm and canary-publish-npm jobs
  • Remove the npm install -g npm@11 upgrade step (Node 24 LTS ships npm 11 already)

Why

node:22 resolved to Node 22.22.2, which ships with a broken bundled npm (missing promise-retry in its internal dependency tree). This caused the upgrade step to fail before any publishing could happen. Node 24 LTS (lts/*) does not have this issue and already includes npm 11.

Node 22.22.2 (the latest node:22 image) ships with a broken bundled npm
(missing promise-retry) that causes npm install -g npm@11 to fail before
publishing. Switch to lts/* so both publish-npm and canary-publish-npm
always run on the latest LTS (currently Node 24), which bundles npm 11
and no longer needs the manual upgrade step.
@wyattjoh

wyattjoh commented Apr 9, 2026

Copy link
Copy Markdown
Contributor Author

@coderabbitai

coderabbitai Bot commented Apr 9, 2026

Copy link
Copy Markdown

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 42c0927d-4aba-4e85-8a05-9a68d1ada584

📥 Commits

Reviewing files that changed from the base of the PR and between 1bfbec1 and e160dc0.

📒 Files selected for processing (1)
  • .github/workflows/snapshot.yml

📝 Walkthrough

Walkthrough

Updated GitHub Actions workflows to use node-version: "lts/*" instead of the pinned "22" in publish jobs across .github/workflows/release.yml and .github/workflows/snapshot.yml. Removed explicit npm upgrade steps (npm install -g npm@11) from the affected publish jobs. The workflows continue to use oven-sh/setup-bun@v2, run bun install --frozen-lockfile, and invoke the same bun run release / bun run release:canary / bun run release:snapshot publish commands.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title 'fix(ci): upgrade npm publish jobs to Node.js LTS' accurately describes the main changes in the pull request: switching Node.js version from 22 to LTS in publish jobs.
Description check ✅ Passed The description clearly explains the changes (switching node-version to 'lts/*' and removing npm upgrade step) and provides relevant context about the underlying issue with Node 22's bundled npm.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Comment @coderabbitai help to get the list of available commands and usage tips.

Same broken npm issue as release.yml — node:22 resolved to 22.22.2
with a broken bundled npm. Switch to lts/* and drop the manual upgrade
step, which Node 24 LTS makes unnecessary.
- uses: actions/setup-node@v6
with:
node-version: "22"
node-version: "lts/*"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't "lts/krypton" safer, since this will just resolve to whatever is the newest LTS, but eventually that will be Node 26 or whatever.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just to enable the npm publish flow, so getting the latest LTS version of that should be ok I'd think!

@wyattjoh
wyattjoh merged commit f9be436 into main Apr 9, 2026
6 checks passed
@wyattjoh
wyattjoh deleted the fix/ci-release-node-lts branch April 9, 2026 21:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants