[macOS] Recent loading loop pegs renderer at ~100% CPU; collapsing sidebar drops it to ~2%
What version of the Codex App are you using (From “About Codex” dialog)?
26.810.52044 (build 6662)
What subscription do you have?
ChatGPT subscription (exact tier not verified)
What platform is your computer?
Darwin 25.5.0 arm64 arm (macOS 26.5.2, build 25F84)
What issue are you seeing?
Summary
In the macOS Codex desktop app, the Recent area can remain indefinitely in a loading state after the remote task-list request fails. While the sidebar is expanded, the primary Renderer stays near one full CPU core and retains substantially more memory. Collapsing the sidebar immediately restores normal resource usage without restarting the Renderer.
Local Codex history remains healthy during the incident.
Observed behavior
- Recent never leaves the loading state, including after the active local turn has completed.
- Restarting Codex and remounting/switching the view did not clear the state.
- Local app-server
thread/listrequests continued to succeed quickly. - Desktop logs recorded repeated failures for:
/backend-api/wham/tasks/list?limit=20&task_filter=current
including timeouts/connection resets and HTTP 500/503 responses.
- Local state databases passed
PRAGMA quick_check; there was no SQLite lock or corruption error.
Same-process A/B measurement
Five samples were taken before and after collapsing the sidebar. The Renderer PID stayed the same, so this was not a process restart:
| State | Renderer CPU | Renderer RSS | Whole app CPU | Whole app RSS |
|---|---:|---:|---:|---:|
| Recent/sidebar expanded and stuck loading | 98.0% | 822.8 MiB | 120.3% | 1929.3 MiB |
| Sidebar collapsed | 1.9% | 173.2 MiB | 8.2% | 819.9 MiB |
The app-server was near idle in the high-CPU snapshot. A short process sample concentrated the hot path on the Renderer V8/JavaScript main thread while the compositor thread was mostly waiting. This points to a visible sidebar state/render loop rather than model execution or the spinner's CSS animation alone.
What steps can reproduce the bug?
- Launch Codex Desktop on macOS and keep the Recent sidebar expanded.
- Let the cloud task-list request fail or become unavailable while local
thread/liststill succeeds. The failure in this report occurred naturally; no network configuration was changed to induce it. - Wait until the active local turn completes.
- Observe that Recent remains in a loading state and the primary Renderer stays near 100% CPU.
- Restart the app or switch away and back; the loading state may persist.
- Collapse the sidebar.
- Observe the same Renderer PID drop from about 98% CPU to about 2%, with a large RSS reduction.
The exact trigger may be the interaction between the failed cloud-list query and the visible Recent component tree, rather than either one alone.
What is the expected behavior?
A remote/cloud task-list failure must degrade gracefully without blocking healthy local task history or keeping the Renderer busy.
Most importantly, failed requests must not remain in an unbounded retry/loading loop:
- After a bounded number of failed attempts, stop active retries and leave the loading state.
- Render an explicit non-blocking error or stale-data state and provide a user-triggered Retry action.
- If background recovery is necessary, use capped exponential backoff with jitter rather than continuous retries.
- Continue rendering successful local
thread/listresults independently. - The Renderer should return to idle resource usage after the failure is handled.
Additional information
Related reports:
- #16857: hiding the thinking/loading indicator by collapsing the sidebar lowers GPU usage.
- #34183:
/wham/tasks/list503 responses break the merged sidebar while localthread/listremains healthy. - #37518: repeated conversation-list requests can leave the macOS sidebar waiting on retries.
This report adds a same-Renderer CPU/RSS A/B measurement on app version 26.810.52044. Full logs are not attached because they contain local paths and session identifiers; sanitized excerpts can be provided if needed.
5 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
Symptom: Codex App shows a never-ending spinner in the bottom-left "recent threads" panel, one
Codex (Renderer)process pegged at 100%+ CPU, restarts don't help. Hiding the panel drops CPU immediately.Diagnosis
sample <renderer pid>: main thread is entirely in V8 microtasks/JIT, meaning a JS-level rerender loop, not a network issue.``
bash
`sqlite3 ~/.codex/state_5.sqlite "SELECT COUNT(*) FROM threads WHERE thread_source='subagent' AND archived=0;"
approvals_reviewer = auto_review`, every approval spawns a subagent thread carrying the full transcript (1MB+ titles/previews), which overloads the list.A count in the hundreds or thousands confirms it: with
Fix (back up first)
Then delete the matching rollout jsonl files (export their paths from the backup DB before deleting). Archiving (
UPDATE threads SET archived=1 WHERE thread_source='subagent') is the softer option, but in this case only full deletion resolved it.Also check:
~/.codex/process_manager/chat_processes.jsonaccumulates dead process records; resetting it to[]helps too.Root cause in one sentence: unbounded subagent thread accumulation plus a render loop in the list widget; clearing the data is the workaround, the widget loop is the upstream bug for the Codex team to fix.
Confirming the same issue on another Mac.
Environment
Observed
thread/listcontinues to succeed quickly andpinnedThreadsis empty.ResizeObserver loop completed with undelivered notificationsover about 9m42s.This appears consistent with a sidebar renderer/layout loop. It also reproduces with dozens of subagent threads, not only the hundreds or thousands mentioned in the previous comment. I can provide sanitized log excerpts if useful.
Same issue, after reset the ~/.codex/.codex-global-state.json file is ok
I had the same issue and may be able to contribute with info on a consistently reproducible cause.
I had a remote system with SSH connection configured, but that remote system did not have the Codex CLI installed. This appeared to be the cause - disabling that remote connection removed the issue.
The symptom was a constantly active spinner in the side panel and like other users report here, collapsing that side panel (or switching to the settings view that doesn't show it) temporarily reduced the CPU usage. At any time when the sidebar was visible, 100% CPU usage would resume.
So in short: seems like this is a re-checking issue with no grace period or graceful failing when a remote SSH connection is inoperable. Codex will continuously attempt to connect to the remote and use the CLI and will never stop trying even after failure.