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

playlist.reload() dos not reload empty playlist #203

Closed
giflw opened this issue Dec 18, 2014 · 2 comments
Closed

playlist.reload() dos not reload empty playlist #203

giflw opened this issue Dec 18, 2014 · 2 comments

Comments

@giflw
Copy link

giflw commented Dec 18, 2014

When I create a playlist using a file (playlist.pls) and try to reload an empty playlist, liquidsoap keep playing old files instead of loading the empty playlist. The same applies to directory playlists (#196).

When I make a playlist empty I need that it plays blank until I reload it (if it is the only source) or be skeeped (if it is in a multiple sources configuration, like rotate).

Those are my expected results:

Single source (playlist should play blank when empty:

pls = playlist("playlist.pls")
out(pls)

Multiple sources (playlist should skipped when empty (or skip its turns)):

songs = playlist("songs.m3u")
jingles = playlist("jingles.pls")
s = rotate(weights=[1,3], [jingles, songs])
out(s)

In multiple sources configuration, if all playlist are empty, it should play blank.

@toots
Copy link
Member

toots commented May 13, 2015

So, a fallible playlist should accept empty playlists on reload. See #218 for that. If you need the source to play blank when receiving an empty playlist, you will need use mksafe().

@dbaelde
Copy link
Member

dbaelde commented Aug 25, 2015

Note that the playlist is fallible here so the proposed change won't be useful. The usual workaround, if one really wants an empty playlist is to make it non-empty but containing a broken URI, e.g., "/path/to/nowhere.ogg". I admit this is ugly and I am open to discussing a change of behavior, but I wonder if we have the time this deserves before a release.

@toots toots closed this as completed Jul 2, 2018
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

3 participants