-
Notifications
You must be signed in to change notification settings - Fork 378
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
java.lang.SecurityException - Session rejected the connection request. #423
Comments
This is the sort of exception that the controller also gets if the media session does not start properly (e.g. crash in Such errors in |
any solution for this? |
Thanks for asking, @iaarav We would need some more details from you. This was reported for 1.0.1. Can you repro this with the actual 1.2.0 version? If so can you please describe your repro steps and do a bug report just after this happens and then upload here? If you're unable to share bug reports or test content publicly, please send them to [email protected] using a subject in the format "Issue #423". Please also update this issue to indicate you’ve done this. |
@marcbaechinger I can reproduce with 1.2.0
|
Hey @PaulWoitaschek. We need more information to resolve this issue but there hasn't been an update in 14 weekdays. I'm marking the issue as stale and if there are no new updates in the next 7 days I will close it automatically. If you have more information that will help us get to the bottom of this, just add a comment! |
What kind of information are you missing? |
Sorry, the bot doesn't recognize the reply from someone else (who is not the issue poster) and was still in the "need more info" stage. Your last question today actually fixed that ;) |
Looking at the stack trace again, I wonder if this is an issue in you app where the |
i dont understand why it is crashing on some devices
i am dooing that because i want to load last queue when app launches, maybe you have another way of that? |
It's difficult to help you here. It's for instance unclear when this problem happens in the lifecycle of the app, the session or the controller. The dependency injection code for instance does hide a bit how the app is bootstrapped.
From the JavaDoc of If you call I think this can happen if there is a problem on the session side, that doesn't allow a controller to connect. Another reason can be that the controller is released before the session notified the connection back to the controller. I think I would search for another exception happening somewhere that makes the connection fail. A first step would be to search the logs for other problems, for instance on the session side. And catch the exception thrown by |
AndroidSessionCallback.kt return if (isThirdPartyController(context, controller) && !thirdPartyApiEnabled) { |
I am seeing this same issue. I get random
when I start the app. Then when I reopen the app, it works fine. The stack trace, like above is library code.
MediaLibrarySession.Builder.Build() is only called in the Service onCreate method, and the releasing in the onDestroy method, so there should never be a duplicate. Weirdly, if I reopen the app after the exception is thrown, sometimes the app runs fine and the exception is not thrown. |
In my case, it ended up being that this code works if inside onCreate of the Service.
but this code does not work intermittently
|
Similar crash happened. In my case I observe a media session updates with As this is happening inside the library, it's impossible to catch this other than
|
Media3 Version
Media3 1.0.1
Devices that reproduce the issue
Devices that do not reproduce the issue
No response
Reproducible in the demo app?
Not tested
Reproduction steps
https://github.com/PaulWoitaschek/Voice/blob/7.0.12/playback/src/main/kotlin/voice/playback/session/PlaybackService.kt
Expected result
It doesn't crash
Actual result
I'm seeing a ton of crashes with a stack trace that doesn't relate to application code. I assume, this is related to broken device implementations which I can not catch as they are in the library internal space.
Additionally with media3 I see a lot of user reports where people state that the playback doesn't start. I assume that this might be related to this issue.
Media
no media
Bug Report
adb bugreport
to [email protected] after filing this issue.The text was updated successfully, but these errors were encountered: