codex - 💡(How to fix) Fix Skill instructions to use subagents are ignored unless repeated in the prompt [3 comments, 3 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openai/codex#23496Fetched 2026-05-20 03:48:53
View on GitHub
Comments
3
Participants
3
Timeline
8
Reactions
0
Timeline (top)
labeled ×4commented ×3cross-referenced ×1

Error Message

{ "status": "not_available", "reason": "The installed Codex CLI version does not support codex doctor --json; it exits with error: unexpected argument '--json' found. Running codex doctor in this non-interactive session exits with Error: stdin is not a terminal." }

Code Example

codex --dangerously-bypass-approvals-and-sandbox

---

{
  "status": "not_available",
  "reason": "The installed Codex CLI version does not support `codex doctor --json`; it exits with `error: unexpected argument '--json' found`. Running `codex doctor` in this non-interactive session exits with `Error: stdin is not a terminal`."
}

---

codex --dangerously-bypass-approvals-and-sandbox
RAW_BUFFERClick to expand / collapse

What version of Codex CLI is running?

codex-cli 0.130.0

Installed via Homebrew cask on this machine. Homebrew currently still serves 0.130.0 even though 0.131.0 is the latest upstream release.

What subscription do you have?

N/A / not subscription-specific.

Which model were you using?

Default Codex CLI model for the session. This does not appear to be model-specific.

What platform is your computer?

Linux 7.0.4-200.fc44.x86_64 x86_64 unknown

What terminal emulator and version are you using (if applicable)?

Linux terminal session. TERM=xterm-256color, COLORTERM=truecolor; no tmux/zellij detected.

The observed session was running Codex in YOLO mode / bypass-approval mode:

codex --dangerously-bypass-approvals-and-sandbox

Codex doctor report

{
  "status": "not_available",
  "reason": "The installed Codex CLI version does not support `codex doctor --json`; it exits with `error: unexpected argument '--json' found`. Running `codex doctor` in this non-interactive session exits with `Error: stdin is not a terminal`."
}

What issue are you seeing?

Codex CLI does not reliably use subagents when the instruction to use them comes from a loaded skill, even when YOLO mode is enabled. It only uses subagents when the user prompt also explicitly says to use subagents.

That means these two cases behave differently:

  1. Skill instructions say to use subagents, user asks for the skill-matching task, YOLO mode is enabled: Codex proceeds locally without spawning subagents.
  2. Same skill and same task, but the user also says something like "use subagents" in the prompt: Codex spawns subagents.

The second prompt-level instruction is redundant with the skill. If a skill is selected and its SKILL.md or supporting workflow instructions explicitly require subagents, the CLI should treat that as sufficient authorization/instruction to spawn them, especially when approval bypass / YOLO mode is already on.

What steps can reproduce the bug?

  1. Create or install a Codex skill whose instructions explicitly require subagents for a workflow. For example, a review skill that says to split independent surfaces across subagents and merge the findings.
  2. Start Codex CLI with YOLO/bypass mode enabled:
codex --dangerously-bypass-approvals-and-sandbox
  1. Ask for a task that clearly triggers the skill, but do not repeat "use subagents" in the prompt.
  2. Observe that Codex performs the work in the main agent and does not call spawn_agent.
  3. Repeat the same task, with the same skill available, but add explicit prompt text such as "use subagents".
  4. Observe that Codex now spawns subagents.

A concrete pattern that exposes the issue is a documentation or code review workflow where the skill already says to use subagents across independent review surfaces. Without the redundant prompt text, the intended subagent workflow is skipped.

What is the expected behavior?

When a selected skill explicitly instructs Codex to use subagents, Codex CLI should honor that instruction without requiring the user to repeat it in the prompt.

If the product intentionally requires prompt-level authorization for subagent spawning regardless of skill instructions, the CLI should make that explicit and warn when a skill requests subagents but the prompt did not separately authorize them. Otherwise skill-authored workflows are brittle: the same task can silently run with a different execution strategy depending on whether the user happens to duplicate the skill instruction in natural language.

Additional information

I searched open issues for subagents + skills + YOLO mode before filing and did not find an obvious duplicate.

This is not asking Codex to spawn subagents for every task. The problem is narrower: when a loaded skill itself requires subagents, that instruction should be honored the same way as other skill instructions, or the CLI should surface why it is being ignored.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

codex - 💡(How to fix) Fix Skill instructions to use subagents are ignored unless repeated in the prompt [3 comments, 3 participants]