Skip to content

Release 1.20.1: publish to npm with trusted publishing - #58

Merged
sagnik11 merged 1 commit into
mainfrom
ci/npm-trusted-publishing
Nov 15, 2026
Merged

sagnik11 merged 1 commit into
mainfrom
ci/npm-trusted-publishing

Conversation

@sagnik11

@sagnik11 sagnik11 commented Nov 15, 2026 •

Copy link
Copy Markdown
Member

Why

The release workflow publishes with an NPM_TOKEN secret. npm caps publish tokens' lifetime and is restricting tokens that bypass 2FA for direct publishing, so the next expiry would block a Runtime release the way it blocked CLI 3.10.0 on npm. The CLI moved to trusted publishing in Autter-dev/autter-cli#106 and published 3.10.1 that way.

What changes

  • release.yml authenticates with npm trusted publishing (OIDC). The token-check step, registry-url and NODE_AUTH_TOKEN are removed; npm install -g npm@11 runs before the publish loop (trusted publishing needs npm 11.5.1+, Node 22 ships npm 10). It already ran on ubuntu-latest with id-token: write.
  • Patch bump of all six public packages, no code changes, so each publishes once through its new trusted publisher. npm drops a trusted publisher that isn't used within 2 days, and the loop skips unchanged versions: runtime-browser 1.8.2, runtime-node 1.16.1, runtime-edge 1.4.3, runtime-next 1.11.1, runtime-cli 1.4.1, otlp-ingester 1.18.1.
  • docs/RELEASING.md describes the per-package setup instead of the token.

Order (do not tag before step 1)

  1. On npmjs.com, add a trusted publisher to each of the six packages: GitHub Actions, Autter-dev / autter-runtime, workflow release.yml, no environment, Allow npm publish ticked.
  2. Merge this PR. The otlp-ingester version change redeploys the hosted ingester with the same code, reporting 1.18.1.
  3. Tag v1.20.1; the Release workflow publishes all six.
  4. Then set each package to "Require two-factor authentication and disallow bypass 2fa tokens" and delete the NPM_TOKEN secret.

🤖 Generated with Claude Code


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

The release workflow authenticated with an NPM_TOKEN secret, which expires.
It now uses npm trusted publishing (OIDC): each package's settings on
npmjs.com trust Autter-dev/autter-runtime's release.yml, so no token is
stored. The token check step, registry-url and NODE_AUTH_TOKEN are gone;
npm is updated to 11 (trusted publishing needs 11.5.1 or newer) before the
publish loop.

Every public package gets a patch bump with no code changes, so each one
publishes through its new trusted publisher within npm's 2-day window:
runtime-browser 1.8.2, runtime-node 1.16.1, runtime-edge 1.4.3,
runtime-next 1.11.1, runtime-cli 1.4.1, otlp-ingester 1.18.1.
docs/RELEASING.md describes the one-time setup per package.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@sagnik11
sagnik11 merged commit 1a89c77 into main Nov 15, 2026
18 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