Skip to content

Commit

Permalink
POPM (popularity meter) tag support
Browse files Browse the repository at this point in the history
  • Loading branch information
jmbannon committed Jul 24, 2024
1 parent 3d6bff2 commit 50bab4e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
7 changes: 7 additions & 0 deletions mediafile.py
Original file line number Diff line number Diff line change
Expand Up @@ -1881,6 +1881,13 @@ def as_dict(self):
ASFStorageStyle('TotalDiscs'),
out_type=int,
)
popm = MediaField(
MP3StorageStyle('POPM'),
MP4StorageStyle('POPM'),
StorageStyle('POPM'),
ASFStorageStyle('Popm'),
out_type=int
)

url = MediaField(
MP3DescStorageStyle(key='WXXX', attr='url', multispec=False),
Expand Down
3 changes: 2 additions & 1 deletion test/test_mediafile.py
Original file line number Diff line number Diff line change
Expand Up @@ -1114,7 +1114,8 @@ def test_known_fields(self):
('encoder', 'images', 'genres', 'albumtype', 'artists',
'albumartists', 'url', 'mb_artistids', 'mb_albumartistids',
'albumtypes', 'catalognums', 'languages', 'artists_credit',
'artists_sort', 'albumartists_credit', 'albumartists_sort')
'artists_sort', 'albumartists_credit', 'albumartists_sort',
'popm')
)
assertCountEqual(self, MediaFile.fields(), fields)

Expand Down

0 comments on commit 50bab4e

Please sign in to comment.