codex - 💡(How to fix) Fix Codex Desktop becomes slow or stuck after context compaction and approval transcript injection

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…

Codex Desktop feels noticeably slower than Codex CLI/TUI during reasoning, and several sessions appeared stuck enough that I had to interrupt or start a new session.

The issue seems correlated with long-running Desktop sessions, context_compacted events, and injected approval-review transcript blocks such as approval assessment / TRANSCRIPT DELTA.

Root Cause

I can provide redacted snippets from the session logs if needed, but I would avoid attaching full raw jsonl logs publicly because they may include local paths, commands, repository names, and internal work context.

Code Example

Total session files:        156
Total turns:                1695
Total turn_aborted events:  85
Total context_compacted:    70

Codex Desktop:
  files:                    69
  turns:                    72
  turn_aborted:             4
  turns >= 8 minutes:       3

Codex CLI/TUI:
  files:                    117
  turns:                    1547
  turn_aborted:             78
  turns >= 8 minutes:       52

---

originator: Codex Desktop
turn start line: 610
turn end line:   748
duration:        about 23 minutes
events:          context_compacted, then task_complete
tool calls:      about 36
tool outputs:    about 30

---

originator: Codex Desktop
pattern: repeated approval assessment / TRANSCRIPT DELTA messages

---

originator: Codex Desktop
event:      turn_aborted
reason:     interrupted
RAW_BUFFERClick to expand / collapse

Environment

  • Product: Codex Desktop app
  • OS: macOS
  • Comparison baseline: Codex CLI/TUI
  • Local session logs inspected: user-local ~/.codex/sessions logs

Summary

Codex Desktop feels noticeably slower than Codex CLI/TUI during reasoning, and several sessions appeared stuck enough that I had to interrupt or start a new session.

The issue seems correlated with long-running Desktop sessions, context_compacted events, and injected approval-review transcript blocks such as approval assessment / TRANSCRIPT DELTA.

Observed Behavior

  1. Reasoning in Codex Desktop is noticeably slower than CLI/TUI for similar workflows.
  2. Some Desktop sessions become stuck or unresponsive and need interruption.
  3. The slowdown often appears after long conversation history, context_compacted, approval review transcript injection, or large tool call / tool output histories.

Local Log Evidence

I scanned local ~/.codex/sessions logs.

High-level counts:

Total session files:        156
Total turns:                1695
Total turn_aborted events:  85
Total context_compacted:    70

Codex Desktop:
  files:                    69
  turns:                    72
  turn_aborted:             4
  turns >= 8 minutes:       3

Codex CLI/TUI:
  files:                    117
  turns:                    1547
  turn_aborted:             78
  turns >= 8 minutes:       52

Although CLI/TUI has more total aborts, it also has far more turns. Desktop has a relatively high number of slow/interrupted turns in a much smaller sample, which matches the user-facing perception that Desktop is less responsive.

Representative Examples

Example 1: Desktop turn after context compaction took about 23 minutes

Observed details from one local session log:

originator: Codex Desktop
turn start line: 610
turn end line:   748
duration:        about 23 minutes
events:          context_compacted, then task_complete
tool calls:      about 36
tool outputs:    about 30

Example 2: Approval transcript injection appears repeatedly in Desktop sessions

Observed details from another local Desktop session log:

originator: Codex Desktop
pattern: repeated approval assessment / TRANSCRIPT DELTA messages

These injected blocks include prior tool call arguments, tool outputs, retry reasons, and planned actions. They appear to increase context size and may be contributing to slower Desktop reasoning or UI responsiveness.

Example 3: Desktop session interrupted shortly after starting

Observed details from another local Desktop session log:

originator: Codex Desktop
event:      turn_aborted
reason:     interrupted

From the user side, this corresponds to a session that appeared stuck and had to be interrupted.

Expected Behavior

  • Codex Desktop should not become significantly slower than CLI/TUI after long context, compaction, or approval-review injection.
  • Approval transcript / TRANSCRIPT DELTA data should not cause unbounded context growth or repeated heavy reprocessing.
  • The UI should clearly distinguish model reasoning, tool execution, waiting for approval, and frontend/UI unresponsiveness.
  • If a session becomes stuck, Desktop should provide a reliable recovery path without requiring a new session.

Possible Areas to Investigate

  1. Whether Desktop repeatedly injects or over-injects approval transcript / tool output history.
  2. Whether context_compacted causes later turns to receive unexpectedly large or inefficient context.
  3. Whether Desktop UI rendering of long reasoning/tool output blocks blocks interaction.
  4. Whether turn_aborted represents explicit user interruption only, or also UI hangs where interruption is the only recovery path.
  5. Differences between Desktop and CLI/TUI context assembly for the same workflows.

Notes

I can provide redacted snippets from the session logs if needed, but I would avoid attaching full raw jsonl logs publicly because they may include local paths, commands, repository names, and internal work context.

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 becomes slow or stuck after context compaction and approval transcript injection