s17: IDLE teammates cannot resume their own in-progress tasks
I maintainer di solito rispondono entro 1 giorno
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 84/100
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
- Create a pending task and start a teammate.
- Let the teammate claim the task but end a WORK phase before marking it complete.
- Observe that the task is still
in_progresswith that teammate as owner. - 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
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di shareAI-lab/learn-claude-code
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
shareAI-lab/learn-claude-code#583 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
shareAI-lab/learn-claude-code#528 ·
I maintainer di solito rispondono entro 1 giorno
-
s09: select_relevant_memories 的 "recent" 拼接顺序与切片不合理,不是真正的最近 2k 上下文Forse già presa @siri666942 l’ha presa 75 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
shareAI-lab/learn-claude-code#517 ·
I maintainer di solito rispondono entro 1 giorno
-
plan_approval_response 不会唤醒 idle teammateForse di nuovo libera Una pull request per questa issue è stata chiusa senza essere unita. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
shareAI-lab/learn-claude-code#455 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 52/100
shareAI-lab/learn-claude-code#605 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di shareAI-lab/learn-claude-code
Issue simili
-
fix(ui): serve bundled fonts from the gatewayForse già presa @dkritarth l’ha presa oggi. Apertaagent: in-progress agent: ready P3 type: bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
dkritarth/scopewatch#336 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
bob
Difficoltà 1/5 1-3 ore Idoneità per principianti 72/100
khuisman/mcp-gee-sweet#1267 ·
I maintainer di solito rispondono entro 1 giorno
-
bug confirmed issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
open-webui/open-webui#33285 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
tv-list
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
Gathin23/cleanyourtv#2337 ·
I maintainer di solito rispondono entro 1 giorno
-
bug P2
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
I maintainer di solito rispondono entro 1 giorno