Archiving active Desktop chat leaves stale active session and stale archived rollout path after unarchive

Open 💬 2 comments Opened Jun 3, 2026 by zeropc1106

Summary

When archiving the chat that is currently open in the Codex Desktop app, the main window continues to keep that session as the active session and the input box remains interactive. Subsequent attempts to restore/continue the chat or create a task fail because the backend correctly sees the session as archived.

After unarchiving the same chat from the Archived Chats settings page, the app may still try to resolve the rollout from the old archived_sessions path, causing a missing file error.

Steps to reproduce

  1. Open Codex Desktop and select an existing chat in a workspace.
  2. Without switching to another workspace or another chat, archive the currently active chat.
  3. The chat appears to be archived, but the main window remains focused on that same session.
  4. Try to restore/continue the conversation, or type a message and submit it.
  5. Go to Settings, then return to the app.
  6. The window is still focused on the archived session and the same error keeps appearing.
  7. Go to Settings > Archived Chats and unarchive the chat.
  8. Return to the app and open/use the same chat again.

Actual behavior

After archiving the currently active chat, the UI still treats the archived session as active. The input box remains usable and actions such as restoring the conversation or creating a task are still possible from the UI, but they fail with an error like:

session <id> is archived. Run `codex unarchive <id>` to unarchive it first.

After unarchiving the chat from the Archived Chats page, the UI may still reference the old archived rollout path and fail with:

failed to resolve rollout path `<home>/.codex/archived_sessions/rollout-...-<id>.jsonl`: No such file or directory (os error 2)

Expected behavior

After archiving the currently active chat, the app should immediately do one of the following:

  • switch to a new chat,
  • show the archived chat in a read-only archived state,
  • or refresh/clear the active session so the input box and restore/task actions are disabled.

After unarchiving the chat, the app should refresh the session path and no longer reference archived_sessions for that session.

Impact

This leaves Codex Desktop in a broken state: the current chat remains focused and interactive, but restore/continue/task creation fails. Even after unarchiving, the app can continue failing because it still uses the stale archived rollout path.

Notes

This looks like a stale active session / stale rollout path issue after archiving or unarchiving the currently focused chat. It seems easier to reproduce when the user does not switch to another workspace or another chat before archiving.

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗