[GH-ISSUE #81] pause after last track has finished #71

Closed
opened 2026-02-27 19:28:40 +03:00 by kerem · 10 comments
Owner

Originally created by @sashahilton00 on GitHub (Jan 29, 2018).
Original GitHub issue: https://github.com/librespot-org/librespot/issues/81

Issue by herrernst
Saturday Aug 26, 2017 at 17:20 GMT
Originally opened as https://github.com/plietar/librespot/pull/239


Currently, librespot plays endlessly: After the last track in a playlist/album it continues playing the first one.

This changes the behaviour to match the official Spotify client: The first track is loaded again, but the player is paused.

See #237


herrernst included the following code: https://github.com/plietar/librespot/pull/239/commits

Originally created by @sashahilton00 on GitHub (Jan 29, 2018). Original GitHub issue: https://github.com/librespot-org/librespot/issues/81 <a href="https://github.com/herrernst"><img src="https://avatars2.githubusercontent.com/u/20795?v=4" align="left" width="96" height="96" hspace="10"></img></a> **Issue by [herrernst](https://github.com/herrernst)** _Saturday Aug 26, 2017 at 17:20 GMT_ _Originally opened as https://github.com/plietar/librespot/pull/239_ ---- Currently, librespot plays endlessly: After the last track in a playlist/album it continues playing the first one. This changes the behaviour to match the official Spotify client: The first track is loaded again, but the player is paused. See #237 ---- _**[herrernst](https://github.com/herrernst)** included the following code: https://github.com/plietar/librespot/pull/239/commits_
kerem 2026-02-27 19:28:40 +03:00
Author
Owner

@sashahilton00 commented on GitHub (Jan 29, 2018):

Comment by markubiak
Tuesday Sep 12, 2017 at 17:21 GMT


+1 would really like to see this. @herrernst any way you could include this PR in your raspberry pi builds?

<!-- gh-comment-id:361276168 --> @sashahilton00 commented on GitHub (Jan 29, 2018): <a href="https://github.com/markubiak"><img src="https://avatars0.githubusercontent.com/u/2127493?v=4" align="left" width="48" height="48" hspace="10"></img></a> **Comment by [markubiak](https://github.com/markubiak)** _Tuesday Sep 12, 2017 at 17:21 GMT_ ---- +1 would really like to see this. @herrernst any way you could include this PR in your raspberry pi builds?
Author
Owner

@sashahilton00 commented on GitHub (Jan 29, 2018):

Comment by awiouy
Wednesday Sep 20, 2017 at 20:22 GMT


What about adding this as a runtime option?

<!-- gh-comment-id:361276196 --> @sashahilton00 commented on GitHub (Jan 29, 2018): <a href="https://github.com/awiouy"><img src="https://avatars0.githubusercontent.com/u/9913019?v=4" align="left" width="48" height="48" hspace="10"></img></a> **Comment by [awiouy](https://github.com/awiouy)** _Wednesday Sep 20, 2017 at 20:22 GMT_ ---- What about adding this as a runtime option?
Author
Owner

@sashahilton00 commented on GitHub (Jan 29, 2018):

Comment by markubiak
Tuesday Sep 26, 2017 at 14:37 GMT


I don't think it should be included as a runtime option. This is a good stopgap measure until someone gets the repeat button working.

<!-- gh-comment-id:361276218 --> @sashahilton00 commented on GitHub (Jan 29, 2018): <a href="https://github.com/markubiak"><img src="https://avatars0.githubusercontent.com/u/2127493?v=4" align="left" width="48" height="48" hspace="10"></img></a> **Comment by [markubiak](https://github.com/markubiak)** _Tuesday Sep 26, 2017 at 14:37 GMT_ ---- I don't think it should be included as a runtime option. This is a good stopgap measure until someone gets the repeat button working.
Author
Owner

@sashahilton00 commented on GitHub (Jan 29, 2018):

Comment by herrernst
Tuesday Sep 26, 2017 at 18:16 GMT


I also think this shouldn't be an extra option, but the repeat mode should be toggled/controlled with the Spotify app as raised in #237

<!-- gh-comment-id:361276250 --> @sashahilton00 commented on GitHub (Jan 29, 2018): <a href="https://github.com/herrernst"><img src="https://avatars2.githubusercontent.com/u/20795?v=4" align="left" width="48" height="48" hspace="10"></img></a> **Comment by [herrernst](https://github.com/herrernst)** _Tuesday Sep 26, 2017 at 18:16 GMT_ ---- I also think this shouldn't be an extra option, but the repeat mode should be toggled/controlled with the Spotify app as raised in #237
Author
Owner

@sashahilton00 commented on GitHub (Jan 29, 2018):

Comment by markubiak
Tuesday Sep 26, 2017 at 18:43 GMT


I would agree that that is the best possible option. Unfortunately, I do not have any experience with rust and it doesn't seem to share a lot of similarities with languages I am familiar with. If you have the time and energy to implement that, it would be fantastic. It does seem that the repeat status is received in protocol/src/spirc.rs, and the original file (src/spirc.rs) could simply have the logic self.load_track(!was_last_track || is_repeating);

<!-- gh-comment-id:361276274 --> @sashahilton00 commented on GitHub (Jan 29, 2018): <a href="https://github.com/markubiak"><img src="https://avatars0.githubusercontent.com/u/2127493?v=4" align="left" width="48" height="48" hspace="10"></img></a> **Comment by [markubiak](https://github.com/markubiak)** _Tuesday Sep 26, 2017 at 18:43 GMT_ ---- I would agree that that is the best possible option. Unfortunately, I do not have any experience with rust and it doesn't seem to share a lot of similarities with languages I am familiar with. If you have the time and energy to implement that, it would be fantastic. It does seem that the repeat status is received in protocol/src/spirc.rs, and the original file (src/spirc.rs) could simply have the logic self.load_track(!was_last_track || is_repeating);
Author
Owner

@sashahilton00 commented on GitHub (Jan 29, 2018):

Comment by kingosticks
Monday Oct 30, 2017 at 09:42 GMT


So I had a go at integrating this with the connect side of things, my first stab at rust: https://github.com/plietar/librespot/compare/master...kingosticks:master

However, it's not quite there yet as it's missing the ability to repeat just one song which is available on the native client (you toggle repeat, repeat one, and off through the same control on the Android app). The repeat state is just a boolean so maybe there's a different bit of state to control repeat one (single?). Any ideas welcome.

I also wanted to do shuffle but doing the actual track shuffle is a bit more work.

<!-- gh-comment-id:361276291 --> @sashahilton00 commented on GitHub (Jan 29, 2018): <a href="https://github.com/kingosticks"><img src="https://avatars2.githubusercontent.com/u/934824?v=4" align="left" width="48" height="48" hspace="10"></img></a> **Comment by [kingosticks](https://github.com/kingosticks)** _Monday Oct 30, 2017 at 09:42 GMT_ ---- So I had a go at integrating this with the connect side of things, my first stab at rust: https://github.com/plietar/librespot/compare/master...kingosticks:master However, it's not quite there yet as it's missing the ability to repeat just one song which is available on the native client (you toggle repeat, repeat one, and off through the same control on the Android app). The repeat state is just a boolean so maybe there's a different bit of state to control repeat one (single?). Any ideas welcome. I also wanted to do shuffle but doing the actual track shuffle is a bit more work.
Author
Owner

@ComlOnline commented on GitHub (Jan 29, 2018):

I think this was fixed due to #2. I've just tested it and it stopped at the end of a playlist.

Could someone else confirm the same?

<!-- gh-comment-id:361333047 --> @ComlOnline commented on GitHub (Jan 29, 2018): I think this was fixed due to #2. I've just tested it and it stopped at the end of a playlist. Could someone else confirm the same?
Author
Owner

@sashahilton00 commented on GitHub (Jan 29, 2018):

This was fixed, however just looking over that PR, we need to open a new issue for Shuffle and Repeat functionality, which isn't fully implemented.

<!-- gh-comment-id:361335174 --> @sashahilton00 commented on GitHub (Jan 29, 2018): This was fixed, however just looking over that PR, we need to open a new issue for Shuffle and Repeat functionality, which isn't fully implemented.
Author
Owner

@ComlOnline commented on GitHub (Jan 29, 2018):

@sashahilton00 I think #19 covers this.

<!-- gh-comment-id:361336137 --> @ComlOnline commented on GitHub (Jan 29, 2018): @sashahilton00 I think #19 covers this.
Author
Owner

@sashahilton00 commented on GitHub (Jan 29, 2018):

@ComlOnline agreed.

<!-- gh-comment-id:361337947 --> @sashahilton00 commented on GitHub (Jan 29, 2018): @ComlOnline agreed.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/librespot#71
No description provided.