Environment
- Zed 1.19.2
- codex-acp 1.11.0
- Codex CLI 0.154.0
- Linux
Problem
Reopening a large Codex session in Zed only shows an older, partial section of the conversation. The latest user and assistant messages are present in the Codex transcript but never appear in the Agent Panel.
The affected transcript was unusually large: about 610 MiB, 40k events, and 328 started turns. It also contained many completed terminal, Playwright, and image tool outputs.
What seems to be happening
threadReadHistory() fetches turns in pages of 50, but collects every page into one array. streamThreadHistory() then publishes every historical item to Zed sequentially, including large completed tool outputs.
While loading this session, Zed reported hangs around crates/agent/src/db.rs and crates/agent_servers/src/acp.rs. The load did not show a clear failure; the panel was simply left with an incomplete transcript.
Confirmed workaround
For historical replay only, I filtered the oversized session to userMessage and agentMessage, leaving the canonical Codex transcript untouched. After restarting Zed, the full conversation—including the newest messages—loaded correctly.
Suggested fix
Could historical replay preserve all user/assistant messages while truncating or omitting large completed tool payloads? A byte/item budget and a placeholder such as Historical tool output omitted (12.4 MiB) would avoid silently losing the recent conversation.
Incremental replay or backpressure would also help, but simply bounding historical tool output appears to fix this case.
Environment
Problem
Reopening a large Codex session in Zed only shows an older, partial section of the conversation. The latest user and assistant messages are present in the Codex transcript but never appear in the Agent Panel.
The affected transcript was unusually large: about 610 MiB, 40k events, and 328 started turns. It also contained many completed terminal, Playwright, and image tool outputs.
What seems to be happening
threadReadHistory()fetches turns in pages of 50, but collects every page into one array.streamThreadHistory()then publishes every historical item to Zed sequentially, including large completed tool outputs.While loading this session, Zed reported hangs around
crates/agent/src/db.rsandcrates/agent_servers/src/acp.rs. The load did not show a clear failure; the panel was simply left with an incomplete transcript.Confirmed workaround
For historical replay only, I filtered the oversized session to
userMessageandagentMessage, leaving the canonical Codex transcript untouched. After restarting Zed, the full conversation—including the newest messages—loaded correctly.Suggested fix
Could historical replay preserve all user/assistant messages while truncating or omitting large completed tool payloads? A byte/item budget and a placeholder such as
Historical tool output omitted (12.4 MiB)would avoid silently losing the recent conversation.Incremental replay or backpressure would also help, but simply bounding historical tool output appears to fix this case.