autoMemoryDirectory: default global memory dir still created each session
Resolved 💬 1 comment Opened May 14, 2026 by dvdrtrgn Closed Jun 12, 2026
Bug
When autoMemoryDirectory is set in settings.local.json, Claude Code still creates an empty directory at the default global memory path (~/.claude/projects/<hashed-path>/memory/) at the start of each session.
Steps to reproduce
- Set
autoMemoryDirectoryin.claude/settings.local.jsonto a project-local path (e.g./path/to/project/.claude/memory). - Start a Claude Code session.
- Observe that
~/.claude/projects/<hashed-path>/memory/is created as an empty directory even thoughautoMemoryDirectorypoints elsewhere.
Expected behavior
When autoMemoryDirectory is set, the default global memory directory should not be created. The override should suppress the default path entirely.
Actual behavior
An empty directory is created at the default global path each session. It contains no files (writes correctly go to autoMemoryDirectory), but the phantom directory persists and must be manually removed.
Context
- Platform: macOS (Darwin 24.6.0)
- Shell: zsh
- Use case: keeping memory files version-controlled in the project repo rather than the global
~/.claude/location
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗