Up to now my library has been sorting relatively sanely, I am careful to tag my files with artists in library sort format, such as moving articles to the end and “Last, First” format for given names. But now it is consistently showing all names in “First Last” format and I’m ready to lose my s**t. Am I really going to have to manually edit 1,200+ artists and lock the tag to fix this? It doesn’t seem to matter whether I use “Prefer Local Metadata” or not. I’m baffled as to why the field would exist and be populated the way it is, if I wanted to sort by the artist tag I would just leave the sort blank.
There is a very large change to how music metadata is handled in the 1.27.0 beta, it might be an oversight from this change but I cannot seem to reproduce the problem on my end.
Could you give me an exact example of the artist or even DM me a sample file?
Ah thanks, I thought you meant for artist names with articles like “The, A, etc”.
The actual issue is that we’re not correctly holding on to the titleSort from embedded tags, I’ve already found the issue and it will be patched before 1.27.0 goes to public.
I’ve tried refreshing metadata both with and without “Prefer local metadata” turned on, neither gets correct sorting. I’d rather leave it turned off since I’m generally happy with the results and don’t want to lock myself out of any new data.
@drzoidberg33
I’ve got this happening again in build 1.27.0.5897. Weird thing is, a few artists are getting it right, but most are not. I allowed Plex to create a whole new library for my classical music, and I found a few that had Sort Artist=Last, First and couple that had obviously gotten the sort order tag from MusicBrainz instead of the embedded tag. For example:
Doesn’t look like we provide artist sort values at all, so I don’t think that’s coming from Plex. Are you sure it’s not tagged in another attribute in the file?
Could you run ffprobe on the file and post the output?
Aha! You’ve found it. It turns out that Picard has put the artist sort in a tag that I wasn’t aware of, albumartistsort. The few artists that Plex is correctly sorting by last, first are the ones with this tag populated. I’m finding more and more tags where Picard and Puddletag do things differently, and no wonder why they match MusicBrainz. I can clean this up now.
There is still some weirdness going on with the “Sort Artist” for the artist. The “Sort Artist” is coming from the first track’sARTISTSORT ID3 tag. “Prefer local metadata” is disabled for the library.
Here is an example. I added a single track to my library that has a featuring artist. After scanning in the file, Plex grabbed the track ARTISTSORT ID3 tag and set it as the “Sort Artist”. This is undesirable because the tag includes the featuring artist.
I then removed that file and added a different track to my library. After scanning, emptying trash, and refreshing the artist metadata, the “Sort Artist” updated to match the new track.
I then removed the second track and scanned/emptied trash so the artist is completely removed from my server. Next I tried adding the both tracks one at a time to my library but in different orders. The “Sort Artist” always took the ARTISTSORT tag from whichever track I added first and refreshing the artist metadata will not change it.
Long story short, I don’t want Plex to use the embedded ARTISTSORT tag, especially when it depends on the order files are scanned in and some files contain info like a featuring artist. This was definitely unexpected since I have “Prefer local metadata” unchecked. I would prefer if the “Sort Artist” field just used the “Artist” field without anything coming from the embedded tags.
I had a quick look at this code and this behaviour shouldn’t be new, in the Python code there is actually still this comment
# Look for artist/artist sort field from first track.
# TODO maybe analyse all tracks and only add title_sort if they are the same.
As we tried to not modify any behaviour while re-writing the music agent code this behaviour is still present.
I will open an issue to fix this as it’s definitely not ideal.
Also note that “Prefer local metadata” behaves exactly like the wording implies, it prefers local tags when enabled but will still use local tags when it’s disabled if the cloud metadata source doesn’t return a value for a specific field.
I downgraded to PMS 1.26.2.5797 (the last public version with the Python Plex Music agent) to make sure I’m not crazy.
I added the same one track with the featuring artist in the ARTISTSORT and the agent didn’t use it as the artist’s Sort Title. This is what I expected and actually prefer (First Last instead of Last, First).