fix(qobuz): adapt to album/get and playlist/get no longer returning inline tracks#1013
Open
izzoa wants to merge 1 commit into
Open
fix(qobuz): adapt to album/get and playlist/get no longer returning inline tracks#1013izzoa wants to merge 1 commit into
izzoa wants to merge 1 commit into
Conversation
…nline tracks Qobuz removed inline track listings from its metadata API (~2026-07-18): album/get no longer returns a "tracks" object (extra=tracks now 400s) and playlist/get returns an always-empty tracks.items. Request the replacement extra=track_ids and fall back to the id list when the legacy shape is absent; ids are hydrated per-track via the existing track/get paths. Fixes nathom#1012 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1012.
Problem
On ~2026-07-18 Qobuz removed inline track listings from its metadata API:
album/getno longer returns atracksobject at all (and rejectsextra=trackswith HTTP 400), andplaylist/get?extra=tracksreturns an always-emptytracks.items. As a result every Qobuz album download crashes withKeyError: 'tracks'and every playlist download silently resolves 0 tracks. The replacement contract, confirmed against the current web player (bundle 8.2.0-b034), isextra=track_ids, which returns the plain id list.Changes
client/qobuz.py: requestextra=track_idsfor albums, andextra=tracks,track_idsfor playlists (both values, so either the old or new server behavior works).metadata/util.py:get_album_track_ids()readsresp["track_ids"]when the legacytracksobject is absent.metadata/playlist.py:PlaylistMetadata.from_qobuz()tolerates a missing/emptytracksobject and falls back to thetrack_idslist — the samelist[str]shape the Deezer path already uses; ids are hydrated per-track byPendingPlaylistTrack.resolve()exactly as before.No new requests are introduced: albums and playlists already fetched each track individually via
track/get(which is unchanged); these endpoints only ever needed the id lists.Compatibility
limit=500paging window —track_idsreturned complete lists for everything tested (up to 100 tracks), but very large playlists are worth a look.Testing (live API, Qobuz Studio subscription, US store)
devcrashesKeyError: 'tracks'on any album; with this patch the same call returns the full id list.extra=albums, 353 albums returned) and single-track flows: unaffected.Happy to add fixture tests for the new response shape if wanted.
🤖 Generated with Claude Code