[Bug] Claude Code corrupts source files with sed command, causing token waste on recovery

Resolved 💬 2 comments Opened Apr 10, 2026 by withoutthem Closed May 28, 2026

Bug Description

  • 세션 ID: d09cf298-5916-4cef-8f4e-2338aebf7512
  • 발생 일시: 2026-04-10
  • 사고 요약: Claude Code가 sed 명령어로 source 파일을 0바이트로 만든 후 transcript

복구에 추가 토큰 소요

  • withoutthem50@gmail.com
  • Max 사용자

Environment Info

  • Platform: darwin
  • Terminal: intellij
  • Version: 2.1.96
  • Feedback ID: 81eea9c1-a4c9-47e6-bec9-48b92d0434ed

Errors

[{"error":"Error: EISDIR: illegal operation on a directory, read '/Users/victorlee/Desktop/Yggdrasil/Odin/frontend_odin/src/shared/ui/unitComponents/badges'\n    at N4H (/$bunfs/root/src/entrypoints/cli.js:3867:14841)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-10T00:59:10.943Z"},{"error":"Error: 1P event logging: 31 events failed to export (code=ECONNABORTED, timeout of 10000ms exceeded)\n    at queueFailedEvents (/$bunfs/root/src/entrypoints/cli.js:422:2574)\n    at async doExport (/$bunfs/root/src/entrypoints/cli.js:422:1516)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-10T01:04:05.519Z"},{"error":"Error: {\"message\":\"Failed to export 31 events (code=ECONNABORTED, timeout of 10000ms exceeded)\",\"originalLine\":\"422\",\"originalColumn\":\"1668\",\"line\":\"422\",\"column\":\"1668\",\"sourceURL\":\"/$bunfs/root/src/entrypoints/cli.js\",\"stack\":\"Error: Failed to export 31 events (code=ECONNABORTED, timeout of 10000ms exceeded)\\n    at doExport (/$bunfs/root/src/entrypoints/cli.js:422:1668)\\n    at processTicksAndRejections (native:7:39)\",\"name\":\"Error\"}\n    at error (/$bunfs/root/src/entrypoints/cli.js:1827:4371)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:417:36794)\n    at L04 (/$bunfs/root/src/entrypoints/cli.js:417:37338)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:418:19103)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-10T01:04:05.519Z"},{"error":"Error: 1P event logging: 1 events failed to export (code=ECONNREFUSED, ECONNREFUSED)\n    at queueFailedEvents (/$bunfs/root/src/entrypoints/cli.js:422:2574)\n    at async doExport (/$bunfs/root/src/entrypoints/cli.js:422:1516)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-10T01:04:21.417Z"},{"error":"Error: {\"message\":\"Failed to export 1 events (code=ECONNREFUSED, ECONNREFUSED)\",\"originalLine\":\"422\",\"originalColumn\":\"1668\",\"line\":\"422\",\"column\":\"1668\",\"sourceURL\":\"/$bunfs/root/src/entrypoints/cli.js\",\"stack\":\"Error: Failed to export 1 events (code=ECONNREFUSED, ECONNREFUSED)\\n    at doExport (/$bunfs/root/src/entrypoints/cli.js:422:1668)\\n    at processTicksAndRejections (native:7:39)\",\"name\":\"Error\"}\n    at error (/$bunfs/root/src/entrypoints/cli.js:1827:4371)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:417:36794)\n    at L04 (/$bunfs/root/src/entrypoints/cli.js:417:37338)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:418:19103)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-10T01:04:21.417Z"},{"error":"Error: 1P event logging: 22 events failed to export (code=FailedToOpenSocket, Was there a typo in the url or port?)\n    at queueFailedEvents (/$bunfs/root/src/entrypoints/cli.js:422:2574)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-10T01:06:52.449Z"},{"error":"Error: {\"message\":\"Failed to export 22 events (code=FailedToOpenSocket, Was there a typo in the url or port?)\",\"originalLine\":\"422\",\"originalColumn\":\"1668\",\"line\":\"422\",\"column\":\"1668\",\"sourceURL\":\"/$bunfs/root/src/entrypoints/cli.js\",\"stack\":\"Error: Failed to export 22 events (code=FailedToOpenSocket, Was there a typo in the url or port?)\\n    at doExport (/$bunfs/root/src/entrypoints/cli.js:422:1668)\\n    at processTicksAndRejections (native:7:39)\",\"name\":\"Error\"}\n    at error (/$bunfs/root/src/entrypoints/cli.js:1827:4371)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:417:36794)\n    at L04 (/$bunfs/root/src/entrypoints/cli.js:417:37338)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:418:19103)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-10T01:06:52.449Z"},{"error":"Error: 1P event logging: 4 events failed to export (code=FailedToOpenSocket, Was there a typo in the url or port?)\n …

Note: Content was truncated.

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗