Fix FK constraint violation in bulk_ingest by filtering dropped assets

Co-authored-by: Amp <amp@ampcode.com>
Amp-Thread-ID: https://ampcode.com/threads/T-019c3626-c6ad-7139-a570-62da4e656a1a
This commit is contained in:
Luke Mino-Altherr
2026-02-06 20:09:54 -08:00
parent 7139045b21
commit b378e69aed
4 changed files with 27 additions and 1 deletions

View File

@@ -356,7 +356,7 @@ def setup_database():
if dependencies_available():
init_db()
if not args.disable_assets_autoscan:
if asset_seeder.start(roots=("models", "input", "output"), prune_first=True):
if asset_seeder.start(roots=("models", "input", "output"), prune_first=True, compute_hashes=True):
logging.info("Background asset scan initiated for models, input, output")
except Exception as e:
logging.error(f"Failed to initialize database. Please ensure you have installed the latest requirements. If the error persists, please report this as in future the database will be required: {e}")