Back to timeline

Mon, July 1304:55ToolsAPI & pricing

sqlite-utils 4.1.1 released, fixes foreign key cascade delete transaction bug

Decision Brief

What changedsqlite-utils 4.1.1 fixes an issue where table.transform() could silently delete or modify referenced rows due to foreign key cascade actions within a transaction.
Why it mattersThis fix prevents silent data corruption from cascade deletes during table.transform(); developers using sqlite-utils should upgrade to eliminate this edge case risk.
Who should careAI coding tool users
Affected stackClaude
Source confidenceMedium · Reliable media or first-hand reporting

sqlite-utils 4.1.1 primarily fixes a foreign key cascade edge case discovered by Claude Chat while testing version 4.1. When inside a transaction with PRAGMA foreign_keys enabled, table.transform() now raises TransactionError, preventing CASCADE, SET NULL, or SET DEFAULT actions triggered by deleting the old table from silently deleting or modifying referenced rows. Previously, since the pragma cannot be changed within a transaction, the operation could cause data loss without warning. Additionally, the release improves documentation: CLI and Python API docs now cross-reference each other, with CLI sections linking to corresponding Python API docs and vice versa. Developers using sqlite-utils should upgrade to 4.1.1 promptly, especially when performing table transformations with foreign key constraints in production, to avoid potential data integrity issues.

Summary basis: official / RSS sourceCompiled from the source scope noted above; the original remains authoritative.

Sources

  • Simon Willison:Blog

    Hands-on notes on LLM tools, local models, and practical AI engineering.

  • Simon Willison:Blog

Related intel

留言

登入后即可留言,和其他 builder 交换实测心得。

还没有留言,抢头香。