Sync alternativer

This commit is contained in:
2026-04-22 10:00:12 +02:00
parent 37b49c1fed
commit b695a4858b
9 changed files with 778 additions and 43 deletions

View File

@@ -219,11 +219,17 @@ def run_acoustid_scan(db_path: str, api_key: str = "", on_progress=None, stop_ev
(acoustid or None, row["id"])
)
if mbid:
conn.execute(
"UPDATE songs SET mbid=? WHERE id=? AND (mbid IS NULL OR mbid='')",
(mbid, row["id"])
)
conn.commit()
try:
conn.execute(
"UPDATE songs SET mbid=? WHERE id=? AND (mbid IS NULL OR mbid='')",
(mbid, row["id"])
)
conn.commit()
except Exception:
conn.rollback()
logger.debug(f"MBID {mbid[:8]} allerede i brug — springer over")
else:
conn.commit()
found += 1
total_found += 1
logger.info(