fix(ci): use OIDC id-token for npm publish#39
Merged
Conversation
npm publish failed ENEEDAUTH on v0.4.0 — NPM_TOKEN is not usable and node 20's bundled npm is too old for Trusted Publisher OIDC. Update npm to latest and publish without NODE_AUTH_TOKEN (provenance disabled on the self-hosted Blacksmith runner), mirroring flowcore-sdk's fix. Also add workflow_dispatch so a failed publish can be retried from main, with the jsr step skipping versions that are already published. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MmTkzbSACo6PhBj9o1Sr8A
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.
v0.4.0 published to jsr but
npm publishfailed with ENEEDAUTH —NPM_TOKENisn't usable and node 20's bundled npm is too old for Trusted Publisher OIDC. Same failure mode flowcore-sdk hit; same fix (flowcore-io/flowcore-sdk#235):npm install -g npm@latestthennpm publish --access public --provenance=falsewith noNODE_AUTH_TOKEN(pure OIDC;id-token: writewas already set).workflow_dispatchso the failed 0.4.0 npm publish can be retried from main; the jsr step now skips already-published versions so the re-run doesn't fail there.Note: requires @flowcore/hono-api to have the GitHub Trusted Publisher configured on npmjs.com (repo flowcore-io/hono-api, workflow build.yml) — same setup as @flowcore/sdk.
🤖 Generated with Claude Code
https://claude.ai/code/session_01MmTkzbSACo6PhBj9o1Sr8A