GNOME Bugzilla – Bug 673888
Unable to resume playback after an error occurred during gapless playback.
Last modified: 2012-06-17 09:21:47 UTC
Created attachment 211811 [details] Full log, sample python script, and media files to reproduce the problem. I'm using playbin2 and about-to-finish signal to implement gapless playback. It works well with valid sound files. However after it encounters invalid media file it's impossible to resume playback with playbin2. I'm trying to set state to NULL, set URL to a valid media file, and then set state to PLAYING, but it doesn't work and I'm getting an assert message in the log (full log is attached): CRITICAL **: deactivate_group: assertion `group->active' failed I have attached a python script and test media files to reproduce the issue.
This looks very suspiciously like something that was fixed in january: commit c433ef9b701f48bae2d0268323d4f69972b91c7f Author: Vincent Penquerc'h <vincent.penquerch@collabora.co.uk> Date: Wed Jan 18 14:58:08 2012 +0000 playbin2: do not try to deactivate an inactive group A group may have failed to activate due to an error (for instance, having set the URI to a non existent location in about-to-finish). https://bugzilla.gnome.org/show_bug.cgi?id=666395 Can you try with either this commit in, or with latest -base release and see if this still happens ?
Missed the test case. I'm not getting the assert with git -base, but playbin2 still fails to chain to the next valid stream, so setting back to NEW for debuging.
Created attachment 215974 [details] [review] playbin2: remove uridecodebin from bin when it fails to switch to PAUSED This avoids that bin being leftover and being found when reusing playbin2, and fixes restarting on a new URI after failing to activate with a previous URI.
The test case now goes on with the new URI (albeit not gaplessly, as the intervening invalid URI prevents this). commit 9f2e829bf5b373fe7cee21c7bc2e2262dc2c285b Author: Vincent Penquerc'h <vincent.penquerch@collabora.co.uk> Date: Fri Jun 8 17:28:28 2012 +0100 playbin2: remove uridecodebin from bin when it fails to switch to PAUSED This avoids that bin being leftover and being found when reusing playbin2, and fixes restarting on a new URI after failing to activate with a previous URI. https://bugzilla.gnome.org/show_bug.cgi?id=673888
Created attachment 216244 [details] 1 second long audio file Pipeline doesn't switch into PLAYING state and doesn't play the valid file if it is too short.
Created attachment 216245 [details] Python script to reproduce the problem with short file.
(In reply to comment #4) > The test case now goes on with the new URI (albeit not gaplessly, as the > intervening invalid URI prevents this). > > commit 9f2e829bf5b373fe7cee21c7bc2e2262dc2c285b > Author: Vincent Penquerc'h <vincent.penquerch@collabora.co.uk> > Date: Fri Jun 8 17:28:28 2012 +0100 > > playbin2: remove uridecodebin from bin when it fails to switch to PAUSED > > This avoids that bin being leftover and being found when reusing playbin2, > and fixes restarting on a new URI after failing to activate with a previous > URI. > > https://bugzilla.gnome.org/show_bug.cgi?id=673888 Thank you very much for fixing this bug. I have noticed another related issue and not sure if I need to file separate bug for it. With the same test script if I use short 1 second long sound file, about-to-finish signal is emitted before playbin switches into PLAYING state and starts playback. After an error is reported for the invalid file, playbin never switches to PLAYING state to start playback of the valid file. I have attached updated script with sample media files. Could you please have a look?
I have also submitted another bug which might be related: "Unable to tell when playback stops after an error occurred during gapless playback" https://bugzilla.gnome.org/show_bug.cgi?id=677991
*** Bug 670321 has been marked as a duplicate of this bug. ***