Bugzilla – Bug 4582
ALBUMARTIST causes problem with ARTISTSORT in single album FLAC files
Last modified: 2011-04-07 11:29:19 UTC
Hi, I rip my music to a single FLAC file for each CD. Each FLAC file has VORBIS comments in the following form ARTIST=Artist Name ARTISTSORT=Name, Artist ALBUMARTIST=Artist Name ALBUM=Some Album TRACKNUMBER[1]=1 ARTIST[1]=Artist Name ARTISTSORT[1]=Name, Artist TITLE[1]=Track Number 1 ARTIST[2]=Artist Name ARTISTSORT[2]=Name, Artist TITLE[2]=Track Number 2 ARTIST[3]=Artist Name ARTISTSORT[3]=Name, Artist TITLE[3]=Track Number 3 If I have the 'ALBUMARTIST' track present, then the ARTISTSORT tag appears to be ignored. If I removed the ALBUMARTIST tag, ARTISTORT is applied correctly.
Ross could you have a look at this? I would try to reproduce just by editing the flac tags first and if you cannot reproduce, doing some research into the VORBIS tags mentioned.
I can provide a full dump of all the tags for one of my FLAC files if it would help. You could then try it with and without the 'ALBUMARTIST' tag (I'm currently running with it removed) Andy
Andy, Sounds great, go ahead and attach any files you think will help us out.
Created attachment 1741 [details] Tags dump from one of my files This file is a dump of tags from one of my files. As is, the sort field in the database will end up as 'Brown, Sam'. If I add 'ALBUMARTIST=Sam Brown', the sort field will be 'Sam Brown'
Andy what application are you using to edit vorbis comments on your flac files?
This is all under Linux, so I either use metaflac to export them to a text file, edit them and re-import using metaflac, or I use an application I wrote myself that uses libflac++ to write them. I don't think this is necessarily relevant, but am prepared to try another method if you think it would help isolate the problem.
Andy would it be possible for you to send me the file you're able to reproduce this behavior with? I realize it's probably a very large file; you could send it to me via www.dropload.com to ross@slimdevices.com.
Are you having problems recreating this? It was fairly obvious when I tries. Scanning a file without an ALBUMARTIST tag worked fine, if I added the ALBUMARTIST tag, then the sort name was overwritten. Perhaps something has changed in a recent nightly?
The reason I'm asking for a sample file of yours is I think it would help me to reproduce this. None of the utilities I've used for adding/changing vorbis comments on a flac file show me anything similar to what you're showing. Would you mind sending me a sample file to demonstrate this issue? If it's too much trouble I understand. I'll be working on this here on my end, but it may take me a few more days.
Hmm, this is odd. I've just tried to recreate it myself (after updating to the latest code) and I'm no longer seeing this behaviour. I'm not sure if anything has changed in the last week or two that might have fixed this? My svn update certainly grabbed a lot of files. I'll keep an eye on it and see if I can work out what's going on. Andy
A festivus miracle perhaps... Keep us posted please.
Andy, were you ever able to see this again? Thanks.
Yes Just changed all of my 'Sam Brown' collection to include tags like: ALBUM=Stop! ALBUMARTIST=Sam Brown ARTIST=Sam Brown ARTISTSORT=Brown, Sam ... TRACKNUMBER[1]=1 ARTIST[1]=Sam Brown ARTISTSORT[1]=Brown, Sam MUSICBRAINZ_ARTISTID[1]=8ec33fe2-4775-474c-a4a8-65dbbb98f87c MUSICBRAINZ_TRACKID[1]=a803c6cf-9616-4fc6-8c87-08789932521c TITLE[1]=Walking Back to Me TRACKNUMBER[2]=2 ARTIST[2]=Sam Brown ARTISTSORT[2]=Brown, Sam MUSICBRAINZ_ARTISTID[2]=8ec33fe2-4775-474c-a4a8-65dbbb98f87c MUSICBRAINZ_TRACKID[2]=3c77ceaf-5ee6-432d-adae-5da7426b2dd0 And Sam Brown is appearing under 'S'. The sort field in the database is 'SAM BROWN' Andy
So artistsort is broken again? Andy would you mind attaching the Sam Brown file please?
Correct, the ARTISTSORT breaks when I add an 'ALBUMARTIST' tag. I have several Sam Brown albums. The smallest one is 78 Meg. Anywhere I can upload it to make it available to you? Andy
Andy, I think I may need to have a look at your files. I'm not able to reproduce this. I'm using SlimServer 6.5.1 on Ubuntu with two flac files. One of them I have tagged with Artist Name "Sam Brown", Album Artist as "Sam Brown", and Artist Sort as "Brown, Sam". The other artist name starts with N, and when I browse -> artists in SlimServer it's correctly sorting Sam Brown before the song titles with N. Andy would you mind sending the offending file(s) to me via dropload.com? ross@slimdevices.com
Ok, I've uploaded one of my files here: http://www.gently.org.uk/uke.flac All of my files are tagged virtually the same (I use a program I wrote to download data from MusicBrainz and do the tagging). My database shows the following: mysql> select * from contributors where name like "%Sam Brown%"; +----+-----------+-----------+------------+--------------+--------------+-------------------+----------------+--------------------+ | id | name | namesort | namesearch | customsearch | moodlogic_id | moodlogic_mixable | musicbrainz_id | musicmagic_mixable | +----+-----------+-----------+------------+--------------+--------------+-------------------+----------------+--------------------+ | 10 | Sam Brown | SAM BROWN | SAM BROWN | 0726027696 | NULL | NULL | NULL | NULL | +----+-----------+-----------+------------+--------------+--------------+-------------------+----------------+--------------------+ 1 row in set (0.00 sec) If I remove the 'ALBUMARTIST' tag, then the namesort value becomes correct (Brown, Sam) Please let me know when you've downloaded this file so that I can delete it. Andy
Just for info, this is the output of my svn info in the slimserver directory andy@gently:/usr/lib/slimserver/server$ svn info Path: . URL: http://svn.slimdevices.com/repos/slim/branches/6.5/server Repository UUID: 60ad55ce-86ed-0310-8cf8-f9d879be5ea1 Revision: 11435 Node Kind: directory Schedule: normal Last Changed Author: titmuss Last Changed Rev: 11414 Last Changed Date: 2007-02-12 20:18:12 +0000 (Mon, 12 Feb 2007) Properties Last Updated: 2006-10-12 11:19:50 +0100 (Thu, 12 Oct 2006) I tend to update every couple of days when I remember. Andy
Andy, Thanks for attaching. I've downloaded the file you can go ahead and remove it. It seems to work fine on my SlimServer XP instance, but I'm having issues with my debian instance. I might not be able to test this out until next week. I will comment again soon.
Andy, Just to clarify the exact problem: when you implement ALBUMARTIST, ARTISTSORT isn't working. In other words your Sam Brown album is being sorted (within browse -> artists) under S and not B? I've just tried this with SlimServer 6.5.1 on Ubuntu 6.06.1 and it's sorting it properly for me. Am I correctly summarizing the exact issue?
That is correct, yes. As you can see from the database listing I provided in comment #17, the 'namesort' column is incorrect. Are there any useful flags I can pass to the scanner process that might help in the diagnosis? Andy
If you'd like you can try d_scan and d_source. Is it possible that another file is causing some confusion here? I'm not sure how this is possible if I'm using the same file you are, what are you comparing against in terms of sort order? Do you have any ideas what might be causing this?
Ok, I'll do a scan of my Sam Brown directory with those flags. I'm not sure what you mean by another file affecting it. I have no other music by Sam Brown except what's in this directory (nothing on any compilations or anything). As to what I'm comparing it against, in comment #17 I included a database dump for the Sam Brown contributor, that clearly shows the 'NAMESORT' column containing 'SAM BROWN' and not 'BROWN, SAM' Andy
Ok, the following command: ./scanner.pl --wipe --d_parse --d_source --d_sql /var/spool/music/FLAC/B/Sam\ Brown/Ukulele\ and\ Voice\ -\ 5\ Songs.../ 2>sambrown.txt (--d_source is reported as an invalid argument) produces the attached output. As you can clearly see, the output contains the line: 2007-03-08 09:29:35.9634 INSERT INTO contributors (musicbrainz_id, name, namesearch, namesort) VALUES (?, ?, ?, ?): 'NULL', 'Sam Brown', 'SAM BROWN', 'SAM BROWN' which is populating the namesort column with 'SAM BROWN' If there's any more debugging arguments you'd like me to try, then just let me know. Andy
Created attachment 1833 [details] Output of scanner.pl This is the output from: ./scanner.pl --wipe --d_parse --d_source --d_sql /var/spool/music/FLAC/B/Sam\ Brown/Ukulele\ and\ Voice\ -\ 5\ Songs.../ 2>sambrown.txt
Enhancement request Bug 4584 seems related.
This log seems as it should, it's picking up artistsort as Brown, Sam. Dan does anything seem out of the ordinary in his log?
But the SQL insert command is: 2007-03-08 09:29:35.9634 INSERT INTO contributors (musicbrainz_id, name, namesearch, namesort) VALUES (?, ?, ?, ?): 'NULL', 'Sam Brown', 'SAM BROWN', 'SAM BROWN' No mention of 'Brown, Sam' anywhere on that line. Andy
Ahh good point. Dan does this make any sense?
Until we support albumartistsort I don't see this bug making much progress. Changing the target accordingly.
This is an odd approach to tagging. We are already considering paying attention to an albumartistsort tag, but behaving properly with this tagging scheme would involve pretty major changes.
(In reply to comment #31) > This is an odd approach to tagging. We are already considering paying > attention to an albumartistsort tag, but behaving properly with this tagging > scheme would involve pretty major changes. i agree. this bug should probably be closed, as well as the similar bug 6189 ALBUMARTIST tags should always take precendence over artist tags, of any type. a user could then just use ALBUMARTISTSORT which i believe SBS now supports (one day, hopefully SBS will be smart enough to switch on the fly between artists/albumartists, but thats not an issue for this bug) see: bug 5177 bug 11159