Name the reload exit for what it checks, gate --help only on a typed task, drop the outlived todo caveat

This commit is contained in:
2026-09-26 13:39:09 +02:00
parent a64461f2c1
commit 805eb868db
3 changed files with 9 additions and 11 deletions
+7 -6
View File
@@ -10,9 +10,10 @@ interrupt: `claude --resume` on the terminal, every worktree first marked truste
An unfinished chunk resumes the same session next cycle; a finished one starts a fresh session.
Cycles continue until that interrupt or Ctrl-C. Words: ~/.claude/CLAUDE.md → "Vocabulary".
Exit 1: no task, not inside a checkout, no premises, claude leaves no transcript, a reload handing
over no task, or the worker or the judge fails three times running. A worker fails when claude exits non-zero, is killed, or ends
without a result event; a judge when its verdict misses a field or quotes nothing in the transcript.
Exit 1: no task, not inside a checkout, no premises, claude leaves no transcript, a reload whose
state it cannot read, or the worker or the judge fails three times running. A worker fails when
claude exits non-zero, is killed, or ends without a result event; a judge when its verdict misses a
field or quotes nothing in the transcript.
Exit 2: the human is needed and stdin or stdout is not a terminal, or the interrupt ended without
them typing anything. Rerunning resumes any open session.
@@ -390,10 +391,10 @@ def main():
state = reloaded_state(argv[1:])
else:
state = {"cycle_number": 0, "failures": 0, "root": "", "task": " ".join(argv)}
if state["task"] in ("", "-h", "--help"):
print(__doc__.strip())
sys.exit(0 if state["task"] else 1)
task = state["task"]
if task in ("", "-h", "--help"):
print(__doc__.strip())
sys.exit(0 if task else 1)
root = state["root"] or checkout_root()
cycle_number, failures = state["cycle_number"], state["failures"]
while True: