mirror of
https://github.com/aome510/spotify-player.git
synced 2026-04-26 17:35:50 +03:00
[GH-ISSUE #378] Add automix flag (always play random music from the current playlist) #202
Labels
No labels
bug
documentation
enhancement
good first issue
help wanted
pull-request
question
third-party
third-party
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/spotify-player#202
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @FromWau on GitHub (Feb 24, 2024).
Original GitHub issue: https://github.com/aome510/spotify-player/issues/378
Hi, I would love to have a flag
automixin the config, which makes it that the next song is truly random. (Same internal handling like sending the commandPlayRandom).Is your feature already implemented in the latest
master?No. But there is thou already a
PlayRandomcommand.Is your feature request related to a problem? Please describe.
Without this feature, spotify_player plays just a mix from the last 50 songs added to my liked playlist.
Describe the solution you'd like
I would like to have a flag
automixadded to the config,This flag should when enabled behave like currently. But when disabled, it should always play a random song from the current playlist.
Describe alternatives you've considered
Pressing
PlayRandomsolves this, but it would be nice if it would automatically play a random song.@aome510 commented on GitHub (Feb 24, 2024):
50comes fromtracks_playback_limitconfig (https://github.com/aome510/spotify-player/blob/master/docs/config.md#general). You can try to increase the value to allow creatingtracksplayback of more songs. Just a note that a big value will not work because there is a limit on number of tracks specified in atracksplayback API request.Should have added a note to how
tracks_playback_limitworks. In short, the app will pick an interval with at mosttracks_playback_limitsongs containing the selected song to start atracksplayback.@aome510 commented on GitHub (Feb 24, 2024):
To clarify,
tracksplayback is a playback with a bunch of songs unlikecontextplayback (artist,playlist,album). "liked songs" doesn't count as a playlist. Playing song from "liked songs" page will start atracksplayback and invokingCurrentlyPlayingContextPagecommand will lead you to acannot determine current page's contextpage.@FromWau commented on GitHub (Feb 25, 2024):
Thanks for the clarification.
This might be a dump question, but why do we use the
tracksplayback, which creates a subset of songs as I understand, instead of picking random songs from the page (e.g. Liked Songs) where they don't provide acontextplayback? Wouldn't this solve the limitation of the Spotify API, that we can only createtracksplayback with up to 100 songs?@aome510 commented on GitHub (Feb 25, 2024):
The main reason is to avoid possible confusion when user doesn't have shuffle on.
Not really as the playback still contains a subset of the liked songs, e.g if you listen for a long time, it will loop between pre-selected 100 songs.
automixbehaviour can be supported by implementing a custom logic to invoketracksplayback by "batches". For example, after finish playing a 50-song playback, the app will pick another "batch" of 50 songs to start the nexttracksplayback.@FromWau commented on GitHub (Feb 27, 2024):
I would think
mixautowould only apply when shuffle is enabled. When not shuffling, we just have an ordered playback.Yes, but wouldn't it always be the same 100 songs, just ordered differently?
E.g. having a
tracks_playback_limitof 1 will always result in the same song.This would also be a great feature to have.
@FromWau commented on GitHub (Feb 27, 2024):
I am not a rust dev, but I can look into it.
@aome510 commented on GitHub (Feb 27, 2024):
Yeah, exactly =).
Great! Lmk if you have a PR up. It's always good to learn Rust IMO 😎
@diniamo commented on GitHub (Apr 16, 2024):
+1, it's very annoying that shuffle only plays songs from around the one I select manually