Repository navigation
codex resume hides sessions when current path differs only by case on WSL #7995
Description
What version of Codex is running?
codex-cli 0.72.0
What subscription do you have?
Plus
Which model were you using?
N/A
What platform is your computer?
Linux 6.6.87.2-microsoft-standard-WSL2 x86_64 x86_64
What issue are you seeing?
Summary
On WSL2, codex resume only shows sessions if the current working directory string matches the session workspace path exactly, including letter case.
The filesystem is effectively case-insensitive, so paths like:
/mnt/c/Users/Carlos/Desktop/Projects//mnt/c/Users/Carlos/desktop/projects/
refer to the same directory. Codex sessions created in one path are not visible to codex resume when I am in the other. The underlying ~/.codex/sessions files are shared and identical, but the resume picker shows No sessions yet in the second terminal.
This looks like the workspace filter for codex resume is doing a case sensitive string compare on the stored workspace path.
Environment
- Codex CLI version:
codex-cli 0.65.0 - Auth: ChatGPT Plus account
- OS: Windows 11 with WSL2
- WSL distro: Ubuntu 24.04
- Filesystem where repo lives: Windows NTFS mounted as
/mnt/c CODEX_HOME:$HOME/.codexwhich codex:/home/carlos/.nvm/versions/node/v24.11.1/bin/codex
What steps can reproduce the bug?
In WSL2, cd into a project directory and start a Codex session:
cd "/mnt/c/Users/Carlos/Desktop/Projects/"
codex
Have a short conversation, then exit Codex
Open another WSL terminal that uses the same distro and environment (same CODEX_HOME, same which codex), but cd into the same directory using a slightly different case in the path. For example:
cd "/mnt/c/Users/Carlos/desktop/projects"
On NTFS these refer to the same directory. The two terminals see the same files if I run ls.
In this second terminal run:
codex resume
Observe that the resume picker lists No sessions yet, even though:
The session files from step 1 are present under ~/.codex/sessions/...
codex resume in the first terminal does list and resume the session
Both terminals report identical CODEX_HOME, HOME, which codex, and identical ~/.codex/sessions contents
What is the expected behavior?
codex resume should list and allow resuming any sessions associated with the actual workspace directory, even if the path used in the shell differs only by case from the path string that was stored originally.
On platforms where the underlying filesystem is case insensitive (for example Windows paths or WSL mounts of NTFS), Codex should normalize paths or compare them in a case insensitive way so that small casing differences do not hide sessions.
Additional information
No response
Activity
Fixed resume matching to respect case insensitivity when using WSL mo…
Fixed resume matching to respect case insensitivity when using WSL mo…
etraut-openai commentedon Dec 17, 2025
Thanks for the bug report. This will be fixed in the next release.
Fixed resume matching to respect case insensitivity when using WSL mo…
aalasadtx commentedon Sep 10, 2026
Reopening context: this same failure reproduces on codex-cli 0.154.0 (WSL2, Ubuntu 24.04, Windows 11), through a different path than #8000 fixed.
#8000 added
normalize_for_path_comparisonincodex-rs/core/src/path_utils.rs, scoped to the rollout-file-based resume picker's comparison step. On 0.154.0,codex resume's default picker instead reads a SQLite-backedthreadstable (~/.codex/state_5.sqlite), and itscwdcolumn is stored pre-lowercased at write time for paths on a case-insensitive mount — not just compared case-insensitively at read time. Querying that table directly:while the live directory (and the value actually recorded in that same session's own rollout
.jsonl,session_meta.payload.cwd) is mixed-case. Systemic on this machine — every recent session on this case-insensitive drive has a lowercasedcwdinthreads, while sessions predating a certain point kept correct casing.Looks like the normalization from #8000 needs to also apply wherever
cwdgets written intothreads, not just the legacy rollout-file lookup. Happy to share more diagnostics if useful.