mirror of
https://github.com/simonw/datasette.git
synced 2025-12-10 16:51:24 +01:00
Rename InterruptedError => QueryInterrupted, closes #490
This commit is contained in:
parent
edb36629e7
commit
bd4dbc8519
7 changed files with 20 additions and 20 deletions
|
|
@ -1,7 +1,7 @@
|
|||
from pathlib import Path
|
||||
|
||||
from .utils import (
|
||||
InterruptedError,
|
||||
QueryInterrupted,
|
||||
detect_fts,
|
||||
detect_primary_keys,
|
||||
detect_spatialite,
|
||||
|
|
@ -58,8 +58,8 @@ class Database:
|
|||
).rows[0][0]
|
||||
counts[table] = table_count
|
||||
# In some cases I saw "SQL Logic Error" here in addition to
|
||||
# InterruptedError - so we catch that too:
|
||||
except (InterruptedError, sqlite3.OperationalError):
|
||||
# QueryInterrupted - so we catch that too:
|
||||
except (QueryInterrupted, sqlite3.OperationalError):
|
||||
counts[table] = None
|
||||
if not self.is_mutable:
|
||||
self.cached_table_counts = counts
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue