Cover completed background tasks in the Lead's inbox poller, and mark when teammates finish (#46)#429
Merged
Bill-Billion merged 1 commit intoJun 25, 2026
Conversation
… when teammates finish (shareAI-lab#46) The inbox poller added in shareAI-lab#291 wakes the Lead on teammate inbox messages, but a completed background task still strands its result: nothing wakes the Lead for it, and collect_background_results() runs only inside the tool-use branch, so a plain-text turn never picks it up. There is also no signal once every teammate has finished. Extend the same poller instead of adding a second path. has_pending_background() reports, without consuming, whether any background task has completed. The poller now wakes on unread inbox messages or a completed background task, and the wake handler drains both the inbox and collect_background_results() before running the turn, so background results become new turns without user input, the same way teammate results already do. When the last teammate finishes and its output has been drained, a single "[all teammates done]" marker is printed.
|
@Bill-Billion is attempting to deploy a commit to the crazyboym's projects Team on Vercel. A member of the Team first needs to authorize it. |
Bill-Billion
added a commit
to Bill-Billion/learn-claude-code
that referenced
this pull request
Jun 26, 2026
Bring in upstream s15 inbox poller fixes (shareAI-lab#291, shareAI-lab#46, shareAI-lab#428, shareAI-lab#429).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to #428 (now merged), which added the Lead's inbox poller for #291. That poller delivers teammate inbox messages, but a completed background task still strands its result, and there is no signal once every teammate has finished.
A completed background task does not wake the Lead, and collect_background_results() runs only inside the tool-use branch, so a plain-text turn never picks it up. This is the same stranding as #46, in s15.
Change (only s15_agent_teams/code.py), extending the same poller rather than adding a second path:
Verification with the real API, sending no user input between the task prompt and quit:
Out of scope: terminal prompt/output still interleaves (needs a TUI; real Claude Code uses Ink). Three-language README not updated.