Skip to content

fix(release): wait for the npm tarball, not just its metadata - #84

Merged
psmyrdek merged 2 commits into
masterfrom
fix/release-tarball-wait
Oct 6, 2026
Merged

psmyrdek merged 2 commits into
masterfrom
fix/release-tarball-wait

Conversation

@psmyrdek

@psmyrdek psmyrdek commented Oct 6, 2026

Copy link
Copy Markdown
Collaborator

Summary

The 1.29.0 release (run 37431530565) failed in release / publish with Registry tarball unavailable, after npm publish had already succeeded. The metadata wait (#50, #69) polls with backoff, but the tarball download right after it made one attempt. npm completed 1.29.0's metadata ~45 s after publish, while the tarball 404'd for ~5 minutes (published 07:46:35, served 07:51:53). Binaries and the GitHub release were skipped until a manual rerun resumed (reason: resumed, no republish).

  • downloadTarball now polls: only a 404 means "not yet" (backoff 1 s → 15 s, unique ?t= query like the metadata poll). Any other status fails at once.
  • The metadata and tarball waits share one DEFAULT_WAIT budget (10 min) in both verify and the resume path, so the 20-minute job timeout still holds.
  • The deadline still ends in "never republish"; the fix(release): recover from an interrupted release without manual reruns #69 resume path remains the fallback.

None of the recent commits touched this path (#79 is test-only, #80 is PR-run cancellation); it's been a single fetch since #50.

Test plan

  • New tests: polls a 404 with unique URLs until served; stops at the deadline with "never republish"; fails once on a non-404
  • Deliberate break (every failed fetch final): tests/publish-npm-verify.test.ts 31 pass → 29 pass / 2 fail
  • Confirmed the npm tarball URL serves with a ?t= query (200)
  • bun test full suite (3 failing Stop-hook tests are the known local bash 3.2 failures), typecheck, lint

🤖 Generated with Claude Code

psmyrdek and others added 2 commits October 6, 2026 12:08
Run 37431530565 published 1.29.0 and saw complete metadata after ~45 s,
but its single tarball download got a 404: npm served the tarball about
five minutes after publish. The publish job failed, so no binaries or
GitHub release were made until a manual rerun resumed it.

downloadTarball now polls a 404 with the metadata wait's backoff and a
unique query, sharing one DEFAULT_WAIT budget with the metadata wait so
both stay inside the 20-minute job. Any other status fails at once, and
the deadline still ends in 'never republish'.

Deliberate break: treating every failed fetch as final turns
tests/publish-npm-verify.test.ts from 31 pass to 29 pass / 2 fail.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@psmyrdek
psmyrdek merged commit d93f453 into master Oct 6, 2026
8 checks passed
mkczarkowski added a commit that referenced this pull request Oct 6, 2026
Takes master's 1.30.0, already on npm; the stale 1.29.1 bump from the
prepare-version bot is dropped and the bot recomputes it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Mrk1nt2Ky21Thcv4PxrAzm
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