Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add use_mb_genres config option. #3786

Merged
merged 3 commits into from
Oct 31, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion beets/autotag/mb.py
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ def album_info(release):
info.media = first_medium.get('format')

genres = release.get('genre-list')
if genres:
if config['musicbrainz']['genres'] and genres:
info.genre = ';'.join(g['name'] for g in genres)

info.decode()
Expand Down
1 change: 1 addition & 0 deletions beets/config_default.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ musicbrainz:
ratelimit_interval: 1.0
searchlimit: 5
extra_tags: []
genres: no

match:
strong_rec_thresh: 0.04
Expand Down
6 changes: 4 additions & 2 deletions docs/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -159,9 +159,11 @@ New features:
* :doc:`/plugins/web`: add DELETE and PATCH methods for modifying items
* :doc:`/plugins/lyrics`: Removed LyricWiki source (shut down on 21/09/2020).
* Added a ``--plugins`` (or ``-p``) flag to specify a list of plugins at startup.
* Use musicbrainz genre tag api to get genre information. This currently
* Use the musicbrainz genre tag api to get genre information. This currently
depends on functionality that is currently unreleased in musicbrainzngs.
See https://github.com/alastair/python-musicbrainzngs/pull/247 and
Once the functionality has been released, you can enable it with the
``genres`` option inside the ``musicbrainz`` config. See
https://github.com/alastair/python-musicbrainzngs/pull/247 and
https://github.com/alastair/python-musicbrainzngs/pull/266 .
Thanks to :user:`aereaux`.

Expand Down
12 changes: 11 additions & 1 deletion docs/reference/config.rst
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,6 @@ Sets the albumartist for various-artist compilations. Defaults to ``'Various
Artists'`` (the MusicBrainz standard). Affects other sources, such as
:doc:`/plugins/discogs`, too.


UI Options
----------

Expand Down Expand Up @@ -721,6 +720,17 @@ above example.

Default: ``[]``

.. _genres:

genres
~~~~~~

Use MusicBrainz genre tags to populate the ``genre`` tag. This will make it a
semicolon-separated list of all the genres tagged for the release on
MusicBrainz.

Default: ``no``

.. _match-config:

Autotagger Matching Options
Expand Down