diff --git a/core/listenbrainz_manager.py b/core/listenbrainz_manager.py index ddae7ae8..efa16158 100644 --- a/core/listenbrainz_manager.py +++ b/core/listenbrainz_manager.py @@ -743,7 +743,7 @@ class ListenBrainzManager: ) row = cursor.fetchone() playlist_type = row[0] if row else '' - except Exception: + except Exception: # noqa: S110 — best-effort lookup, delete proceeds either way pass # Delete tracks first (SQLite FK CASCADE requires PRAGMA foreign_keys=ON) diff --git a/core/playlists/sources/listenbrainz.py b/core/playlists/sources/listenbrainz.py index 0c5f72ff..838cda15 100644 --- a/core/playlists/sources/listenbrainz.py +++ b/core/playlists/sources/listenbrainz.py @@ -233,7 +233,7 @@ class ListenBrainzPlaylistSource(PlaylistSource): return tracks out = list(tracks) - for slot_idx, result in zip(match_indices, matched): + for slot_idx, result in zip(match_indices, matched, strict=False): if not result: continue track = out[slot_idx] @@ -270,7 +270,7 @@ class ListenBrainzPlaylistSource(PlaylistSource): return None try: manager.update_all_playlists() - except Exception: + except Exception: # noqa: S110 — caller falls back to last cached playlist on refresh failure pass return self.get_playlist(playlist_id) diff --git a/core/playlists/sources/soulsync_discovery.py b/core/playlists/sources/soulsync_discovery.py index c648830c..d2cfec25 100644 --- a/core/playlists/sources/soulsync_discovery.py +++ b/core/playlists/sources/soulsync_discovery.py @@ -102,9 +102,7 @@ class SoulSyncDiscoveryPlaylistSource(PlaylistSource): variant=record.variant, profile_id=record.profile_id, ) - except Exception: - # Manager already persists ``last_generation_error`` on - # failure; surface the existing snapshot regardless. + except Exception: # noqa: S110 — manager persists last_generation_error on failure; surface existing snapshot pass return self.get_playlist(playlist_id) diff --git a/web_server.py b/web_server.py index 7e6209ed..268ec877 100644 --- a/web_server.py +++ b/web_server.py @@ -22610,7 +22610,7 @@ _APPLE_MUSIC_BUNDLE_SCRAPE_CAP = 8 def _parse_itunes_link_url(url): """Return {'type': 'album'|'track'|'playlist', 'id': str} for supported Apple links.""" import re - from urllib.parse import parse_qs, urlparse + from urllib.parse import parse_qs raw = (url or '').strip() if not raw: