-
Notifications
You must be signed in to change notification settings - Fork 460
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
The player hangs under certain circumstances #1571
Comments
As far as I remember, if there is a player error after the media item failed to load and is in buffering state for too long, you can capture the error inside onPlayerError(). I have handled this case manually based on my requirements. |
@debz-eight |
If mediaItem has failed to load, then is it giving source error. Can you share any links for the files you are trying to create media item with, so that I can try to replicate with same. I tried with m3u8 files from my side. I used controller.setMediaItems() and set a MutableList of 5 MediaItems. |
@debz-eight I have attached the media files to the issue so you can download them directly. |
Thanks for reporting! I could reproduce this issue from my end. I think your theory is right, the first item is shorter than the minimum buffer length for playback, but the buffer length will not increase as the second item fails to load, thus the Will work on a fix for this. |
It is possible for playback to be stuck when there is failure in loading further data, while the player is required to load more due to the buffered duration being under `DefaultLoadControl.bufferForPlayback`. Therefore, we check if there is any loading error in `isLoadingPossible`, so that the player will allow the playback of the existing data rather than waiting forever for the data that can never be loaded. Issue: #1571 #cherrypick PiperOrigin-RevId: 665801674
It is possible for playback to be stuck when there is failure in loading further data, while the player is required to load more due to the buffered duration being under `DefaultLoadControl.bufferForPlayback`. Therefore, we check if there is any loading error in `isLoadingPossible`, so that the player will allow the playback of the existing data rather than waiting forever for the data that can never be loaded. Issue: #1571 PiperOrigin-RevId: 665801674 (cherry picked from commit 351593a)
The fix is now in 1.4.1. |
Version
Media3 1.4.0
More version details
No response
Devices that reproduce the issue
Redmi k60 Android 14
Devices that do not reproduce the issue
No response
Reproducible in the demo app?
Not tested
Reproduction steps
Adds two mediaitem to exoplayer, one of which is less than the minimum buffer length and the other needs to fail to load.
In practice there are more mediaitem behind it, and for the sake of reproducing the problem, two is enough.
Expected result
play the first mediaitem, failed on the second
Actual result
playback hang in buffering state, not play anything
Media
[removed]
Bug Report
adb bugreport
to android-media-github@google.com after filing this issue.The text was updated successfully, but these errors were encountered: