Claude Desktop (MSIX/Windows Store build) fails to persist session metadata with EXDEV error — sidebar empty on every restart
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
Environment
- OS: Windows 11 Home (China edition), build 10.0.26200
- Claude Desktop version: 1.3883.0.0
- Install type: MSIX package at
E:\WindowsApps\Claude_1.3883.0.0_x64__pzs8sxrjxfjjc\ - Installation source: Official download
Summary
On Windows with the MSIX-packaged Claude Desktop, the Code feature's left-side conversation sidebar is empty on every app restart. Root cause: fs.rename fails with EXDEV: cross-device link not permitted when persisting session metadata, so nothing is ever saved to claude-code-sessions\<id>\<account>\.
Workaround I'm using
None effective from Desktop UI. Reading conversation content directly from the JSONL files as read-only history; no way to resume sessions within Desktop itself.
Happy to provide additional logs or test any fix.
What Should Happen?
Suggested fix
Fall back to fs.copyFile + fs.unlink when fs.rename fails with EXDEV. Standard pattern for Node.js atomic writes on systems with virtualized/redirected filesystems. Example:
\\\javascript\
try {
await fs.rename(tmp, dest);
} catch (err) {
if (err.code === 'EXDEV') {
await fs.copyFile(tmp, dest);
await fs.unlink(tmp);
} else {
throw err;
}
}
\\
Error Messages/Logs
## Log evidence (`%APPDATA%\Claude\logs\main.log`)
Repeatedly throughout the log (hundreds of occurrences):
\`\`\`
[error] Failed to save session local_076d5b59-b251-415e-bb76-9c219b2ee8b3:
EXDEV: cross-device link not permitted,
rename 'C:\Users\86182\AppData\Roaming\Claude\claude-code-sessions\418561af-c0f6-411e-a70c-43f08eb0d9a8\057243bc-100f-4fb1-a3ea-4c95406dbb58\local_076d5b59-b251-415e-bb76-9c219b2ee8b3.json.tmp'
-> '....json'
at async Object.rename (node:internal/fs/promises:782:10)
at async EC.writeSessionToDisk (E:\WindowsApps\Claude_1.3883.0.0_x64__pzs8sxrjxfjjc\app\resources\app.asar\.vite\build\index.js:1391:7012)
\`\`\`
## Confirmed impact
- `claude-code-sessions\<id>\<account>\` is **empty** (no `.json` files ever persisted)
- `git-worktrees.json` tracks all 12 historical worktrees correctly — not the issue
- Conversation content JSONLs at `%USERPROFILE%\.claude\projects\<namespace>\*.jsonl` **are** saved (different code path, uses a different storage mechanism) — so only the sidebar index is broken, actual content is preserved
## Likely root cause
MSIX file-system virtualization causes the `.json.tmp` and target `.json` to resolve to different physical volumes after virtualization redirect, even though both logical paths are under `%APPDATA%\Claude\`. `fs.rename` can't perform atomic cross-volume rename → EXDEV.
Steps to Reproduce
- Open Claude Desktop, go to Code
- Start a conversation, send a few messages
- Close the app
- Reopen the app
- Observe: conversation sidebar on the left is empty. Previously-used worktrees still appear in the worktree list (correctly loaded from
git-worktrees.json), but clicking into any of them shows an empty conversation history.
Claude Model
None
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
1.3883.0.0
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
Other
Additional Information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗