jellyfin / jellyfin-android

Android Client for Jellyfin
https://jellyfin.org
GNU General Public License v2.0
1.6k stars 257 forks source link

Media controls disappear when casting to Chromecast #1211

Closed eloykrikken closed 1 year ago

eloykrikken commented 1 year ago

Describe the bug

  1. Open app
  2. Click cast button and select a source to cast to
  3. Select media (movie or tv show)

The media controls on the bottom of the screen sometimes do not show up at all, and sometimes show up for a second and then dissapear again. I have not found a way to access them after they dissapear. Media when casting cannot be controlled and the only way to stop playback is to disconnect from the chromecast.

Logs

10-22 11:31:03.181 23168 23168 D VRI[MainActivity]: mPopUpViewOffsets: offset=(0.0, 0.0), scale=(1.0, 1.0) 10-22 11:31:03.187 23168 23187 W Parcel : Expecting binder but got null! 10-22 11:31:03.204 23168 23168 W MR2 : registerTransferCallback: Ignoring the same callback 10-22 11:31:03.204 23168 23168 W MR2 : registerControllerCallback: Ignoring the same callback 10-22 11:31:03.204 1620 5904 D MediaRouterService: Client org.jellyfin.mobile (pid 23168): Set discovery request, routeTypes=0x0, activeScan=false 10-22 11:31:03.204 1620 5904 D MediaRouterService: Client org.jellyfin.mobile (pid 23168): Set discovery request, routeTypes=0x800000, activeScan=true 10-22 11:31:03.205 26462 26462 W DiscoveryManager: BroadcastReceiver is already registered 10-22 11:31:03.205 26462 2952 I DiscoveryManager: Filter criteria(F007D354,CFE7FEDA,%urn:x-cast:com.google.cast.media) scannerFlags(2) 10-22 11:31:03.207 26462 26462 I CastMediaRouteProvider: Published 4 routes 10-22 11:31:03.208 26462 26462 D MR2ProviderService: notifySessionUpdated: Updating session id=RoutingSessionInfo{ sessionId=e73fbc1e-65b1-4e9c-96a6-f7fdb54f733e, name=Woonkamer, clientPackageName=com.netflix.mediaclient, selectedRoutes={46ff40661ada1b36a080b850ca71759e}, selectableRoutes={}, deselectableRoutes={}, transferableRoutes={}, volumeHandling=1, volumeMax=20, volume=19 } 10-22 11:31:03.208 26462 26462 D MR2ProviderService: notifySessionUpdated: Updating session id=RoutingSessionInfo{ sessionId=12511851-7b9e-407a-a75d-f0a71a6e8316, name=Woonkamer, clientPackageName=com.google.android.youtube, selectedRoutes={46ff40661ada1b36a080b850ca71759e}, selectableRoutes={}, deselectableRoutes={}, transferableRoutes={}, volumeHandling=1, volumeMax=20, volume=19 } 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: Failed to notify router of the session info change. Router probably died. 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: android.os.DeadObjectException 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at android.os.BinderProxy.transactNative(Native Method) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at android.os.BinderProxy.transact(BinderProxy.java:584) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at android.media.IMediaRouter2$Stub$Proxy.notifySessionInfoChanged(IMediaRouter2.java:297) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at com.android.server.media.MediaRouter2ServiceImpl$UserHandler.notifySessionInfoChangedToRouter(MediaRouter2ServiceImpl.java:1870) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at com.android.server.media.MediaRouter2ServiceImpl$UserHandler.onSessionInfoChangedOnHandler(MediaRouter2ServiceImpl.java:1776) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at com.android.server.media.MediaRouter2ServiceImpl$UserHandler.$r8$lambda$kJWtxriKWmzBPKaC6Yp_JVj4kP8(Unknown Source:0) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at com.android.server.media.MediaRouter2ServiceImpl$UserHandler$$ExternalSyntheticLambda9.accept(Unknown Source:6) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at com.android.internal.util.function.pooled.PooledLambdaImpl.doInvoke(PooledLambdaImpl.java:295) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at com.android.internal.util.function.pooled.PooledLambdaImpl.invoke(PooledLambdaImpl.java:204) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at com.android.internal.util.function.pooled.OmniFunction.run(OmniFunction.java:97) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at android.os.Handler.handleCallback(Handler.java:942) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at android.os.Handler.dispatchMessage(Handler.java:99) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at android.os.Looper.loopOnce(Looper.java:227) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at android.os.Looper.loop(Looper.java:327) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at com.android.server.SystemServer.run(SystemServer.java:998) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at com.android.server.SystemServer.main(SystemServer.java:683) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at java.lang.reflect.Method.invoke(Native Method) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:920) 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: onSessionInfoChangedOnHandler: No matching router found for session=RoutingSessionInfo{ sessionId=com.google.android.gms/.cast.media.CastMediaRoute2ProviderService_Persistent:e73fbc1e-65b1-4e9c-96a6-f7fdb54f733e, name=Woonkamer, clientPackageName=com.netflix.mediaclient, selectedRoutes={com.google.android.gms/.cast.media.CastMediaRoute2ProviderService_Persistent:46ff40661ada1b36a080b850ca71759e}, selectableRoutes={}, deselectableRoutes={}, transferableRoutes={}, volumeHandling=1, volumeMax=20, volume=19 } 10-22 11:31:03.211 1620 1620 W MR2ServiceImpl: onSessionInfoChangedOnHandler: No matching router found for session=RoutingSessionInfo{ sessionId=com.google.android.gms/.cast.media.CastMediaRoute2ProviderService_Persistent:12511851-7b9e-407a-a75d-f0a71a6e8316, name=Woonkamer, clientPackageName=com.google.android.youtube, selectedRoutes={com.google.android.gms/.cast.media.CastMediaRoute2ProviderService_Persistent:46ff40661ada1b36a080b850ca71759e}, selectableRoutes={}, deselectableRoutes={}, transferableRoutes={}, volumeHandling=1, volumeMax=20, volume=19 } 10-22 11:31:03.211 1620 1620 D MR2ProviderSvcProxy: Service connection com.google.android.gms/.cast.media.CastMediaRoute2ProviderService_Persistent: updated 10-22 11:31:03.212 26462 26462 D MediaRouter: Dispatching route change: UserRouteInfo{ name=Bedroom, description=Google Nest Mini, status=null, category=RouteCategory{ name=Devices types=ROUTE_TYPE_USER groupable=false }, supportedTypes=ROUTE_TYPE_USER , presentationDisplay=null } 10-22 11:31:03.214 26462 26462 D MediaRouter: Dispatching route change: UserRouteInfo{ name=Bedroom, description=Google Nest Mini, status=null, category=RouteCategory{ name=Devices types=ROUTE_TYPE_USER groupable=false }, supportedTypes=ROUTE_TYPE_USER , presentationDisplay=null } 10-22 11:31:03.214 26462 26462 D MediaRouter: Dispatching route change: UserRouteInfo{ name=Slaapkamer, description=Chromecast, status=null, category=RouteCategory{ name=Devices types=ROUTE_TYPE_USER groupable=false }, supportedTypes=ROUTE_TYPE_USER , presentationDisplay=null } 10-22 11:31:03.214 26462 26462 D MediaRouter: Dispatching route change: UserRouteInfo{ name=Slaapkamer, description=Chromecast, status=null, category=RouteCategory{ name=Devices types=ROUTE_TYPE_USER groupable=false }, supportedTypes=ROUTE_TYPE_USER , presentationDisplay=null } 10-22 11:31:03.216 27549 27549 I GoogleInputMethodService: GoogleInputMethodService.onFinishInput():3260 10-22 11:31:03.217 27549 27549 I GoogleInputMethodService: GoogleInputMethodService.updateDeviceLockedStatus():2103 repeatCheckTimes = 0, locked = false 10-22 11:31:03.217 27549 27549 I GoogleInputMethodService: GoogleInputMethodService.onStartInput():1894 onStartInput(EditorInfo{EditorInfo{packageName=org.jellyfin.mobile, inputType=0, inputTypeString=NULL, enableLearning=false, autoCorrection=false, autoComplete=false, imeOptions=0, privateImeOptions=null, actionName=UNSPECIFIED, actionLabel=null, initialSelStart=-1, initialSelEnd=-1, initialCapsMode=0, label=null, fieldId=-1, fieldName=null, extras=null, hintText=null, hintLocales=[]}}, false) 10-22 11:31:03.219 26462 26462 D MediaRouter: Dispatching route change: UserRouteInfo{ name=Woonkamer speaker, description=JBL Bar 5.0, status=null, category=RouteCategory{ name=Devices types=ROUTE_TYPE_USER groupable=false }, supportedTypes=ROUTE_TYPE_USER , presentationDisplay=null } 10-22 11:31:03.219 26462 26462 D MediaRouter: Dispatching route change: UserRouteInfo{ name=Woonkamer speaker, description=JBL Bar 5.0, status=null, category=RouteCategory{ name=Devices types=ROUTE_TYPE_USER groupable=false }, supportedTypes=ROUTE_TYPE_USER , presentationDisplay=null } 10-22 11:31:03.219 26462 26462 D MediaRouter: Dispatching route change: UserRouteInfo{ name=Woonkamer, description=Chromecast, status=null, category=RouteCategory{ name=Devices types=ROUTE_TYPE_USER groupable=false }, supportedTypes=ROUTE_TYPE_USER , presentationDisplay=null } 10-22 11:31:03.219 26462 26462 D MediaRouter: Dispatching route change: UserRouteInfo{ name=Woonkamer, description=Chromecast, status=null, category=RouteCategory{ name=Devices types=ROUTE_TYPE_USER groupable=false }, supportedTypes=ROUTE_TYPE_USER , presentationDisplay=null } 10-22 11:31:03.219 27549 27549 I GoogleInputMethodService: GoogleInputMethodService.updateDeviceLockedStatus():2103 repeatCheckTimes = 1, locked = false 10-22 11:31:03.224 8148 8245 V Avrcp_ext: updateCurrentMediaState: mMediaController: null 10-22 11:31:03.224 8148 8245 W Avrcp_ext: isMusicActive: false getBluetoothPlayState: 2 A2dp State: 11 mAudioPlaybackIsActive: false 10-22 11:31:03.224 8148 8245 W Avrcp_ext: updateCurrentMediaState: isPlaying = false 10-22 11:31:03.224 8148 8245 V Avrcp_ext: Media update: id -1➡-1? [MediaAttributes: none] : [MediaAttributes: none] 10-22 11:31:03.224 8148 8245 D Avrcp_ext: isPackageNameValid: browsedPackage = isValid = false 10-22 11:31:03.224 8148 8245 W Avrcp_ext: updateCurrentMediaState: isInactivePlayer = true 10-22 11:31:03.224 1620 5904 W PendingIntentHolder: Unresolvable implicit intent is set, pi=PendingIntent{9b8c311: PendingIntentRecord{61cba98 com.google.android.gms/com.google.android.gms.cast broadcastIntent}} 10-22 11:31:03.224 8148 8245 V Avrcp_ext: updatePlaybackState, state: PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658552258, actions=0, custom actions=[], active item id=-1, error=null} device: null 10-22 11:31:03.224 8148 8245 V Avrcp_ext: Device: no name: 10-22 11:31:03.224 8148 8245 V Avrcp_ext: Device: no name: 10-22 11:31:03.224 8148 8245 V Avrcp_ext: Device: no name: 10-22 11:31:03.224 8148 8245 V Avrcp_ext: Device: no name: 10-22 11:31:03.224 8148 8245 V Avrcp_ext: Device: no name: 10-22 11:31:03.224 8148 8245 V Avrcp_ext: updatePlayerStateAndPosition, old=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658538082, actions=0, custom actions=[], active item id=-1, error=null}, state=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658552258, actions=0, custom actions=[], active item id=-1, error=null} 10-22 11:31:03.225 8148 8245 V Avrcp_ext: old state = PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658538082, actions=0, custom actions=[], active item id=-1, error=null}, new state= PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658552258, actions=0, custom actions=[], active item id=-1, error=null} 10-22 11:31:03.225 8148 8245 D HeadsetService: getHeadsetService(): returning com.android.bluetooth.hfp.HeadsetService@ee0ba6e 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 D HeadsetService: isAudioOn: The number of audio connected devices 0 10-22 11:31:03.225 8148 8245 D HeadsetService: isScoOrCallActive(): Call Active:falseCall is Ringing:falseSCO is Active:false 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 D HeadsetService: isAudioOn: The number of audio connected devices 0 10-22 11:31:03.225 8148 8245 I Avrcp_ext: updatePlayStatusForDevice: device: null 10-22 11:31:03.225 8148 8245 V Avrcp_ext: updatePlaybackState (1): old=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658538082, actions=0, custom actions=[], active item id=-1, error=null}(2), new=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658552258, actions=0, custom actions=[], active item id=-1, error=null}(2) 10-22 11:31:03.225 8148 8245 I Avrcp_ext: Exit updatePlayStatusForDevice 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 D HeadsetService: isAudioOn: The number of audio connected devices 0 10-22 11:31:03.225 8148 8245 D HeadsetService: isScoOrCallActive(): Call Active:falseCall is Ringing:falseSCO is Active:false 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 D HeadsetService: isAudioOn: The number of audio connected devices 0 10-22 11:31:03.225 8148 8245 I Avrcp_ext: updatePlayStatusForDevice: device: null 10-22 11:31:03.225 8148 8245 V Avrcp_ext: updatePlaybackState (1): old=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658538082, actions=0, custom actions=[], active item id=-1, error=null}(2), new=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658552258, actions=0, custom actions=[], active item id=-1, error=null}(2) 10-22 11:31:03.225 8148 8245 I Avrcp_ext: Exit updatePlayStatusForDevice 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 D HeadsetService: isAudioOn: The number of audio connected devices 0 10-22 11:31:03.225 8148 8245 D HeadsetService: isScoOrCallActive(): Call Active:falseCall is Ringing:falseSCO is Active:false 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 D HeadsetService: isAudioOn: The number of audio connected devices 0 10-22 11:31:03.225 8148 8245 I Avrcp_ext: updatePlayStatusForDevice: device: null 10-22 11:31:03.225 8148 8245 V Avrcp_ext: updatePlaybackState (1): old=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658538082, actions=0, custom actions=[], active item id=-1, error=null}(2), new=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658552258, actions=0, custom actions=[], active item id=-1, error=null}(2) 10-22 11:31:03.225 8148 8245 I Avrcp_ext: Exit updatePlayStatusForDevice 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 26462 26703 I CastService: [instance-182] [com.google.android.gms] follow session disabled, with outputSwitcher: disabled 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 D HeadsetService: isAudioOn: The number of audio connected devices 0 10-22 11:31:03.225 8148 8245 D HeadsetService: isScoOrCallActive(): Call Active:falseCall is Ringing:falseSCO is Active:false 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.225 26462 26703 I CastService: [instance-182] [com.google.android.gms] acquireDeviceController: Google Play services client: 234014000 and APK: 234014000 10-22 11:31:03.225 8148 8245 D HeadsetService: isAudioOn: The number of audio connected devices 0 10-22 11:31:03.225 8148 8245 I Avrcp_ext: updatePlayStatusForDevice: device: null 10-22 11:31:03.225 8148 8245 V Avrcp_ext: updatePlaybackState (1): old=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658538082, actions=0, custom actions=[], active item id=-1, error=null}(2), new=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658552258, actions=0, custom actions=[], active item id=-1, error=null}(2) 10-22 11:31:03.226 8148 8245 I Avrcp_ext: Exit updatePlayStatusForDevice 10-22 11:31:03.226 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.226 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.226 8148 8245 D HeadsetService: isAudioOn: The number of audio connected devices 0 10-22 11:31:03.226 8148 8245 D HeadsetService: isScoOrCallActive(): Call Active:falseCall is Ringing:falseSCO is Active:false 10-22 11:31:03.226 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.226 8148 8245 E HeadsetStateMachine: returning mCurrentState as Disconnected 10-22 11:31:03.226 8148 8245 D HeadsetService: isAudioOn: The number of audio connected devices 0 10-22 11:31:03.226 8148 8245 I Avrcp_ext: updatePlayStatusForDevice: device: null 10-22 11:31:03.226 8148 8245 V Avrcp_ext: updatePlaybackState (1): old=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658538082, actions=0, custom actions=[], active item id=-1, error=null}(2), new=PlaybackState {state=2, position=-1, buffered position=0, speed=0.0, updated=658552258, actions=0, custom actions=[], active item id=-1, error=null}(2) 10-22 11:31:03.226 8148 8245 I Avrcp_ext: Exit updatePlayStatusForDevice 10-22 11:31:03.227 8148 8245 D Avrcp_ext: Enter sendPlayPosNotificationRsp 10-22 11:31:03.227 8148 8245 D Avrcp_ext: sendPlayPosNotificationRsp: Not registered or requesting.

Application version

2.5.3

Where did you install the app from?

Google Play

Device information

Nothing Phone 1, Samsung Galaxy A51

Android version

Android 13/Nothing OS 2.0.2

Jellyfin server version

10.8.11

Which video player implementations does this bug apply to?

Terrance commented 1 year ago

I was just about to report this myself, as I've had the same problem with that bottom control bar for a while now.

Some other observations:

BadDownload commented 1 year ago

FYI: This may be related to or a duplicate of bug #459.

Maxr1998 commented 1 year ago

It is. Thanks for the heads-up!