You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Windows Codex Desktop 26.924: Archive fails from UI ("无法归档对话") and app API, but codex archive CLI succeeds #49116
appIssues related to the Codex desktop appapp-serverIssues involving app server protocol or interfacesbugSomething isn't workingwindows-osIssues related to Codex on Windows systems
Environment
• OS: Windows 11 x64
• Codex Desktop: 26.924.22138 (build 11645), prod channel
• Bundled codex-cli: 0.158.0-alpha.2.1
Summary
On this build, archiving a local thread from the sidebar shows the error 无法归档对话(cannot archive conversation). The archive request never reaches the app server (nothread/archive JSON-RPC in logs). The app-level archive API also fails with Could not determine the account for worktree cleanup. However, the bundled CLI codex archive archives the same thread successfully.
Steps to reproduce
Open Codex Desktop on Windows.
Hover over a local thread in the sidebar, click ⋯ → 归档聊天.
Observe the error 无法归档对话; the thread stays in the active list.
Actual behavior
• UI archive fails and the thread is not archived.
• No thread/archive request appears in the app-server logs (request is blocked client-side).
• Invoking archive through the app API returns Could not determine the account for worktree cleanup.
• After archiving successfully via codex archive , the sidebar still shows the stale thread title until the entry is clicked or the app is restarted.
Expected behavior
• Archive should work from the sidebar and remove the thread from the active list.
• The sidebar should refresh immediately after a successful archive.
Additional context
• The earlier Windows os error 2archive failure was fixed by PR Deduplicate rollout moves when archiving threads #39256; this appears to be a separate regression in the 26.924 UI/API path.
• Related: Windows Codex Desktop: archived tasks cannot be deleted, are missing from the web archive, and the archive-first workflow is misleading #46240 (Windows archive/delete workflow gaps), [Windows] Local thread archiving fails with thread-store os error 2 #39130 (os error 2, fixed).
Sidebar -> Archive shows "Failed to archive conversation" (无法归档对话); thread stays in the active list.
No thread/archive RPC ever goes out - only "Archive requested", then nothing.
Deleting the exact same conversation works fine, so it is specific to the archive path.
Every conversation in the workspace is affected, including brand-new ones.
Restarting Desktop does not change anything.
Here the bundled CLI escape hatch does not work either - codex archive <id> returns "Error: failed to archive session".
Looks like the same client-side preflight issue as #48367 (account lookup for worktree cleanup throwing before the RPC). I am not signed in and would rather keep it that way, so archiving from the UI used to work previously and should keep working for custom-provider users.
Follow-up after more testing on the same machine (Windows 11 23H2, Desktop 26.924.22138, bundled CLI 0.158.0-alpha.2.1):
Correction to my earlier comment: the CLI Error: failed to archive session I saw there was not the same failure as the UI preflight. It was the thread-writer lock. The desktop app keeps <thread-id>.lock in %USERPROFILE%\.codex\thread-writer-locks\ for sessions it has loaded, and codex archive <id> fails while that lock is held. The lock file is opened with FILE_SHARE_DELETE, so renaming the canonical name out of the way while the app is still running is enough: the next codex archive <id> returned exit 0, the thread flipped to archived in the local state DB, and the rollout moved to archived_sessions. Verified twice on idle threads, and reversible with codex unarchive.
That still does not explain the UI button in the original report: on my install the sidebar action fails before any RPC is sent (Could not determine the account for worktree cleanup, no thread/archive in the log) - the client-side preflight in #48367, not a lock conflict. So there appear to be two distinct blockers on this build: (a) account/worktree preflight for the UI path, and (b) writer-lock conflicts for the CLI/agent path.
I wrapped the lock workaround in a small local tool in case it helps others blocked by (b): https://github.com/HenryFone/codex-archive-manager - Windows 11 + 26.924 tested, Python standard library only, binds 127.0.0.1 only, and every state change goes through the official codex archive/unarchive/delete; it never writes the SQLite DB itself. It cannot fix the UI preflight. I understand the writer lock exists to protect concurrent writers, and I am not suggesting it be weakened - the owner-side release/handoff direction discussed in #45406 is the real fix.
appIssues related to the Codex desktop appapp-serverIssues involving app server protocol or interfacesbugSomething isn't workingwindows-osIssues related to Codex on Windows systems
Activity
github-actions commentedon Sep 29, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
HenryFone commentedon Sep 30, 2026
Can confirm the same regression from the UI side on Windows, with a bit more environment detail that may help narrow it down.
codex login status->Not logged in), no auth.jsonrequires_openai_auth = falseWhat I see:
thread/archiveRPC ever goes out - only "Archive requested", then nothing.Here the bundled CLI escape hatch does not work either -
codex archive <id>returns "Error: failed to archive session".Looks like the same client-side preflight issue as #48367 (account lookup for worktree cleanup throwing before the RPC). I am not signed in and would rather keep it that way, so archiving from the UI used to work previously and should keep working for custom-provider users.
HenryFone commentedon Oct 1, 2026
Follow-up after more testing on the same machine (Windows 11 23H2, Desktop 26.924.22138, bundled CLI 0.158.0-alpha.2.1):
Correction to my earlier comment: the CLI
Error: failed to archive sessionI saw there was not the same failure as the UI preflight. It was the thread-writer lock. The desktop app keeps<thread-id>.lockin%USERPROFILE%\.codex\thread-writer-locks\for sessions it has loaded, andcodex archive <id>fails while that lock is held. The lock file is opened with FILE_SHARE_DELETE, so renaming the canonical name out of the way while the app is still running is enough: the nextcodex archive <id>returned exit 0, the thread flipped to archived in the local state DB, and the rollout moved toarchived_sessions. Verified twice on idle threads, and reversible withcodex unarchive.That still does not explain the UI button in the original report: on my install the sidebar action fails before any RPC is sent (
Could not determine the account for worktree cleanup, nothread/archivein the log) - the client-side preflight in #48367, not a lock conflict. So there appear to be two distinct blockers on this build: (a) account/worktree preflight for the UI path, and (b) writer-lock conflicts for the CLI/agent path.I wrapped the lock workaround in a small local tool in case it helps others blocked by (b): https://github.com/HenryFone/codex-archive-manager - Windows 11 + 26.924 tested, Python standard library only, binds 127.0.0.1 only, and every state change goes through the official
codex archive/unarchive/delete; it never writes the SQLite DB itself. It cannot fix the UI preflight. I understand the writer lock exists to protect concurrent writers, and I am not suggesting it be weakened - the owner-side release/handoff direction discussed in #45406 is the real fix.