T-IZLC-task-work-resume-reaps-orphan-heartbeat
Status: closed/superseded · Impact: medium · Complexity: small
/sdlc:task-work’s resume path (Step 2 resume-detection) recovers from a
killed previous run, but it does not reap the orphaned lease-heartbeat
process the prior run backgrounded. The killed run leaves both a live
heartbeat process and a stale lease-heartbeat-<basename>.pid file under the
worktree’s .sdlc/runtime/, which the resuming operator has to kill and
remove by hand before continuing. Resume should reap the orphan as part of
its own machinery — the same try/finally-shaped reaping Step 6 does on the
happy path — so a resumed run is self-cleaning.
From the originating task’s post-mortem:
“Resume after a killed run left an orphan heartbeat process and a stale
lease-heartbeat-<basename>.pidfile under the worktree’s.sdlc/runtime/; the resume path had to kill the PID and rm the file by hand — task-work’s resume-detection (Step 2) should reap an orphan heartbeat (kill the recorded PID + remove the stale.pid) as part of resume, the sametry/finallyreaping Step 6 does on the happy path.”
TBD — receiver to fill before promoting from planning/draft.
Proposed
Section titled “Proposed”TBD — receiver to fill before promoting from planning/draft.
Approach
Section titled “Approach”TBD — receiver to fill before promoting from planning/draft.
Files to touch
Section titled “Files to touch”TBD — receiver to fill before promoting from planning/draft.
Acceptance criteria
Section titled “Acceptance criteria”TBD — receiver to fill before promoting from planning/draft.
Out of scope
Section titled “Out of scope”- none
Dependencies
Section titled “Dependencies”- none
Discovery context
Section titled “Discovery context”Spawned by /sdlc:spawn-task-pr on 2026-06-04 UTC from T-E9C9-project-check-flags-operations-column-drift in git@github.com:sksizer/dev.git.