spotube icon indicating copy to clipboard operation
spotube copied to clipboard

Sorting Playlist by Newest Added and Oldest Added is wrong

Open gitgonwild opened this issue 6 months ago • 4 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Current Behavior

When I try to sort a playlist by 'newest added' or 'oldest added' it does not correctly sort.

The default 'None' sort is how I added the songs into the playlist. Meaning the top song shown in the below screenshot is the oldest song in the playlist and the bottom song is the newest, so sorting by 'Oldest added' shouldn't change the order of the songs. default

When I sort by 'Oldest Added' this is the result. oldest sort

When I sort by 'Newest Added' this is the result. newest sort

Note that in 'Oldest Added' the order from bottom up is 'Hard to Say Goodbye' --> 'she knows it' --> 'Bubbly' --> 'Lifeline'. Then in the following image 'Bubbly' and 'Lifeline' switch places giving the order 'Hard to Say Goodbye' --> 'she knows it' --> 'Lifeline' --> 'Bubbly'.

Screen shots were taken on version 3.2.0 but I have verified that the sorting is consistent in version 3.3.0. Meaning the order of the songs for "Oldest Added' is the same in version 3.3.0 and 3.2.0. The same applies to 'None' and 'Newest Added' as well.

Expected Behavior

Since I am adding things into a playlist and I am unable to sort or move songs around through Spotify, the songs in the playlist should not move when I sort by 'Oldest Added' and the song list should flip around when I sort by "Newest Added'.

Steps to reproduce

  1. Create a playlist
  2. Individually insert 10 or more songs into the playlist and note the order you add them
  3. Notice the order of the songs in the playlist from top down. (Default sort 'None' should be oldest track to newest track)
  4. Sort playlist by 'Oldest Added'
  5. Notice songs move
  6. Sort Playlist by 'None'
  7. Notice order of songs from the bottom up
  8. Sort playlist by 'Newest Added'
  9. Notice songs are not in order

Operating System

Windows 10 Version 22H2

Spotube version

3.3.0 and 3.2.0

Installation source

Website (spotube.netlify.app) or (spotube.krtirtho.dev)

Additional information

I was able to reproduce this issue on both 3.3.0 and 3.2.0.

I have tried reinstalling Spotube 3.3.0 and moving the installation location. The issue persists.

I think there is a small delay when adding songs to a playlist so I get that some things could get out of order a little, but this also happens if you add songs to a playlist through Spotify where it instantly puts a song into a playlist. If you are looking at said playlist within an hour of adding songs on Spotify it will tell you X-song was added X-minutes ago and the default order of said playlist would be in 'Oldest Added', so sorting on Spotube should again not change the order of the songs when selecting 'Oldest Added' and then flip the order around when selecting 'Newest Added'.

If this turns out to be a huge pain to fix a temporary fix could be to add a 'Sort By' option that does indeed just flip the playlist around from the default 'None'. Ideally this is also an option I would like to have as a permanent option. I am going through the effort to add songs into a playlist in reverse order that I want them in so I can easily append new songs to the list in a specific order. So to be able to 'flip' the list would be awesome.

gitgonwild avatar Dec 25 '23 07:12 gitgonwild