Repository navigation
fix(dashboard): classify wedged pre-queue reruns - #1176
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs maintainer review before merge. Reviewed August 15, 2026, 11:44 PM ET / August 16, 2026, 03:44 UTC. ClawSweeper reviewWhat this changesThe PR classifies aged pending GitHub Actions reruns as wedged telemetry rather than live queue pressure and records their unremediable cancellation result as a structured skip. Merge readinessKeep open: current main does not contain this focused repair, and the current PR head has no actionable correctness finding. The submitted receipt supplies sufficient real-behavior proof for the dashboard and remediation paths. Priority: P1 Review scores
Verification
How this fits togetherThe dashboard Worker collects active GitHub Actions runs, derives operational queue health, and publishes a privacy-filtered status response for the dashboard. The remediation CLI separately inventories stale runs and either requests cancellation or records a safe structured skip. flowchart LR
A[GitHub Actions runs] --> B[Dashboard Worker]
B --> C[Operational health summary]
C --> D[Public status API]
C --> E[Dashboard alert]
A --> F[Remediation CLI]
F --> G[Cancel or structured skip]
Before merge
Agent review detailsSecurityNone. Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Land the narrow classification and skip behavior once normal required checks finish, retaining the aggregate-only public status contract and exact cancellation fallback. Do we have a high-confidence way to reproduce the issue? Yes: the receipt captures the production CLI and dashboard paths against loopback GitHub API fixtures, with the merge-base failing the three new claims and the repaired source passing them. Is this the best way to solve the issue? Yes: classifying only aged pending reruns with attempts above one, then exact-rechecking before a no-POST skip, preserves ordinary queue pressure and avoids unsafe remediation. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 43799a11fc26. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
Summary
Classify unremediable GitHub Actions reruns stuck in the pre-queue
pendingstate aswedged_rerunafter 60 minutes whenrun_attempt > 1. They stay visible through aggregate status fields but no longer count as live queue pressure. The stuck queued-run remediation CLI discovers aged pending reruns, emits the structured skip before cancellation, and also turns GitHub's exact pre-queue cancellation 409 intoskip_reasons.wedged_rerunwith exit 0.Production evidence
Run 31910632853 ("repair publish cluster results", created 2026-08-15T21:52Z): status=pending,
run_attempt=2, stuck >4.5h in PRE-QUEUE state. GitHub refuses every remediation: cancel and
force-cancel both 409 "Cannot cancel a workflow re-run that has not yet queued"; rerun
conflicts with "This workflow is already running". operational_health counts it in
queued_over_threshold → status=degraded for up to 24h until the zombie boundary excludes it,
even though NOTHING can remediate it. (Same family as the Aug-7 HTTP-500 cancel zombies the
24h boundary already handles — see the comment block in dashboard/operational-health.ts.)
Production run: https://github.com/openclaw/clawsweeper/actions/runs/31910632853
Behavior and data contract
The 60-minute threshold is deliberately conservative: pre-queue pending normally lasts seconds, while one hour leaves ample margin for transient scheduling delay. The comparison is strict, so exactly 60 minutes remains ordinary queue pressure. Fresh reruns and genuinely queued over-threshold runs retain their existing behavior.
The Actions list path already passes full run objects to the summarizer. The webhook read model persists and returns the bounded full workflow-run snapshot, and stale revalidation replaces it with the full exact-run API response.
run_attemptwas not being dropped; this change records it in the local types without a storage migration. Remediation now queries both queued and pending inventories, admits only pending attempts greater than one beyond its existing strict 90-minute stuck threshold, and exact-rechecks the run before recording a skip without a POST.Public status exposes only
wedged_rerun_runsandoldest_wedged_rerun_minutes. The containment fixture proves run IDs and diagnostic URLs are removed. The dashboard mentions wedged reruns distinctly only inside details when another real execution problem opens the alert.OpenClaw Bay is unaffected: it does not consume
operational_health, and no Bay lifecycle, projection, or observer-action contract changed.Real-behavior proof
/api/statussummarization and public projection, dashboard alert rendering, and the production remediation CLI through itsGITHUB_API_URLloopback seam.provider=local-container, imagenode:24-bookworm, leasecbx_f7e8db6e9e13(tidal-shrimp-7cbb), runrun_463709e0dc4a.0b677cbcca1651b7ea73f83f4f12a0fbf56589c9; merge base43799a11fc2612df7d80918e0012d6f03b339747; final PR head40f0c392f9b031883e4aaa5624302582f1a02aaeadds refreshed receipt files only. The repaired source and receipt commits were pushed together.check:dashboard-strictpassed; fullpnpm run checkpassed 3,535 tests with 3,527 passed, zero failed, and eight skipped.docs/proof/wedged-rerun-classification/contains the contract, source-blind behavior report, normalized transcript, provenance, secret scan, and reproducible launcher. Staticjq, SHA-256,git cat-file, and merge-base checks pass.Review disposition
ClawSweeper's first current-head review accepted one P1 finding: the production
pendingstate could not reach the original cancellation-response classifier. Fix round 1 now queries the pending inventory, selects only aged rerun attempts, exact-rechecks live state, recordswedged_rerunbefore cancellation, and proves no POST is sent. The exact 409 fallback remains covered for queued-looking responses. Focused, proof-only, and final committed-branch Codex reviews after the fix reported no additional accepted or actionable findings. NoCHANGELOG.mdchange is included, as requested.Rank-up moves: both requested moves are applied. The production CLI loopback now uses a discovered and freshly read
pendingrun, and the Docker-backed receipt was refreshed for the repaired source head.