mirror of
https://github.com/aome510/spotify-player.git
synced 2026-04-26 17:35:50 +03:00
[GH-ISSUE #123] feature request: notifications for tracks #54
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#54
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 @justchokingaround on GitHub (Feb 7, 2023).
Original GitHub issue: https://github.com/aome510/spotify-player/issues/123
The official Spotify client (on linux) sends notifications when a new track is played, or when you reach the end of a song, and the next one starts playing. It would be great if this could be added to
spotify-player👉 👈Here's an example of how it looks like with the official client:

@sewnie commented on GitHub (Feb 8, 2023):
this tbh
@aome510 commented on GitHub (Feb 17, 2023):
@justchokingaround @apprehensions implemented in https://github.com/aome510/spotify-player/pull/137.
You guys can test it out by running
cargo run --features notify.Also @apprehensions, I've implemented the first section in your #103
You can find the downloaded album covers in
$APP_CACHE_FOLDER/images.@justchokingaround commented on GitHub (Feb 17, 2023):
it works really well, except one minor detail. when you select a song to play and then select another one a few seconds after that, it will display 2 notifications, which is different from the behavior of the official client, where the first song notification gets replaced by the second one. hopefully this screenshot helps you understand:

@sewnie commented on GitHub (Feb 17, 2023):
that is because the notifications have completely seperate ids, if they had the same ids the notification daemon will automatically replace the previous if existing, i hope that can provide a solution
for example
@aome510 commented on GitHub (Feb 18, 2023):
Yeah, you're right. It's because
spotify-playercreates new notification on each track change event. In theory, it can reuse the previous notification with anupdatefunction. I'm not too sure if that'll work well. Will try and get back to you later.@aome510 commented on GitHub (Feb 18, 2023):
@justchokingaround, I did take a look. It's possible to implement updating functionality, but it is not trivial as it's only available in OSes with
xdg. In other words, the implementation will involve some flag setup to avoid compilation failing in other OSes (macos,windows). I would avoid doing that if possible.Hopefully, this is enough for now. I may go back to this in the future.