Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Playing large playlists times out #36

Closed
jaedb opened this issue Jan 14, 2017 · 7 comments
Closed

Playing large playlists times out #36

jaedb opened this issue Jan 14, 2017 · 7 comments

Comments

@jaedb
Copy link
Owner

jaedb commented Jan 14, 2017

When playing a playlist uri (eg spotify:user:barnabyriggs:playlist:2rzRYYavfpTA8FqcNxRQQm) Mopidy-Spotify often throws a timeout error. Especially on slow connections or if no content is cached. This is triggered by the Play button in any playlist, and when it times out it creates the appearance of nothing happening.

Either:

  • Notify the user to try again
  • Revisit how we play large playlists. Previously we added each track, but this was a horrific resource killer and often jammed Mopidy server
@Mengesh
Copy link

Mengesh commented Jan 16, 2017

There's a workaround, but it doesn't work with mobile version, obviously.

  • Open Playlist
  • Left click first song
  • Shift + Left click last song
  • Press RET

The music starts immediately, but it takes a while to load a list in Now playing section.

@vojtapolasek
Copy link

I suspect this also happens when trying to play an artist radio or that special Spotify playlist "Discover new tracks", which always contains 30 tracks selected by Spotify.

@antons-
Copy link

antons- commented Feb 6, 2017

A workaround is increasing the Mopidy-Spotify timeout. Increasing it to 20 (default is 10) worked for the larger playlists we listen to. Your mileage may vary.

[spotify]
timeout = 20

@jaedb
Copy link
Owner Author

jaedb commented Feb 9, 2017

See #20

@jaedb
Copy link
Owner Author

jaedb commented Mar 15, 2017

Hasn't really been resolved. Need to address with a new approach...

Options:

  • Build server-side queue manager that only loads tracks as needed. This is the slickest option but will be a large piece of work as we'll essentially be building a custom tracklist engine.
  • Create faux-TlTrack objects from the tracks we've loaded client-side and plug these straight into tracklist. Not sure if this is technically viable.
  • Batch-load track URIs. This will still hog the server until completed, but not as bad as all tracks at once. Least preferable option.

@jaedb
Copy link
Owner Author

jaedb commented Mar 28, 2017

I've set it up to split the playlist tracks URIs and adding in batches of 20. This prevents a Failed to load URI(s) error as we don't rely on Mopidy-Spotify loading all tracks at once. However it renders Mopidy server unresponsive until all tracks have been loaded, which is a pretty ugly experience.

@jaedb
Copy link
Owner Author

jaedb commented Apr 6, 2017

Have introduced processes. These handle long-running processes like adding a lot of URIs to the queue. Now released in 2.13.9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants