fix(lint): log S110 bare except-pass in amazon client and worker

Three ruff S110 violations replaced with logger.debug calls:
- amazon_client.py:527 duration backfill ASIN search
- amazon_client.py:679 album metadata fetch in _fetch_album_metas
- amazon_worker.py:401 artist image backfill from albums
pull/617/head
Broque Thomas 1 week ago
parent 42a833fcb2
commit 35db1ac06d

@ -524,8 +524,8 @@ class AmazonClient:
for item in search_items:
if item.album_asin == asin and item.duration_seconds:
duration_map[item.asin] = item.duration_seconds * 1000
except Exception:
pass
except Exception as exc:
logger.debug("Duration backfill failed for ASIN %s: %s", asin, exc)
items = [
{
@ -676,8 +676,8 @@ class AmazonClient:
with _meta_cache_lock:
_meta_cache[asin] = (time.monotonic(), meta)
metas[asin] = meta
except Exception:
pass
except Exception as exc:
logger.debug("Album metadata fetch failed for ASIN %s: %s", asin, exc)
from concurrent.futures import ThreadPoolExecutor
with ThreadPoolExecutor(max_workers=min(len(asins), 5)) as pool:

@ -398,8 +398,8 @@ class AmazonWorker:
if not image_url:
try:
image_url = self.client._get_artist_image_from_albums(result.id)
except Exception:
pass
except Exception as exc:
logger.debug("Artist image from albums failed for %s: %s", result.id, exc)
if image_url:
cursor.execute("""
UPDATE artists SET thumb_url = ?

Loading…
Cancel
Save