Repository navigation
thirdshift stop for a Run #773
Copy link
Copy link
Closed
Labels
ready-for-agentFully specified, ready for an AFK agentFully specified, ready for an AFK agent
Description
Parent
What to build
thirdshift stop <command> [--requeue] is a Stop for a live Run. #574's case becomes one command: stop a Run that started too early, and it isn't taken again.
stoprefuses a Command that has ended or died, giving the reason, so no unrelated process is ever signalled.- It writes a Stop request beside the Command record. The request says who asked: the Unix user, from the CLI. Later, the Console will pass an account's email. It also says whether to requeue.
- It sends
SIGTERMto the Command's process, which interrupts and cleans up as today. - The interrupted Command reads the request. It writes the Activity log line
<subject> stopped from the CLI by <who>before itsended:line. - Then it ends its Claim the Stop's way:
- Without
--requeue:needs-triageis added andready-for-agentis not put back.in-progressfollows the usual rules: it's removed when nothing reachedorigin, and kept while an Issue branch or pull request waits for the Day shift. - With
--requeue: the Claim is released andready-for-agentput back, even when something is onorigin. The next Run continues the Issue branch (ADR 0002).
- Without
stopwaits for the record's outcome, or for the process to be gone. Meanwhile it prints a "still ending" line each minute. Then it prints the outcome and the Issue branch or pull request left onorigin.
stop never prompts. There is no forced kill.
Acceptance criteria
-
stopon a live Run that had pushed nothing:- it ends interrupted;
- the issue gets
needs-triage, withoutin-progressorready-for-agent; - the Activity log has the stopped line before the ended line.
-
stopon a live Run that pushed its Issue branch keepsin-progress, addsneeds-triage, and prints the branch left behind. -
stop --requeueputsready-for-agentback and removesin-progress, whether or not the branch was pushed. -
stopon an ended or died Command is refused with the reason, and no signal is sent. -
stopprints a "still ending" line while the cleanup runs past a minute. - The Claim's in-memory tests cover the Stop endings. End-to-end tests with the existing fakes check the labels and the Activity log.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
ready-for-agentFully specified, ready for an AFK agentFully specified, ready for an AFK agent
Activity
JacobStephens2 commentedon Oct 18, 2026
Closed by #783, merged into issue-711 by a thirdshift Merge run.