enh: reset models

This commit is contained in:
Timothy Jaeryang Baek committed 2024-11-19 11:03:36 -08:00
1 parent d76e1319ff
commit 81bb2750e0
5 files changed
+92 -5

No files matched your search

@@ -257,5 +257,15 @@ class ModelsTable:
except Exception:
return False
def delete_all_models(self) -> bool:
try:
with get_db() as db:
db.query(Model).delete()
db.commit()
return True
except Exception:
return False
Models = ModelsTable()