From 0767647056ae9cf218ec8899bd251aaa990c24a4 Mon Sep 17 00:00:00 2001 From: kim <89579420+NyaaaWhatsUpDoc@users.noreply.github.com> Date: Fri, 22 Mar 2024 12:26:02 +0000 Subject: [PATCH] [bugfix] add all possible busy result codes to the sqlite errBusy catching check (#2775) --- internal/db/bundb/errors.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/internal/db/bundb/errors.go b/internal/db/bundb/errors.go index ddbb302f8..f2633786a 100644 --- a/internal/db/bundb/errors.go +++ b/internal/db/bundb/errors.go @@ -72,7 +72,9 @@ func processSQLiteError(err error) error { case sqlite3.SQLITE_CONSTRAINT_UNIQUE, sqlite3.SQLITE_CONSTRAINT_PRIMARYKEY: return db.ErrAlreadyExists - case sqlite3.SQLITE_BUSY: + case sqlite3.SQLITE_BUSY, + sqlite3.SQLITE_BUSY_SNAPSHOT, + sqlite3.SQLITE_BUSY_RECOVERY: return errBusy case sqlite3.SQLITE_BUSY_TIMEOUT: return db.ErrBusyTimeout