Repository navigation
ci: drop setup-node registry-url so npm uses OIDC trusted publishing - #8
Merged
Merged
Conversation
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.
Problem
Tag-triggered publish (attempts #1: run 39019347080, #2: run 39020017166 on tag v1.5.2) fails at the publish job with:
Provenance succeeds (sigstore logIndex published), so OIDC id-token works; auth is the failure.
Root cause
actions/setup-nodewithregistry-urlwrites intoRUNNER_TEMP/.npmrc:NODE_AUTH_TOKENis unset (trusted publishing), so that resolves to an empty token. npm prioritises this generated.npmrc, looks for a traditional_authToken, and skips the trusted-publisher OIDC handshake — the registry then answers 404.registry.npmjs.orgis the default registry, soregistry-urlis unnecessary.Fix
registry-urlfrom the publish job's setup-node step..npmrc, and whether the OIDC env vars are present.References
.npmrcprecedence skips OIDC even with empty token vars)Repo
created_atis 2026-05-20, so npm/cli#9969 (immutable OIDC subject claims for repos created after 2026-07-15) does not apply.