`MultiAgentV2` `followup_task` accepts self-targets and can(and will) livelock orchestration
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 76/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Quiet
- Tech stack
- rust
- Domain
- ai-infra-agents, backend
Research direction
Start in codex-rs/core/src/tools/handlers/multi_agents_v2/message_tool.rs around the followup_task validation, then compare the self-target check in interrupt_agent.rs. Add regression coverage for self-targeting by canonical task path and thread ID, verifying rejection occurs before a NEW_TASK is delivered.
Written by the indexing model from the issue text.
Description
Summary
A MultiAgentV2 agent can call followup_task targeting its own canonical task path or thread ID.
The call succeeds and delivers a NEW_TASK whose author and recipient are the same agent. If the agent interprets this as delegation to another executor, it can repeatedly call wait_agent while waiting for itself to finish.
Reproduction
-
Spawn a child named
/root/self_followup_probe. -
From that child, call:
{ "target": "/root/self_followup_probe", "message": "Run `pwd` and report the result." } -
Observe that
followup_taskreturns success. -
Observe a delivered
NEW_TASKwhere both author and recipient are/root/self_followup_probe.
The same invalid call is accepted when targeting the caller by thread ID.
Expected behavior
followup_task should reject any target resolving to the calling thread and return a model-visible error before delivering the message.
Regression tests should cover self-targeting through:
- the current canonical task path;
- the current thread ID.
Impact
In my transcript, the agent delegated the task to itself and then waited for itself for 4 hours 14 minutes, issuing 239 wait_agent calls. The actual work never started. 😍
Source
followup_task rejects the root agent but does not check whether the resolved target is the calling thread:
interrupt_agent already performs the corresponding self-target check:
The missing validation is:
receiver_thread_id == session.thread_id
Related but distinct
- #32203 — completion routing for a non-child descendant;
- #24951 —
wait_agentexceeding its requested deadline; - #23296 — failure to execute an initial spawn task.
None covers followup_task targeting its own caller.
Definitely not a meme
- Dominant language
- Rust
- Stars
- 125k
- Forks
- 19.5k
- Avg merge
- 1m
- Merged PRs (30d)
- 1k
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from openai/codex
-
enhancement remote
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
bug CLI windows-os
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
macOS sandbox blocks hw.optional.arm64 sysctl, causing Flutter to misdetect Apple Silicon as x64 Openbug CLI sandbox
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
bug CLI TUI
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
CLI config enhancement skills
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
kwakseongjae/auto-hwp#319 ·
-
area:cli bug filter-quality good first issue priority:medium
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
Difficulty 1/5 Under an hour Newbie friendliness 72/100
bevyengine/bevy#25861 ·
-
comp-datalake
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
ClickHouse/ClickHouse#121222 ·
-
A-linter
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
oxc-project/oxc#26863 ·