From c70cfd335af33ad3ffdbfb83f97b69417a3e7fbd Mon Sep 17 00:00:00 2001 From: Broque Thomas Date: Thu, 19 Feb 2026 10:50:53 -0800 Subject: [PATCH] Fix missing formats key in error path and clean up format query --- database/music_database.py | 3 +-- web_server.py | 3 ++- webui/static/style.css | 4 ++++ 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/database/music_database.py b/database/music_database.py index 71bc0cc..2e06f7b 100644 --- a/database/music_database.py +++ b/database/music_database.py @@ -2227,7 +2227,7 @@ class MusicDatabase: try: placeholders = ','.join('?' for _ in sibling_ids) cursor.execute(f""" - SELECT DISTINCT file_path, bitrate FROM tracks + SELECT file_path, bitrate FROM tracks WHERE album_id IN ({placeholders}) AND file_path IS NOT NULL """, sibling_ids) @@ -2241,7 +2241,6 @@ class MusicDatabase: elif ext == 'MP3': format_set.add('MP3') else: - # FLAC, OGG, AAC, etc. — just the extension format_set.add(ext) return sorted(format_set) except Exception as e: diff --git a/web_server.py b/web_server.py index 5160bfd..c3bf672 100644 --- a/web_server.py +++ b/web_server.py @@ -5760,7 +5760,8 @@ def _check_album_completion(db, album_data: dict, artist_name: str, test_mode: b "completion_percentage": 0, "confidence": 0.0, "found_in_db": False, - "error_message": str(db_error) + "error_message": str(db_error), + "formats": [] } # Calculate completion percentage diff --git a/webui/static/style.css b/webui/static/style.css index b1b4e45..cdbef82 100644 --- a/webui/static/style.css +++ b/webui/static/style.css @@ -13381,6 +13381,10 @@ body { /* Fixed height for consistent layout */ } +.discography-sections .release-card { + height: fit-content; +} + .release-card:hover { background: linear-gradient(135deg, rgba(40, 40, 40, 0.95) 0%, rgba(30, 30, 30, 0.98) 100%); border-color: rgba(255, 255, 255, 0.15);