0.3.40
Agent teams were wired to the subagent execution engine but never actually ran a
member. Four defects compounded, each of them silent: the tools reported success
and the team produced nothing.
Requires subagents-pydantic-ai >= 0.2.12, which adds the programmatic
answer_task / steer_task surface and exposes SubAgentToolset.registry.
Fixed
- Teams registered members in a registry the subagent engine never reads. With
subagent_registry=None— thecreate_deep_agentdefault — the team block built
a freshDynamicAgentRegistry(), sospawn_teamput its members somewhere the
subagenttasktool does not look and everyassign_taskcame back
Error: Unknown subagent. Teams plus subagents was broken in the default
configuration. Teams now sharesubagent_toolset.registry. - A refused delegation was recorded as a started task. The subagent
tasktool
reports an unknown subagent or a busy chat trace as an error string rather than
raising, soassign_task'sexceptnever fired: it set the member torunning
and appended the error to an "Agent running in background" message. The member
then sat atrunningforever. A started task is now identified by itsTask ID:
line, and a refusal marks the memberfailedwith the reason. message_teammatedelivered nothing. It wrote toTeamMessageBus, which no
running member reads — a member is a background subagent and only sees what the
subagent engine hands it, andTeamMessageBus.receive()is called from tests
only. It now routes through the engine:answer_taskwhen the member is blocked
inask_parent,steer_taskwhile it runs, and it says plainly when there is
nothing to deliver into instead of reporting "Message sent".- A finished member left its shared task
in_progressforever, so the lead read
completed work as outstanding.AgentTeam.sync_membercompletes the todo when a
member completes, and releases the claim when one fails so the lead can reassign
it rather than watching a dead member hold it.
Added
create_team_toolset(subagent_toolset=...)— the subagent toolset backing
execution, which is what makesmessage_teammateable to deliver. The existing
registry/task_fn/task_managerarguments still work.TeamMemberHandle.todo_id, linking a member to the shared-todo item it
claimed so finishing the task can close the todo.TestTeamSubagentWiringintests/test_teams.py, which fails on each of the
four defects independently.
Changed
TestCreateTeamToolset::test_message_teammateasserted the"Message sent"that
the third defect shows was a lie; it now asserts the honest outcome.