Skip to content

fix: serialize multi-semantic-release init to avoid flaky release failures#1364

Merged
ffflorian merged 2 commits into
mainfrom
claude/node-packages-ci-error-vegn6k
Jul 23, 2026
Merged

fix: serialize multi-semantic-release init to avoid flaky release failures#1364
ffflorian merged 2 commits into
mainfrom
claude/node-packages-ci-error-vegn6k

Conversation

@ffflorian

@ffflorian ffflorian commented Jul 23, 2026

Copy link
Copy Markdown
Owner

Problem

The Release on npm step failed on run 30022960959 with ENONPMTOKEN No npm token specified for electron-info and @ffflorian/jszip-cli.

The root cause is not a missing token or a code regression:

  • Every prior release run was green; this is the first failure, and the only release-tooling dependency change since then was top-level semantic-release 25.0.6 -> 25.0.8, which multi-semantic-release does not use (it bundles its own nested copy).
  • All packages are correctly configured for npm OIDC trusted publishing.
  • The two attempts of the same commit failed with different errors:
    • Attempt 1: git log ... --notes=refs/notes/semantic-release* exited 128 (Failed to read notes tree).
    • Attempt 2: ENONPMTOKEN for a subset of packages (their OIDC token exchange returned nothing).

Non-deterministic failures across re-runs point to a concurrency/throttling issue. multi-semantic-release runs every package's init/verifyConditions phase in parallel with no concurrency limit, so all ~15 packages fire their git tag/notes reads and npm OIDC token exchanges simultaneously. Under that burst the calls intermittently collide or get rate limited, and which packages fall over varies run to run.

Changes

  • release script: add --sequential-init. This is the built-in multi-semantic-release flag for exactly this case (its own comment: "Avoid hypothetical concurrent initialization collisions / throttling issues", Is it possible to add the --debug arg to be passed to semantic-release? dhoulb/multi-semantic-release#24). It serializes the init phase so each package initializes one at a time, so the git-notes reads and OIDC token exchanges no longer race or get throttled.
  • Workflow: grant issues: write to the release job. When a release does fail, @semantic-release/github's fail step tries to open a "release is failing" issue and was getting 403 Resource not accessible by integration because the job only had id-token + contents. This lets that notification be created instead of erroring.

Verification

The release step only runs on push to main (skipped on PRs), so the real confirmation is the next push to main, or re-running the failed job with these changes in place.

claude added 2 commits July 23, 2026 16:25
The release job runs with minimal permissions (id-token + contents). When
multi-semantic-release fails, @semantic-release/github's fail step tries to
open a "release is failing" issue and gets 403 Resource not accessible by
integration. Granting issues:write lets that notification be created.
… failures

multi-semantic-release runs every package's init/verifyConditions phase in
parallel with no concurrency limit, so all packages fire their git tag/notes
reads and npm OIDC token exchanges simultaneously. Under that load the
operations intermittently collide or get throttled: two consecutive attempts
of the same commit failed differently, one on 'git log --notes=refs/notes/
semantic-release*' (exit 128, failed to read notes tree) and one on the npm
OIDC token exchange (ENONPMTOKEN for a subset of packages), while every
package is correctly configured for trusted publishing.

--sequential-init serializes the init phase (dhoulb/multi-semantic-release#24),
letting each package initialize one at a time so the git and OIDC calls no
longer race or get rate limited.
@ffflorian ffflorian changed the title ci: grant issues:write so semantic-release can report release failures fix: serialize multi-semantic-release init to avoid flaky release failures Jul 23, 2026
@ffflorian
ffflorian merged commit 53ab3ad into main Jul 23, 2026
5 checks passed
@ffflorian
ffflorian deleted the claude/node-packages-ci-error-vegn6k branch July 23, 2026 19:04
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.

2 participants