Recipes / Dev & code
Multi-agentWorkflowDev & code

Route stuck bugs to the other agent

When one agent loops on a bug for hours, hand it to a different agent; this developer settled on Claude Code for features and Codex for bug fixes and review.

From @sujee on X · Jan 2026

Setup time2 min
CostTwo subscriptions
RunsWhen stuck
NeedsClaude Code, Codex
Last updated2026-10-17

What the source did

  • Saw Codex fix a SwiftUI bug Claude Code had struggled with for hours.
  • Adopted a split: features in Claude Code, bug fixes and review in Codex.

Summary written by Agent Cookbook from the original post. See the original for the full context. How we source recipes

Our notes

What it takes
Claude Code for feature development, and Codex for bug fixes and code review: the split he settled on.
Where it breaks
A bug Claude Code keeps struggling with. His was a SwiftUI issue it had worked on for hours before Codex fixed it, and he says Codex "did it again".
Human checkpoint
You still review Codex's fix before you keep it.
Tools involved
Claude Code, Codex

✓ Verified Source link checked and still live. Notes by Thomas, editor. How we verify

Copy the prompt

Ours Our version, based on what @sujee described. Not their wording. Fill in the [BRACKETS].

Fresh eyes: another agent has tried to fix this for a while without success. Bug: [SYMPTOM]. Repro: [STEPS]. What was tried: [SUMMARY OF ATTEMPTS]. Don't repeat those approaches. State 3 different hypotheses, test the cheapest first, and show evidence before changing code.

Approval rule

🛡
Revert the stuck agent's partial edits before the second agent starts.

Set it up

  1. Set a rule: after 30 minutes of looping, switch agents.
  2. Summarize what was tried (the stuck agent can write it).
  3. Paste into the other agent.

Common failures

⚠
  • Passing along a wrong diagnosis biases the second agent; list attempts, not conclusions.

Variations

  • Ask both for hypotheses in parallel and compare.

Get the 10 best agent setups. Free.

Plus new recipes every week. One email, no spam.

Unsubscribe anytime. Privacy

Related recipes

Same job: Dev & code

In these guides: Claude Code vs Codex →

Read original ↗