Add ability to start a radio based on the current track
the-lay opened this issue · 9 comments
sp radio
As stated in this post, there is currently no way to create a radio-playlist, using the Spotify Web API. However, it also states that you could do something similar by calling the "Get Recommendations"-endpoint with the currently selected song as input. You would need to aggregate the recommended songs in its own playlist, which is where I am currently at my wits' end. Do you have an idea on how to achieve that? I don't think creating a temporary playlist is a solution, since users can directly access spotify and modify stuff while using this plugin. What do you think?
@BeeJay28
This extensions uses spotipy library to communicate with WebAPI, and looking at the list of methods, spotipy has recommendations
method. My first intuition would be to call this method with the currently playing track in seed_tracks
parameter with limit set to N tracks, and then just queue all those N tracks to play next. This is not the best solution, but probably one that would be the quickest to implement. Please let me know if you have other ideas!
Oh right, I completely forgot that you can just add unrelated songs to playback-queue. I think that would be the best option. However, it should be labeled appropriately. Since people know what a song-radio is and this wouldn't be quite it. Something that reads "Add similar songs to playback queue".
Anyway, if it's okay with you, I would like to try my hands on that. I already took a small look into your code and I think I can handle adding it. I got exams next week until thursday, but after that I should be free for a bit. Considering how old this issue is, I don't think a couple more days make a difference ^^". I would add a PR and you can look over it and discuss improvements.
If you want to do it yourself, you obviously can, it's your code. Just gimme a heads up ^^
PRs are very welcome! I definitely won't have time to do this in the next few months, so please feel free to implement this! :)
Could you link the source from where you got the icons for the ulauncher command-preview from, so I can try finding an appropriate one myself?
You may undo it, I see why :)
I hoped there would be some icon related to the radio function or something like that. Otherwise I could just take some icon from the web. A simple radio, since I don't know what symbol would properly represent "get recommendations for this song".
Feel free to find something that fits, I would go with the aforementioned solution if you don't have anything better.
Yea, that's fine. I'll take it