Stale unstarted record retries a worker start forever while the Claude is live (platform #567)

Aperta
#151 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
44/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
python
Ambito
devtools

Direzione di ricerca

Start with retry_starts and start_existing in advance.py, then trace the revive/resume paths and relay selection for PR conflicts. The report points to slots.json records and the two relay files as evidence; first reproduce the stale unstarted record and live worktree refusal. Done means a live Claude no longer leaves a brief retrying forever, the log describes the actual state, and tests cover that behavior and ensure a conflict gets only the appropriate relay.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Seen 2026-11-18 on the platform board. From about 1:56 PM to 8:55 PM ET every cascade pass logged "start: queued the worker start of #567 (minavo-use-one-name): its window has no Claude". Each start failed in the launcher with "swarm-start-scoped refused: another Claude is live in /home/memnar/ver/platform.minavo-use-one-name (pid 3126318): one Claude per worktree" (events DB, source launcher). Meanwhile the Claude in pane %276 had finished at 7:00 PM ET and sat idle at its prompt.

Cause: this is not pane inspection. retry_starts (advance.py) never looks at the pane; it starts every PR in slots.json unstarted. #567 had an unstarted record from 1:56 PM ET (brief /tmp/relay-567-merge-main.md, issue None, no brief_pane), written when the merge-main relay found no Claude (Flow.to_worker deferred start). The Claude was then resumed in a rework slot (rework record started 13:56 ET), but nothing removed the unstarted record. With no brief_pane, start_existing always calls swarm-start-scoped, which refuses, and unstarted_retry keeps the record. The log text "its window has no Claude" is wrong.

A second problem: at 1:56 PM ET the worker got two different relays for the same conflict: /tmp/relay-567-premerge.md (resolve on the speculative branch minavo-use-one-name-v5 only, never merge main into minavo-use-one-name) and /tmp/relay-567-merge-main.md (merge origin/main into minavo-use-one-name). The live Claude got the premerge one and did it (v5 tip 52643003). The merge-main one stayed in the stuck unstarted record. By 8:37 PM ET main had moved and v5 was stale, while the PR (draft, In Progress) still conflicted with main.

swarmbot relayed the merge-main work to %276 with tell_agent at about 8:50 PM ET. The worker pushed 9f21bd2d, and the Stop hook moved #567 to Auto Review and asked Codex at 8:55 PM ET.

Fix:

  1. When a revive or resume starts a Claude for a PR, or start_existing sees a live Claude in the PR's worktree, drop the unstarted record (or set brief_pane so only the brief line is sent). A refused start because a Claude is live must not be retried forever.
  2. Log what is true: "a Claude runs in the worktree; sending the brief" instead of "its window has no Claude".
  3. Send one relay per conflict: premerge on -vN for a Ready PR, or merge-main for an In Progress PR, never both.
    Tests for 1 and 3.
Lingua principale
Python
Stelle
3
Fork
0
Merge medio
5h 57m
PR unite (30g)
60

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di tangentcode/tangentswarm

Tutte le issue di tangentcode/tangentswarm

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.