[Bug] Unintended TRUNCATE command executed instead of DELETE with WHERE clause
Resolved 💬 3 comments Opened Apr 14, 2026 by marius-vilbury Closed Apr 18, 2026
Bug Description
claude code truncated the table whilst working on a script, that populates the said table via python. It said, that it ran TRUNCATE command instead of DELETE FROM with WHERE clause. It realised this by itself and stopped working on the plan to notify me about it and offer recovery options. We've never discussed using TRUNCATE and it was aware of other records in the table. This has never happened before.
Environment Info
- Platform: win32
- Terminal: windows-terminal
- Version: 2.1.107
- Feedback ID: 3c6a287e-4dd1-49fb-b8e3-cb7788e91fb2
Errors
[{"error":"Error: Request was aborted.\n at eI8 (B:/~BUN/root/src/entrypoints/cli.js:1344:12508)\n at next (native:1:11)\n at rB_ (B:/~BUN/root/src/entrypoints/cli.js:7940:9167)\n at next (native:1:11)\n at sB_ (B:/~BUN/root/src/entrypoints/cli.js:7945:12433)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-14T13:03:49.024Z"},{"error":"Error: Request was aborted.\n at eI8 (B:/~BUN/root/src/entrypoints/cli.js:1344:12508)\n at next (native:1:11)\n at rB_ (B:/~BUN/root/src/entrypoints/cli.js:7940:9167)\n at next (native:1:11)\n at sB_ (B:/~BUN/root/src/entrypoints/cli.js:7945:12433)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-14T13:04:49.882Z"},{"error":"Error: ENOENT: no such file or directory, unlink 'C:\\Users\\Marius\\AppData\\Local\\Temp\\claude\\C--Users-Marius-vilbury-scripts-amazon\\557856cc-c03f-48e5-ae02-1a68be8d8ffb\\tasks\\ac88aa89af5b4ea3c.output'\n at async <anonymous> (B:/~BUN/root/src/entrypoints/cli.js:7795:299)","timestamp":"2026-04-14T13:05:28.341Z"}]This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗