Repository navigation
fix(qa-lab): evidence summary hangs when checkout-ref git probe stalls - #111448
Patrick-Erichsen merged 1 commit into
Conversation
|
Codex review: needs maintainer review before merge. Reviewed July 19, 2026, 10:44 AM ET / 14:44 UTC. Summary PR surface: Source +6, Tests +66. Total +72 across 2 files. Reproducibility: yes. The supplied before/after terminal run uses a PATH-shimmed Review metrics: none identified. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Next step before merge
Security Review detailsBest possible solution: Land the bounded probe with its fallback-preservation tests after the normal required checks complete, retaining the existing reference precedence and metadata shape. Do we have a high-confidence way to reproduce the issue? Yes. The supplied before/after terminal run uses a PATH-shimmed Is this the best way to solve the issue? Yes. Adding a timeout at the existing synchronous probe is the narrowest maintainable fix because the established fallback chain already handles a failed probe without changing ref precedence. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 783a5d21cfc1. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Source +6, Tests +66. Total +72 across 2 files. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
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. How this review workflow works
|
…claw#111448) Co-authored-by: thomas.szbay <[email protected]>
…claw#111448) Co-authored-by: thomas.szbay <[email protected]>
What Problem This Solves
Fixes an issue where QA evidence summary generation would hang forever when the checkout-ref probe (
git rev-parse --verify HEAD) blocked indefinitely — for example a wedged filesystem (NFS), a git credential helper waiting on input, or an otherwise stalled git process.resolveQaEvidenceEnvironmentin the QA Lab plugin shells out synchronously with no timeout, so one stuck git process froze evidence metadata resolution, and the evidence summary built on top of it, with no recovery short of killing the process.Why This Change Was Made
Bounds the probe with a 5s timeout and SIGKILL, matching the bounded-probe pattern already used for similar synchronous lookups (process-tree CPU snapshot, daemon Node binary lookup). On timeout the existing error handling already degrades gracefully: the checkout ref falls back to
GITHUB_SHA, thennull, so evidence output is still produced. Non-goal: changing ref precedence or the fallback chain.User Impact
QA evidence and summary generation now completes within ~5s even when git is wedged, emitting the same metadata shape with an env-fallback or null ref instead of hanging forever. Happy-path behavior is unchanged.
Evidence
Real before/after run calling the exported
resolveQaEvidenceEnvironmentwithgitreplaced by a wedged shim (sleep 60):Happy path with real git unchanged:
RETURNED after 8ms ref=ec01949d86281746f6c2e1c1ba3c8b63b0b18298.New regression test
evidence-environment.test.tscovers: probe invoked withtimeout: 5_000+killSignal: "SIGKILL",GITHUB_SHAfallback on probe timeout,OPENCLAW_QA_REFprecedence without invoking git, and null ref when the probe fails.Sibling evidence suites also pass: evidence-summary, evidence-gallery, scorecard-evidence → 20 tests passed. oxfmt/oxlint clean.