jellyfin / mopidy-jellyfin

Jellyfin Extension for Mopidy
https://jellyfin.org
Apache License 2.0
93 stars 16 forks source link

[bug] Tracks appearing out of order, built-in library not populating #84

Open sudotm opened 3 years ago

sudotm commented 3 years ago

I have upgraded mopidy-jellyfin to 0.9.3 after experiencing the bug in issue #18 and I can now successfully see all of the artists and albums when using the mopidy/mpd client's file browser.

Though, when within the Jellyfin -> Music directory, the tracks of each album appear out of order. This occurs on every client I tested on (MALP, Cantata, Musicbox, Iris and ncmpcpp).

The built-in Mopidy library remains empty and unpopulated when using Cantata/Iris/MALP. Conversely, when pressing 4 in ncmpcpp to get to the "Media Library" screen, all the tracks appear in their proper order.

"Error 2/0: incorrect arguments" still occurs when launching MALP.

I've not used Mopidy much before, but in my previous experience with MPD, the symptoms described above would occur when the internal database was still being built. In this case, the issue has not resolved itself after being left for an extended period. This occurs even with an extremely small library of just a few albums.

Please note that there are currently no issues with my library organization. All of the content is neatly structured Artist -> Album -> Tracks.

mcarlton00 commented 3 years ago

Sounds like there's several unrelated issues here, but we'll see where they each lead to.

Screenshot_20200828-093109

mcarlton00 commented 3 years ago

Alright, maximum fun.

When going through the browse/files entrypoint, the output isn't sorted with any logic I can follow. The order that I return tracks to Mopidy is not the order that they appear in any of the clients. Further, it doesn't appear I can add any extra bits to the items to let it sort in a different order, that does indeed appear to be entirely a client side option.

For ncmpcpp, I have this in my config file that seems to have solved this problem

song_list_format = '{%n - %t}|{%t}'$R{$3(%l)$9}
browser_sort_mode = format
browser_sort_format = '{%n - %t}|{%t}'

This will sort by track number first (%n), then the title afterwards (%t).

sudotm commented 3 years ago

After clearing the data & cache in MALP, mine now behaves the same as yours, so the ERROR 2/0 thing seemed to have been solved by the 0.9.3 update after all. The disc view is also empty for me, but I know that it is supposed to be an album view.

Setting the URI in Iris seems to work somewhat, though the album library view is completely empty similar to MALP. Also, clicking on an artist fails to parse the albums and just shows a long list of tracks.

I have noticed that these issues as well as the out-of-order tracks do not occur with the mopidy-local extension. Perhaps utilizing a library.db file like mopidy-local does could solve these issues? I'm not sure if this is at all feasible, so feel free to disregard the suggestion.