Phonograph
Phonograph copied to clipboard
Artist sort order incorrect
When viewing the list of artists, the sort order is not being applied properly.
Device info:
App version | 1.0.0 |
App version code | 160 |
Android build version | 1735215358056 |
Android release version | 7.0 |
Android SDK version | 24 |
Android build ID | NRD90U |
Device brand | lge |
Device manufacturer | LGE |
Device name | lucye |
Device model | LG-H872 |
Device product name | lucye_tmo_us |
Device hardware name | lucye |
ABIs | [arm64-v8a, armeabi-v7a, armeabi] |
ABIs (32bit) | [armeabi-v7a, armeabi] |
ABIs (64bit) | [arm64-v8a] |
This is with sort order set to "Ascending" - Note the artist names are inserted into incorrect places in the list.
Bug appeared in commit be54afd3
Seems to be an issue with sorting the songs in the albums in AlbumLoader#splitIntoAlbums
Hello @thedoc31 , thanks for reporting. I cannot reproduce this. What are your sort order for titles and albums?
Happens for me both with Ascending and Descending order on Artists. Does not happen for me with Ascending or Descending order on Albums or Songs.
On artists the sort order is consistently wrong in the same way - for instance "The Chemical Brothers" always shows up after "Aerosmith" and "No Doubt" shows up after "The Chemical Brothers", even if I sort Descending and go back to Ascending.
Thinking about reinstalling the app, because songs within an album are playing shuffled and I can't seem to find a way to turn that off.
Artist Ascending
Artist Descending
Albums Ascending
Songs Ascending
@thedoc31 is the shuffle button disabled (when you slide up the player)?
Thank you @kabouzeid, that fixed the shuffle issue. I didn't even realize that existed or have any idea how it accidentally got turned on. Probably one of those days I was on the subway fumbling to pause music at my stop. I think I'll submit an enhancement request of some sort to make the "Shuffle" button on the main album song list tie in with the one on the player so you can easily see/turn it off.
While sorting it ignore the word 'the' everywhere.
@h4h13 this is intended and the default sort order of Android
Sorry for bothering. Already tried changing the shuffle button and the artists are in the wrong order.
I can notice this issue on my OnePlus 6 as well.
Any update on this guys? The sort order is completely off (Samsung S7 Android 8.0).
So, simply based on the code, there doesn't seem to be anything problematic. It implements the default Android mediastore interface sort order.
Perhaps the issue is with the music tags themselves? I don't think it's displayed, but there is a tag sometimes used called "artistsortorder". I am not sure if it's respected by the mediastore but it could be something causing this issue. If you could provide two files with the issues for testing purposes, it might be easier to identify the issue @SnakeyHips . One with proper sorting and one that appears as an exception.
For what it's worth, I still have the problem on my new LG G7 ThinQ with Android 8.0.0, and no other media application I have on my device (LG Music, Google Play Music) sorts these incorrectly. I'll check my files for the artistsortorder as well.
The most interesting thing I've noticed from your screenshots is that Plaisir De France appears in two different spots on the ascend and descend lists. On the ascend list, it's between "Dick Dale" and something off screen. On the descend list, it's between "101" and "Zero 7". Here, both are sorted wrong.
EDIT: On another note, I've noticed that the tag editor doesn't appear to work.
Here's a gif illustrating me sorting by ascending and descending. Not only is the order wrong for both but one artist doesn't even change. Something strange is going on here especially as I don't have this issue using any other app.
The tag editor on mine works fine and the artist field is being filled correctly there so really have no idea what's going on. Sorting on other tabs is fine.
I've spot-checked some of the MP3s with corresponding artists out-of-order within Phonograph, but I'm not seeing an ARTISTSORTORDER tag on any of them so far with the tools I have (mp3tag, Windows Explorer, checking files through File Manager on the Android device). Happy to package up some of the troublesome albums or do a screenshare session to check them out, if that might help.
@thedoc31 I would very much appreciate a zip package containing some of the albums with the issues. Additionally, perhaps one song from a working album from which to compare with. I'll see if I can replicate the issue.
If you don't mind me asking, are these files stored in one general directory (with sub-directories) or are they stored in multiple storage locations, some on internal storage, some on external storage?
Additionally, I found the issue with the tag editor. It seems that Phonograph doesn't have proper write permissions on the /storage/0000-0000 mount, which is the external SD card on my Sammsung S8+. I could only delete files using my file manager after giving it write permissions.
This was technically addressed in #458 but I'm not entirely sure how @kabouzeid intended on fixing it.
Did you mean #457? Could be an issue with language or the way that artists get recognized.
#498 *
I did a little more playing around with this today. It seems this may actually be related to #496 or #497 and Phonograph's handling of Various Artist albums (compilations, soundtracks, etc).
Video [1] shows the bug in action and how to "fix" the issue by deleting songs from the same artist in "Various Artists" compilation albums. My Android device's SD card has the same permissions issue as @Vesnyx, so deleting from Phonograph just seems to remove the references in the back-end database but the files stay on the SD card. This also uncovered a secondary bug where once a file is deleted from the database and you go back to the Artists list, the next artist from the next song in the VA album will replace the deleted one but does not re-sort.
[2] Shows the folder structure on the SD Card and what happens when I use Phonograph to re-scan the Various Artists folder. It puts us right back where we started
[3] Is a .7z file for you with some of the files so you can play with this.
[1] STR #1 - https://youtu.be/LepHd2-Wlo8 [2] STR #2 - https://youtu.be/Asjoup1esQw [3] https://drive.google.com/file/d/1bdrVdQdDf9NJrsu5-BlrHkCEd9y9-Z6o/view?usp=sharing
Please let me know after you've downloaded the .7z so I can remove public access.
Ok, so I tested the songs you gave on my device as well. The issue is easily replicated.
One of the primary things to be fixed is how some of the artists don't even show up. This is because of this code here: https://github.com/kabouzeid/Phonograph/blob/master/app/src/main/java/com/kabouzeid/gramophone/loader/ArtistLoader.java#L60-L62
Since the call is done per album and the albumid returns the artist for only the first track if an album artist is unassigned, many of the songs end up missing altogether. This can be remedied by iterating over them in another way.
I'll take a look at the other part later, but I suspect that this may have something to do with it.
Thanks for the explanation, @Vesnyx! Will be great to have it fixed. Let me know when you've got a beta patch in place and I'm happy to test it out for you on my phone.
If I can help with testing (or even with the code, though I haven't done any Android development yet), just tell me!
I am having this same bug. About 2/3 of the my albums sort properly by name, but the other 1/3 do not (and they show up before the ones which sort properly). Was this resolved?
I am having this same bug. About 2/3 of the my albums sort properly by name, but the other 1/3 do not (and they show up before the ones which sort properly). Was this resolved?
Oops that should have said "properly by artist name".
Also, for what it's worth, I don't ever use the AlbumArtist tag, at least not intentionally. As far as I know all of my songs are just tagged via Artist Name.
So, any update on this? I LOVE Phonograph but this issue is extremely frustrating.
I've managed to work around this problem with the technique below. It's worth noting my occurence of this problem is only with compilation albums, regular albums that are well tagged are in the right order.
In "Artists" display, find an artist that's not where they should. Select this artist. Now, in the current display, tap on the album cover above the list of tracks. Once again, in the case I'm describing, this is necessarily a compilation album. ALSO NOTE : THIS WILL PUT THE ARTIST AWAY INTO "VARIOUS ARTISTS" UNDER ARTIST VIEW, I DON'T KNOW HOW TO KEEP ARTISTS VISIBLE IN THE LIST IF THEY'RE ONLY ON A COMPILATION!
In the top right, tap "Tag Editor". Under "Album artist", type "Various Artists". In some cases, this might be already written. If so, place your cursor at the end of "Artists" and delete, then re-type the "s" so that the app understands you want to save a change. Once "saving changes..." and then "scanning () of () files" are done, go back all the way to Artists display. In my case, this made the artist dissappear from view and get put with "Various Artists". Hope this could help someone 🙂
Ive noticed that if you had songs from an artist that already is present on your device, it adds a "duplicate" artist with the same name, which is out of alphabetical order