From ac89fba674255aa176e3a5df994abae527e0b3eb Mon Sep 17 00:00:00 2001 From: "Scott Yeager (aider)" Date: Thu, 2 Jan 2025 19:01:30 -0800 Subject: [PATCH] feat: add PRAGMA synchronous=NORMAL to database connection setup --- receipts.py | 1 + 1 file changed, 1 insertion(+) diff --git a/receipts.py b/receipts.py index 159dbd1..887b12a 100644 --- a/receipts.py +++ b/receipts.py @@ -37,6 +37,7 @@ def __init__( for _ in range(self.connection_pool_size): conn = sqlite3.connect(self.db_path, check_same_thread=False) conn.execute("PRAGMA journal_mode=WAL") + conn.execute("PRAGMA synchronous=NORMAL") conn.execute("PRAGMA busy_timeout=5000") # 5 second timeout self.pool.put(conn)