Bug: Sessions not appearing in /resume list despite existing in filesystem

Resolved 💬 5 comments Opened Feb 20, 2026 by rar-cru Closed Mar 20, 2026

Bug Description

Sessions are being saved to the filesystem but not indexed in sessions-index.json, causing them to be invisible to the /resume command.

Steps to Reproduce

  1. Have a long-running session with significant work
  2. Exit Claude Code normally
  3. Reopen Claude Code and run /resume
  4. Session does not appear in the list

Expected Behavior

All saved session files should appear in the /resume list.

Actual Behavior

Sessions exist as .jsonl files in ~/.claude/projects/<project-path>/ but are missing from sessions-index.json, making them invisible to /resume.

Evidence

Session File Exists

$ ls -lh ~/.claude/projects/-Users-robert-rawson-Documents-dev-documentation-ai-workflow/bb66c1a2-7983-46f5-9201-10d5d5d9021a.jsonl
-rw-------  1 user  staff   3.2M Feb 20 00:54 bb66c1a2-7983-46f5-9201-10d5d5d9021a.jsonl

Session Contains Recent Work

$ grep -o 'Week 8' <session-file> | wc -l
5

Session Not in Index

$ grep 'bb66c1a2-7983-46f5-9201-10d5d5d9021a' sessions-index.json
# No results

Latest Indexed Session is Much Older

Most recent indexed session: 2026-02-03T20:33:03.174Z
Orphaned session file: 2026-02-20 00:54 (17 days later)

Impact

  • Data Loss Risk: Users believe work is lost when it's just not indexed
  • Workflow Disruption: Cannot resume important sessions via /resume
  • Workaround Exists: Can manually resume with claude resume <session-uuid>

Workaround

Users can resume orphaned sessions by finding the UUID in the filesystem:

# Find recent sessions
ls -lt ~/.claude/projects/<project-path>/*.jsonl | head -5

# Resume by UUID
claude resume <session-uuid>

System Information

  • OS: macOS (Darwin 25.3.0)
  • Claude Code Version: Unknown (please add version check)
  • Project Path: /Users/robert.rawson/Documents/dev/documentation/ai-workflow

Additional Context

User reported: "this has happened before" - suggesting this is a recurring issue, not a one-time failure.

The indexing mechanism appears to fail silently - sessions save successfully but the index update fails.

Suggested Fix

  1. Add retry logic for index updates
  2. Add index repair command: claude repair-index
  3. Validate index integrity on startup
  4. Log warnings when index updates fail
  5. Fall back to filesystem scan if session not in index

View original on GitHub ↗

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