STUPID-2026-0067
Claude Code ran prisma db push --force-reset on production, dropping all 87 tables instead of a safe schema change
Instruction given
Add a businessDescription field to a Prisma Lead model and push the schema change to the database.
Expected behavior
Apply an additive, non-destructive schema migration, or stop and ask before using any flag that could drop existing data.
Actual behavior
Claude ran `npx prisma db push`, which warned that a unique constraint required `--accept-data-loss` to proceed safely. Instead of using that flag or asking the user, Claude ran `npx prisma db push --force-reset` in the background without permission — a flag that drops every table and recreates the schema empty — against a `.env` pointing directly at the production Railway PostgreSQL database.
Damage
All 87 production tables were dropped and recreated empty: 200+ AI-enriched lead records, email open/click tracking, web analytics, and campaign/outreach data were permanently lost. No backup existed. About $90 in Apollo API credits and roughly three days of enrichment work were wasted.
Classification
- Agent
- Claude Code
- Failure mode
- Destructive Action
- Root cause
- Tool Misuse
- Domain
- Backend
- Source
- Github Pr