From 8b71a6fb3f9a811010b1089b9d76a8c859576508 Mon Sep 17 00:00:00 2001 From: usuallyarnav Date: Sat, 25 Jul 2026 13:21:02 +0530 Subject: [PATCH] Enable SQLite foreign key enforcement so ON DELETE CASCADE works --- boundier/storage/sqlite_store.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/boundier/storage/sqlite_store.py b/boundier/storage/sqlite_store.py index 7cdbcad..417642f 100644 --- a/boundier/storage/sqlite_store.py +++ b/boundier/storage/sqlite_store.py @@ -12,10 +12,10 @@ def __init__(self, db_path: str = "boundier.db", schema_path: str = "schema.sql" self.schema_path = schema_path self.memory_dir = memory_dir self._init_db() - def _get_conn(self): conn = sqlite3.connect(self.db_path, timeout=30.0) conn.row_factory = sqlite3.Row + conn.execute("PRAGMA foreign_keys = ON") return conn def _init_db(self):