mirror of
https://github.com/beetbox/beets.git
synced 2026-01-05 07:23:33 +01:00
Fix musicbrainz genres fetching
- genres are now called tags - tags needs to be in "mb fetch includes" - release-group has them - release has them - and recording as well but we don't use them - not sure what this outdated check was doing - see musicbrainz.VALID_INCLUDES for reference
This commit is contained in:
parent
a1c0ebdeef
commit
f4d41482e8
1 changed files with 7 additions and 4 deletions
|
|
@ -104,8 +104,11 @@ BROWSE_MAXTRACKS = 500
|
|||
TRACK_INCLUDES = ["artists", "aliases", "isrcs"]
|
||||
if "work-level-rels" in musicbrainzngs.VALID_INCLUDES["recording"]:
|
||||
TRACK_INCLUDES += ["work-level-rels", "artist-rels"]
|
||||
if "genres" in musicbrainzngs.VALID_INCLUDES["recording"]:
|
||||
RELEASE_INCLUDES += ["genres"]
|
||||
if "tags" in [
|
||||
musicbrainzngs.VALID_INCLUDES["release"],
|
||||
musicbrainzngs.VALID_INCLUDES["release-group"],
|
||||
]:
|
||||
RELEASE_INCLUDES += ["tags"]
|
||||
|
||||
|
||||
def track_url(trackid: str) -> str:
|
||||
|
|
@ -607,8 +610,8 @@ def album_info(release: dict) -> beets.autotag.hooks.AlbumInfo:
|
|||
|
||||
if config["musicbrainz"]["genres"]:
|
||||
sources = [
|
||||
release["release-group"].get("genre-list", []),
|
||||
release.get("genre-list", []),
|
||||
release["release-group"].get("tag-list", []),
|
||||
release.get("tag-list", []),
|
||||
]
|
||||
genres: Counter[str] = Counter()
|
||||
for source in sources:
|
||||
|
|
|
|||
Loading…
Reference in a new issue