Skip to content

fix(ci): revert setup-node v5→v4 to fix npm publish 404 - #213

Merged
kokorolx merged 1 commit into
masterfrom
fix/release-setup-node-v4-revert
May 30, 2026
Merged

kokorolx merged 1 commit into
masterfrom
fix/release-setup-node-v4-revert

Conversation

@kokorolx

Copy link
Copy Markdown
Collaborator

Summary

PR #212 fixed the tag scheme but accidentally bumped actions/setup-node@v4 → @v5. With v5, npm 11.x auto-detects an OIDC trusted-publishing context even when only classic NPM_TOKEN auth is configured, and surfaces the failure as a misleading 404 from PUT /@nano-step%2fnano-brain.

Result: every CI publish since May 30 has failed at the npm-publish job — including the otherwise-correct v2026.5.3001 (binaries + GH release exist, only npm publish failed).

Evidence

Tag setup-node Result Notes
v2026.5.2902 @v4 ✅ published Last successful CI publish (May 29)
v2026.5.30.{1,2,3} @v5 ❌ 404 Broken tag scheme and v5
v2026.5.3001 @v5 ❌ 404 Tag scheme is correct, only v5 is the regression

Upstream issues confirming the regression:

Change

Surgical revert. always-auth: false is removed because it only existed to silence a v5-only deprecation warning.

-      - uses: actions/setup-node@v5
+      # Pinned to v4 — v5 breaks classic NPM_TOKEN publish with misleading 404
+      # via npm 11.x OIDC auto-detection (actions/setup-node#1551, npm/cli#8730).
+      - uses: actions/setup-node@v4
         with:
           node-version: 24
           registry-url: https://registry.npmjs.org
-          always-auth: false

Follow-up (manual, after merge)

  1. Delete tag + GitHub release v2026.5.3001 (binaries can stay or be re-uploaded by the workflow)
  2. Re-push tag v2026.5.3001 onto the new master HEAD
  3. release.yml re-fires with the v4 fix → npm publish should succeed
  4. Verify npm view @nano-step/[email protected] and npm view [email protected]

Validation

  • go build ./... — unaffected (workflow-only change)
  • Diff is 3 inserts, 2 deletes — surgical
  • Republish v2026.5.3001 succeeds (post-merge step)

Change type: infrastructure (CI). No new test required, validation is the next release.yml run.

PR #212 bumped setup-node@v4 → @v5 while fixing the tag scheme. With
setup-node@v5, npm 11.x auto-detects an OIDC trusted-publishing context
even when only classic NPM_TOKEN auth is configured, and surfaces the
result as a misleading 404 from PUT /@nano-step%2fnano-brain.

Evidence:
  - v2026.5.2902 (setup-node@v4) → published OK on May 29
  - v2026.5.30.1/.2/.3 (setup-node@v5) → 404 (broken tag scheme + v5)
  - v2026.5.3001 (setup-node@v5, valid tag) → still 404, tag is valid

Upstream issues confirming the regression:
  - actions/setup-node#1551 — v5 writes _authToken line that breaks OIDC
  - actions/setup-node#1445 — Trusted Publisher 404 with NODE_AUTH_TOKEN
  - npm/cli#8730        — npm 11.x OIDC publish surfaces as E404

Fix is the minimum diff: pin setup-node@v4, drop the always-auth: false
line (only needed for v5's deprecated warning), add a comment so the
next maintainer doesn't innocently bump it again.

Republish path (manual, follow-up):
  1. Delete tag + GitHub release for v2026.5.3001
  2. Re-push v2026.5.3001 onto the new master HEAD
  3. release.yml fires with the v4 fix → npm publish should succeed
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Note

Gemini is unable to generate a review for this pull request due to the file types involved not being currently supported.

@kokorolx
kokorolx merged commit 831ceb9 into master May 30, 2026
1 of 2 checks passed
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.

1 participant