From: Alexander Schmidt Date: Mon, 26 Oct 2020 22:43:36 +0000 (+0100) Subject: disable sqlite same thread check X-Git-Url: http://git.treefish.org/~alex/photosort.git/commitdiff_plain/c14b3934d3a602d806e68c2f92f05ad4dd115a54?ds=sidebyside disable sqlite same thread check --- diff --git a/src/locator.py b/src/locator.py index 7a57e09..ff74e0c 100644 --- a/src/locator.py +++ b/src/locator.py @@ -10,10 +10,10 @@ class Locator: self._base_dir = base_dir self._exclude_dir = exclude_dir if not os.path.isfile(db_file): - self._conn = sqlite3.connect(db_file) + self._conn = sqlite3.connect(db_file, check_same_thread=False) self._create_db() else: - self._conn = sqlite3.connect(db_file) + self._conn = sqlite3.connect(db_file, check_same_thread=False) logging.info("Opened locator for %s.", self._base_dir) def locate_file(self, name, size, meta_time):