Codex Desktop macOS: archiving the currently viewed chat leaves right pane on archived thread and triggers `session is archived`
Summary
On Codex Desktop for macOS, archiving the currently viewed chat appears to succeed on the backend, but the Desktop UI does not navigate away from that chat. The right-side viewer remains bound to the just-archived thread, then the app immediately shows a red error/toast:
Failed to resume chat
session <thread_id> is archived. Run `codex unarchive <thread_id>` to unarchive it first.
This looks like an active-thread navigation/state bug after thread/archive: the archived thread is still treated as the current resumable thread instead of the UI clearing the active route, switching to another non-archived thread, or showing a new-chat empty state.
This seems closely related to #25713, which reports the same active-thread-after-archive resume loop on Windows. This issue is for the same/similar behavior confirmed on macOS, with the visible symptom that the right pane/viewer stays on the archived chat.
Environment
- Product: Codex Desktop
- Platform: macOS / Darwin
- Chat type observed: projectless/local chat
- Exact Codex Desktop version: not collected yet
- Bundled CLI version: not collected yet
Version can be collected with:
/Applications/Codex.app/Contents/Resources/codex --version
Steps to reproduce
- Open Codex Desktop on macOS.
- Open a local/projectless chat so it is the currently viewed active chat in the right-side viewer.
- Click Archive on that same currently viewed chat.
- Observe that the archive action appears to complete, but the right-side viewer remains on the same chat instead of navigating away.
- A red error/toast appears saying the same thread is archived and suggesting
codex unarchive <thread_id>.
Expected behavior
After archiving the currently viewed/active chat, Codex Desktop should do one of the following:
- clear the active conversation/viewer route and show a new-chat empty state;
- navigate to the next available non-archived thread;
- if the user is intentionally viewing an archived thread, show an archived/read-only/unarchive recovery state.
It should not call thread/resume or goal hydration on the thread it just archived.
Actual behavior
The archive itself appears to succeed, but the renderer/viewer remains bound to the archived thread. The app then tries to resume the same archived thread and shows:
session <thread_id> is archived. Run `codex unarchive <thread_id>` to unarchive it first.
This makes the archive action look like it failed, even though the underlying state is likely already archived.
Notes / likely cause
The important detail is that the thread id in the error is exactly the thread that was just archived. That suggests the issue is not a corrupt session and not a failed archive; rather, the active conversationId / route / viewer state is not cleared after a successful archive.
Potential client-side fix:
- On successful
thread/archive, if the archived thread id matches the currently active conversation id, immediately clear the active conversation id or navigate away. - Re-query/select only non-archived threads for the next active thread.
- Guard
thread/resume/thread/goal/getso they are not called for archived threads. - If no non-archived thread exists, display a new-chat empty state.
Workaround currently used
Avoid archiving the chat that is currently open in the right pane. Instead, first switch to a different/new chat, then archive the target chat from the sidebar. If already stuck, restarting the app or clearing UI/session storage can clear the stale active route; codex unarchive <thread_id> only restores the archived chat and is not desired when the user actually intended to archive it.
Related issues
- #25713 — Same active-thread archive/resume loop reported on Windows.
- #20317 — Archived local thread cannot be resumed after restore due to sessions/archived_sessions path mismatch.
- #18216 — Archived thread route/deep-link lacks recovery UI.
- #11907 — macOS app has archive/unarchive refresh gap.
10 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
Additional confirmation from Codex Desktop on macOS. This reproduces for archiving the currently viewed/active thread: archive succeeds, then the UI repeatedly tries to resume the same archived
conversationIdand shows the redFailed to resume chattoast.Environment observed:
codex-cli 0.136.0-alpha.2codex-cli 0.136.0019e884c-78ce-7ea2-8218-b2035c938952Local state checks after archiving:
~/.codex/archived_sessions/rollout-2026-06-02T08-26-13-019e884c-78ce-7ea2-8218-b2035c938952.jsonl.threadsrow in~/.codex/state_5.sqlitehadarchived=1androllout_pathpointing toarchived_sessions.codex doctor --summary --asciireported state DBs healthy andthreads rollout files and state DB thread inventory agree.Relevant log pattern:
The same archive-then-resume loop also appeared for another archived session in the same app log, so this does not appear isolated to one corrupt thread.
Workaround confirmed: switch to another/new thread before archiving the target thread, or unarchive via
codex unarchive <session_id>if already stuck. The underlying archive state appears correct; the visible failure is the app continuing to route/resume the archived active conversation.I’m seeing this frequently on macOS as well.
Environment:
26.527.60818codex-cli 0.136.0-alpha.215.6.1 arm64Latest toast from the app:
This happens after archiving a chat from the Desktop UI. The archive appears to work, but the UI remains bound to the archived thread and tries to resume it.
Seeing this as well. Then the remaining chat will sometimes show a message from the archived chat and it will blink in and out, as if caught in a re-render loop.
This happens upon clicking "confirm" when archiving a chat in the sidebar.
Edit:
<img width="1056" height="273" alt="Image" src="https://github.com/user-attachments/assets/d5119778-aa9c-452c-9f04-4c7e0b7ee321" />
Seeing this today as well. In my case its the keyboard shortcut to archive, but same result. Codex helpfully sent me here to search for existing issues :)
codex appand directly from dock.Another macOS confirmation from Codex Desktop. This happens every time I archive/delete a chat from the app UI: the archive appears to succeed, then the app immediately shows the red
Failed to resume chattoast for the same just-archived session.Environment:
26.601.20914(3497)codex-cli 0.136.0-alpha.2codexon PATH:codex-cli 0.133.0(notably does not exposearchive/unarchive, while the bundled app CLI does)26.5(25F71)Local checks after reproducing:
codex doctorreported the state DBs as healthy.archived = 1in~/.codex/state_5.sqlite.~/.codex/archived_sessions, so this did not look like storage corruption or a failed archive.projectless-thread-idslist looked stale: 208 ids total, only 4 active, 149 archived, 55 missing. That may be unrelated, but it seems consistent with archived/missing sidebar entries still being treated as selectable/resumable UI state.User-visible behavior: after archiving/deleting a chat, no extra action is taken, but the app still tries to resume that archived chat and shows the error. This makes normal chat cleanup noisy even though the underlying archive seems to have worked.
same issue
Another confirmation from Codex Desktop on macOS. This reproduces when archiving from the recent tasks menu: the archive succeeds, then the Desktop UI immediately tries to resume the same archived conversation and shows the red
Failed to resume chattoast.Environment:
26.601.21317(3511)codex-cli 0.136.0-alpha.2codex-cli 0.136.026.5(25F71) arm64Two session ids observed in back-to-back reproductions:
019e8bcf-303c-7932-b8cc-3260608f760c019e8bd1-ba84-76a0-9b8b-c588e2c5541cLocal state after reproducing:
archived=1in~/.codex/state_5.sqlite.~/.codex/archived_sessions:rollout-2026-06-02T21-47-51-019e8bcf-303c-7932-b8cc-3260608f760c.jsonlrollout-2026-06-02T21-50-38-019e8bd1-ba84-76a0-9b8b-c588e2c5541c.jsonlcodex doctorreports state DBs healthy, but also reports thread inventory warnings: rows pointing at missing/unusable archived rollout files. That may be unrelated, but the two reproduced sessions above had valid archived files and DB rows.Relevant log sequence for
019e8bd1-ba84-76a0-9b8b-c588e2c5541c:Same pattern for
019e8bcf-303c-7932-b8cc-3260608f760c: archive requested fromrecent_tasks_menu, then repeatedmethod=thread/resumefailures for the same archived conversation id.This looks like the archive action is correct, but the mounted Desktop route/view continues to hydrate/resume the just-archived active conversation instead of navigating away or clearing the active conversation.
Adding another macOS repro with the same active-thread-after-archive state bug.
Environment:
codex-cli 0.136.0-alpha.2Observed flow:
Expected behavior: after archiving the active thread, Desktop should shut down/clear that active thread route and navigate to a net-new thread/new-chat state, or to another non-archived thread. It should not leave the archived thread as the target for resume or new task creation.
Check whether your iCloud storage is full: Codex reads your Non-project session from ~/Documents/Codex. If sessions from other devices have not been downloaded locally, that error may occur.