Skip to content
Open
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
1 change: 0 additions & 1 deletion beets/config_default.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ statefile: state.pickle
# --------------- Plugins ---------------

plugins: [musicbrainz]

pluginpath: []

# --------------- Import ---------------
Expand Down
2 changes: 2 additions & 0 deletions beets/library/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,7 @@ class Album(LibModel):
"language": types.STRING,
"country": types.STRING,
"albumstatus": types.STRING,
"media": types.STRING,
"albumdisambig": types.STRING,
"releasegroupdisambig": types.STRING,
"rg_album_gain": types.NULL_FLOAT,
Expand Down Expand Up @@ -320,6 +321,7 @@ def _types(cls) -> dict[str, types.Type]:
"language",
"country",
"albumstatus",
"media",
"albumdisambig",
"releasegroupdisambig",
"release_group_title",
Expand Down
1 change: 1 addition & 0 deletions docs/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ New features:
- :doc:`plugins/mbpseudo`: Add a new `mbpseudo` plugin to proactively receive
MusicBrainz pseudo-releases as recommendations during import.
- Added support for Python 3.13.
- Added album-level `$media` field derived from items’ media metadata.

Bug fixes:

Expand Down
13 changes: 13 additions & 0 deletions test/test_media_field.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
from beets import library
from beets.library import Item


def test_album_media_field(tmp_path):
lib = library.Library(
path=str(tmp_path / "library.db"), directory=str(tmp_path / "music")
)

item = Item(title="Test Song", album="Test Album", media="Vinyl")
album = lib.add_album([item])

assert album.media == "Vinyl"
Loading