codex - 💡(How to fix) Fix Mac app hides older local conversations after update because bogus root-level `status` sessions flood recent local history [2 comments, 3 participants]

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…
GitHub stats
openai/codex#18364Fetched 2026-04-18 05:55:12
View on GitHub
Comments
2
Participants
3
Timeline
5
Reactions
0
Author
Timeline (top)
labeled ×3commented ×2

Root Cause

  • At some point the app created a large number of bogus local sessions with:
    • source='cli'
    • cwd='/'
    • first_user_message / title values like status, atus, tus, us, s, status/status, us/status
  • In my case there were about 100 of these bogus root-level sessions.
  • They were newer than my real local conversations, with timestamps from April 16-17, 2026.
  • I had not been using the Codex CLI recently, so these do not seem to correspond to intentional CLI usage.
  • The app appears to only load a recent subset of local conversations. I saw telemetry/log evidence of thread_count_loaded_recent=50, and because the bogus sessions occupied that recent window, the real local conversations were pushed out of view.
  • The app also logged warnings like No cwd found for local task conversationId=... for those bogus thread IDs.

Fix Action

Fix / Workaround

Workaround that worked

  1. Back up ~/.codex/state_5.sqlite.
  2. Identify the bogus rollout JSONL files under ~/.codex/sessions/... that correspond to the root-level status / atus / tus / us / s sessions.
  3. Move those bogus rollout files out of ~/.codex/sessions to a backup/quarantine folder.
  4. Mark the matching rows in ~/.codex/state_5.sqlite as archived.
  5. Relaunch the app.
RAW_BUFFERClick to expand / collapse

What version of the Codex App are you using (From “About Codex” dialog)?

26.415.30602 (1773)

What subscription do you have?

Pro

What platform is your computer?

Darwin 25.4.0 arm64 arm

What issue are you seeing?

After updating and/or relaunching the Codex Mac app, all older local conversations disappeared from the sidebar. Only cloud conversations were visible, plus the new conversation I started to investigate this issue. This new conversation persisted across all restarts while investigating.

The local data was not deleted. The older conversations were still present on disk in ~/.codex/sessions, and they also existed in ~/.codex/state_5.sqlite.

What appears to be happening is:

  • At some point the app created a large number of bogus local sessions with:
    • source='cli'
    • cwd='/'
    • first_user_message / title values like status, atus, tus, us, s, status/status, us/status
  • In my case there were about 100 of these bogus root-level sessions.
  • They were newer than my real local conversations, with timestamps from April 16-17, 2026.
  • I had not been using the Codex CLI recently, so these do not seem to correspond to intentional CLI usage.
  • The app appears to only load a recent subset of local conversations. I saw telemetry/log evidence of thread_count_loaded_recent=50, and because the bogus sessions occupied that recent window, the real local conversations were pushed out of view.
  • The app also logged warnings like No cwd found for local task conversationId=... for those bogus thread IDs.

Things that did not fix it:

  • Restarting the app
  • Clearing app-side cache/storage
  • Rebuilding or deleting state_5.sqlite
  • Rebuilding or deleting session_index.jsonl (when present)
  • Archiving the bogus rows in state_5.sqlite only

DB-only fixes were not durable because on relaunch the app re-imported the bogus sessions from ~/.codex/sessions.

Workaround that worked

  1. Back up ~/.codex/state_5.sqlite.
  2. Identify the bogus rollout JSONL files under ~/.codex/sessions/... that correspond to the root-level status / atus / tus / us / s sessions.
  3. Move those bogus rollout files out of ~/.codex/sessions to a backup/quarantine folder.
  4. Mark the matching rows in ~/.codex/state_5.sqlite as archived.
  5. Relaunch the app.

After removing those bogus rollout files and re-archiving the matching DB rows, the older local conversations reappeared.

What steps can reproduce the bug?

  1. Start with an existing Codex Mac app setup that already has many local conversations stored in ~/.codex/sessions.
  2. Update the Codex Mac app.
  3. Quit and relaunch the app.
  4. Open the sidebar and compare local history.
  5. Observe that older local conversations are missing, while cloud conversations and the current/new local conversation still appear.
  6. Inspect ~/.codex/state_5.sqlite after relaunch.
  7. Observe many newly created local rows with source='cli', cwd='/', and titles / first messages like status, atus, tus, us, s.

Manual reproduction attempt If the above doesn't repro, the symptom can likely be reproduced by seeding bogus local session rollouts and relaunching Codex:

  1. Start with a Codex Mac app profile that already has real local conversations in ~/.codex/sessions.
  2. Add at least 50 newer bogus rollout files under ~/.codex/sessions/... that look like local CLI/TUI sessions with:
    • source="cli"
    • originator="codex-tui"
    • cwd="/"
    • user message / title values like status, atus, tus, us, or s
  3. Remove or rebuild ~/.codex/state_5.sqlite so the app re-imports session history from ~/.codex/sessions.
  4. Relaunch Codex.
  5. Observe that older real local conversations disappear from the sidebar, while newer cloud/current conversations still appear.

What is the expected behavior?

Existing local conversations should still appear in the sidebar after updating and relaunching the Mac app. The app should not generate bogus root-level status sessions that displace real local conversation history.

Additional information

No response

extent analysis

TL;DR

The most likely fix for the issue of missing older local conversations in the Codex Mac app is to remove the bogus local session rollout files and archive the corresponding rows in the state_5.sqlite database.

Guidance

  1. Identify and remove bogus session files: Look for files under ~/.codex/sessions/... with source='cli', cwd='/', and titles like status, atus, tus, us, or s, and move them out of the sessions directory.
  2. Archive corresponding DB rows: Mark the matching rows in ~/.codex/state_5.sqlite as archived to prevent the app from re-importing the bogus sessions.
  3. Verify the fix: Relaunch the app and check if the older local conversations reappear in the sidebar.
  4. Prevent future occurrences: Monitor the ~/.codex/sessions directory for new bogus session files and remove them promptly to avoid displacing real local conversation history.
  5. Check app updates: Wait for an official update from the Codex team that addresses the issue of generating bogus local sessions.

Example

No code snippet is provided as the issue is related to data files and database management.

Notes

This workaround may not be a permanent solution, and the issue may recur if the app continues to generate bogus sessions. The Codex team should investigate and fix the root cause of the problem.

Recommendation

Apply the workaround by removing the bogus session files and archiving the corresponding DB rows, as it has been proven to resolve the issue temporarily.

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