/heapdump fails on Windows: EEXIST mkdir 'C:\Users\<username>\Desktop'
Resolved 💬 3 comments Opened Mar 10, 2026 by kirmraft Closed Mar 13, 2026
Bug Report
Command: /heapdump
Error:
Failed to create heap dump: EEXIST: file already exists, mkdir 'C:\Users\<username>\Desktop'
Environment:
- OS: Windows 11 Home (10.0.26200)
- Claude Code version: 2.1.72
- Shell: bash (Git Bash)
Description:
The /heapdump command fails because it tries to mkdir on the Desktop path, which already exists as a directory. It doesn't handle the case where the directory already exists (missing { recursive: true } or equivalent check).
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗