Sort by date added not working correctly with navidrome

Issue description:

Sorting by date added does not work as I would expect it to. In the navidrome UI the “Recently Added” option sorts the albums correctly, and DSub shows it correctly too. I tried with compatibility mode, fetch more metadata and combinations but it doesn’t work.


Upload description: 4ntb forum

Additional information:

 Also, checking the getAlbum and getAlbumList endpoints on my instance, the values returned are correct, as shown on Dsub 

Reproduction steps:

 Not provided 

Media provider:



Wrong order ----------------------------- Correct Order

In what part of Symfonium are you ?

And the logs is empty, I need logs containing a full sync + reproducing the issue…

The left image is an album playlist sorted by “Date added”. I have synced the media provider with debug enabled an uploaded the file again with the identifier 4ntb sync. Relevant logs start from 12:00. Thanks for your time.

Looking at it a bit more, looks like the search3 endpoint from navidrome returns the imported file time instead of the modification time, which is the correct one as ND_RECENTLYADDEDBYMODTIME is set. Other endpoints like, getAlbum and GetAlbumList work correctly. I guess this is not a Symfonium problem but a navidrome one, if it is not possible to use another endpoint for the sync.

Well the API have only one date for that and it’s the created one.

You need to validate with @deluan why the data is not the same on the different end points.

All created attributes in all Subsonic responses are the same: It is the birthDate of the file, if the system supports it. If it is not supported, it is the import time.

The getAlbumList?type=newest sort order is governed by the RecentlyAddedByModTime flag: It uses created by default, but if the flag is true it uses the modTime.

So it is not really an issue with Navidrome. The results in the responses are consistent, but the behaviour of the order of the response is controlled at runtime by the that flag.

Different than other Subsonic clients, Symfonium does not use the browsing endpoints to display its “Recently Added” list, it syncs everything with search3 and uses its own logic to sort albums. As the (Open)Subsonic API does not provide modified time, I think it is not currently possible to replicate the behaviour of the “live” getAlbumList endpoint in Symfonium.

Ok so this is a specific hack in Navidrome for a specific endpoint.

Symfonium is multi provider, date added is what is used to sort by recently added as in the name of the sort :slight_smile:

Not a “hack”, it is an option. Anyway, the default false should make the behaviour consistent in all Subsonic clients and Navidrome’s UI.

If you want, but in the end this change the behavior of one end point based on non exposed data.

IMO such option should be more global and the created returned should match the end point for consistency. Recently added is sort by date added, date added is created in Subsonic POV. Exposing modified as added everywhere would be more consistent.

Anyway not a big deal, just something to know.

but in the end this change the behavior of one end point based on non exposed data.

That is true for a lot of options, even in OG Subsonic. Ex: IgnoredArticles (bad example, this is exposed). That’s the cost of the added flexibility :slight_smile:

Exposing modified as added everywhere would be more consistent.

A better solution would be to add a changed field alongside created. That would be more consistent, IMHO.

Not really, the endpoint is recentlyAdded not recentlyModified, so that would allow clients to add a sort by recently modified, but that would not change the difference in recentlyAdded that return non conventional data that users do not understand.

So the real proper solution is to expose the field and a new endpoint, but even then if you want to support legacy client this still won’t work.

That’s why as a legacy option for consistency it makes more sense to expose consistent data.

But since it’s legacy let’s ignore this as you probably won’t agree with me on this :wink:

From what I see in this discussion, the problem lies in the use of the RecentlyAddedByModTime flag. I used it to keep the dates I added each album because I just recently started using navidrome, and so it used import time not mod time by default. Although I’d prefer standarization between endpoints, this is such a small thing I will just modify the database and remove the flag.

Thanks a lot for your time guys!