[BUG] Did `2.1.1` delete all of your *local* chat logs > 30 days old without asking?
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?
I had (and regularly reference) 4+ months of chat logs (.jsonl) under ~/.claude/projects/; just now, after starting a new session, everything before December 4th has been deleted. I have explicitly configured cleanupPeriodDays to 99999:
jq '.cleanupPeriodDays' ~/.claude/settings.json
99999
Did Anthropic unilaterally decide that until I opt-into data sharing, that they'd bulk delete files from my local machine? Because I'm pretty sure that's what just happened.
Here's the prompt I was presented in the new session:
<img width="807" height="614" alt="Image" src="https://github.com/user-attachments/assets/42275c9b-deba-4d69-be6d-803323f8eed6" />
All of my history was deleted and I haven't even selected a choice yet.
Is this intentional behavior? Does the latest release of Claude Code preemptively delete our local chat logs without authorization?
What Should Happen?
Claude Code should not delete chat logs fresher than cleanupPeriodDays.
Error Messages/Logs
Steps to Reproduce
- Upgrade Claude Code to latest
Claude Model
None
Is this a regression?
Yes, this worked in a previous version
Last Working Version
~2.0.76
Claude Code Version
2.1.1
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
iTerm2
Additional Information
_No response_
This issue has 8 comments on GitHub. Read the full discussion on GitHub ↗