codex - 💡(How to fix) Fix Codex Desktop subagent completions render as raw notifications and create unknown-conversation errors

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…

multi_agent_v2 can turn a subagent completion/rendering bug into a durable Codex Desktop session corruption bug: after using subagents, the affected conversation can no longer be opened in the app. Opening that conversation hits the LocalConversationPage / markdown renderer error boundary.

After disabling multi_agent_v2 and keeping legacy multi_agent enabled, the same two-subagent smoke test no longer made the conversation unopenable, but it still emitted raw <subagent_notification> blocks into the main chat and logged unknown conversation / No turns for conversation errors. So v2 appears to amplify an underlying subagent notification/state-race problem into a renderer-breaking persisted session record.

Error Message

multi_agent_v2 can turn a subagent completion/rendering bug into a durable Codex Desktop session corruption bug: after using subagents, the affected conversation can no longer be opened in the app. Opening that conversation hits the LocalConversationPage / markdown renderer error boundary. 4. The desktop app hits a renderer error boundary: invalid syntax at line 1 col 2.

  • The renderer hit an error boundary with invalid syntax at line 1 col 2. 2026-05-21T03:42:11.952Z error [electron-message-handler] error boundary name=LocalConversationPage errorMessage="invalid syntax at line 1 col 2: 2026-05-21T03:55:07.045Z error [electron-message-handler] Received turn/started for unknown conversation conversationId=019e48ac-2bc9-7bb3-94b8-1254b9256a72 2026-05-21T03:55:09.286Z error [electron-message-handler] Received turn/started for unknown conversation conversationId=019e48ac-398b-7ed1-b2ed-a8cc1fda7ef9 2026-05-21T03:55:10.665Z error [electron-message-handler] No turns for conversation conversationId=019e48ac-2bc9-7bb3-94b8-1254b9256a72 2026-05-21T03:55:11.217Z error [electron-message-handler] No turns for conversation conversationId=019e48ac-398b-7ed1-b2ed-a8cc1fda7ef9 2026-05-21T03:55:21.505Z error [electron-message-handler] Received turn/completed for unknown conversation conversationId=019e48ac-42f6-70f1-b971-688027a69d54 2026-05-21T03:55:35.204Z error [electron-message-handler] Received turn/completed for unknown conversation conversationId=019e48ac-39cd-75c2-9abc-65668e3f880d

Root Cause

Relationship to possible duplicates

  • Related to #23174, which also describes Codex Desktop sessions becoming impossible to open because malformed/raw subagent notification records are persisted in local session history. This issue adds a minimal two-subagent repro, the multi_agent_v2 severity difference, and concrete renderer/log excerpts.
  • Not a duplicate of #23588. That issue is about agent_path UUID being shown instead of a nickname. This issue is about raw subagent payloads being rendered/persisted in a way that can break the desktop conversation renderer and make a conversation unopenable.

Fix Action

Fix / Workaround

Environment

  • Codex Desktop: release=26.513.31313 in desktop logs
  • Codex CLI in subagent session metadata: 0.131.0-alpha.9
  • Platform: macOS / darwin
  • Latest repro config after mitigation:
    • features.multi_agent = true
    • features.multi_agent_v2.enabled = false
  • Earlier failing state: multi_agent_v2 was enabled before it was disabled as a mitigation.

Code Example

2026-05-21T03:42:11.952Z error [electron-message-handler] error boundary name=LocalConversationPage errorMessage="invalid syntax at line 1 col 2:

1  \"completed\":\"Task `/root/agent_smoke_two` is alive. `pwd` returned `~/Documents/Codex/2026-05-18/codex`, and local time is `2026-05-21 11:41:16 CST +0800`. No files changed.\"}
    ^"

---

2026-05-21T03:55:07.045Z error [electron-message-handler] Received turn/started for unknown conversation conversationId=019e48ac-2bc9-7bb3-94b8-1254b9256a72
2026-05-21T03:55:09.286Z error [electron-message-handler] Received turn/started for unknown conversation conversationId=019e48ac-398b-7ed1-b2ed-a8cc1fda7ef9
2026-05-21T03:55:10.665Z error [electron-message-handler] No turns for conversation conversationId=019e48ac-2bc9-7bb3-94b8-1254b9256a72
2026-05-21T03:55:11.217Z error [electron-message-handler] No turns for conversation conversationId=019e48ac-398b-7ed1-b2ed-a8cc1fda7ef9
2026-05-21T03:55:21.505Z error [electron-message-handler] Received turn/completed for unknown conversation conversationId=019e48ac-42f6-70f1-b971-688027a69d54
2026-05-21T03:55:35.204Z error [electron-message-handler] Received turn/completed for unknown conversation conversationId=019e48ac-39cd-75c2-9abc-65668e3f880d

---

<subagent_notification>
{"agent_path":"019e48ac-398b-7ed1-b2ed-a8cc1fda7ef9","status":{"completed":"agent_smoke_two is alive. `pwd`: `~/Documents/Codex/2026-05-21/019e3a4c-f6af-7a31-9b6d-78b411626059-agent`; local time: `Thu May 21 11:55:15 CST 2026`."}}
</subagent_notification>
RAW_BUFFERClick to expand / collapse

This issue was drafted and submitted by Codex on behalf of the user.

Summary

multi_agent_v2 can turn a subagent completion/rendering bug into a durable Codex Desktop session corruption bug: after using subagents, the affected conversation can no longer be opened in the app. Opening that conversation hits the LocalConversationPage / markdown renderer error boundary.

After disabling multi_agent_v2 and keeping legacy multi_agent enabled, the same two-subagent smoke test no longer made the conversation unopenable, but it still emitted raw <subagent_notification> blocks into the main chat and logged unknown conversation / No turns for conversation errors. So v2 appears to amplify an underlying subagent notification/state-race problem into a renderer-breaking persisted session record.

Relationship to possible duplicates

  • Related to #23174, which also describes Codex Desktop sessions becoming impossible to open because malformed/raw subagent notification records are persisted in local session history. This issue adds a minimal two-subagent repro, the multi_agent_v2 severity difference, and concrete renderer/log excerpts.
  • Not a duplicate of #23588. That issue is about agent_path UUID being shown instead of a nickname. This issue is about raw subagent payloads being rendered/persisted in a way that can break the desktop conversation renderer and make a conversation unopenable.

Environment

  • Codex Desktop: release=26.513.31313 in desktop logs
  • Codex CLI in subagent session metadata: 0.131.0-alpha.9
  • Platform: macOS / darwin
  • Latest repro config after mitigation:
    • features.multi_agent = true
    • features.multi_agent_v2.enabled = false
  • Earlier failing state: multi_agent_v2 was enabled before it was disabled as a mitigation.

Reproduction / timeline

  1. Use Codex Desktop with subagent support enabled.
  2. With multi_agent_v2 enabled, run a minimal two-subagent smoke test. Each subagent only reports pwd and local date.
  3. A raw subagent completion JSON fragment is rendered into the main thread, beginning with "completed":"Task /root/agent_smoke_two is alive....
  4. The desktop app hits a renderer error boundary: invalid syntax at line 1 col 2.
  5. User impact: the affected conversation becomes unopenable in Codex Desktop.
  6. Disable multi_agent_v2, restart Codex Desktop, and rerun the same two-subagent smoke test.
  7. With v2 disabled, both subagents complete and the conversation remains usable, but raw <subagent_notification> blocks and conversation-state errors still appear.

Latest subagent IDs from the v2-disabled repro:

  • 019e48ac-2bc9-7bb3-94b8-1254b9256a72
  • 019e48ac-398b-7ed1-b2ed-a8cc1fda7ef9

Expected

  • Subagent completions should be consumed as internal structured notifications, not persisted/rendered as raw XML or raw JSON in the main chat.
  • A malformed subagent notification should never make an existing conversation impossible to open.
  • The desktop renderer should fail soft on malformed historical records instead of crashing LocalConversationPage.
  • No unknown conversation, No turns for conversation, empty rollout, or renderer markdown parse crash should occur.

Actual

With multi_agent_v2.enabled=true:

  • Raw subagent completion JSON was rendered into the main thread.
  • The renderer hit an error boundary with invalid syntax at line 1 col 2.
  • The affected conversation could no longer be opened in the Codex Desktop app.

With multi_agent_v2.enabled=false after restart:

  • Both subagents completed successfully.
  • Raw <subagent_notification> blocks still appeared in the main conversation.
  • Desktop logs showed repeated unknown conversation and No turns for conversation errors for subagent conversation IDs.
  • The severe “conversation cannot be opened” symptom did not recur in the latest v2-disabled smoke test.

Inline log excerpts

These are copied directly from local Codex Desktop logs because local log file paths are not accessible to maintainers.

v2-enabled run that produced the renderer crash:

2026-05-21T03:42:11.952Z error [electron-message-handler] error boundary name=LocalConversationPage errorMessage="invalid syntax at line 1 col 2:

1  \"completed\":\"Task `/root/agent_smoke_two` is alive. `pwd` returned `~/Documents/Codex/2026-05-18/codex`, and local time is `2026-05-21 11:41:16 CST +0800`. No files changed.\"}
    ^"

v2-disabled run after restart:

2026-05-21T03:55:07.045Z error [electron-message-handler] Received turn/started for unknown conversation conversationId=019e48ac-2bc9-7bb3-94b8-1254b9256a72
2026-05-21T03:55:09.286Z error [electron-message-handler] Received turn/started for unknown conversation conversationId=019e48ac-398b-7ed1-b2ed-a8cc1fda7ef9
2026-05-21T03:55:10.665Z error [electron-message-handler] No turns for conversation conversationId=019e48ac-2bc9-7bb3-94b8-1254b9256a72
2026-05-21T03:55:11.217Z error [electron-message-handler] No turns for conversation conversationId=019e48ac-398b-7ed1-b2ed-a8cc1fda7ef9
2026-05-21T03:55:21.505Z error [electron-message-handler] Received turn/completed for unknown conversation conversationId=019e48ac-42f6-70f1-b971-688027a69d54
2026-05-21T03:55:35.204Z error [electron-message-handler] Received turn/completed for unknown conversation conversationId=019e48ac-39cd-75c2-9abc-65668e3f880d

Example raw notification still visible with v2 disabled

<subagent_notification>
{"agent_path":"019e48ac-398b-7ed1-b2ed-a8cc1fda7ef9","status":{"completed":"agent_smoke_two is alive. `pwd`: `~/Documents/Codex/2026-05-21/019e3a4c-f6af-7a31-9b6d-78b411626059-agent`; local time: `Thu May 21 11:55:15 CST 2026`."}}
</subagent_notification>

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 Codex Desktop subagent completions render as raw notifications and create unknown-conversation errors