Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

s17: IDLE teammates cannot resume their own in-progress tasks

Aperta Adatta ai principianti
#519 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@hichipli ci sta già lavorando.

Dal 30/8/2026.

  • #555 di @hichipli — aperta

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
84/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Tranquilla
Stack tecnologico
python
Ambito
ai

Direzione di ricerca

Inizia in s17_autonomous_agents/code.py leggendo idle_poll(name, ...) e scan_unclaimed_tasks(). Riproduci il percorso IDLE con un'attività in_progress di proprietà e un'altra attività pending, quindi verifica il comportamento di regressione descritto: il teammate riprende la propria attività, torna a WORK, inserisce un resume message e lascia l'attività pending non reclamata.

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

Descrizione

Bug

In the teaching implementation of s17_autonomous_agents/code.py, a teammate can leave tasks it already owns stuck in in_progress and then exit after the 60-second IDLE timeout.

Cause

idle_poll(name, ...) only calls scan_unclaimed_tasks(). That scan accepts only tasks that are:

  • status == "pending"
  • unowned
  • dependency-ready

It never looks for tasks with status == "in_progress" and owner == name.

Therefore, after a WORK phase ends without a tool_use response (for example, the model returns ordinary text before it has called complete_task), the outer loop enters IDLE. The teammate cannot rediscover its own unfinished task, waits for IDLE_TIMEOUT = 60, sends a final summary, and exits. The task remains owned and in_progress.

Reproduction
  1. Create a pending task and start a teammate.
  2. Let the teammate claim the task but end a WORK phase before marking it complete.
  3. Observe that the task is still in_progress with that teammate as owner.
  4. The teammate polls for 60 seconds, finds no unclaimed work, and exits instead of resuming its owned task.
Expected behavior

During IDLE, after handling inbox messages and before claiming new work, a teammate should resume one of its own in_progress tasks. It should return to WORK with that task injected into its messages, rather than timing out.

Minimal fix

Add a helper such as scan_resumable_tasks(owner) to find in_progress tasks owned by the current teammate. In idle_poll, prioritize one resumable task before scan_unclaimed_tasks() and append a message like:

{"role": "user", "content": "<resume-task>Task ...</resume-task>"}

I verified this with a regression test: when Alice owns an in_progress task and another pending task exists, idle_poll("alice", ...) returns "work", injects the owned task, and leaves the pending task unclaimed.

This is a teaching-version bug report; it is not a claim about the production Claude Code scheduler.

Lingua principale
Python
Stelle
79k
Fork
12.6k
Merge medio
8g 11h
PR unite (30g)
7

Preparare l'ambiente

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 shareAI-lab/learn-claude-code

Tutte le issue di shareAI-lab/learn-claude-code

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.