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
[BUG] claude --resume shows "No conversations found" despite session directories existing #18311
I have searched existing issues and this hasn't been reported yet
This is a single bug report (please file separate reports for different bugs)
I am using the latest version of Claude Code
What's Wrong?
Description:
Session directories exist in ~/.claude/projects/ with subagent .jsonl files, but the main conversation .jsonl files are missing. This causes --resume to fail even though sessions were
recently used.
I am experiencing exactly the same issue, except my version of Claude Code is 2.1.11 and I am on macOS Tahoe 26.2. I have been working in my project for a month or longer without issues. I finished working in the project at 2026-01-16T06:40:00Z. I always export at the start and end of a session, so I have the export if it would be helpful. I will be able to load it for some context, but I do not know what issues that may cause.
[edit] I opened the exported file and found the following at the top:
▐▛███▜▌ Claude Code v2.1.9
▝▜█████▛▘ Opus 4.5 · Claude Max
▘▘ ▝▝ ~/Ada/github.com/abitofhelp/adafmt
══════════════════ Conversation compacted · ctrl+o for history ═════════════════
So, in my last session, I was using Claude Code 2.1.9 and somehow it was updated since that time to 2.1.11 and won't resume. I need to see if I can return to 2.1.9 to see if things work. I will report the result.
[edit] I tried to install the previous version and resume, but had the same issue.
npm install @anthropic-ai/claude-code@2.1.9
added 3 packages, and audited 4 packages in 1s
2 packages are looking for funding
run npm fund for details
found 0 vulnerabilities
√ adafmt % claude --resume
No conversations found to resume.
When I launched claude in another directory to avoid potential issues with my project, I found that 2.1.9 was not installed, but it appears that a new release 2.1.12 was applied. I returned to my project folder and tried to resume with 2.1.12, but the issue persists. Next step is to uninstall claude and try to install 2.1.9 again.
[edit] Okay, so I removed 2.1.12 but did not delete my $HOME/.claude folder. In fact, I made a backup of it, just in case... After removing that version, my data files were okay, I installed 2.1.9, and successfully resumed with claude. Here are the steps to nirvana:
Three session files exist but only one is indexed. The 69MB session (substantial conversation history) doesn't appear in the resume picker.
Workaround
Resuming directly with the session ID works:
claude --resume 8a11dff0-d274-4001-aeb5-241eba9bcf06
Suggested Fix
The resume picker could scan for .jsonl files directly and rebuild/validate the index on startup if inconsistencies are detected, rather than relying solely on sessions-index.json being correct.
Reacted by Adhiraj Deshmukh, Taylor Eernisse, Ahacad, Yakov Till, Kenneth Smith, Jason Pan, Franco Daneri and Błażej Czapp
Additional data: sessions-index.json stops syncing after auto-update (~v2.1.31)
I'm seeing the same issue. Investigated the root cause on macOS (Darwin 25.3.0, Claude Code 2.1.34):
Setup: All sessions started from the same directory (~/agent), no exceptions.
Findings:
560.jsonl session files exist on disk (2GB total)
371 are in sessions-index.json
189 sessions exist on disk but are missing from the index - including every session from the last 3 days
0 ghost entries (nothing in the index that's missing from disk)
The /resume picker reads from the index, so 189 sessions are invisible despite being fully intact on disk.
When it broke: The index file was last modified on 03-Feb-2026 at 16:54. Auto-update installed v2.1.31 on 04-Feb, then v2.1.32 (05-Feb) and v2.1.34 (06-Feb). No sessions have been indexed since.
Compounding issue: Separately, context compaction rewrites .jsonl files and strips the system header (first line with sessionId, version, cwd), replacing it with file-history-snapshot or summary type entries. Of the 189 missing sessions, only 15 still have a valid system header. Even if the index were rebuilt, the 174 sessions with stripped headers may not be resumable via the picker.
For some reason claude -r would return all the sessions in the project. But if you were to do the command in a e.g. (e.g. claude then /resume) then it would only show the last 10-15 sessions with no way to searching/loading older sessions
Experiencing the same issue on Windows with Claude Code v2.1.37. Sessions .jsonl files exist in ~/.claude/projects/ but --resume says "No conversations found to resume." This affects both regular repos and git worktree directories.
Experiencing this on Windows 10 Home (10.0.19045), Claude Code v2.1.39.
claude --resume returns "No conversations found to resume" immediately after ending a session that displayed a valid session ID. Resuming with the explicit ID (claude --resume ) works fine.
Confirmed that ~/.claude/history.jsonl does not exist on my system, while session transcript .jsonl files are being written correctly to ~/.claude/projects/.
Hey! I ran into a similar pattern in our bug knowledge base and thought this might help.
What's happening: --resume relies solely on sessions-index.json to enumerate sessions, but this index gets out of sync with actual .jsonl files on disk (writes can fail silently, index not updated after crashes/forced exits, or subagent-only sessions never register a parent entry). When the index is missing an entry, the session is invisible to --resume even though the .jsonl file exists.
What worked for us:
When listing sessions for --resume, fall back to filesystem scan: glob for *.jsonl in the project sessions directory, parse each file's first JSON line for metadata (session ID, timestamp, summary), then merge with sessions-index.json entries (preferring index metadata but including any files the index missed). Optionally reconcile the index by writing back discovered sessions. This makes --resume resilient to index desync.
// In the session listing/resume logic (pseudocode for the fix):asyncfunctionlistSessions(projectDir: string){// 1. Read index (existing behavior)constindexed=awaitreadSessionsIndex(projectDir);constindexedIds=newSet(indexed.map(s=>s.id));// 2. Filesystem scan fallbackconstjsonlFiles=glob.sync(path.join(projectDir,'*.jsonl'));constdiscovered: Session[]=[];for(constfileofjsonlFiles){constid=path.basename(file,'.jsonl');if(!indexedIds.has(id)){// Parse first line for metadataconstfirstLine=awaitreadFirstLine(file);try{constmeta=JSON.parse(firstLine);discovered.push({
id,lastModified: (awaitfs.stat(file)).mtimeMs,summary: meta.summary||meta.message?.content?.slice(0,80)||'(recovered session)',});}catch{discovered.push({ id,lastModified: (awaitfs.stat(file)).mtimeMs,summary: '(recovered session)'});}}}// 3. Merge and reconcileconstall=[...indexed, ...discovered].sort((a,b)=>b.lastModified-a.lastModified);if(discovered.length>0){awaitwriteSessionsIndex(projectDir,all);// heal the index}returnall;}
Hope this helps! Let me know if it doesn't match your case — happy to dig deeper. 🦞
Disclosure: This analysis is from Confucius Debug, an AI-powered community KB for agent bugs. Please verify before applying.
🦞 Confucius Debug — community knowledge base for AI agent bugs. Free to search via MCP.
If you're hitting this, check ~/.claude/settings.json for "cleanupPeriodDays": 0. That value stops .jsonl transcript files from being written — you'll see session directories with nothing in them. The schema says 0 means "disable cleanup," but the code treats it as "don't write transcripts." Root cause tracked in #23710.
This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.
Activity
abitofhelp commentedon Jan 18, 2026
I am experiencing exactly the same issue, except my version of Claude Code is 2.1.11 and I am on macOS Tahoe 26.2. I have been working in my project for a month or longer without issues. I finished working in the project at 2026-01-16T06:40:00Z. I always export at the start and end of a session, so I have the export if it would be helpful. I will be able to load it for some context, but I do not know what issues that may cause.
[edit] I opened the exported file and found the following at the top:
▐▛███▜▌ Claude Code v2.1.9
▝▜█████▛▘ Opus 4.5 · Claude Max
▘▘ ▝▝ ~/Ada/github.com/abitofhelp/adafmt
══════════════════ Conversation compacted · ctrl+o for history ═════════════════
So, in my last session, I was using Claude Code 2.1.9 and somehow it was updated since that time to 2.1.11 and won't resume. I need to see if I can return to 2.1.9 to see if things work. I will report the result.
[edit] I tried to install the previous version and resume, but had the same issue.
npm install @anthropic-ai/claude-code@2.1.9
added 3 packages, and audited 4 packages in 1s
2 packages are looking for funding
run
npm fundfor detailsfound 0 vulnerabilities
√ adafmt % claude --resume
No conversations found to resume.
When I launched claude in another directory to avoid potential issues with my project, I found that 2.1.9 was not installed, but it appears that a new release 2.1.12 was applied. I returned to my project folder and tried to resume with 2.1.12, but the issue persists. Next step is to uninstall claude and try to install 2.1.9 again.
[edit] Okay, so I removed 2.1.12 but did not delete my $HOME/.claude folder. In fact, I made a backup of it, just in case... After removing that version, my data files were okay, I installed 2.1.9, and successfully resumed with claude. Here are the steps to nirvana:
+--------------+
| SOLUTION |
+--------------+
remove current binary but keep our data.
npm uninstall -g @anthropic-ai/claude-codecurl -fsSL https://claude.ai/install.sh | bash -s 2.1.12
rm -rf /usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js
install the happy version.
npm install @anthropic-ai/claude-code@2.1.9
validate in your project directory.
claude --resume
blasphemetheus commentedon Jan 18, 2026
Experiencing this on Linux (Manjaro 6.1.159-1) as well, so it's not macOS-specific. This may be related to #14157.
Root Cause
In my case,
sessions-index.jsonis out of sync with the actual session files:Session files present:
Index contents:
{ "version": 1, "entries": [ { "sessionId": "8a11dff0-d274-4001-aeb5-241eba9bcf06" } ] }Three session files exist but only one is indexed. The 69MB session (substantial conversation history) doesn't appear in the resume picker.
Workaround
Resuming directly with the session ID works:
Suggested Fix
The resume picker could scan for
.jsonlfiles directly and rebuild/validate the index on startup if inconsistencies are detected, rather than relying solely onsessions-index.jsonbeing correct.Safibulae commentedon Feb 6, 2026
Additional data:
sessions-index.jsonstops syncing after auto-update (~v2.1.31)I'm seeing the same issue. Investigated the root cause on macOS (Darwin 25.3.0, Claude Code 2.1.34):
Setup: All sessions started from the same directory (
~/agent), no exceptions.Findings:
.jsonlsession files exist on disk (2GB total)sessions-index.jsonThe
/resumepicker reads from the index, so 189 sessions are invisible despite being fully intact on disk.When it broke: The index file was last modified on 03-Feb-2026 at 16:54. Auto-update installed v2.1.31 on 04-Feb, then v2.1.32 (05-Feb) and v2.1.34 (06-Feb). No sessions have been indexed since.
Compounding issue: Separately, context compaction rewrites
.jsonlfiles and strips thesystemheader (first line withsessionId,version,cwd), replacing it withfile-history-snapshotorsummarytype entries. Of the 189 missing sessions, only 15 still have a validsystemheader. Even if the index were rebuilt, the 174 sessions with stripped headers may not be resumable via the picker.Breakdown of missing sessions by first-line type:
file-history-snapshot: 90 (compaction stripped header)user: 55summary: 24 (compaction stripped header)system: 15 (valid header, just never indexed)Workaround: Direct resume by session ID still works:
claude --resume <session-id>Environment: macOS 15.4, Claude Code 2.1.34 (standalone binary via
~/.local/share/claude/versions/), not installed via npm global.FelixIsaac commentedon Feb 8, 2026
For some reason
claude -rwould return all the sessions in the project. But if you were to do the command in a e.g. (e.g.claudethen/resume) then it would only show the last 10-15 sessions with no way to searching/loading older sessionsimanoel01 commentedon Feb 9, 2026
Experiencing the same issue on Windows with Claude Code v2.1.37. Sessions
.jsonlfiles exist in~/.claude/projects/but--resumesays "No conversations found to resume." This affects both regular repos and git worktree directories.ethanfischer commentedon Feb 21, 2026
Experiencing this on Windows 10 Home (10.0.19045), Claude Code v2.1.39.
claude --resume returns "No conversations found to resume" immediately after ending a session that displayed a valid session ID. Resuming with the explicit ID (claude --resume ) works fine.
Confirmed that ~/.claude/history.jsonl does not exist on my system, while session transcript .jsonl files are being written correctly to ~/.claude/projects/.
FelixIsaac commentedon Feb 21, 2026
I think it's been largely solved since v2.1.45+, at least for me. Consider updating to the latest development release
sstklen commentedon Feb 24, 2026
Hey! I ran into a similar pattern in our bug knowledge base and thought this might help.
What's happening: --resume relies solely on sessions-index.json to enumerate sessions, but this index gets out of sync with actual .jsonl files on disk (writes can fail silently, index not updated after crashes/forced exits, or subagent-only sessions never register a parent entry). When the index is missing an entry, the session is invisible to --resume even though the .jsonl file exists.
What worked for us:
When listing sessions for --resume, fall back to filesystem scan: glob for *.jsonl in the project sessions directory, parse each file's first JSON line for metadata (session ID, timestamp, summary), then merge with sessions-index.json entries (preferring index metadata but including any files the index missed). Optionally reconcile the index by writing back discovered sessions. This makes --resume resilient to index desync.
Hope this helps! Let me know if it doesn't match your case — happy to dig deeper. 🦞
🦞 Confucius Debug — community knowledge base for AI agent bugs. Free to search via MCP.
chrisvaillancourt commentedon Mar 12, 2026
If you're hitting this, check
~/.claude/settings.jsonfor"cleanupPeriodDays": 0. That value stops.jsonltranscript files from being written — you'll see session directories with nothing in them. The schema says0means "disable cleanup," but the code treats it as "don't write transcripts." Root cause tracked in #23710.gonewx commentedon Mar 31, 2026
This is a common problem. The issue is Claude's session index (
sessions-index.json) can get out of sync with the actual session files.Quick fix:
ls ~/.claude/projects/*/sessions/Prevention:
The real problem is that Claude treats sessions as disposable. For serious development work, you need your own session management strategy.
github-actions commentedon Apr 22, 2026
This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.