Skip to content

fix(release): avoid npm publish timeout on prior beta selector - #124080

Merged
steipete merged 2 commits into
mainfrom
steipete/happy-swartz-bc1297
Aug 15, 2026
Merged

steipete merged 2 commits into
mainfrom
steipete/happy-swartz-bc1297

Conversation

@steipete

@steipete steipete commented Aug 15, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes an issue where publishing a prepared beta release could time out while validating the current npm selector. During v2026.8.1-beta.2, the publish job's shallow release-tag checkout attempted to fetch v2026.8.1-beta.1 and exhausted the 120-second fetch timeout, even though the trusted workflow checkout already contained all tags.

Incident evidence: https://github.com/openclaw/openclaw/actions/runs/31866304845/job/94967932650

Why This Change Was Made

The publish-time npm selector recheck remains fail-closed, but its tag commit is now resolved from the existing trusted full-history checkout. This removes the redundant network fetch from the frozen release checkout while preserving the immutable manifest, release SHA, dist-tag, tarball digest, Plugin SDK evidence, acknowledgement, and trusted-workflow SHA checks.

Exact-head CI also exposed two merge-gate failures: this PR's new source-order assertion needed an explicit workflow-script type guard, and current main had two shadowed diagnostic catch bindings in the Control UI E2E helper. Both are repaired without changing runtime behavior.

User Impact

Release operators can publish prepared beta candidates without a redundant prior-selector tag fetch blocking the core npm publish path. Candidate evidence and provenance enforcement are unchanged.

Evidence

  • Before fix: the focused regression failed with the selector still resolved from the release checkout; the observed workflow run exited 124 after 120 seconds fetching v2026.8.1-beta.1.
  • node scripts/run-vitest.mjs test/scripts/openclaw-npm-extended-stable-workflow.test.ts — 14 passed.
  • node scripts/run-vitest.mjs test/scripts/ci-workflow-guards.test.ts test/scripts/package-acceptance-workflow.test.ts — 310 passed, 2 skipped.
  • node scripts/run-tsgo.mjs -p test/tsconfig/tsconfig.test.root.json --incremental --tsBuildInfoFile /tmp/openclaw-pr-124080-lead-test-root.tsbuildinfo — passed.
  • node scripts/run-oxlint.mjs ui/src/test-helpers/control-ui-e2e.ts — passed.
  • node scripts/check-changed.mjs --dry-run -- .github/workflows/openclaw-npm-release.yml test/scripts/openclaw-npm-extended-stable-workflow.test.ts — lanes testRoot, tooling.
  • node_modules/.bin/oxfmt --check test/scripts/openclaw-npm-extended-stable-workflow.test.ts — clean.
  • git diff --check — clean.
  • Codex autoreview (--mode branch --base origin/main) — no accepted/actionable findings.

AI-assisted: yes.

@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 self-assigned this Aug 15, 2026
@steipete
steipete marked this pull request as ready for review August 15, 2026 07:14
@steipete
steipete requested a review from a team as a code owner August 15, 2026 07:14
@openclaw-barnacle openclaw-barnacle Bot added size: XS maintainer Maintainer-authored PR labels Aug 15, 2026
@clawsweeper clawsweeper Bot added merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Aug 15, 2026
@clawsweeper

clawsweeper Bot commented Aug 15, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 15, 2026, 3:48 AM ET / 07:48 UTC.

ClawSweeper review

What this changes

The branch resolves the npm selector tag from the trusted full-history checkout, updates its workflow guard, and carries a no-shadow Control UI test-helper cleanup already present on current main.

Regression provenance

Possible regression — probable (reviewed change; failure trace). No predecessor PR is attributed.

Merge readiness

⚠️ Ready for maintainer review - 3 items remain

Keep open for the protected maintainer release-path decision. Current main still performs the timed tag fetch; the PR removes that dependency while retaining the provenance verifier inputs.

Priority: P2
Reviewed head: 6b74099bc5c154c212fac1ac19a900af07ecb13a
Owner decision: Required. See Decision needed.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The implementation is focused and preserves the verifier boundary, but no post-fix production publish can be safely exercised from the PR.
Proof confidence 🦐 gold shrimp (3/6) Not applicable: This maintainer-authored release-workflow PR is exempt from the external-contributor proof gate; its body supplies an observed failed job and focused after-fix regression evidence, while the next beta remains the production confirmation.
Patch quality 🦞 diamond lobster (5/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This maintainer-authored release-workflow PR is exempt from the external-contributor proof gate; its body supplies an observed failed job and focused after-fix regression evidence, while the next beta remains the production confirmation.
Evidence reviewed 7 items Current-main failure path: Current main still resolves the selector from the shallow release checkout and conditionally performs the 120-second tag fetch.
Head repair preserves the validation boundary: The PR resolves the same selector ref from trusted-workflow and passes its SHA, target ref, workflow SHA, and immutable evidence to the existing verifier.
Trusted checkout contract: The trusted verifier checkout already requests fetch-depth: 0, while the frozen release checkout deliberately uses depth 1 for real publishes.
Findings None None.
Security None None.

How this fits together

The npm release workflow validates a prepared tarball against npm’s current selector before publication. It combines the frozen release checkout, immutable preflight evidence, and trusted workflow tooling to decide whether publishing may proceed.

flowchart LR
  A[Prepared release] --> B[NPM dist-tag lookup]
  B --> C[Trusted full-history checkout]
  D[Frozen release checkout] --> E[Provenance validator]
  C --> E
  E --> F[NPM publish]
Loading

Decision needed

Question Recommendation
Should this release-path repair land with the observed timeout, focused regression, and exact-head CI as evidence, accepting the next beta publish as the first production confirmation? Land with publish follow-up: Accept the bounded release-path risk and record the next beta publish’s selector-validation result.

Why: A disposable end-to-end rehearsal could publish to npm, so the remaining evidence cannot be obtained safely through ordinary PR validation.

Before merge

  • Resolve merge risk (P1) - The first beta publish after merge is the only real production rehearsal; selector resolution now depends on the existing trusted checkout retaining its full-history tag contract.
  • Complete next step (P2) - The protected maintainer release workflow needs an explicit acceptance of the remaining production-only validation gap; no repair job is needed.
Agent review details

Security

None.

PR surface

Source 0, Tests +15, Config -4. Total +11 across 3 files.

View PR surface stats
Area Files Added Removed Net
Source 1 4 4 0
Tests 1 23 8 +15
Docs 0 0 0 0
Config 1 1 5 -4
Generated 0 0 0 0
Other 0 0 0 0
Total 3 28 17 +11

Review metrics

Metric Value Why it matters
Production vs test delta workflow +1/-5; tests +23/-8; test support +4/-4 The release-path change is net-negative while adding a focused workflow contract assertion; the UI helper edit is behavior-neutral and already matches current main.

Merge-risk options

Maintainer options:

  1. Land with production follow-up (recommended)
    The existing full-history trusted checkout and focused guard support landing; capture the next beta publish result as the final operational proof.

Technical review

Best possible solution:

Land the focused release repair only with explicit acceptance of the production-validation gap, retain the trusted checkout’s full-history setting, and record the next beta publish outcome.

Do we have a high-confidence way to reproduce the issue?

Yes in source: current main fetches a missing prior selector tag from the frozen release checkout; the reported timeout is the matching production path. A new publish was not run because it could perform a real npm publication.

Is this the best way to solve the issue?

Yes. Resolving the tag from the existing full-history trusted checkout removes only the redundant fetch while preserving the verifier’s fail-closed selector, evidence, and workflow-SHA checks.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 49e1ea2c9f08.

Labels

Label changes:

  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🦞 diamond lobster.
  • remove rating: 🐚 platinum hermit: Current PR rating is rating: 🦐 gold shrimp, so this older rating label is no longer current.

Label justifications:

  • P2: This repairs a bounded npm release-operator timeout without an active runtime outage.
  • merge-risk: 🚨 automation: The patch changes the checkout used by the npm publication workflow’s provenance gate.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🦞 diamond lobster.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This maintainer-authored release-workflow PR is exempt from the external-contributor proof gate; its body supplies an observed failed job and focused after-fix regression evidence, while the next beta remains the production confirmation.

Evidence

What I checked:

Likely related people:

  • steipete: Blame attributes the current selector-fetch path to this contributor, who also authored the proposed repair. (role: recent release-workflow contributor; confidence: high; commits: e530b58b44b8, ae8cb296b6f7; files: .github/workflows/openclaw-npm-release.yml, test/scripts/openclaw-npm-extended-stable-workflow.test.ts)
  • obviyus: Recent history attributes the Plugin SDK API evidence refactor that owns the preserved selector invariant to this contributor. (role: validator refactor contributor; confidence: medium; commits: d2afbd05ad0f; files: scripts/plugin-sdk-api-release-evidence.mjs, test/scripts/plugin-sdk-api-release-evidence.test.ts)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Record a redacted selector-validation result from the next beta publish.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (1 earlier review cycle)
  • reviewed 2026-08-15T07:21:04.280Z sha 6c8620907e820eca589ad1d2cc5cc63779964537 :: needs maintainer review before merge. :: none

@steipete
steipete force-pushed the steipete/happy-swartz-bc1297 branch from 6c86209 to 6b74099 Compare August 15, 2026 07:38
@openclaw-barnacle openclaw-barnacle Bot added the app: web-ui App: web-ui label Aug 15, 2026
@steipete

Copy link
Copy Markdown
Contributor Author

Land-ready review completed on exact head 6b74099bc5c154c212fac1ac19a900af07ecb13a.

Root cause: publish provenance resolved the live npm selector from the shallow release-tag checkout, so a missing prior beta tag triggered a redundant 120-second fetch even though trusted-workflow had already fetched full history and tags. The fix resolves that commit from trusted-workflow and leaves the immutable manifest/evidence comparison plus every provenance verifier argument intact.

Proof:

  • Pre-fix focused regression failed on the release-checkout selector resolution path.
  • node scripts/run-vitest.mjs test/scripts/openclaw-npm-extended-stable-workflow.test.ts — 14 passed.
  • node scripts/run-vitest.mjs test/scripts/ci-workflow-guards.test.ts test/scripts/package-acceptance-workflow.test.ts — 310 passed, 2 skipped.
  • node scripts/run-tsgo.mjs -p test/tsconfig/tsconfig.test.root.json --incremental --tsBuildInfoFile /tmp/openclaw-pr-124080-lead-test-root.tsbuildinfo — passed.
  • node scripts/run-oxlint.mjs ui/src/test-helpers/control-ui-e2e.ts — passed.
  • git diff --check — passed.
  • Fresh Codex autoreview on the rebased branch — no accepted/actionable findings.
  • Exact-head CI: https://github.com/openclaw/openclaw/actions/runs/31872484933 — green.

ClawSweeper rank-up move: a disposable publish-job rehearsal was not run because exercising this exact step requires the real publish path and could reach npm publication. The safe substitute is the observed production failure, the pre-fix/post-fix workflow regression, direct inspection of the pinned checkout contract, and green exact-head CI. This gap is accepted for landing; production confirmation will occur on the next beta publish.

The exact-head CI repair also includes the minimal current-main no-shadow fix that was failing the merge gate; no runtime behavior changes.

@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. and removed rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. labels Aug 15, 2026
@steipete
steipete merged commit 55adb60 into main Aug 15, 2026
180 checks passed
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

@steipete
steipete deleted the steipete/happy-swartz-bc1297 branch August 15, 2026 07:56
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 16, 2026
…law#124080)

* fix(release): avoid prior beta selector fetch timeout

* fix(ci): repair test typecheck and UI lint
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui maintainer Maintainer-authored PR merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. P2 Normal backlog priority with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: XS status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant