Skip to content

fix(ci): release discovery tests fail as fixtures age - #137620

Closed
steipete wants to merge 1 commit into
mainfrom
codex/test-release-candidate-clock
Closed

steipete wants to merge 1 commit into
mainfrom
codex/test-release-candidate-clock

Conversation

@steipete

@steipete steipete commented Sep 3, 2026 •

Copy link
Copy Markdown
Contributor

Related: #137502, #137563.

Additional instructions

MUST: Keep Allow edits from maintainers enabled for this PR so maintainers can help update the branch when needed.

What Problem This Solves

Resolves a problem where release-discovery CLI tests started failing after their fixed artifact expiry approached the real date. On September 3 at 22:00 UTC, two scenarios stopped reaching their intended bounded-scan and missing-package branches because the fixtures had less than the required 14 hours remaining.

Why This Change Was Made

The five discovery CLI cases now share the unit tests' existing artifact clock. Their child process still advances with real elapsed time, preserving timeout and deadline behavior. Production expiry, provenance, and authorization checks are unchanged.

User Impact

CI continues testing release discovery as the calendar advances. This is a test-only repair with no application behavior change.

Evidence

The unchanged baseline reproduced both CI failures; the repaired complete owner file passes all 30 cases, including expiry, deadline, provenance, and sealed-artifact checks. The actual discovery CLI runs in each affected case. Formatting and diff checks pass. Production delta: zero; tests: +22/−12, net +10.

The local changed gate reached test-root typechecking but found unrelated dependency/API mismatches in the shared dependency checkout; no source workaround or dependency reconciliation was applied. Fresh exact-head CI (33814357153) has now passed its selected test and type gates. Its security audit alone timed out against the public bulk-advisory endpoint, with the aggregate gate failing downstream; landing waits for that service check to pass. Independent Codex review is scoped-clean with no accepted P0–P2 findings; the reviewer checked child-clock isolation and composition with the existing fetch preload.

ClawSweeper reviewed head 57d8b65513328307f7b16a4cbc6b42685c67c3b7 at 22:55 UTC and found no actionable findings or before-merge moves.

@clawsweeper

clawsweeper Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

@openclaw-barnacle openclaw-barnacle Bot added size: XS maintainer Maintainer-authored PR labels Sep 3, 2026
@clawsweeper clawsweeper Bot added P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. 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 Sep 3, 2026
@clawsweeper

clawsweeper Bot commented Sep 3, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed September 3, 2026, 7:19 PM ET / 23:19 UTC.

ClawSweeper review

What this changes

The PR preloads an advancing fixed clock into five release-discovery CLI test processes so expiring fixtures continue reaching their intended branches.

Merge readiness

✅ Ready for maintainer review

Keep open. Current main still leaves the CLI fixtures calendar-dependent, while this narrow test-only repair restores their intended coverage without changing release-discovery production behavior; no blocking correctness or security finding was found.

Priority: P3
Reviewed head: 57d8b65513328307f7b16a4cbc6b42685c67c3b7

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused, source-supported test repair with no actionable correctness or security concern.
Proof confidence 🌊 off-meta tidepool Not applicable: The changed owner is a test fixture that invokes the real discovery CLI; the repository-member PR is exempt from the external-contributor proof gate, and this read-only review did not execute code.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The changed owner is a test fixture that invokes the real discovery CLI; the repository-member PR is exempt from the external-contributor proof gate, and this read-only review did not execute code.
Evidence reviewed 5 items Current-main failure condition: Current main retains the fixed 2026-09-04 expiry fixture and starts the CLI cases without a clock preload; after the reported 2026-09-03 22:00 UTC threshold, it cannot satisfy the required remaining lifetime.
Expiry owner contract: Candidate selection rejects an artifact whose expiry is not more than 14 hours beyond its supplied clock, establishing why a real-date CLI fixture ages out.
Introduced repair: The PR writes a temporary preload that anchors Date.now to the fixture date while retaining elapsed wall time, then uses it for each affected child CLI invocation.
Findings None None.
Security None None.

How this fits together

Release discovery selects trusted release artifacts for release workflows. Its tests spawn the discovery CLI with fixture requests and verify expiry, provenance, bounded scanning, and sealed-artifact outcomes.

flowchart LR
  A[Fixture request] --> B[Discovery CLI child process]
  C[Advancing fixed clock] --> B
  B --> D[Artifact and provenance checks]
  D --> E[Candidate result]
  E --> F[CLI regression assertions]
Loading

Before merge

None.

Agent review details

Security

None.

PR surface

Tests +10. Total +10 across 1 file.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 1 22 12 +10
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 1 22 12 +10

Review metrics

Metric Value Why it matters
Production versus test delta production +0/-0; tests +22/-12 The entire introduced change is test harness code, so it cannot alter release-discovery runtime behavior.

Technical review

Best possible solution:

Retain the advancing fixture clock so the CLI cases keep exercising the 14-hour expiry contract without changing production discovery behavior.

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

Yes, source-reproducible: current main uses the real child-process clock with an expiry fixture that the discovery owner rejects inside its 14-hour window. This read-only review did not execute repository code.

Is this the best way to solve the issue?

Yes. A child-process preload is the narrowest maintainable repair because it stabilizes fixture time while preserving elapsed-time deadline behavior.

AGENTS.md: found and applied where relevant.

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

Labels

Label justifications:

  • P3: This is a focused test-only CI reliability repair with no production behavior change.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: The changed owner is a test fixture that invokes the real discovery CLI; the repository-member PR is exempt from the external-contributor proof gate, and this read-only review did not execute code.

Evidence

What I checked:

Likely related people:

  • Vincent Koc: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

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-09-03T22:55:09.509Z sha 57d8b65 :: needs maintainer review before merge. :: none

@steipete

steipete commented Sep 4, 2026

Copy link
Copy Markdown
Contributor Author

The fixture-clock defect is now fixed on main by #137633, commit 01c7675. Its five discovery CLI calls receive the fixture clock, while production expiry, trust, and deadline code remains unchanged.

Verified exact main 3d30b3accb235aec2b67eeca5feafc41ea0bc387 on an isolated Blacksmith Testbox: all 30 tests in test/scripts/full-release-candidate-reuse.test.ts pass, including both former failures and the expiry/deadline controls. All 17 checked source inputs matched before and after; the lease is stopped. Proof run.

Closing this duplicate repair as superseded. The elapsed-clock variant here is not needed to repair any remaining demonstrated failure. The separate npm audit timeout is handled by the subsequently landed #137716 and is not being waived.

@steipete steipete closed this Sep 4, 2026
@RomneyDa
RomneyDa deleted the codex/test-release-candidate-clock branch October 22, 2026 00:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintainer Maintainer-authored PR P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. 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