claude-code
claude-code copied to clipboard
[BUG] Two claude sessions will conflict and overwrite ~/.claude.json
Environment
- Platform (select one): Claude Code
- Claude CLI version: 0.2.107 (Claude Code)
- Operating System: macOS 15.4
- Terminal: Terminal App
Bug Description
Two claude sessions will conflict and overwrite ~/.claude.json.
Steps to Reproduce
- Run a first claude session in one terminal.
- Run a second claude session in another terminal.
- After both sessions have exited, look at ~/.claude.json
- You will observe that portions of history are missing.
Expected Behavior
I expected to see the complete history of both sessions.
Actual Behavior
history seemed to be truncated, I could not see some commands executed by one of the sessions.
Additional Context
Presumably related to file output buffering of ~/.claude.json?