/resume fails to find sessions when working directory is a subst drive (Windows)

Resolved 💬 3 comments Opened Feb 9, 2026 by gm-hispagnol Closed Feb 13, 2026

Bug Description

/resume always reports "no sessions to resume" even immediately after exiting a session, when the working directory is on a Windows subst drive.

Environment

  • Claude Code version: 2.1.37
  • OS: Windows

Steps to Reproduce

  1. Create a substituted drive: subst Z: D:\git\MyRepo
  2. Open Claude Code from Z:\, have a conversation, exit
  3. Open Claude Code again from Z:\
  4. Run /resume - Result: no sessions found

Root Cause

  • Session creation uses the drive letter path -> stores .jsonl files in ~/.claude/projects/Z--/
  • Session lookup (/resume) resolves the real path -> looks in ~/.claude/projects/D--git-MyRepo/
  • D--git-MyRepo has a sessions-index.json (with entries pointing to Z-- paths) but zero .jsonl session files
  • Result: /resume finds no sessions

Evidence from disk:

  • ~/.claude/projects/Z--/ -> 112 .jsonl files + sessions-index.json (85 entries)
  • ~/.claude/projects/D--git-MyRepo/ -> sessions-index.json only (0 .jsonl files)

Expected Behavior

/resume should find and list all previous sessions regardless of whether the working directory is accessed via a subst drive letter or the underlying real path.

Suggested Fix

When resolving the project directory path, Claude Code should either:

  1. Consistently use the drive letter path (as provided by the user) without resolving through subst
  2. Or check both the virtual and resolved paths when looking up sessions
  3. Or store a mapping between equivalent paths

Additional Context

  • This worked correctly in previous versions
  • The same issue likely affects subst drives, net use mapped drives, and possibly junction points
  • The sessions-index.json in both directories has originalPath: "Z:\", confirming the path inconsistency

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗