Skip to content

fix(release): preflight plugin npm trusted publishers - #124095

Merged
steipete merged 2 commits into
mainfrom
steipete/strange-lichterman-e656ce
Aug 15, 2026
Merged

steipete merged 2 commits into
mainfrom
steipete/strange-lichterman-e656ce

Conversation

@steipete

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes an issue where plugin release operators could select the existing-package OIDC route even when npm had no matching trusted-publisher configuration, causing the publish job to fail late with ENEEDAUTH. This happened for @openclaw/fish-audio-speech during the v2026.8.1-beta.2 release: https://github.com/openclaw/openclaw/actions/runs/31863860804/job/94962239580

Why This Change Was Made

The npm package has been configured for repository openclaw/openclaw, workflow plugin-npm-release.yml, environment npm-release, and publish permission. This PR adds a separate protected preflight subtype that requests the GitHub OIDC token, performs npm's package-specific token exchange, and immediately discards the returned npm token. It does not invoke npm publish, change dist-tags, or mutate a package version; the existing artifact-only preflight remains secretless and unchanged.

The live check is routed directly from validated package selection and runs once in the npm-release environment, rather than rebuilding or packing every selected plugin.

User Impact

Release operators can verify trusted-publisher configuration before the next plugin version is published. Missing or mismatched npm trust settings now fail in a safe, non-publishing workflow instead of during the release publish step.

Evidence

  • npm trusted-publisher record verified after repair: GitHub repository openclaw/openclaw, workflow plugin-npm-release.yml, environment npm-release, permission createPackage.
  • node scripts/run-vitest.mjs test/scripts/npm-trusted-publisher-preflight.test.ts test/scripts/plugin-npm-extended-stable-workflow.test.ts — 16 tests passed.
  • actionlint .github/workflows/plugin-npm-release.yml — passed.
  • node --check scripts/npm-trusted-publisher-preflight.mjs — passed.
  • node scripts/check-changed.mjs -- <touched files> — passed on Blacksmith Testbox: https://github.com/openclaw/openclaw/actions/runs/31872630706
  • git diff --check — passed.
  • Codex autoreview — no accepted/actionable findings.
  • Production/tooling LOC: +177/-5 (new non-publishing OIDC verification capability). Tests: +166/-0.

AI-assisted; reviewed and understood by the maintainer.

@clawsweeper

clawsweeper Bot commented Aug 15, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

@steipete
steipete marked this pull request as ready for review August 15, 2026 07:46
@openclaw-barnacle openclaw-barnacle Bot added scripts Repository scripts size: M maintainer Maintainer-authored PR labels Aug 15, 2026
@steipete
steipete merged commit 2c0de87 into main Aug 15, 2026
170 checks passed
@steipete
steipete deleted the steipete/strange-lichterman-e656ce branch August 15, 2026 08:05
@steipete

steipete commented Aug 15, 2026 •

Copy link
Copy Markdown
Contributor Author

Merged via squash.

  • Prepared head SHA: 6ed7e39a29407745fbc8550d5fdf1153d1aa58a3
  • Landed commit: 2c0de878c61f59cb1170870f7e5541c391c3609c
  • Post-merge OIDC proof: run 31873729062 verified the trusted-publisher exchange for @openclaw/fish-audio-speech on the landed commit. The publish, artifact-pack, and dist-tag jobs were skipped.
  • Registry state remained unchanged: versions 2026.7.2-beta.7 and 2026.8.1-beta.2; beta still points to 2026.8.1-beta.2; latest still points to 2026.7.2-beta.7; modified timestamp remained 2026-08-15T04:33:42.584Z.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintainer Maintainer-authored PR scripts Repository scripts size: M

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants