Skip to content

Bug report: Local projects disappear from sidebar after Windows desktop update #42739

Open

Description

@rizal281065

Bug report: Local projects disappear from sidebar after Windows desktop update

Summary

After updating the Codex/ChatGPT Windows desktop app, the Projects section shows No projects. Existing chats remain visible under Recents, and all source folders still exist on disk.

Environment

  • OS: Windows 11
  • Installed Windows package: OpenAI.Codex_26.901.4073.0_x64
  • App-server client version observed in logs: 26.901.31953
  • Bundled Codex CLI: codex-cli 0.153.1

Steps to reproduce

  1. Have multiple local Codex projects with chats assigned to them.
  2. Update the Windows desktop app.
  3. Launch Codex.
  4. Inspect the left sidebar under Projects.

Actual result

  • Sidebar displays No projects.
  • Clicking Choose project opens Create project, requiring projects to be recreated manually.
  • Restarting the app and restarting Windows do not restore the projects.
  • Closing the visible app window does not terminate all ChatGPT.exe background processes.

Expected result

Existing local projects and their chat assignments should be migrated and remain visible after an update.

Diagnostic evidence

The underlying data was checked locally:

  • state_5.sqlite still contains 14 project records and 14 project roots.
  • All 14 source folders still exist.
  • 54 of 62 local threads have a non-null project assignment.
  • The desktop global-state file is rewritten on startup with:
    • local-projects: {}
    • thread-project-assignments: null
    • migration state projectsMigrated: true
    • migration state threadAssignmentsMigrated: false
  • Reconstructing the sidebar registry while the app is running is overwritten by the app's in-memory state when it closes.
  • A recovery helper waiting for the app to exit timed out after 30 minutes because background ChatGPT.exe processes remained active after the window was closed.

This looks like a Windows desktop migration/regression where the durable SQLite project records survive, but the sidebar registry and thread-assignment migration do not load or complete.

Data-loss impact

No source folders appear to be deleted, but project organization is effectively lost in the UI. Manually recreating the projects would also require users to remember which chats belonged to each project.

Activity

  1. added
    bug
    app
    windows-os
    session
    on Sep 4, 2026
  2. github-actions commented on Sep 4, 2026

    @github-actions
    Contributor
  3. Takanashi-Rikka1 commented on Sep 4, 2026

    @Takanashi-Rikka1

    I can confirm the same issue on app-server version 26.901.31953.

    My local read-only diagnostics show the same incomplete migration state:

    projectsMigrated: true
    threadAssignmentsMigrated: false

    In my case:

    • 6 project definitions still exist in state_5.sqlite
    • all 6 project roots still exist
    • all 1,115 thread rows survived
    • all threads retain their original cwd
    • however, all 1,115 threads currently have project_id = NULL
    • local-projects is empty
    • thread-project-assignments is missing

    A valid pre-migration snapshot still contains the original 6 projects and 89 exact thread-to-project assignments.

    So this appears to be the same migration regression, but in my case the thread-assignment migration failed completely rather than partially.

  4. Vitorrro commented on Sep 4, 2026

    @Vitorrro

    Independent reproduction on Windows, with a more severe thread-assignment outcome.

    Environment:

    • Codex Desktop app-server version before restart: 26.901.31953
    • Version after the restart/update: 26.901.41123
    • Windows local Codex workspace

    Observed:

    • All local projects disappeared from the Projects section.
    • A full application restart did not restore them.
    • The SQLite database passes PRAGMA quick_check (ok).
    • state_5.sqlite still contains 11 project records and 29 project-root records.
    • All project folders and durable session files remain present.
    • The database contains 66 local threads, but 0 now have a non-null project_id.
    • Global state has an empty local-projects registry.
    • Migration state remains:
      • projectsMigrated: true
      • threadAssignmentsMigrated: false

    The state was inspected read-only and a verified backup was made before any recovery attempt. No database or history record has been modified.

    Impact: the underlying work is still present, but all local project organization and chat-to-project associations are unavailable in the UI. This is a high-severity data-integrity and recovery issue because manual re-creation risks losing the original mapping.

    Please provide or implement a supported way to re-run/repair this migration from the durable SQLite project and session records.

  5. Vitorrro commented on Sep 4, 2026

    @Vitorrro

    Additional deterministic evidence from the same Windows reproduction (sanitized):

    • After a full Desktop restart on client build 26.901.41123, the host log reports: [host-app-server-projects] Local app-server project migration completed projectCount=11.
    • A direct project/list control returns the same 11 projects and 29 roots, while the Desktop sidebar still renders no local projects. This isolates a post-load visibility/gating failure rather than missing project records.
    • Separately, all 66 threads still have project_id = NULL. A recovery rehearsal on a disposable copy, using the supported thread/metadata/update API and deepest-root matching, restored 47 unambiguous thread associations with 0 errors. Counts remained 11 projects / 66 threads and PRAGMA quick_check remained ok; all non-project thread fields, project rows, and roots were byte-for-byte/value identical.

    No live user database has been modified. The UI visibility defect must be resolved (or a supported bypass provided) before this recovery can produce the expected sidebar state.

  6. Vitorrro commented on Sep 5, 2026

    @Vitorrro

    Update after installing today's Windows package: the issue persists on OpenAI.Codex_26.901.5280.0_x64 with bundled codex-cli 0.153.4.

    Fresh startup evidence:

    • Host log again reports [host-app-server-projects] Local app-server project migration completed projectCount=11.
    • Sidebar still shows no local projects.
    • The live state database remains healthy (PRAGMA quick_check = ok) with 11 projects, 29 roots, and 66 threads, but 0 thread project assignments.
    • Static inspection of the newly installed renderer bundle still contains the showLocalProjects, adminWorkLocalEnabled, workspace-disabled, admin_work_local_enabled, and feature-gate 1463309241 code paths.

    So package 26.901.5280.0 does not repair the migration or the post-load sidebar visibility failure. No live database/history records were modified during this verification.

  7. Vitorrro commented on Sep 5, 2026

    @Vitorrro

    Final recovery evidence on Windows package 26.901.5280.0:

    • After a verified backup, 47/47 unambiguous thread associations were restored through the supported thread/metadata/update app-server method while Desktop was fully closed.
    • After reopening Desktop, the live database still has 11 projects, 29 roots, 66 threads, and 47 non-null project assignments; PRAGMA quick_check remains ok.
    • Nevertheless, the Desktop-facing project inventory still exposes only ChatGPT projects and no local projects, and .codex-global-state.json still has an empty local-projects object with no thread-project-assignments entry.

    This confirms two independent regressions: (1) thread-project assignments were lost during migration, and (2) even after supported assignment recovery, the renderer/sidebar continues to suppress all durable local projects. The remaining blocker is the post-load local-project visibility/gating path, not the data layer.

  8. juerghegglin commented on Sep 6, 2026

    @juerghegglin

    Additional Windows reproduction on Codex Desktop 26.901.51231, with one potentially useful migration edge case.

    I had the same user-visible symptom: Projects → No projects, while local source folders and conversations remained present.

    Forensics

    Pre-migration global-state snapshot:

    • 9 project definitions
    • 9 project roots
    • 45 legacy thread-project-assignments

    Current state_5.sqlite after migration:

    • 9/9 projects successfully created
    • 9/9 roots successfully created
    • 9/9 legacy project IDs mapped to new app-server project UUIDs through project_idempotency_keys
    • initially 0 threads had project_id

    Migration marker was:

    • projectsMigrated: true
    • threadAssignmentsMigrated: false

    Potentially important edge case

    Of the 45 legacy thread assignments:

    • 43 referenced project IDs that had successfully migrated.
    • The remaining 2 referenced the same legacy project ID.
    • That legacy project ID no longer had a corresponding definition in the same pre-migration local-projects snapshot.
    • It therefore had no mapping in project_idempotency_keys.

    Those two stale assignments belonged to old automation threads rooted in a local repository that was no longer registered as a project.

    This suggests the assignment migration may be failing all-or-nothing when it encounters a stale project reference, rather than migrating the 43 valid mappings and leaving only the 2 unresolved/projectless.

    Recovery experiment

    After making a complete backup of the Codex state directory:

    • Restored only the 43 unambiguous thread assignments.
    • Used the existing project_idempotency_keys table as the authoritative legacy-ID → new-project-UUID mapping.
    • Left the 2 stale/orphaned assignments projectless.
    • state_5.sqlite retained all 9 projects and roots.
    • 43 threads then had valid non-null project_id values.
    • Desktop still rendered No projects.

    Additional Desktop-state evidence

    The separate Desktop catalog database under the Codex state directory contained:

    • local host: 212 threads
    • local project assignments: 0
    • ChatGPT-hosted catalog: 246 threads
    • ChatGPT-hosted project assignments: 162 across 12 projects

    Of the 43 repaired state-database threads:

    • 19 were also present in the Desktop local catalog.
    • All 19 still had project_id = NULL there.
    • None of the new app-server project UUIDs appeared anywhere in the local Desktop catalog.

    Desktop did issue project/list requests during startup, and no project-specific app-server error was found around those requests.

    Interpretation

    This reproduction appears to show the same two independent failures already discussed here:

    1. Legacy thread-project assignment migration can fail while project creation succeeds.
    2. Even after durable SQLite thread assignments are repaired, Desktop continues to suppress the valid local project inventory.

    The potentially new detail is the presence of 2 stale legacy thread assignments referencing a project that no longer existed in the legacy project registry.

    A useful migration regression test could seed:

    • several valid legacy projects and assignments;
    • one stale thread-project-assignment referencing a deleted/nonexistent project;
    • then verify that valid assignments still migrate and only the stale mapping remains unresolved.

    Disclosure: this comment was drafted and worded by ChatGPT based on my local diagnostics; I reviewed and approved the content before posting.

  9. cwr256 commented on Sep 10, 2026

    @cwr256

    使用codex,我临时解决了。如下:

    临时解决方法:local-projects 数据不完整导致本地项目消失

    我的测试环境:

    • Windows
    • Codex Desktop OpenAI.Codex 26.903.8094.0
    • Desktop 捆绑的 Codex CLI / app-server 0.153.4

    问题表现

    • state_5.sqlite 执行 PRAGMA quick_check 返回 ok

    • project/list 可以正常返回全部本地项目

    • Desktop 日志显示:

      Local app-server project migration completed projectCount=<正确数量>
      
    • 已分配到项目的历史会话从 Recent 消失

    • 真正无项目的会话仍然显示在 Recent

    • 左侧 Projects 区域为空

    我这里的根因

    这个案例中,我之前使用自定义迁移脚本重建了:

    $CODEX_HOME/.codex-global-state.json
    

    其中 local-projects 下的项目对象只有:

    {
      "id": "...",
      "name": "...",
      "rootPaths": ["..."]
    }

    但当前版本的 Desktop 还要求每个本地项目包含数字类型的时间戳:

    {
      "id": "...",
      "name": "...",
      "rootPaths": ["..."],
      "createdAt": 1234567890000,
      "updatedAt": 1234567890000
    }

    当项目对象缺少 createdAt 或 updatedAt 时,前端 schema 校验会静默丢弃该项目,没有明显的 React/schema 报错,因此最终只表现为 Projects 为空。

    这也解释了为什么项目中的会话会从 Recent 消失:会话分配关系仍然存在,但对应的项目容器已经被前端过滤。

    如何确认是否属于同一种问题

    首先以只读方式打开 state_5.sqlite,执行:

    PRAGMA quick_check;

    应返回:

    ok
    

    然后检查旧项目 ID 与 core project 的映射:

    SELECT
        pik.key AS legacy_project_id,
        p.id AS core_project_id,
        p.name,
        p.created_at_ms,
        p.updated_at_ms
    FROM project_idempotency_keys AS pik
    JOIN projects AS p
        ON p.id = pik.project_id;

    需要确认:

    1. 每个 local-projects 的 key 都能匹配 project_idempotency_keys.key
    2. 每条映射只对应一个 core project
    3. thread-project-assignments 引用的项目 ID 都存在于 local-projects
    4. local-projects 项目缺少的确实只是 createdAt 和 updatedAt

    修复方法

    重要:必须先完全退出 Codex Desktop,并在任务管理器中确认没有 ChatGPT.exe 进程。

    如果在 Desktop 运行期间修改文件,退出时它可能用内存中的旧状态覆盖修复结果。

    1. 备份:

      $CODEX_HOME/.codex-global-state.json
      $CODEX_HOME/state_5.sqlite
      
    2. 不要修改 SQLite。

    3. 对 local-projects 下的每个项目,使用对象的 key 作为 legacy project ID。

    4. 通过以下关系查找时间戳:

      local-projects 的项目 key
          → project_idempotency_keys.key
          → project_idempotency_keys.project_id
          → projects.id
      
    5. 把数据库中的时间戳添加到对应项目对象:

      "createdAt": 1234567890000,
      "updatedAt": 1234567890000

      值分别来自:

      projects.created_at_ms
      projects.updated_at_ms
      

      必须写成 JSON 数字,不能写成字符串。

    6. 不要修改:

      • 项目 ID
      • 项目名称和 rootPaths
      • thread-project-assignments
      • project-order
      • SQLite 中的 project_id
      • sessions 或 rollout 文件
      • migration flags
    7. 验证 JSON 格式正确后,再启动 Codex Desktop。

    在我的环境中,离线补齐这两个字段后,所有本地项目以及对应的历史会话都重新恢复显示。

    注意

    这是针对内部 Desktop 状态文件的应急恢复方法,不是官方公开接口。

    只有同时满足以下特征时才建议尝试:

    • SQLite 项目目录完整且健康
    • project/list 能正常返回项目
    • local-projects 中仍有项目记录
    • 项目对象只缺少 createdAt / updatedAt
    • legacy project ID 可以通过 project_idempotency_keys 唯一映射

    如果数据库损坏、项目已经被删除、ID 无法唯一匹配,或者故障特征不同,请不要直接套用此方法。

    另外需要特别说明:这个案例是因为自定义迁移脚本生成了不完整的 local-projects 状态对象,因此并不代表 Codex Desktop 在正常使用、没有手工修改内部状态的情况下也一定会出现同样的问题。

    OpenAI 官方文档说明 CODEX_HOME 是 Codex 状态目录,默认是 ~/.codex;但其中各内部状态文件的 schema 并不是公开稳定接口:

    https://learn.chatgpt.com/zh-Hans/docs/config-file/environment-variables

  10. TTTIII2025 commented on Sep 12, 2026

    @TTTIII2025

    Additional Windows reproduction, still present on OpenAI.Codex 26.908.4834.0 (desktop release reported in logs: 26.908.40834; bundled app-server: 0.153.4). Windows 11 build 26200.

    Read-only diagnostics establish this sequence:

    • A valid September 3 local state snapshot contains 16 local project definitions, the legacy-to-server project ID map, and 263 explicit thread-to-project assignments.
    • On September 9 at 08:03:12 UTC, desktop version 26.901.6511.0 logs two Failed to load global state warnings with a JSON parse error identifying a NUL (U+0000) character. This resembles the state-load failure in [Windows] Re-added local projects lose historical sessions after project-state/index recovery #43661.
    • A September 10 snapshot and the current global state have local-projects: {}. The legacy project ID map and explicit thread-project assignment registry are absent. The migration state says projectsMigrated: true, threadAssignmentsMigrated: false.
    • The current state_5.sqlite passes read-only PRAGMA quick_check with ok. It retains 16 project records and 16 project roots. All 16 root directories exist.
    • At the diagnostic snapshot, the database contains 1,714 thread rows (including internal/subagent rows), with 0 non-null project_id values. This is not a count of user-visible conversations. A historical user task remains readable through the desktop task-reading tool, and archived-task listing works.
    • Startup logs on the current desktop release still report Local app-server project migration completed projectCount=16, while the desktop list_projects tool returns only ChatGPT projects and zero local projects. No unavailable host/source is reported by list_threads.

    There is an operational impact beyond the sidebar: three scheduled-run failures across September 9 and 12 report Automation project no longer exists, affecting two existing automations. Their target project records and directories still exist. Static inspection of the installed current desktop bundle shows that the automation project resolver reads LOCAL_PROJECTS from global state and throws this error if the legacy entry is missing. This is consistent with the empty registry causing those failures; no automation was manually triggered during diagnosis.

    The earliest confirmed failure in this environment predates today's update. The NUL corruption's underlying cause is unknown, and I am not attributing that write failure to a specific updater operation. The current state file parses successfully but has lost the legacy registry. Project/source-file deletion is not supported by the checks above; full integrity of every historical session and source file has not been established.

    Please investigate recovery after a global-state parse failure, reconciliation with the durable SQLite project inventory and legacy ID mappings, completion of thread assignment migration, and the automation resolver's dependency on the missing legacy registry. A supported recovery path that preserves existing project identities and history would be preferable to recreating projects.

    No live state/configuration/history files were edited, no projects were recreated, and no schedules were changed. This report intentionally excludes account identifiers, local paths/project names, session identifiers, raw logs, credentials, screenshots, and conversation contents.

  11. kmich commented on Sep 14, 2026

    @kmich

    Additional diagnostic for Windows users seeing “Projects disappeared”

    I had almost identical symptoms: all of my normal local Projects and chats disappeared, while a different set of imported Projects appeared. My original state_5.sqlite, sessions, project records, and conversation history were all still intact.

    In my case this was not ultimately caused by deleted history or the project migration itself.

    A recently installed tool had set a persistent Windows user environment variable:

    CODEX_HOME=G:\Hermes\codex

    Codex Desktop inherited that variable on restart and therefore opened an entirely different Codex state directory. The alternate CODEX_HOME had its own state_5.sqlite, Projects, and thread history, which exactly matched what the Desktop UI was showing.

    Useful diagnostic on Windows:

    "Process = $([Environment]::GetEnvironmentVariable('CODEX_HOME','Process'))"
    "User    = $([Environment]::GetEnvironmentVariable('CODEX_HOME','User'))"
    "Machine = $([Environment]::GetEnvironmentVariable('CODEX_HOME','Machine'))"
    

    Also compare:

    %USERPROFILE%\.codex\state_5.sqlite

    against the state DB under whatever CODEX_HOME reports.

    After removing the unintended user-level CODEX_HOME, fully terminating Codex/ChatGPT background processes, and starting Codex Desktop normally, all of my original Projects immediately returned.

    So for anyone seeing this symptom, I strongly recommend checking CODEX_HOME before modifying SQLite, rebuilding indexes, reinstalling, or assuming the sessions were deleted.

    This does not prove that CODEX_HOME is the cause of the migration issue reported here. It is a separate cause that produces an almost identical user-visible symptom.

  12. 62 remaining items

  13. ORI-Fourreaumaxime commented on Nov 5, 2026

    @ORI-Fourreaumaxime

    Recurrence on Windows — November 5, 2026

    The issue recurred on the same installation after the recovery I reported on October 17. After a desktop app update, the local Projects list was empty and existing threads no longer appeared under their projects. Threads still appeared in history.

    Environment — Windows 11 25H2 x64, build 26200.9711. Microsoft Store package OpenAI.Codex version 26.1029.7803.0. This is the version observed during diagnosis. The exact update transition and root cause remain unconfirmed.

    Before recovery

    • state_5.sqlite passed PRAGMA quick_check and contained 29 project records and 5,716 thread records. Zero thread records had a non-null project_id.
    • .codex-global-state.json had an empty local-projects registry and no entries in thread-project-assignments.
    • The local migration state showed projectsMigrated = true and threadAssignmentsMigrated = false.

    Recovery verified — After fully exiting the app and verifying a backup, I reconstructed the JSON project registry using the existing project IDs and restored 260 exact historical thread-to-project associations across 24 projects. After reopening Codex, all 29 project entries and 260 associations were present, and I opened an older thread from its project. The recovery required no SQLite edits or migration flag resets.

    Could the Windows desktop team investigate why the project registry and historical memberships disappear across updates, and provide a supported recovery procedure that preserves existing project IDs and thread history? A regression test using a profile with historical JSON associations and incomplete assignment migration would cover the observed state.

    Previous recovery report: #42739 (comment)

    Local recovery and update checks

    I built a Python recovery tool and a separate Windows Task Scheduler check. Two parts may be useful to the desktop team:

    • Recovery. After all profile writers exit, the tool makes a hash-verified backup of the JSON and SQLite metadata, including any WAL/SHM files present. It resolves saved project IDs against the surviving catalog, keeps current assignments and explicit projectless choices, and restores only exact historical links whose thread and project still exist. It replaces the affected JSON fields atomically, then checks that the projects and links persist after reopening the app.
    • Update checks. The scheduled task saves versioned snapshots of project metadata outside the Codex profile. It reads the version of the running Store app and compares project IDs and individual memberships after a version change. If projects or links disappear or move, it retains the last verified baseline and writes a local report for review.

    The recovery was verified on the affected profile. The scheduled task also ran successfully there. Its update checks were exercised with simulated intact and missing-membership scenarios. Validation against a subsequent real update is still pending.

    If this would help, I can share a sanitized standalone version of the tool, synthetic before/after fixtures, and the checks for incomplete migrations, concurrent writes, and disappearing assignments. Would the desktop team prefer a minimal reproduction fixture or a reference implementation?

  14. Reza-Vaez commented on Nov 6, 2026

    @Reza-Vaez

    After a Codex update on Windows, my local projects and previous chats stopped appearing. Fully quitting and restarting the app did not fix it.

    We found that my 18 local projects still existed in the database, but the saved local-projects list in .codex-global-state.json was empty.

    This is the procedure that actually worked for me:

    1. A repair script named restore-codex-projects.py was prepared.

    2. While Codex was still open, I started the script from Windows PowerShell using:

      & "PATH\TO\python.exe" "PATH\TO\restore-codex-projects.py"
      example: & "C:\Users\SampleUser\AppData\Local\Programs\Python\Python311\python.exe" "C:\Users\SampleUser\Documents\Codex\2026-11-05\n\outputs\restore-codex-projects.py"

      Replace these placeholders with the locations of Python and the attached repair script on your computer.

    3. The script waited for the desktop app to close.

    4. I fully quit Codex using Quit/Exit.

    5. Once the app had closed, the script backed up the settings file and rebuilt the empty local project list using the existing database records.

    6. I waited until PowerShell displayed:

      Restored 18 projects
      
    7. I reopened Codex. My projects and their chats were visible again.

    The script restored the project list; it did not recreate chats or modify their contents. The exact cause of the update issue remains unconfirmed.

    Attach the actual restore-codex-projects.py file to this post. The version used in my repair was prepared specifically for my installation and expected 18 projects, so it needs adjustment before being used on another computer.

  15. sjyEva commented on Nov 6, 2026

    @sjyEva

    Recovery confirmed — Windows Codex Desktop 26.1029.61003

    After a Codex Desktop update, most local projects disappeared from the sidebar, while project folders and session data remained intact.

    Read-only findings:

    • SQLite integrity check: ok
    • state_5.sqlite: 27 projects, 30 project roots, 944 threads (all project_id = NULL)
    • .codex-global-state.json: 3 local projects, 2 order entries, 11 chat assignments (2 local, 9 remote)
    • 27 unique, valid idempotency-key-to-project mappings; 4 orphan mappings excluded
    • Both local chat assignments matched existing threads and valid projects
      Recovery:
    • Reconstructed the project registry using validated legacy IDs, SQLite metadata, and existing JSON mappings.
    • Restored local-projects from 3 to 27 and project-order from 2 to 28, preserving the original order entries, including the remote project.
    • Expanded ID mappings from 4 to 28 while preserving all 11 chat assignments.
    • Rejected stale recovery candidates when the live JSON hash changed and blocked replacement while code.exe was running.
    • After closing VS Code, atomically replaced only .codex-global-state.json, with a verified backup and rollback snapshot. SQLite, session files, and migration flags remained unchanged.
      Result: All 27 local projects were recovered in Codex Desktop.

    This is a profile-specific, unsupported workaround, not an official fix. It restores the project registry but does not reconstruct historical project assignments for all 944 threads.

  16. asx888 commented on Nov 6, 2026

    @asx888

    Additional affected installation — Windows desktop 26.1103.31037, November 6, 2026

    Reporting an additional affected installation with the user's authorization.

    Environment

    • Windows 10, x64.
    • Desktop updater reports version 26.1103.31037, build 25241, production channel.
    • Update check on November 6 returned up_to_date for the configured update channel. This is not evidence that the defect is fixed.

    User-observed trigger and persistence

    1. Local projects and their chat grouping worked before a desktop update on this same computer.
    2. After the update, switching accounts caused the local projects to disappear; existing chats remained visible as individual conversations.
    3. The user switched back to the original account and confirmed the original workspace was selected. The projects did not return.
    4. The user fully quit the app through its menu and reopened it. The projects still did not return.

    These steps were reported and checked by the affected user; the update/account-switch sequence has not been independently replayed on a clean profile.

    Read-only findings on the affected profile

    • state_5.sqlite still contains 6 project records.
    • 0 thread records have a non-null project_id.
    • The active renderer globals have 0 local-projects and 0 thread-project-assignments.
    • An inactive account renderer-state snapshot still preserves 6 local projects and 43 explicit chat-to-project assignments.
    • The saved local migration state reports:
    {
      "projectsMigrated": true,
      "threadAssignmentsMigrated": false,
      "pendingThreadAssignmentCount": 45
    }
    • The inspected source-code folders still exist on disk.
    • Sidebar grouping is already set to project, so this is not simply a flat-list preference.
    • The pending count and explicit-assignment count come from different saved fields; they are not being treated as identical sets.

    This appears consistent with lost/unrestored renderer project registration plus incomplete membership migration, but the exact cause remains unconfirmed. No live database, account-scope state, migration flags, or feature gates were modified. The original state and project metadata were backed up locally.

    Impact and requested resolution
    The user can access old conversations but cannot use the original local project organization, even after returning to the original account/workspace and fully restarting the app.

    Please investigate account-switch project-state restoration and membership migration on this current build, and provide a supported recovery procedure that preserves original project IDs and exact historical chat membership. Please also confirm any planned fix version or release timing if known.

    This comment intentionally excludes account identifiers, credentials, private filesystem paths, project names, chat IDs/content, full state files, and raw logs.

  17. KadenID commented on Nov 6, 2026

    @KadenID

    Additional Windows Reproduction — Codex 26.1103.3517.0: Projects Disappeared After Windows Update Restart Hangs, With Duplicate Project IDs and Pending Thread Assignments

    I am experiencing the same issue and have conducted extensive read-only diagnostics. I would like to share additional findings that may help identify the cause and develop a non-destructive recovery procedure.

    Status: Unresolved as of November 6, 2026.

    1. Environment

    Component | Value -- | -- Application | OpenAI Codex Windows Desktop Package | OpenAI.Codex Version | 26.1103.3517.0 OS | Windows 11 Home Windows version | 10.0.26200 Windows build | 26200 Python used for diagnostics | 3.13.14 Data directory | %USERPROFILE%\.codex CODEX_HOME | Not explicitly configured Time zone | KST (UTC+09:00) Diagnostic method | Python sqlite3, read-only mode, against a backup

    All 131 pending records satisfy the diagnostic heuristic for top-level conversation candidates.

    Unlike the other group, none of the pending records was identified as a subagent session by the inspected source metadata.

    These classifications are heuristic, not authoritative counts of user-visible conversations.

    13. Preliminary Interpretation

    The available evidence suggests several potentially related problems:

    A. Project catalog or sidebar reconciliation failure

    Historical project records are present in SQLite, but the application does not reliably display them.

    B. Incomplete or inconsistent thread-assignment restoration

    All SQLite thread project_id fields are NULL.

    The inspected global-state files lack explicit thread-project assignment mappings.

    Exactly 131 top-level conversation candidates are simultaneously recorded as pending and projectless.

    C. Duplicate project creation during manual recovery

    Ctrl+O appears to create a new project identity for an existing registered root rather than reusing the historical project.

    D. Project membership reclassification when opening conversations

    Opening a historical conversation causes its displayed project association to disappear and moves it to Recents.

    E. Possible contributing Windows restart event

    The project disappearance was discovered after repeated Windows Update restart hangs and a forced shutdown.

    Two unexpected shutdowns were independently confirmed in Windows event logs.

    However, there is no direct evidence yet that Windows Update or the forced shutdown caused the Codex metadata inconsistency.

    These problems may involve multiple distinct defects.

    14. Data Preservation and Precautions

    Confirmed:

    • Historical project records remain present.

    • Original local project directories exist.

    • All 454 thread records are readable.

    • All threads retain nonempty working-directory metadata.

    • Sampled conversations open normally.

    • SQLite quick integrity check passes.

    • A backup of the Codex state directory exists.

    • Diagnostics were performed read-only.

    Not yet confirmed:

    • Completeness of every historical conversation transcript.

    • Authoritative original membership of every conversation.

    • Whether clicking a conversation permanently modifies assignment metadata.

    • Whether the Windows Update installation completed or rolled back.

    • Whether the Windows shutdowns directly contributed to the Codex failure.

    No destructive recovery actions have been performed:

    • No SQL UPDATE or DELETE.

    • No manual global-state JSON modifications.

    • No migration flag changes.

    • No duplicate project deletion.

    • No mass thread reassignment.

    • No destructive reset or reinstall.

    Additional Ctrl+O recovery experiments have been stopped.

    15. Request to Maintainers

    Could the maintainers please investigate the following?

    1. Project catalog visibility: Why do valid historical SQLite project records remain present while the sidebar displays "No projects"?

    2. Thread-assignment migration: Is threadAssignmentsMigrated=False, combined with 131 identical pending/projectless thread IDs, expected behavior in Codex version 26.1103.3517.0?

    3. Duplicate registration: Why does Ctrl+O create new project IDs for paths already associated with historical projects?

    4. Conversation reclassification: Why does opening a historical conversation remove its displayed project association and move it to Recents?

    5. Abnormal restart handling: Could Codex desktop state persistence or migration be vulnerable to an interrupted Windows shutdown or restart?

    6. Supported recovery procedure: Is there a non-destructive way to restore the original local project catalog and historical conversation assignments while preserving existing project IDs?

    A supported recovery method should ideally:

    • Reuse original historical project IDs.

    • Reconcile duplicate IDs without deleting conversations.

    • Restore membership using authoritative metadata rather than cwd inference alone.

    • Preserve all existing sessions and project directories.

    • Remain stable across sign-out, sign-in, and application restart.

    I can provide additional sanitized diagnostic outputs or metadata-only evidence if useful.

    Raw SQLite databases, authentication data, private directory paths, and full conversation transcripts will not be posted publicly.

    Thank you for investigating this issue.

  18. cmderdanblackburno7 commented on Nov 6, 2026

    @cmderdanblackburno7

    I had the same issue on 4th November. Codex ran initial on-boarding again (which I skipped) It was several jobs later that I realized that Codex was not working in the assigned workspace and all the project context had been lost.

  19. MatthiasCantini commented on Nov 6, 2026

    @MatthiasCantini

    I am seeing the same missing-local-projects issue on Windows with Codex package version 26.1103.3517.0, observed on November 6, 2026.

    Read-only checks found:

    • Original local project definitions and project-root records are still present in state_5.sqlite, and all registered project folders exist on disk.
    • SQLite PRAGMA quick_check returns ok.
    • All inspected thread records have project_id = NULL.
    • The saved local-projects registry is empty.
    • The local migration checkpoint has projectsMigrated: true and threadAssignmentsMigrated: false.
    • The desktop's built-in project-list tool returns ChatGPT projects but no local projects. Existing local chats remain listed with working-directory metadata.
    • Sidebar grouping is already set to project.

    A local backup was created. No repair was applied: no live database or settings edits, migration-flag resets, or project re-registration were performed during these checks. The exact trigger and root cause have not been established.

    Could you provide a supported recovery procedure that restores the original local project entries and chat associations while preserving existing project IDs and conversation history?

    This comment intentionally omits usage counts, project names, filesystem paths, account and thread identifiers, and conversation content. No raw logs, settings files, or databases are attached.

  20. CGI07 commented on Nov 7, 2026

    @CGI07

    For Windows users seeing No projects after an update, or older chats missing from their project groups, I released AI Repair Kit v1.0.0rc3 as an independent prerelease. Its read-only diagnostics can check whether local project records, registry entries, and chat links are still present before any repair is considered.

    Limited cache repairs are available for Windows MSIX builds 26.903.8094.0, 26.911.7940.0, 26.1013.3656.0, and 26.1029.7803.0 when the required records agree. Builds 26.915.4065.0, 26.924.2738.0, 26.1103.4239.0, and other unlisted builds are diagnosis-only for this cache issue. The repair tests use synthetic data, and successful recovery in the actual Codex Desktop UI has yet to be verified. The tool does not write to SQLite or restore conversation contents or Goals.

    If the read-only scan gives a result that does not match what you see, a reproducible report with the Windows version, Codex MSIX build, steps, and a reviewed support summary would help. Keep private paths, raw logs, databases, and chat text out of the report.

  21. Neoniq commented on Nov 7, 2026

    @Neoniq

    https://github.com/CGI07/ai-repair-kit Currently under development (incomplete)

    I also faced a problem from the topic. I can't check this repository qualitatively security wise, but will monitor thread if someone can.

  22. oflavioc commented on Nov 8, 2026

    @oflavioc

    Additional affected Windows installation, reported at the user's request.

    Version comparison and chronology (local time, UTC−03:00):

    • Windows deployment history shows OpenAI.Codex 26.1027.6604.0 registered on Nov 3. Desktop logs then reported Local app-server project migration completed projectCount=8.
    • 26.1103.4239.0 was staged Nov 6 and registered Nov 7 at 16:41. At 16:42, the new desktop build again logged projectCount=8.
    • Windows Event Log records an unexpected shutdown on Nov 8 at 02:12 and reboot at 02:37.
    • On desktop startup at 02:39, logs repeatedly recorded [global-state] Failed to load global state with Unexpected token '\u0000'. The same startup logged projectCount=9.

    Current observations: The Codex sidebar shows “No projects,” while Recents still shows chats. Read-only SQLite PRAGMA quick_check is ok; the database retains 9 projects and 9 roots, and the bundled app-server's project/list returns all 9. All 9 root directories exist. The current .codex-global-state.json has local-projects: {} and a migration checkpoint with projectsMigrated: true, threadAssignmentsMigrated: false. The 103 chats that were subsequently assigned to existing project IDs through the official thread/metadata/update API remain correctly assigned (11 archived chats stayed archived), but the sidebar stayed empty after a full restart.

    Read-only inspection of the current bundled desktop code shows the global-state loader tries the primary JSON and then .bak, returning an empty state if both fail. This is consistent with the observed empty display registry while project data survives in SQLite. The exact first moment the registry became empty, and whether the app update caused the null-byte corruption, are not established. The previous app binary is no longer installed locally for a code diff.

    Please provide a supported way to reconcile the sidebar registry from existing app-server project IDs, preserving chat associations, and investigate the behavior after corrupt primary/backup state. No private project names, paths, account identifiers, raw logs, databases, or transcripts are included.

  23. zhaowang-w commented on Nov 9, 2026

    @zhaowang-w

    Additional affected Windows installation, observed on 2026-11-09. Posting at the affected user's request.

    Symptoms and impact

    All existing local Codex projects disappeared from the Projects sidebar, while previous chats remained visible under Recents. The app also showed first-run onboarding again. The loss of project organization interrupts ongoing work and makes existing work appear lost.

    Environment and chronology

    • Windows 11 Enterprise, version 10.0.26300, x64.
    • The earliest confirmed state-load errors in the inspected November 9 startup log occurred at 01:12:58 UTC (09:12:58 UTC+08:00). Their stack traces reference package 26.1103.3517.0.
    • The currently running desktop package is OpenAI.Codex 26.1103.7773.0 x64; the desktop-facing project listing still returns an empty array.
    • The exact event that introduced the corruption is unknown. These observations do not establish that an update caused it.

    Read-only evidence

    The startup log repeatedly reports:

    [global-state] Failed to load global state
    Unexpected token '\u0000' ... is not valid JSON
    

    Later startup logs, including the current package's startup, report:

    [host-app-server-projects] Local app-server project migration completed projectCount=15
    

    Current local checks:

    • state_5.sqlite: 15 project records, 15 roots, 106 thread rows, and 0 non-null thread project_id values. The thread-row count is a database count, not a count of user-visible conversations.
    • SQLite PRAGMA quick_check returns ok.
    • .codex-global-state.json is currently valid JSON, but local-projects is empty and thread-project-assignments is absent.
    • The host migration checkpoint has projectsMigrated: true and threadAssignmentsMigrated: false.
    • Two retained older state snapshots still contain 13 project definitions and legacy-to-server project ID mappings, plus some explicit historical thread associations. The database also retains two more recently created projects.
    • Project folders and historical chat entries remain available. These checks do not establish the integrity of every source file or historical conversation.

    The NUL parse failure also resembles #43661. No live configuration/database repair, migration-flag reset, or project re-creation has been performed during diagnosis; a local state backup and a consistent SQLite snapshot were saved.

    Requested investigation

    Please treat this as a high-impact project-metadata persistence/recovery issue and investigate:

    1. How the global-state JSON becomes NUL-corrupted, including interrupted-write recovery.
    2. Why the desktop presents no projects while durable project records survive and startup reports successful project migration.
    3. How to reconcile the desktop registry and historical thread memberships using existing identities, with a supported repair/rebuild action.
    4. How onboarding state and known-good backups can be preserved when state parsing fails.

    No source-file deletion has been established. This report omits private project names, paths, account/session identifiers, conversation content, screenshots, credentials, and raw databases or full logs.

  24. jesse0032 commented on Nov 9, 2026

    @jesse0032

    Recurring Windows project-organization failure - 10 November 2026

    The user reports that local projects have disappeared from the desktop app more than once. This looks related to this report, but an identical cause has not been established.

    Environment observed today

    • Windows build: 10.0.26300.0.
    • Installed Windows package: OpenAI.Codex_26.1103.4239.0_x64.
    • The executable reports 157.0.8103.39; that may be an embedded runtime version, so it is not presented as the product's About version.

    Initial read-only observations

    • The relevant local folders still exist and are accessible.
    • Two paginated supported history queries returned 91 non-archived local chats. Of these, 80 have one affected project working directory and six have another. All 86 currently report projectId: null. This does not independently prove that every one had a stored project assignment before the incident.
    • The active project listing does not contain a project rooted at the first affected folder. The second folder is currently listed under a project name intended for the first.
    • Read-only inspection of the app's durable project/thread tables found original stored project links for 75 of those 80 first-folder chats. Five first-folder chats and the six second-folder chats are unassigned there. Thus the current API's null projectId results must not be interpreted as proof that all original assignments were deleted.
    • The original local project definitions remain in an inactive account-renderer-state snapshot. One original local project has ChatGPT backing metadata and a backing-recovery-pending flag.
    • The user reports correcting the recreated project names/folders, but repeated supported project queries and the current saved local-project registry still show the mismatch. The visible Edit project UI has not been independently inspected. A stale view, different account/window scope, incomplete reconciliation, or incorrect recovery selection remain possibilities.

    Trigger and recovery limits

    • The exact event that caused this recurrence was not captured. No controlled app-update, restart or account-switch reproduction was performed.
    • Account-scoped visibility/recovery is a lead, not a confirmed root cause.
    • The folder-name mismatch occurred during manual recovery and is not proof that the app originally selected the wrong folder automatically.
    • During this investigation no settings or project-registry files were edited, no chats were moved, no running chats were restarted, and no folders were moved or deleted.

    Expected behaviour
    Please preserve or provide a clear supported recovery for local project organization and chat grouping. If account isolation intentionally hides a ChatGPT-backed project, explain that state and how to return to the owning context. Re-adding a permitted local folder should not leave the user guessing which original chats will reconnect. Recovery must preserve histories, pins, existing working directories and account boundaries.

    Please investigate the account-scoped project catalogue, backing-recovery state, local-root matching and sidebar/thread-membership reconciliation. Useful guidance on the specific sanitized diagnostic fields needed would help.

    No company/project names, personal paths, account identifiers, chat identifiers, chat contents, credentials, screenshots or raw state files are included here.

    Recovery update before submitting: The user saved the corrected project settings. A fresh supported project query now reports both intended local folder roots under their correct project names. The chat history listing still reports the affected chats without project membership. Supported chat-regrouping recovery is being investigated separately; no local registry/database rewrite is being attempted.

  25. mitalioAdmin commented on Nov 10, 2026

    @mitalioAdmin

    Hello OpenAI Support Team,

    I am reporting a serious and recurring issue with the Codex desktop application on Windows.

    This is not the first time Codex has unexpectedly removed all my projects from the Projects interface.

    Today, November 10, 2026, I opened Codex and discovered that my entire Projects section was empty. All previously registered projects had disappeared.

    The project source-code folders still exist on my computer, as demonstrated in the attached screenshots. However, the projects and their associated conversation histories, development discussions, decisions, and accumulated context are no longer accessible through their original project structure.

    This is extremely disruptive because I use Codex extensively for software development across multiple projects. Each project contains substantial accumulated context developed through many conversations.

    My concerns are:

    1. Recurring issue: This has happened multiple times, making the application unreliable for long-term development work.
    2. Loss of context: Even though my source code remains saved locally, I lose access to the conversations, architectural decisions, requirements, and development history associated with my projects.
    3. Productivity impact: Recreating projects and rebuilding context requires significant time and effort.
    4. Data integrity: I am concerned that future incidents could permanently compromise or erase important development history.

    I have found similar reports in your GitHub issue tracker, including issue #42739, suggesting that this is an existing problem affecting other Windows users.

    I need your engineering team's assistance with the following:

    • Investigate why my projects repeatedly disappear.
    • Help restore my original projects with their complete conversation histories and project associations.
    • Confirm whether the original context and conversations are still recoverable from local application data.
    • Provide a permanent solution to prevent this from happening again.
    • Explain whether application updates or project-state synchronization could be responsible.

    I am attaching two screenshots showing the empty Codex Projects interface and the existing project folders on my computer.

    As a paying ChatGPT Pro subscriber who relies on Codex for substantial development work, I consider this a critical reliability issue.

    Please escalate this to the Codex desktop engineering team and provide a support case reference and recovery instructions.

    Thank you.

  26. alexg2009 commented on Nov 16, 2026

    @alexg2009

    I'm Alex, co-founder of Synesis OS. We're building a personal AI Chief of Staff focused on persistent memory, contextual intelligence, and keeping track of goals, decisions, and commitments.
    We've already built a working prototype, and we've recently opened our Private Beta waitlist.
    We're trying to better understand how people experience these challenges in their daily workflows, and your perspective caught my attention.

  27. piakwongnet-commits commented on Nov 22, 2026

    @piakwongnet-commits

    I'm experiencing the same issue on Windows with Codex Desktop version 26.1117.4957.0.

    My existing local project AI_TIKTOK_BOT_V2 has disappeared from the Projects sidebar, but the original folder still exists and opens normally.

    Verified details:

    • Project path: D:\AI Projects\AI_TIKTOK_BOT_V2
    • Git branch: codex/sprint8-multiproduct-content-pipeline
    • Git HEAD: faa11bf
    • No tracked file modifications were reported.
    • Two untracked files remain preserved.

    My previous Codex conversation, Build multi-product content pipeline, is still accessible in chat history and shows the original project name. However, the project label is not clickable, and the project does not appear in the Projects sidebar.

    I also successfully restored an accidentally archived conversation, but this did not restore the missing project.

    I have not deleted the repository, reset Codex, or created a duplicate project.

    Could the Codex team please investigate this issue and provide a safe way to restore the original project entry and its associated conversation history without losing any data?

    Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    appbugsessionwindows-os

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions