Repository navigation
Description
Overview
heart/checks/ci_timing.py::classify_cancelled treats every cancelled main run as a kill or hang suspect. But PyAutoFit Tests 39064925733 and 39064933625 (10-17 20:01:07 and 20:01:13) were main pushes cancelled by the concurrency group when the next push arrived seconds later (39064940041, success). These benign supersessions are 8 red rows holding the monitoring inventory red.
Plan
- Treat a cancelled run (any event, including main pushes) as superseded when a newer run of the same workflow on the same branch was created before the cancelled run ended. That's the concurrency-cancel signature.
- A cancelled run with no such successor (a real kill or hang) stays a suspect event.
- No threshold, factor or weight changes.
- Add tests from the real 10-17 sibling runs; re-run the collector and confirm the stale rows clear while real events stay.
Tier: judge (undeclared Consequence) — merge mode: human /prm
Detailed implementation plan
Affected Repositories
- PyAutoHeart (primary) —
heart/checks/ci_timing.py,tests/
Branch Survey
| Repository | Current Branch | Dirty? |
|---|---|---|
| organs/PyAutoHeart | main | clean |
Suggested branch: feature/ci-timing-superseded-main-cancels
Implementation Steps
classify_cancelled: drop the blanket main/non-PR → suspect; superseded iff a sibling (same workflow + head_branch) hascreated_at> mine AND ≤ myupdated_at(+ small slack); otherwise suspect. Update the module docstring bullet.- Check how events carried in the published board history are re-judged (rows from 09-08/10-02 must clear on recompute or age out per existing rules; no hand edits).
- Tests: superseded main push burst; lone cancelled main run (suspect); PR supersession unchanged.
- Run
heart/checks/ci_timing.shlocally, then compare event counts before and after.
Heart RED override (development only) — authorized by the human 2026-10-21 in the health session. Verbatim door reading:
Heart: RED — Release RED; monitoring RED · 14/100 · 464 unresolved (updated 23h ago); red reasons: PyAutoFit CI failure (run 39111874604, since green on d3a7721); PyAutoHands Python Version Matrix failure; PyAutoHeart Workspace Smoke failure; PyAutoMind Spawn Drift failure (fixed in Mind e18c2021); 8 ci_timing suspect_cancelled rows (PyAutoArray×2, PyAutoFit×4, *_workspace_test Smoke×3); CI wall-clock 27 gates/9 hang events; Workspace validation NOT ready 1414p/1f/133s @ cloud#39224774724; euclid/test_run red; PyAutoArray, autolens_inference, autolens_profiling, euclid pipeline repo state red; Worktree drift 5 orphan/4 dirty. Covers commit/push/PR only; merge needs a separate /prm with all checks green; no release.
Original Prompt
Click to expand starting prompt
Heart ci_timing flags superseded (concurrency-cancelled) runs as kill-timer reds
Type: bug
Target: health_fixes
Themes:
- heart
- ci
Difficulty: small
Autonomy: supervised
Priority: low
Status: formalised
Filed: 2026-10-21
Context
Eight red ci_timing:<repo>/<gate>:<run_url> findings on the Heart dashboard are
suspect_cancelled events, e.g. PyAutoFit Tests runs 39064925733 and 39064933625
(2026-10-17 20:01:07/13) cancelled seconds before 39064940041 on the next push
succeeded; PyAutoArray 37002625195/37002707936 (10-02), and workspace_test Smoke
runs from 09-08/09-19. These look like ordinary concurrency-group cancellations,
not hangs or kill-timer hits, yet they hold the monitoring inventory red for weeks.
Primary repository: @PyAutoHeart (heart/checks/ci_timing.py).
Ask
Confirm from the run metadata whether these were superseded by a newer run in the
same concurrency group; if so, classify them as superseded (not red) without
loosening real hang/kill detection. No threshold or weight changes.
Activity
Jammy2211 commentedon Oct 21, 2026
PR opened: #313. Validation: test_ci_timing 43 passed, full suite 1281 passed; scratch-dir collector 8 → 2 suspect_cancelled events (the 6 superseded main-push cancels clear; the two 09-19 workspace_test PR-run cancels with no successor stay — separate decision). Heart RED override (development only) authorized live by the human 2026-10-21 ("Override and proceed"); reasons verbatim in the issue body. Merge needs a separate /prm.
Jammy2211 commentedon Oct 21, 2026
Shipped: #313 merged 2026-10-21. classify_cancelled now treats a cancel whose same-branch successor arrived before it ended (+60 s slack) as superseded on any event incl. main pushes; real kills stay suspect. The 6 superseded main-cancel rows clear on the next ci_timing collection; the two 09-19 PR-close cancels remain (separate decision).