Repository navigation
Read Artist Watch discographies from MusicBrainz too - #588
Merged
henriquesebastiao merged 1 commit intoNov 14, 2026
Merged
henriquesebastiao merged 1 commit into
henriquesebastiao merged 1 commit into
Conversation
Phase 2 of henriquesebastiao#581, first part. Artist Watch reads MusicBrainz as a third catalogue (downtify/musicbrainz.py): one request a second process-wide, a User-Agent naming Downtify, 503s retried. The artist is found once through their Deezer page, YouTube Music channel or an unambiguous name, and kept (musicbrainz_id). Only the artist's own release groups (not guest spots), of the watch's primary types, with secondary types let in by artist_watch_musicbrainz_kinds (mixtapes and soundtracks by default), and not bootleg-only. One official edition per group: explicit, the most tracks, digital, earliest. Groups YouTube Music or Deezer already list are left to them; songs found elsewhere are linked as before. library_songs also folds (From "Film") title tags, which Indian labels add on one catalogue and not another. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Merging this PR will not alter performance1 warning
Comparing |
henriquesebastiao
approved these changes
Nov 14, 2026
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.
Phase 2 of #581, first part: Artist Watch reads MusicBrainz as a third catalogue, beside YouTube Music and Deezer. It fills in what both miss: mixtapes, and older and rarer releases. It reads MusicBrainz directly, not Lidarr's metadata server, since #581 left that question open and MusicBrainz's data is CC0 with public rules for clients.
What it does
downtify/musicbrainz.pyis a small web-service client:503/429("slow down") is retried after a growing pause. In practice MusicBrainz sends 503 now and then even at 1/s.musicbrainz_id, migrated likedeezer_id). In order:release-group-status=website-default, the list MusicBrainz's own artist page shows. So groups made only of bootlegs are left out. A group is one album, EP or single with all of its editions, typed like Lidarr's metadata profiles: a primary type and secondary types.release_typesas before.artist_watch_musicbrainz_kinds. The default is["mixtape", "soundtrack"]. Live, compilation, remix, DJ-mix and demo groups mostly repeat the artist's songs, so they're off unless asked for. A group must have all of its secondary types let in, so a remix mixtape stays out.Officialedition (bootlegs, promos) is recorded as skipped and never asked for again._download_coverdoesn't follow redirects. Without one, the YouTube Music match's cover is used, as before.In
monitor._artist_discography:Settings:
artist_watch_musicbrainz(default on) andartist_watch_musicbrainz_kinds. There's no UI for them yet. I'd add it with the next part (below), where a per-watch choice fits better.Also:
library_songs._SAME_RECORDING_TAGnow folds(From "…")and[From "…"], the film a soundtrack song comes from. Indian labels add it on one catalogue and not another:Tum Hi Ho (From "Aashiqui 2")is MusicBrainz's and Spotify'sTum Hi Ho. The length must still agree, and(Unplugged)and the like stay different songs.Drake, dry run against the real catalogues
A fresh Drake watch, one full sweep with a fake downloader, so nothing was downloaded. These are anonymous public APIs, the same probe as in #583:
9fff2f8a…).website-defaultand the official-edition rule.artist_watch_musicbrainz_kinds: ["soundtrack"]turns mixtapes off.Next (not in this PR)
The rest of Phase 2: a catalogue view per watched artist. It would show each release group with have / partly / missing, let you switch single albums on and off (Lidarr's per-album monitoring), and have a UI for the release kinds. It would build on this client.
Tests
tests/test_artist_watch_musicbrainz.py, 19 tests, all offline:fmt=json; the slow-down retry and giving up; one request per interval; artist mapping by Deezer page, then channel, then unambiguous name; paging; credits (own, joint, guest, with a guest); kinds;test_library_songs_folds_the_film_a_song_is_from.mainon my Windows/Docker setup.ruff check .passes.zh-CN/features/doctor.md, already failing onmainsince docs: complete Simplified Chinese feature translations and fix iOS links #585.features/playlist-monitor.md, a MusicBrainz paragraph after the Deezer one (English only, no structure change, like Read Artist Watch discographies from Deezer too #583).🤖 Generated with Claude Code