Add the abandon command
CI / checks (push) Skipped
CI / checks (pull_request) Successful in 1m18s

A4 already names abandon as one of the ways out of a halt (continue,
re-plan, or abandon) and 0.2 closes a work item as completed or
abandoned, but no command did it: from a gate or a question the only way
to drop a task was to edit the state database.

- 'abandon' ends the task from any waiting state and returns to IDLE.
  The move is made durable first; then the plan issue and any open
  milestone PR are closed with a note (branches kept), and any
  unresolved intent is aborted so boot reconciliation does not gate on
  work dropped on purpose. A Gitea failure is reported, not fatal.
- Like 'status' it is a command in every state, never read as an answer
  or feedback. While work runs, 'stop' comes first, as before.
- The restart / stranded question and the PR_OPEN hints mention it.
- Spec: B1 gains the abandon edge and B2 the command.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PPQ14L3LikyefCMFBqEbKE
This commit is contained in:
dongarandClaude Opus 5.5 committed 2026-09-29 17:43:43 +00:00
1 parent 4e8ebea26a
commit d68e3b3a83
7 files changed
+307 -7

No files matched your search

+5
View File
@@ -150,6 +150,11 @@ class GiteaClient:
def close_pull_request(self, repo: str, index: int) -> None:
self._request("PATCH", f"/repos/{repo}/pulls/{index}", json={"state": "closed"})
def close_issue(self, repo: str, index: int) -> None:
self._request(
"PATCH", f"/repos/{repo}/issues/{index}", json={"state": "closed"}
)
def close(self) -> None:
self._http.close()