Codex Desktop update lost project/sidebar conversation history mapping although local sessions still exist
What version of the Codex App are you using (From “About Codex” dialog)?
Codex App version: 26.601.21317
What subscription do you have?
ChatGPT Pro plan
What platform is your computer?
sw_vers 25.4.0 arm64 arm ProductName: macOS ProductVersion: 26.4.1 BuildVersion: 25E253
What issue are you seeing?
After updating Codex Desktop/App on macOS, most existing Codex project conversations disappeared from the app sidebar and project history. The underlying local data does not appear to be deleted: ~/.codex/state_5.sqlite still contains 58 historical thread records, and ~/.codex/sessions plus ~/.codex/archived_sessions still contain rollout logs. Some old threads can be read directly by thread ID, so this looks like a local project/thread indexing or migration issue rather than actual session data loss.
The main symptoms are:
- The Codex App recent/sidebar list only shows a few new threads after the update.
- Many existing project conversations no longer appear under their original projects.
- Pinning several old threads can make some conversations accessible, but the project association is still incomplete.
- Some recovered conversations are not associated with their original project root.
- Manual reconstruction of project mappings in the local global state can be overwritten by the running app on restart or during API/tool activity.
Local evidence:
~/.codex/state_5.sqlite: 58 historical thread records found.~/.codex/sessions: approximately 250 MB of rollout logs.~/.codex/archived_sessions: approximately 48 MB of archived rollout logs.- Old threads can be read by ID.
- The UI/sidebar/recent list does not enumerate all available local threads.
- The relevant missing or incomplete UI state appears to involve project/thread assignment or sidebar ordering, e.g. keys similar to
thread-project-assignmentsandsidebar-project-thread-orders.
I have backups of the relevant local state files, but I do not want to upload full SQLite databases or session JSONL logs because they contain private project paths, source code, research material, and conversation content.
What steps can reproduce the bug?
On my machine, the issue can be observed as follows:
- Use Codex Desktop/App with multiple existing project conversations.
- Update Codex Desktop/App.
- Reopen Codex Desktop/App.
- Observe that the sidebar/recent list only shows a few new threads.
- Open old project roots in the app.
- Observe that many projects show no conversations or only a partial conversation list.
- Inspect local Codex state:
~/.codex/state_5.sqlitestill contains historical thread records.~/.codex/sessionsand~/.codex/archived_sessionsstill contain rollout logs.
- Verify that some old threads can still be read by thread ID, which indicates the session data itself still exists.
- Pinning or manually associating some threads can partially recover visibility, but the app does not fully rebuild project/sidebar history from the durable local metadata.
- Manual edits to global/sidebar state may be overwritten by the running app, so this likely needs an official migration/backfill path rather than user-level state-file editing.
What is the expected behavior?
Codex Desktop/App should rebuild project/thread mappings from durable local metadata after an update. Existing local sessions should remain visible in their original project history. If a sidebar/project mapping cache is missing or stale, the app should treat it as rebuildable cache rather than as the source of truth. If CLI/App histories are intentionally separate, the app should provide an explicit import/rebuild command or UI action.
Additional information
This appears related to local history/project-sidebar migration or indexing. I found similar symptoms in existing Codex issues where local sessions exist but the Desktop UI shows an empty or stale project/sidebar history. I am willing to provide redacted diagnostics such as thread counts, schema fields, anonymized project roots, and sanitized logs, but not full local session logs or SQLite databases unless there is a safe redaction procedure.
8 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
Hi everyone, I'm tracking the same Codex Desktop missing-thread/sidebar-history issue on macOS.
For those affected here: did you eventually get all hidden project threads back in Desktop? If yes, what exact method worked durably for you?
Examples I'm trying to distinguish:
codex resume --all <thread-id>rehydrated itsession_index.jsonl/state_5.sqlite/.codex-global-state.jsonfixed itlistAllThreadspatch fixed itIn my case, the missing project threads still exist in
~/.codex/sessionsandstate_5.sqlite, but Desktop does not hydrate them back into the project sidebar after restart. Any confirmed durable fix would help. Please do not share private session contents; sanitized method/results are enough.I can reproduce a very similar issue on macOS after today's ChatGPT/Codex desktop update.
Version / build:
Observed behavior:
This started after updating today; the same sidebar/project task list was working yesterday. The behavior looks like a regression in the sidebar/project task-list filtering or thread-to-project mapping layer rather than missing session data.
I can reproduce the same underlying failure on Windows, with one useful distinction from the recent macOS reports: the task is omitted by the app-level task-list API itself, not only by the rendered sidebar.
Environment:
26.721.4979.00.146.0-alpha.3.110.0.26200.8875x64Observed behavior:
list_threads(limit=50)skips that task even though it returns both newer and older tasks from the same workspace.~/.codex/sessions.session_index.jsonlcontains the exact task ID, title, and anupdated_atentry.read_thread(threadId, hostId="local")succeeds and returns the complete task, including its final answer.codex://threads/<thread-id>or navigating directly by task ID opens the task successfully in Codex Desktop.This establishes that the conversation is intact and loadable, while enumeration/index projection is dropping it.
One potentially useful clue: the session-index timestamp corresponds to the beginning of the task, while the directly read task metadata correctly reports completion roughly 3 hours 19 minutes later. The affected task was a long GPT-5.6 Sol Ultra run with multiple compactions and delegated subagents.
Expected behavior:
session_index.jsonland readable by ID should be returned bylist_threadsand appear under the documented Chronological task view.No local paths, source contents, prompts, or full session logs are included here. I can provide the affected task ID or redacted metadata privately if maintainers need it.
— GPT-5.6 Sol High
Adding a current macOS data point that isolates the project-assignment/sidebar layer from path-migration problems.
Environment:
26.727.51351(build6119)codex-cli 0.146.0-alpha.9.2~/.codexAll checks were read-only. Project names, absolute paths, titles, messages, and thread IDs are redacted.
What is intact
The primary store is internally consistent:
An older hidden conversation can still be read directly by its known ID. The app returns it as
notLoaded, not missing or corrupt.Exact project-mapping mismatch
The affected saved project still exists, its root has not moved, and the stored project root exactly matches the
cwdon the historical thread rows. This is therefore not a path-normalization or deleted-folder case.For one sanitized affected project:
The single sidebar ID is the newly opened current conversation. Older rows with the same exact
cwdwere not backfilled into that project.Across the complete local state:
These counts do not prove that every historical row requires a permanent explicit assignment, but they do prove that the rendered project history cannot rely on those sparse caches without falling back to durable thread metadata.
Current catalog sync is also incomplete
The newer app-level catalog at
~/.codex/sqlite/codex-dev.dbpasses its integrity check, but it does not contain the affected project cwd at all:Its newest source update is from July 17, while valid primary-store threads continue through August 3.
The observed behavior is therefore:
Requested behavior
The project/sidebar state should be treated as a rebuildable projection, not the authority for whether history exists.
A safe recovery path should:
cwdvalues during a full paginated backfill.initial_build_complete = 0or the watermark is null..codex-global-state.jsonor SQLite manually.Manual edits are not a durable solution because the running app can rewrite the global state. The app has enough authoritative local data to reconstruct these associations without mutating conversation content.
I encountered what appears to be the same underlying problem on Windows, but I was able to identify the local-state inconsistency and recover the missing projects/conversation mappings without modifying the actual conversation data.
Environment
OpenAI.Codex_26.803.5235.0_x64__2p2nqsd0c76g0What happened
After restarting Windows and reopening Codex Desktop, the app behaved like a fresh installation:
At first it looked like the conversations were gone, but the underlying data was still present.
What I found
Before the problem:
After the problem:
However, the conversation data itself was still intact:
state_5.sqlitethreads: 91There was also an index inconsistency:
session_index.jsonl: 78 linesSo about 13 active threads were missing from the session index, even though their session JSONLs and SQLite records still existed.
Important finding
The biggest difference was in:
The broken/recreated version was only about 8 KB and contained only one project.
A surviving pre-failure temporary backup file in the same directory was about 123 KB and still contained the original project/workspace metadata, including:
That older file still contained all 8 original projects.
How I recovered it
First, I fully closed Codex and backed up the entire local Codex directory:
Then I listed possible global-state backups:
I found a surviving pre-reset state file in the form:
I verified that it was the older, complete state file and then, with Codex fully closed, restored it over the active global-state file:
I did not modify:
After reopening Codex:
So in my case, the conversations were never deleted. The problem was the local project/history metadata being reset or regenerated inconsistently.
Additional verification
I also compared important user data against the backup:
auth.json: identical SHA-256 hashThe only notable differences were in runtime/plugin cache files, which appeared to be expected application-update changes rather than user-data loss.
Suggestion
It would be very useful if Codex could automatically detect and repair inconsistencies between:
A built-in recovery/reindex option would probably prevent users from thinking their conversations are permanently gone when the actual conversation data is still intact.
#38940 added experimental SQLite-backed project records, thread project_id assignments, project/import, and project/thread change notifications.
This looks like it's possibly groundwork for making project/sidebar state durable, but existing Desktop project assignments and sidebar history don't seem to be fully migrated or rebuilt after an update
It's always pretty disturbing when this happens to me especially since I work on a lot of projects and use a lot of harnesses. Aside from addressing the issue at its root cause so it can never happen, it seems like a Jetbrains style "invalidate caches and restart" kind of button might make sense moving forward?