Skip to content
2 changes: 2 additions & 0 deletions aw_datastore/storages/peewee.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
)

from .abstract import AbstractStorage
from .sqlite_recover import maybe_recover_malformed_sqlite

logger = logging.getLogger(__name__)

Expand Down Expand Up @@ -176,6 +177,7 @@ def __init__(self, testing: bool = True, filepath: Optional[str] = None) -> None
+ ".db"
)
filepath = os.path.join(data_dir, filename)
maybe_recover_malformed_sqlite(filepath)
self.db = _db
self.db.init(
filepath,
Expand Down
Loading
Loading