Repository navigation
fix(qa): prevent stale evidence after failed suite cleanup - #120632
vincentkoc wants to merge 2 commits into
Conversation
Punchcard-Session: amber-workshop-workshop-36
|
Codex review: found issues before merge. Reviewed August 15, 2026, 3:32 PM ET / 19:32 UTC. ClawSweeper reviewWhat this changesThe PR stages canonical QA evidence under an output-directory lock and publishes it only after planning, suite execution, cleanup, and profile-scorecard preparation succeed. Merge readiness⛔ Blocked by patch quality or review findings - 8 items remain Keep this protected maintainer PR open for human review: its lifecycle approach is coherent, but it reverses current direct-suite artifact semantics and bypasses the established secure atomic writer. Priority: P2 Review scores
Verification
How this fits togetherQA Lab writes flowchart LR
A[QA profile or suite command] --> B[Evidence lifecycle]
B --> C[Output directory lock]
C --> D[Suite runners and cleanup]
D --> E[Staged evidence]
E --> F[Canonical evidence]
D --> G[Reports and summaries]
Decision needed
Why: Current main deliberately preserves direct-suite artifacts on atomic-write failure, while this PR intentionally applies the opposite rule to all suite entrypoints; selecting one behavior is a maintainer-owned compatibility decision. Before merge
Findings
Agent review detailsSecurityNeeds attention: The new staged publication bypasses the current 0600 security-runtime artifact writer. PR surfaceSource +208, Tests +761, Config 0. Total +969 across 17 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Keep stale-evidence invalidation at the profile lifecycle owner, preserve direct-suite atomic artifact semantics, and retain the existing secure artifact writer for every published file. Do we have a high-confidence way to reproduce the issue? Yes, source-reproducible: current-main tests establish the direct-suite preservation and 0600 contracts, while the PR lifecycle deletes that artifact before every normal suite run. Is this the best way to solve the issue? No: the all-entrypoint lifecycle reverses a recent direct-suite compatibility and security contract; profile-scoped invalidation is the safer owner-boundary fix unless maintainers intentionally choose new global semantics. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against ab5b8b9a02c8. LabelsLabel justifications:
EvidenceSecurity concerns:
What I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (2 earlier review cycles) |
Punchcard-Session: amber-workshop-workshop-36
|
Closing as broadly superseded by #126407, merged as Those canonical owners now invalidate suite generations before execution, publish canonical evidence only after terminal cleanup, and replace artifacts atomically with The narrower remaining planning-before-invalidation defect is already owned by #120012. Reconstruct and prove that current-main repair there rather than reviving this branch. |
What Problem This Solves
Resolves a problem where QA suite runs could leave stale or prematurely published
qa-evidence.jsonafter planning, execution, profile scorecard finalization, or runner cleanup failed. Concurrent runs targeting the same output directory could also overwrite one another's evidence.This is a clean replacement for the earlier draft. It does not cherry-pick or derive from the stale implementation, and the earlier draft remains open until this replacement eventually lands.
Why This Change Was Made
QA evidence publication now has one internal lifecycle owner. It acquires a fail-fast lock keyed by the resolved output directory, invalidates stale canonical evidence, gives runners an invocation-unique staged target, holds ownership through retries and cleanup, attaches profile scorecards before publication, atomically renames staged evidence into place, and applies explicit discard/publish/release error precedence.
Reports and summaries remain direct diagnostic writes. Only canonical evidence is transactional, and no lifecycle controls were added to
QaSuiteRunParamsor public API barrels.User Impact
Operators can trust canonical QA evidence to represent a fully successful suite lifecycle. Failed planning, execution, cleanup, or profile finalization leaves canonical evidence absent; successful runs publish once after cleanup; same-output contention fails before mutation while different output directories remain concurrent.
Evidence
7ecdef6e2ed4c5d8007ac9a65c952b3af4eb07987b25193235756dd01b5e4e0700c2394489b99ceforigin/main:e6353d85ef3ac52ed33b1ed454c4c7f9ce88cc73bfd58873f07251600b998fbe30e1ead53a7772f0/varto/private/varin lock-path assertionsgit diff --check: passedgpt-5.6-sol, high): clean, no actionable findings, correctness confidence 0.96+274/-250(net+24); tests+615/-273(net+342); workflow+2/-2+445/-307(net+138); tests+962/-131(net+831); workflow+2/-2att_01KZHKR0YS93604CQRXSGWAETBatt_01KZHKT4PRNBG3RQRRY58Y8ND7No hosted CI, heavy QA profile, merge, issue close, or Punchcard finish was run for this checkpoint.
Provenance
PR #120012 is intentionally not closed by this draft and should remain open until a replacement lands.
Punchcard-Session: amber-workshop-workshop-36