Open JaCobbMedia opened 1 year ago
With local playback, a play
command (MediaSession
, PendingIntent
) gets an exemption to be able to start a service in the foreground when playback resumes. This is obviously not possible when this is initiated on the remote cast device and the Android system is not aware of this.
Thanks for reporting.
One of our users got same crash, but from a google quick search box (???), ControllerInfo
in logs - controller = ControllerInfo {pkg=com.google.android.googlequicksearchbox, uid=10232}
. Not really sure how you can control playback from search box, but case is pretty much the same as I described previously, user goes to background and presses play/pause on search box (???). Could this be the same issue as with Cast device @marcbaechinger ?
com.google.android.googlequicksearchbox
is Google Assistant that is part of the search app. This is a known bug on Android 12 (S) that doesn't have an exemption for commands sent over media session.
thank you for a quick answer @marcbaechinger . Can we expect fix with next release?
We can't fix that. It's a platform bug. We are working on a workaround to avoid the crash that will be part of the next release. With this the app won't crash but Assistant will still not be able to resume playback. We will update this issue when this lands on dev-v2
and when merged into the release branch.
Ohh, anyways thank you for the info!
Media3 Version
1.0.0-beta03
Devices that reproduce the issue
Devices that do not reproduce the issue
No response
Reproducible in the demo app?
Not tested
Reproduction steps
Managed to reproduce it on UAMP media3 branch
ForegroundServiceStartNotAllowedException
is thrownMight not happen instantly so repeat 6-8 steps few times with different wait times
Expected result
Should successfully start foreground service or at least not crash
Actual result
ForegroundServiceStartNotAllowedException
is thrownMedia
Any media in the UAMP app
Bug Report
adb bugreport
to dev.exoplayer@gmail.com after filing this issue.