Startup worktree sweep warns about the worktrees of attempts it is reattaching

Aperta
#1,044 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
73/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
typescript
Ambito
backend, testing

Direzione di ricerca

Start with packages/executor/src/remote/sweep.ts and trace how abandonedWorktreeSweepFor identifies attempts and logs paths. Find the durable harness data for open attempts and the existing sweep tests, then add a test with a reattached attempt worktree beside a genuinely abandoned path. Done means known attempts are excluded from the warning, while abandoned paths are summarized at WARN and listed at debug.

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

Descrizione

abandonedWorktreeSweepFor in packages/executor/src/remote/sweep.ts lists every direct child of the worker's attempts/ directory and logs each one at WARN as "Preserving abandoned remote path for salvage reconciliation". The sweep runs once per worker at the first prepare after a restart, which is when the attempts that survived the restart are being reattached. Their own worktrees are therefore reported as abandoned.

Seen on 2026-11-07 at 12:17:17Z after the upgrade to 0.5.1-next.443: attempt 932b2964a857cc2d9183a0905b134d51/review/1 (#1043 review) was reattached at 12:17:15 ("Attempt reattached after an orchestrator restart"), and two seconds later the sweep it triggered warned about its own worktree .../attempts/932b2964a857cc2d9183a0905b134d51_review_1. Nothing was removed, so there is no functional harm, but the WARN is wrong and it is the only WARN of an otherwise clean restart, so it is what an operator reads first.

Fix: exclude the worktrees of attempts the durable harness still knows (at least the attempt that triggered the sweep, better every open attempt on that worker) from the warning, and log the rest at WARN with a count plus the paths at debug. Add a test with a reattached attempt whose worktree exists next to one genuinely abandoned path.

Related ordering oddity from the same restart, same place to fix if it is the same code path: at the forced stop (12:15:06), "Interrupting the child of an aborted tool call" and "Interrupting Claude child session" were logged after "Attempt settled during drain" and after the container was already removed, so the interrupt had nothing to act on.

Lingua principale
TypeScript
Stelle
1
Fork
0
Merge medio
3h 47m
PR unite (30g)
388

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 basaltbytes/usine

Tutte le issue di basaltbytes/usine

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.