Codex CLI: Live Background Agent Streaming in Realtime V2 Sessions

Codex

Codex CLI 0.120.0 introduces live streaming of background agent progress during Realtime V2 sessions. Follow-up responses are now queued rather than dropped when a new one arrives while the current response is still active. This builds on the WebRTC v2 default from 0.119.0.

Key Takeaways

  • Live background agent streaming in Realtime V2 sessions means users no longer wait in silence during long agentic tasks β€” agent progress is visible in real time as it happens.
  • Queued follow-up responses prevent dropped output when multiple agent responses arrive in rapid succession, ensuring every result is delivered sequentially without loss.
  • Hook status display improvements make it easier to debug hook-heavy configurations, with clearer state indicators for SessionStart, SessionStop, and custom hooks visible directly in the TUI.
  • Custom status lines now reflect renamed thread titles, keeping the status bar accurate after a thread is renamed mid-session without requiring a restart.
  • A Windows elevated sandbox regression is fixed, restoring reliable sandbox initialization for users running Codex with elevated permissions on Windows.
  • SessionStart no longer fires on /clear, correcting a subtle but impactful behavioral bug that caused session initialization side effects to run at unintended moments.

Background Agent Streaming Comes to Realtime V2

Codex CLI 0.120.0 delivers a foundational improvement to the Realtime V2 session experience: live streaming of background agent progress. In previous releases, background agents running during a Realtime V2 session were largely invisible β€” their progress was not surfaced in the active voice session until the agent completed and a summary was delivered. With 0.120.0, agent activity streams into the session in real time, giving users live awareness of what the agent is doing without having to wait for a terminal result.

This is particularly impactful for long-running agentic tasks such as multi-file code changes, repository searches, or shell command sequences. Rather than experiencing silence during these operations, users now receive a continuous feed of agent state updates that mirrors the activity visible in the standard text TUI.

Queued Follow-Up Responses

A common pain point in earlier Realtime V2 sessions was response collision: when a new agent response arrived while the current one was still being delivered, the incoming response would be dropped rather than delivered after the active one finished. Codex CLI 0.120.0 resolves this by introducing a response queue.

Follow-up responses are now held in a queue and delivered sequentially once the current active response completes. This ensures that no agent output is lost during high-activity moments β€” a critical improvement for workflows where the agent generates multiple outputs in quick succession, such as iterative code reviews or multi-step debugging sessions.

Improved Hook Status Display in TUI

The 0.120.0 release also improves how hook execution status is displayed in the TUI. Hook activity β€” including SessionStart, SessionStop, and custom hooks β€” is now shown more prominently and with clearer state indicators (pending, running, completed, failed). This makes it easier to diagnose issues in hook-heavy configurations without enabling verbose logging.

Custom status lines defined by users now also reflect renamed thread titles, so the status display stays accurate after a thread is renamed mid-session.

Stability Fixes

Several stability issues from the 0.119.0 series are resolved in this release:

  • Windows elevated sandbox fix: A regression affecting sandbox initialization under elevated Windows permissions is corrected.
  • TLS WebSocket panic fix: A panic that could occur during TLS WebSocket connection teardown is resolved, improving stability in network-unstable environments.
  • Tool search order preserved: Results from tool search operations now maintain their original ordering across paginated fetches, preventing non-deterministic behavior in tool selection.
  • SessionStart and /clear distinction: The SessionStart hook no longer fires after a /clear command, ensuring that session initialization hooks are only triggered at true session boundaries.