claude-code - 💡(How to fix) Fix [Bug] Data Loss: Claude Code deleted important files from user system [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#60540Fetched 2026-05-20 03:55:55
View on GitHub
Comments
1
Participants
2
Timeline
5
Reactions
0
Timeline (top)
labeled ×4commented ×1

Error Message

[{"error":"wgH: Failed to install new version of claude: npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/logs/2026-05-19T12_52_17_092Z-debug-0.log\n at Q$ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T12:52:17.565Z"},{"error":"wgH: Failed to install new version of claude: npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/logs/2026-05-19T12_58_46_055Z-debug-0.log\n at Q$ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T12:58:46.510Z"},{"error":"wgH: Failed to install new version of claude: npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/logs/2026-05-19T12_59_53_239Z-debug-0.log\n at Q$ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T12:59:53.451Z"},{"error":"wgH: Failed to install new version of claude: npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/logs/2026-05-19T13_00_30_940Z-debug-0.log\n at Q$ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:00:31.153Z"},{"error":"AxiosError: timeout of 5000ms exceeded\n at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:120:13305)\n at emit (node:events:92:22)\n at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:119:3321)\n at request (/$bunfs/root/src/entrypoints/cli.js:122:2467)\n at async ht6 (/$bunfs/root/src/entrypoints/cli.js:447:4799)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:05:28.075Z"},{"error":"wgH: Failed to install new version of claude: npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/logs/2026-05-19T13_09_49_394Z-debug-0.log\n at Q$ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:09:49.864Z"},{"error":"Error: Request was aborted.\n at makeRequest (/$bunfs/root/src/entrypoints/cli.js:50:3449)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:11:11.753Z"}]

Code Example

[{"error":"wgH: Failed to install new version of claude:  npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/_logs/2026-05-19T12_52_17_092Z-debug-0.log\n    at Q$_ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n    at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T12:52:17.565Z"},{"error":"wgH: Failed to install new version of claude:  npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/_logs/2026-05-19T12_58_46_055Z-debug-0.log\n    at Q$_ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n    at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T12:58:46.510Z"},{"error":"wgH: Failed to install new version of claude:  npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/_logs/2026-05-19T12_59_53_239Z-debug-0.log\n    at Q$_ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n    at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T12:59:53.451Z"},{"error":"wgH: Failed to install new version of claude:  npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/_logs/2026-05-19T13_00_30_940Z-debug-0.log\n    at Q$_ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n    at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:00:31.153Z"},{"error":"AxiosError: timeout of 5000ms exceeded\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:120:13305)\n    at emit (node:events:92:22)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:119:3321)\n    at request (/$bunfs/root/src/entrypoints/cli.js:122:2467)\n    at async ht6 (/$bunfs/root/src/entrypoints/cli.js:447:4799)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:05:28.075Z"},{"error":"wgH: Failed to install new version of claude:  npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/_logs/2026-05-19T13_09_49_394Z-debug-0.log\n    at Q$_ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n    at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:09:49.864Z"},{"error":"Error: Request was aborted.\n    at makeRequest (/$bunfs/root/src/entrypoints/cli.js:50:3449)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:11:11.753Z"}]
RAW_BUFFERClick to expand / collapse

Bug Description claude ha eliminato dei dati iimportanti dal mio computer.

Environment Info

  • Platform: darwin
  • Terminal: Apple_Terminal
  • Version: 2.1.132
  • Feedback ID: 4aa038a4-387d-4bd5-8128-c54caaa17833

Errors

[{"error":"wgH: Failed to install new version of claude:  npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/_logs/2026-05-19T12_52_17_092Z-debug-0.log\n    at Q$_ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n    at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T12:52:17.565Z"},{"error":"wgH: Failed to install new version of claude:  npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/_logs/2026-05-19T12_58_46_055Z-debug-0.log\n    at Q$_ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n    at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T12:58:46.510Z"},{"error":"wgH: Failed to install new version of claude:  npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/_logs/2026-05-19T12_59_53_239Z-debug-0.log\n    at Q$_ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n    at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T12:59:53.451Z"},{"error":"wgH: Failed to install new version of claude:  npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/_logs/2026-05-19T13_00_30_940Z-debug-0.log\n    at Q$_ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n    at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:00:31.153Z"},{"error":"AxiosError: timeout of 5000ms exceeded\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:120:13305)\n    at emit (node:events:92:22)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:119:3321)\n    at request (/$bunfs/root/src/entrypoints/cli.js:122:2467)\n    at async ht6 (/$bunfs/root/src/entrypoints/cli.js:447:4799)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:05:28.075Z"},{"error":"wgH: Failed to install new version of claude:  npm error code ENOTEMPTY\nnpm error syscall rename\nnpm error path /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code\nnpm error dest /opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V\nnpm error errno -66\nnpm error ENOTEMPTY: directory not empty, rename '/opt/homebrew/lib/node_modules/@anthropic-ai/claude-code' -> '/opt/homebrew/lib/node_modules/@anthropic-ai/.claude-code-2DTsDk1V'\nnpm error A complete log of this run can be found in: /Users/macbookduez/.npm/_logs/2026-05-19T13_09_49_394Z-debug-0.log\n    at Q$_ (/$bunfs/root/src/entrypoints/cli.js:2648:2305)\n    at async <anonymous> (/$bunfs/root/src/entrypoints/cli.js:9160:10892)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:09:49.864Z"},{"error":"Error: Request was aborted.\n    at makeRequest (/$bunfs/root/src/entrypoints/cli.js:50:3449)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-19T13:11:11.753Z"}]

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix [Bug] Data Loss: Claude Code deleted important files from user system [1 comments, 2 participants]