beetbox / beets

music library manager and MusicBrainz tagger
http://beets.io/
MIT License
12.78k stars 1.82k forks source link

Strange Behavior with Musicbrainz Tags #1105

Closed offbeatadam closed 9 years ago

offbeatadam commented 9 years ago

Found some strange behavior today importing some albums. All from the same artist. I actually imported 12 total albums, but only these 2 had problems.

Delerium - Faces, Forms and Illusions Delerium - Spiritual Archives

Examine (output from ncmpcpp):

Song name: 01 Monuments of Deceit.flac
Location in DB: Delerium/Faces, Forms and Illusions

Length: 4:19
Bitrate: 616 kbps
Sample rate: 44,100 Hz
Channels: Stereo
─────────────
Title: Monuments of Deceit;Monuments of Deceit                                                                                                                                                            
Artist: Delerium;Delerium
Album Artist: Delerium
Album: Faces Forms and Illusions;Faces, Forms and Illusions
Date: 1989-01-06 | 1989
Track: 01
Genre: Electronic
Composer: ---
Performer: ---
Disc: 1
Comment: ---

If you notice, the information is doubled in some places. The Title, Artist, Album, Date tags are all doubled. This is not unique to one song, it happens to the entire album - and it is equal in the way it happens.

This happens also for the other album:

Song name: 01 Drama.flac
Location in DB: Delerium/Spiritual Archives

Length: 7:40
Bitrate: 688 kbps
Sample rate: 44,100 Hz
Channels: Stereo
────────────
Title: Drama;Drama                                                                                                                                                                                        
Artist: Delerium;Delerium
Album Artist: Delerium
Album: Spiritual Archives;Spiritual Archives
Date: 1996;1991-12-06 | 1991
Track: 01
Genre: Electronic
Composer: ---
Performer: ---
Disc: 1
Comment: ---

At first I thought this might be doubling the discogs content and the MB content - but I performed some tests. I removed the discogs pluging from the list, deleted it from my library and from MPD as well as removed the content and reimported it with the same results.

The XML for the release appears fine. So, I really am not sure why we are getting the odd tagging data. I'm going to dig into the MB import code, but I wanted to get the issue documented first and see if any others have seen this. I've as of yet been unable to get any additional tags that have experienced this.

sampsyo commented 9 years ago

Please see #350—this is an incompatibilty (I'd call it a "bug" :smiley:) specifically in ncmpcpp.

offbeatadam commented 9 years ago

Whats interesting is if I go and look, I see most of the information referenced, but:

triton@amalthea Faces, Forms and Illusions$ metaflac --list 01\ Monuments\ of\ Deceit.flac | grep -i monument 
comment[9]: TITLE=Monuments of Deceit

The track is only actually there once. So, this would mean that as a result of the other double data, this is then doubled as well.

Also interesting is that overall, this only affects specific albums. If I go to another album with information that works and look at the tag data:

comments: 51
comment[0]: LYRICS=
comment[1]: DISCSUBTITLE=
comment[2]: GENRE=New Age
comment[3]: DISC=1
comment[4]: DISCNUMBER=1
comment[5]: MUSICBRAINZ_TRACKID=e0022cd8-c534-4434-bef7-2cc0c77f052c
comment[6]: COMPOSER=
comment[7]: ALBUMARTISTSORT=Delerium
comment[8]: TITLE=Enchanted
comment[9]: MUSICBRAINZ_ALBUMID=26063260-38d0-42cf-9907-2a5f2699c815
comment[10]:..
comment[11]: MUSICBRAINZ_RELEASEGROUPID=8dec8546-f723-3dd2-a63c-7ec9f539d236
comment[12]: ALBUMARTIST_CREDIT=Delerium
comment[13]: ACOUSTID_ID=0950e08e-8647-4d2b-bcf2-6b1acea1ec64
comment[14]: TRACKTOTAL=11
comment[15]: TRACKC=11
comment[16]: TOTALTRACKS=11
comment[17]: MUSICBRAINZ_ALBUMARTISTID=4279aba0-1bde-40a9-8fb2-c63d165dc554
comment[18]: ARTIST=Delerium feat. Kristy Thirsk
comment[19]: BPM=0
comment[20]: ARTIST_CREDIT=Delerium feat. Kristy Thirsk
comment[21]: DISCTOTAL=1
comment[22]: DISCC=1
comment[23]: TOTALDISCS=1
comment[24]: MUSICBRAINZ_ALBUMSTATUS=Official
comment[25]: ALBUM ARTIST=Delerium
comment[26]: ALBUMARTIST=Delerium
comment[27]: DATE=1997-04-22
comment[28]: YEAR=1997
comment[29]: MUSICBRAINZ_ALBUMCOMMENT=
comment[30]: ALBUM=Karma
comment[31]: ASIN=B000005DCB
comment[32]: MEDIA=CD
comment[33]: ARTISTSORT=Delerium feat. Thirsk, Kristy
comment[34]: DESCRIPTION=
comment[35]: COMMENT=
comment[36]: LABEL=Nettwerk
comment[37]: PUBLISHER=Nettwerk
comment[38]: CATALOGNUMBER=0 6700 30113 2 7
comment[39]: ORIGINALDATE=1997-04-22
comment[40]: MUSICBRAINZ_ARTISTID=4279aba0-1bde-40a9-8fb2-c63d165dc554
comment[41]: TRACK=1
comment[42]: TRACKNUMBER=1
comment[43]: COMPILATION=0
comment[44]: ENCODEDBY=
comment[45]: ENCODER=
comment[46]: LANGUAGE=eng
comment[47]: RELEASECOUNTRY=CA
comment[48]: SCRIPT=Latn
comment[49]: MUSICBRAINZ_ALBUMTYPE=album
comment[50]: GROUPING=

The difference is only one field for the broken one:

comments: 52
comment[0]: ENSEMBLE=Delerium
comment[1]: LYRICS=
comment[2]: DISCSUBTITLE=
comment[3]: GENRE=Electronic
comment[4]: DISC=1
comment[5]: DISCNUMBER=1
comment[6]: MUSICBRAINZ_TRACKID=c1ab7e32-e1e8-4bdd-aee0-b35098177dd8
comment[7]: COMPOSER=
comment[8]: ALBUMARTISTSORT=Delerium
comment[9]: TITLE=Monuments of Deceit
comment[10]: MUSICBRAINZ_ALBUMID=9490eb0d-e4d9-4430-8fa2-316ea40c056c
comment[11]: ..
comment[12]: MUSICBRAINZ_RELEASEGROUPID=2a7d5dfb-7943-3679-983a-abc8acaa2757
comment[13]: ALBUMARTIST_CREDIT=Delerium
comment[14]: ACOUSTID_ID=8e2b05e9-fb36-4fdb-95e7-0d5fe85b040b
comment[15]: TRACKTOTAL=9
comment[16]: TRACKC=9
comment[17]: TOTALTRACKS=9
comment[18]: MUSICBRAINZ_ALBUMARTISTID=4279aba0-1bde-40a9-8fb2-c63d165dc554
comment[19]: ARTIST=Delerium
comment[20]: BPM=0
comment[21]: ARTIST_CREDIT=Delerium
comment[22]: DISCTOTAL=1
comment[23]: DISCC=1
comment[24]: TOTALDISCS=1
comment[25]: MUSICBRAINZ_ALBUMSTATUS=Official
comment[26]: ALBUM ARTIST=Delerium
comment[27]: ALBUMARTIST=Delerium
comment[28]: DATE=1989-01-06
comment[29]: YEAR=1989
comment[30]: MUSICBRAINZ_ALBUMCOMMENT=
comment[31]: ALBUM=Faces, Forms and Illusions
comment[32]: ASIN=
comment[33]: MEDIA=CD
comment[34]: ARTISTSORT=Delerium
comment[35]: DESCRIPTION=
comment[36]: COMMENT=
comment[37]: LABEL=Dossier Records
comment[38]: PUBLISHER=Dossier Records
comment[39]: CATALOGNUMBER=DCD 9008
comment[40]: ORIGINALDATE=1989-01-06
comment[41]: MUSICBRAINZ_ARTISTID=4279aba0-1bde-40a9-8fb2-c63d165dc554
comment[42]: TRACK=1
comment[43]: TRACKNUMBER=1
comment[44]: COMPILATION=0
comment[45]: ENCODEDBY=
comment[46]: ENCODER=
comment[47]: LANGUAGE=eng
comment[48]: RELEASECOUNTRY=DE
comment[49]: SCRIPT=Latn
comment[50]: MUSICBRAINZ_ALBUMTYPE=album
comment[51]: GROUPING=

But the other broken one:

comments: 51
comment[0]: LYRICS=
comment[1]: DISCSUBTITLE=
comment[2]: GENRE=Electronic
comment[3]: DISC=1
comment[4]: DISCNUMBER=1
comment[5]: MUSICBRAINZ_TRACKID=14880467-51dc-4233-ae8e-80e2753a7358
comment[6]: COMPOSER=
comment[7]: ALBUMARTISTSORT=Delerium
comment[8]: TITLE=Drama
comment[9]: MUSICBRAINZ_ALBUMID=ff170067-a1ec-4b9f-9235-0cb7b81c49cf
comment[10]: ..
comment[11]: MUSICBRAINZ_RELEASEGROUPID=3cc4570e-231e-39f3-8dfa-5bbfa42fcff2
comment[12]: ALBUMARTIST_CREDIT=Delerium
comment[13]: ACOUSTID_ID=2ac77400-e2d0-4522-9a96-77136ccae451
comment[14]: TRACKTOTAL=8
comment[15]: TRACKC=8
comment[16]: TOTALTRACKS=8
comment[17]: MUSICBRAINZ_ALBUMARTISTID=4279aba0-1bde-40a9-8fb2-c63d165dc554
comment[18]: ARTIST=Delerium
comment[19]: BPM=0
comment[20]: ARTIST_CREDIT=Delerium
comment[21]: DISCTOTAL=1
comment[22]: DISCC=1
comment[23]: TOTALDISCS=1
comment[24]: MUSICBRAINZ_ALBUMSTATUS=Official
comment[25]: ALBUM ARTIST=Delerium
comment[26]: ALBUMARTIST=Delerium
comment[27]: DATE=1991-12-06
comment[28]: YEAR=1991
comment[29]: MUSICBRAINZ_ALBUMCOMMENT=
comment[30]: ALBUM=Spiritual Archives
comment[31]: ASIN=B000025N9V
comment[32]: MEDIA=CD
comment[33]: ARTISTSORT=Delerium
comment[34]: DESCRIPTION=
comment[35]: COMMENT=
comment[36]: LABEL=Dossier Records
comment[37]: PUBLISHER=Dossier Records
comment[38]: CATALOGNUMBER=DCD 9033
comment[39]: ORIGINALDATE=1991-12-06
comment[40]: MUSICBRAINZ_ARTISTID=4279aba0-1bde-40a9-8fb2-c63d165dc554
comment[41]: TRACK=1
comment[42]: TRACKNUMBER=1
comment[43]: COMPILATION=0
comment[44]: ENCODEDBY=
comment[45]: ENCODER=
comment[46]: LANGUAGE=eng
comment[47]: RELEASECOUNTRY=DE
comment[48]: SCRIPT=Latn
comment[49]: MUSICBRAINZ_ALBUMTYPE=album
comment[50]: GROUPING=

Does not show that difference.

If I diff the fields. which I produced using this method:

Put above output through awk '{print $2}' | awk -F'=' '{print $1}’ into separate files. Diff files.

triton@amalthea Desktop$ diff -w faces.txt spiritual.txt 
2,3c2
 52
< ENSEMBLE
---
> 51
triton@amalthea Desktop$ diff -w faces.txt karma.txt 
2,3c2
< 52
< ENSEMBLE
---
> 51

Karma & Spiritual are equal.

So, as far as I can tell, at least by number of fields, there is no immediate difference.

Oh well. Thanks for the info, I’ll have to see if I can figure out some kind of filter or something to get around it. I just wish there was a more obvious reason in the tags that actually accounted for what they say, since based upon the reasoning they give, every file tagged by beets should experience it.

sampsyo commented 9 years ago

Strange—I don't immediately see why the files would differ. Perhaps some of these did not have their tags written by beets (e.g., as-is imports)?

The true answer for the strange display, of course, lies somewhere in the depths of ncmpcpp.