jellyfin / jellyfin-androidtv

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

Crush when 'Pass Direct Path for external player' is enabled and starting a video with VLC #2269

Closed miberecz closed 1 year ago

miberecz commented 1 year ago

Describe the bug

Since the update to v15 whenever I open a media file I get 'Ops something went wrong..." error. After some debugging I found out, if I turn off the Preferences -> Playback -> Pass Direct Path for external player the error goes away.

Logs


client: Jellyfin for Android TV client_version: 0.15.0-beta.1 client_repository: https://github.com/jellyfin/jellyfin-androidtv type: crash_report format: markdown

Logs

Stack Trace:

java.lang.RuntimeException: Unable to start activity ComponentInfo{org.jellyfin.androidtv/org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'java.util.List org.jellyfin.sdk.model.api.MediaSourceInfo.getMediaStreams()' on a null object reference
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2914)
    at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3049)
    at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
    at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
    at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1809)
    at android.os.Handler.dispatchMessage(Handler.java:106)
    at android.os.Looper.loop(Looper.java:193)
    at android.app.ActivityThread.main(ActivityThread.java:6680)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.util.List org.jellyfin.sdk.model.api.MediaSourceInfo.getMediaStreams()' on a null object reference
    at org.jellyfin.androidtv.data.compat.StreamInfo.getSubtitleProfiles(StreamInfo.java:301)
    at org.jellyfin.androidtv.data.compat.StreamInfo.getSubtitleProfiles(StreamInfo.java:291)
    at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.adaptExternalSubtitles(ExternalPlayerActivity.java:445)
    at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.startExternalActivity(ExternalPlayerActivity.java:418)
    at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.launchExternalPlayer(ExternalPlayerActivity.java:309)
    at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.onCreate(ExternalPlayerActivity.java:121)
    at android.app.Activity.performCreate(Activity.java:7144)
    at android.app.Activity.performCreate(Activity.java:7135)
    at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1271)
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2894)
    ... 11 more

Logcat:

--------- beginning of main
11-16 19:38:13.185 I/jellyfin-apiclient(18272): Response received from: http://192.168.0.108:8096/Sessions/Playing
11-16 19:38:13.535 D/ACRA    (18272): onActivityStopped class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
11-16 19:38:13.538 D/ACRA    (18272): onActivitySaveInstanceState class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
11-16 19:38:13.540 D/ACRA    (18272): onActivityStopped class org.jellyfin.androidtv.ui.browsing.MainActivity
11-16 19:38:13.555 D/ACRA    (18272): onActivitySaveInstanceState class org.jellyfin.androidtv.ui.browsing.MainActivity
11-16 19:38:13.676 I/org.jellyfin.sdk.api.sockets.OkHttpWebsocketSession(18272): Receiving (raw) message {"MessageType":"UserDataChanged","MessageId":"52ecad42cf8846e4828103b47935b052","Data":{"UserId":"25fc68de4aca429c9d32dc0f92026ffc","UserDataList":[{"PlaybackPositionTicks":0,"PlayCount":5,"IsFavorite":false,"LastPlayedDate":"2022-11-16T18:38:13.4705577Z","Played":false,"Key":"366972001001","ItemId":"5c7e697f10441fd46a6a336793620cd5"},{"UnplayedItemCount":10,"PlaybackPositionTicks":0,"PlayCount":0,"IsFavorite":false,"Played":false,"Key":"366972001","ItemId":"8aae5c80f6572f182fdbe3c46a983b3c"}]}}
11-16 19:38:13.996 W/System  (18272): A resource failed to call end. 
11-16 19:38:21.628 D/ExternalPlayerActivity(18272): Returned from player, result <0>, extra data <null>
11-16 19:38:21.629 I/jellyfin-apiclient(18272): ReportPlaybackStopped: Item 5c7e697f-1044-1fd4-6a6a-336793620cd5, Ticks: 0
11-16 19:38:21.629 D/jellyfin-apiclient(18272): Adding request to queue: http://192.168.0.108:8096/Sessions/Playing/Stopped
11-16 19:38:21.672 D/ACRA    (18272): onActivityStarted class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
11-16 19:38:21.673 I/ProcessLifecycleInitializer$create(18272): Process lifecycle started
11-16 19:38:21.674 D/SessionRepositoryImpl(18272): Restoring session
11-16 19:38:21.680 D/ACRA    (18272): onActivityResumed class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
11-16 19:38:21.682 D/BackgroundServiceFragment(18272): Restoring active backgrounds
11-16 19:38:21.682 D/BackgroundServiceFragment(18272): Restoring background drawable
11-16 19:38:21.805 I/jellyfin-apiclient(18272): Response received from: http://192.168.0.108:8096/Sessions/Playing/Stopped
11-16 19:38:22.349 I/org.jellyfin.sdk.api.sockets.OkHttpWebsocketSession(18272): Receiving (raw) message {"MessageType":"UserDataChanged","MessageId":"0308d62c47794345abed29c326f79b44","Data":{"UserId":"25fc68de4aca429c9d32dc0f92026ffc","UserDataList":[{"PlaybackPositionTicks":0,"PlayCount":5,"IsFavorite":false,"LastPlayedDate":"2022-11-16T18:38:13.4705577Z","Played":false,"Key":"366972001001","ItemId":"5c7e697f10441fd46a6a336793620cd5"},{"UnplayedItemCount":10,"PlaybackPositionTicks":0,"PlayCount":0,"IsFavorite":false,"Played":false,"Key":"366972001","ItemId":"8aae5c80f6572f182fdbe3c46a983b3c"}]}}
11-16 19:38:23.257 D/OpenGLRenderer(18272): endAllActiveAnimators on 0xd094e900 (RippleDrawable) with handle 0xcc618070
11-16 19:38:23.275 D/ACRA    (18272): onActivityPaused class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
11-16 19:38:23.293 D/ACRA    (18272): onActivityStarted class org.jellyfin.androidtv.ui.browsing.MainActivity
11-16 19:38:23.294 I/ViewTarget(18272): Glide treats LayoutParams.WRAP_CONTENT as a request for an image the size of this device's screen dimensions. If you want to load the original image and are ok with the corresponding memory cost and OOMs (depending on the input size), use override(Target.SIZE_ORIGINAL). Otherwise, use LayoutParams.MATCH_PARENT, set layout_width and layout_height to fixed dimension, or use .override() with fixed dimensions.
11-16 19:38:23.295 I/chatty  (18272): uid=10108(org.jellyfin.androidtv) identical 2 lines
11-16 19:38:23.295 I/ViewTarget(18272): Glide treats LayoutParams.WRAP_CONTENT as a request for an image the size of this device's screen dimensions. If you want to load the original image and are ok with the corresponding memory cost and OOMs (depending on the input size), use override(Target.SIZE_ORIGINAL). Otherwise, use LayoutParams.MATCH_PARENT, set layout_width and layout_height to fixed dimension, or use .override() with fixed dimensions.
11-16 19:38:23.297 D/ACRA    (18272): onActivityResumed class org.jellyfin.androidtv.ui.browsing.MainActivity
11-16 19:38:23.300 D/BackgroundServiceFragment(18272): Restoring active backgrounds
11-16 19:38:23.301 D/BackgroundServiceFragment(18272): Restoring background drawable
11-16 19:38:23.621 D/ACRA    (18272): onActivityStopped class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
11-16 19:38:23.622 D/ACRA    (18272): onActivityDestroyed class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
11-16 19:38:24.053 D/FullDetailsFragment(18272): current time 1668623904052 last playback event time 1668623901630 last refresh time 1668623890674
11-16 19:38:24.081 D/FullDetailsFragment(18272): Updating info after playback
11-16 19:38:24.082 D/jellyfin-apiclient(18272): Adding request to queue: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items/5c7e697f10441fd46a6a336793620cd5?format=json
11-16 19:38:24.167 I/jellyfin-apiclient(18272): Response received from: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items/5c7e697f10441fd46a6a336793620cd5?format=json
11-16 19:38:24.609 D/NavigationRepositoryImpl(18272): Navigating back
11-16 19:38:24.660 D/HomeRowsFragment(18272): Refresh item Foundation S1 E1
11-16 19:38:24.661 I/ItemRowAdapter(18272): Re-retrieving row of type NextUp
11-16 19:38:24.662 I/org.jellyfin.sdk.api.client.KtorClient(18272): GET http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items/5c7e697f-1044-1fd4-6a6a-336793620cd5
11-16 19:38:24.662 D/jellyfin-apiclient(18272): Adding request to queue: http://192.168.0.108:8096/Shows/NextUp?Fields=PrimaryImageAspectRatio%2COverview%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&Limit=50&ImageTypeLimit=1&format=json
11-16 19:38:24.663 I/HomeRowsFragment(18272): Updating audio queue in HomeFragment (onResume)
11-16 19:38:24.666 D/NavigationRepositoryImpl(18272): Navigating to Fragment(fragment=class org.jellyfin.androidtv.ui.home.HomeFragment (Kotlin reflection is not available), arguments=Bundle[{}])
11-16 19:38:24.936 I/jellyfin-apiclient(18272): Response received from: http://192.168.0.108:8096/Shows/NextUp?Fields=PrimaryImageAspectRatio%2COverview%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&Limit=50&ImageTypeLimit=1&format=json
11-16 19:38:25.127 D/MediaManager(18272): Removed event listener.  Total listeners: 1
11-16 19:38:25.174 I/lyfin.androidt(18272): Background concurrent copying GC freed 53068(2MB) AllocSpace objects, 10(496KB) LOS objects, 43% free, 15MB/27MB, paused 377us total 235.848ms
11-16 19:38:25.184 W/System  (18272): A resource failed to call end. 
11-16 19:38:25.644 I/lyfin.androidt(18272): NativeAlloc concurrent copying GC freed 11701(687KB) AllocSpace objects, 0(0B) LOS objects, 44% free, 15MB/27MB, paused 298us total 216.895ms
11-16 19:38:26.366 I/org.jellyfin.sdk.api.sockets.OkHttpWebsocketSession(18272): Sending (raw) message {"MessageType":"KeepAlive","Data":{}}
11-16 19:38:26.373 I/org.jellyfin.sdk.api.sockets.OkHttpWebsocketSession(18272): Receiving (raw) message {"MessageType":"KeepAlive","MessageId":"8327f2958e67446091ae9864905a7b1a"}
11-16 19:38:27.349 D/NavigationRepositoryImpl(18272): Navigating to Activity(activity=class org.jellyfin.androidtv.ui.preference.PreferencesActivity (Kotlin reflection is not available), extras=Bundle[{screen=org.jellyfin.androidtv.ui.preference.screen.UserPreferencesScreen, screen_args=Bundle[{}]}])
11-16 19:38:27.360 D/NavigationRepositoryImpl$navigate$action(18272): Navigating to nothing
11-16 19:38:27.363 D/ACRA    (18272): onActivityPaused class org.jellyfin.androidtv.ui.browsing.MainActivity
11-16 19:38:27.378 W/ActivityThread(18272): handleWindowVisibility: no activity for token android.os.BinderProxy@e88be5a
11-16 19:38:27.389 D/ACRA    (18272): onActivityCreated class org.jellyfin.androidtv.ui.preference.PreferencesActivity
11-16 19:38:27.390 I/AuthenticatedUserCallbacks(18272): Activity org.jellyfin.androidtv.ui.preference.PreferencesActivity is ignored
11-16 19:38:27.391 I/AppThemeCallbacks(18272): Applying theme: DARK
11-16 19:38:27.405 D/ACRA    (18272): onActivityStarted class org.jellyfin.androidtv.ui.preference.PreferencesActivity
11-16 19:38:27.430 D/ACRA    (18272): onActivityResumed class org.jellyfin.androidtv.ui.preference.PreferencesActivity
11-16 19:38:45.193 D/OpenGLRenderer(18272): endAllActiveAnimators on 0xcaf98e80 (RippleDrawable) with handle 0xcaeb5cb0
11-16 19:38:47.436 D/ACRA    (18272): onActivityPaused class org.jellyfin.androidtv.ui.preference.PreferencesActivity
11-16 19:38:47.467 D/ACRA    (18272): onActivityResumed class org.jellyfin.androidtv.ui.browsing.MainActivity
11-16 19:38:47.470 D/BackgroundServiceFragment(18272): Restoring active backgrounds
11-16 19:38:47.472 D/BackgroundServiceFragment(18272): Restoring background drawable
11-16 19:38:47.473 I/HomeRowsFragment(18272): Updating audio queue in HomeFragment (onResume)
11-16 19:38:47.491 D/ACRA    (18272): onActivityStopped class org.jellyfin.androidtv.ui.preference.PreferencesActivity
11-16 19:38:47.493 D/ACRA    (18272): onActivityDestroyed class org.jellyfin.androidtv.ui.preference.PreferencesActivity
11-16 19:38:49.073 I/lyfin.androidt(18272): NativeAlloc concurrent copying GC freed 38755(1941KB) AllocSpace objects, 2(104KB) LOS objects, 44% free, 15MB/27MB, paused 347us total 223.641ms
11-16 19:38:49.590 D/ItemLauncher(18272): Item selected: 0 - The Emperor’s Peace (Episode)
11-16 19:38:49.591 D/NavigationRepositoryImpl(18272): Navigating to Fragment(fragment=class org.jellyfin.androidtv.ui.itemdetail.FullDetailsFragment (Kotlin reflection is not available), arguments=Bundle[{ItemId=5c7e697f-1044-1fd4-6a6a-336793620cd5}])
11-16 19:38:49.630 D/jellyfin-apiclient(18272): Adding request to queue: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items/5c7e697f-1044-1fd4-6a6a-336793620cd5?format=json
11-16 19:38:49.639 D/MediaManager(18272): Added event listener.  Total listeners: 2
11-16 19:38:49.654 W/RecyclerView(18272): No adapter attached; skipping layout
11-16 19:38:49.750 I/jellyfin-apiclient(18272): Response received from: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items/5c7e697f-1044-1fd4-6a6a-336793620cd5?format=json
11-16 19:38:50.024 D/jellyfin-apiclient(18272): Adding request to queue: http://192.168.0.108:8096/Shows/469174e1deff99a69a660a437bd56aa1/Episodes?AdjacentTo=5c7e697f10441fd46a6a336793620cd5&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
11-16 19:38:50.042 D/FullDetailsFragment(18272): Item type: Episode
11-16 19:38:50.043 D/jellyfin-apiclient(18272): Adding request to queue: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items?ParentId=8aae5c80f6572f182fdbe3c46a983b3c&StartIndex=1&recursive=false&Fields=PrimaryImageAspectRatio%2COverview%2CItemCounts%2CDisplayPreferencesId%2CChildCount&Limit=20&IncludeItemTypes=Episode&format=json
11-16 19:38:50.162 I/ViewTarget(18272): Glide treats LayoutParams.WRAP_CONTENT as a request for an image the size of this device's screen dimensions. If you want to load the original image and are ok with the corresponding memory cost and OOMs (depending on the input size), use override(Target.SIZE_ORIGINAL). Otherwise, use LayoutParams.MATCH_PARENT, set layout_width and layout_height to fixed dimension, or use .override() with fixed dimensions.
11-16 19:38:50.163 I/ViewTarget(18272): Glide treats LayoutParams.WRAP_CONTENT as a request for an image the size of this device's screen dimensions. If you want to load the original image and are ok with the corresponding memory cost and OOMs (depending on the input size), use override(Target.SIZE_ORIGINAL). Otherwise, use LayoutParams.MATCH_PARENT, set layout_width and layout_height to fixed dimension, or use .override() with fixed dimensions.
11-16 19:38:50.184 I/jellyfin-apiclient(18272): Response received from: http://192.168.0.108:8096/Shows/469174e1deff99a69a660a437bd56aa1/Episodes?AdjacentTo=5c7e697f10441fd46a6a336793620cd5&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
11-16 19:38:50.187 I/jellyfin-apiclient(18272): Response received from: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items?ParentId=8aae5c80f6572f182fdbe3c46a983b3c&StartIndex=1&recursive=false&Fields=PrimaryImageAspectRatio%2COverview%2CItemCounts%2CDisplayPreferencesId%2CChildCount&Limit=20&IncludeItemTypes=Episode&format=json
11-16 19:38:50.193 D/ItemRowAdapterHelperKt(18272): Creating items from 0 existing and 9 new, adapter size is 0
11-16 19:38:50.399 D/FullDetailsFragment(18272): current time 1668623930398 last playback event time 1668623901630 last refresh time 1668623930041
11-16 19:38:50.927 D/jellyfin-apiclient(18272): Adding request to queue: http://192.168.0.108:8096/Shows/469174e1-deff-99a6-9a66-0a437bd56aa1/Episodes?Fields=MediaSources%2CMediaStreams%2CPath%2CChapters%2COverview%2CPrimaryImageAspectRatio%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&SeasonId=8aae5c80-f657-2f18-2fdb-e3c46a983b3c&IsMissing=false&IsVirtualUnaired=false&format=json
11-16 19:38:51.569 I/jellyfin-apiclient(18272): Response received from: http://192.168.0.108:8096/Shows/469174e1-deff-99a6-9a66-0a437bd56aa1/Episodes?Fields=MediaSources%2CMediaStreams%2CPath%2CChapters%2COverview%2CPrimaryImageAspectRatio%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&SeasonId=8aae5c80-f657-2f18-2fdb-e3c46a983b3c&IsMissing=false&IsVirtualUnaired=false&format=json
11-16 19:38:51.747 D/NavigationRepositoryImpl(18272): Navigating to Activity(activity=class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity (Kotlin reflection is not available), extras=Bundle[{Position=0}])
11-16 19:38:51.761 D/NavigationRepositoryImpl$navigate$action(18272): Navigating to nothing
11-16 19:38:51.762 D/ACRA    (18272): onActivityPaused class org.jellyfin.androidtv.ui.browsing.MainActivity
11-16 19:38:51.773 W/ActivityThread(18272): handleWindowVisibility: no activity for token android.os.BinderProxy@cee3903
11-16 19:38:51.779 D/ACRA    (18272): onActivityCreated class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
11-16 19:38:51.779 I/AppThemeCallbacks(18272): Applying theme: DARK
11-16 19:38:51.788 I/BackgroundService(18272): Adding BackgroundServiceFragment to activity
11-16 19:38:51.791 D/AndroidRuntime(18272): Shutting down VM
--------- beginning of crash
11-16 19:38:51.792 E/AndroidRuntime(18272): FATAL EXCEPTION: main
11-16 19:38:51.792 E/AndroidRuntime(18272): Process: org.jellyfin.androidtv, PID: 18272
11-16 19:38:51.792 E/AndroidRuntime(18272): java.lang.RuntimeException: Unable to start activity ComponentInfo{org.jellyfin.androidtv/org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'java.util.List org.jellyfin.sdk.model.api.MediaSourceInfo.getMediaStreams()' on a null object reference
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2914)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3049)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1809)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.os.Handler.dispatchMessage(Handler.java:106)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.os.Looper.loop(Looper.java:193)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.app.ActivityThread.main(ActivityThread.java:6680)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at java.lang.reflect.Method.invoke(Native Method)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
11-16 19:38:51.792 E/AndroidRuntime(18272): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.util.List org.jellyfin.sdk.model.api.MediaSourceInfo.getMediaStreams()' on a null object reference
11-16 19:38:51.792 E/AndroidRuntime(18272):     at org.jellyfin.androidtv.data.compat.StreamInfo.getSubtitleProfiles(StreamInfo.java:301)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at org.jellyfin.androidtv.data.compat.StreamInfo.getSubtitleProfiles(StreamInfo.java:291)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.adaptExternalSubtitles(ExternalPlayerActivity.java:445)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.startExternalActivity(ExternalPlayerActivity.java:418)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.launchExternalPlayer(ExternalPlayerActivity.java:309)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.onCreate(ExternalPlayerActivity.java:121)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.app.Activity.performCreate(Activity.java:7144)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.app.Activity.performCreate(Activity.java:7135)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1271)
11-16 19:38:51.792 E/AndroidRuntime(18272):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2894)
11-16 19:38:51.792 E/AndroidRuntime(18272):     ... 11 more
11-16 19:38:51.793 E/ACRA    (18272): ACRA caught a RuntimeException for org.jellyfin.androidtv
11-16 19:38:51.793 E/ACRA    (18272): java.lang.RuntimeException: Unable to start activity ComponentInfo{org.jellyfin.androidtv/org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'java.util.List org.jellyfin.sdk.model.api.MediaSourceInfo.getMediaStreams()' on a null object reference
11-16 19:38:51.793 E/ACRA    (18272):   at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2914)
11-16 19:38:51.793 E/ACRA    (18272):   at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3049)
11-16 19:38:51.793 E/ACRA    (18272):   at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
11-16 19:38:51.793 E/ACRA    (18272):   at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
11-16 19:38:51.793 E/ACRA    (18272):   at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
11-16 19:38:51.793 E/ACRA    (18272):   at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1809)
11-16 19:38:51.793 E/ACRA    (18272):   at android.os.Handler.dispatchMessage(Handler.java:106)
11-16 19:38:51.793 E/ACRA    (18272):   at android.os.Looper.loop(Looper.java:193)
11-16 19:38:51.793 E/ACRA    (18272):   at android.app.ActivityThread.main(ActivityThread.java:6680)
11-16 19:38:51.793 E/ACRA    (18272):   at java.lang.reflect.Method.invoke(Native Method)
11-16 19:38:51.793 E/ACRA    (18272):   at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
11-16 19:38:51.793 E/ACRA    (18272):   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
11-16 19:38:51.793 E/ACRA    (18272): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.util.List org.jellyfin.sdk.model.api.MediaSourceInfo.getMediaStreams()' on a null object reference
11-16 19:38:51.793 E/ACRA    (18272):   at org.jellyfin.androidtv.data.compat.StreamInfo.getSubtitleProfiles(StreamInfo.java:301)
11-16 19:38:51.793 E/ACRA    (18272):   at org.jellyfin.androidtv.data.compat.StreamInfo.getSubtitleProfiles(StreamInfo.java:291)
11-16 19:38:51.793 E/ACRA    (18272):   at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.adaptExternalSubtitles(ExternalPlayerActivity.java:445)
11-16 19:38:51.793 E/ACRA    (18272):   at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.startExternalActivity(ExternalPlayerActivity.java:418)
11-16 19:38:51.793 E/ACRA    (18272):   at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.launchExternalPlayer(ExternalPlayerActivity.java:309)
11-16 19:38:51.793 E/ACRA    (18272):   at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.onCreate(ExternalPlayerActivity.java:121)
11-16 19:38:51.793 E/ACRA    (18272):   at android.app.Activity.performCreate(Activity.java:7144)
11-16 19:38:51.793 E/ACRA    (18272):   at android.app.Activity.performCreate(Activity.java:7135)
11-16 19:38:51.793 E/ACRA    (18272):   at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1271)
11-16 19:38:51.793 E/ACRA    (18272):   at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2894)
11-16 19:38:51.793 E/ACRA    (18272):   ... 11 more
11-16 19:38:51.793 D/ACRA    (18272): Building report
11-16 19:38:51.795 D/ACRA    (18272): Starting collectors with priority FIRST
11-16 19:38:51.798 D/ACRA    (18272): Calling collector org.acra.collector.StacktraceCollector
11-16 19:38:51.799 D/ACRA    (18272): Calling collector org.acra.collector.DropBoxCollector
11-16 19:38:51.799 D/ACRA    (18272): Collector org.acra.collector.DropBoxCollector completed
11-16 19:38:51.799 D/ACRA    (18272): Calling collector org.acra.collector.LogCatCollector
11-16 19:38:51.799 D/ACRA    (18272): Collector org.acra.collector.StacktraceCollector completed
11-16 19:38:51.805 D/ACRA    (18272): Retrieving logcat output (buffer:default)...

App information

App version: 0.15.0-beta.1 (150001)
Package name: org.jellyfin.androidtv
Build:

{"BOARD":"oneday","BOOTLOADER":"unknown","BRAND":"Xiaomi","CPU_ABI":"armeabi-v7a","CPU_ABI2":"armeabi","DEVICE":"oneday","DISPLAY":"PI.3933 release-keys","FINGERPRINT":"Xiaomi\/oneday\/oneday:9\/PI\/3933:user\/release-keys","HARDWARE":"amlogic","HOST":"c5-mitv-bsp-build04.bj","ID":"PI","IS_DEBUGGABLE":false,"IS_EMULATOR":false,"MANUFACTURER":"Xiaomi","MODEL":"MIBOX4","PERMISSIONS_REVIEW_REQUIRED":false,"PRODUCT":"oneday","RADIO":"unknown","SUPPORTED_32_BIT_ABIS":["armeabi-v7a","armeabi"],"SUPPORTED_64_BIT_ABIS":[],"SUPPORTED_ABIS":["armeabi-v7a","armeabi"],"TAGS":"release-keys","TIME":1632823795000,"TYPE":"user","UNKNOWN":"unknown","USER":"jenkins","VERSION":{"ACTIVE_CODENAMES":[],"BASE_OS":"","CODENAME":"REL","FIRST_SDK_INT":28,"INCREMENTAL":"3933","PREVIEW_SDK_INT":0,"RELEASE":"9","RESOURCES_SDK_INT":28,"SDK":"28","SDK_INT":28,"SECURITY_PATCH":"2021-07-05"}}

Build config:

{"APPLICATION_ID":"org.jellyfin.androidtv","BUILD_TYPE":"release","DEBUG":false,"DEVELOPMENT":false,"VERSION_CODE":150001,"VERSION_NAME":"0.15.0-beta.1"}

Device information

Android version: 9
Device brand: Xiaomi
Device product: oneday
Device model: MIBOX4

Crash information

Start time: 2022-11-16T19:36:25.592+01:00
Crash time: 2022-11-16T19:38:51.875+01:00

Application version

0.15.0-beta.1

Where did you install the app from?

Google Play

Device information

Xiaomi Mi Box S

Android version

Android 9

Jellyfin server version

10.8.7

nielsvanvelzen commented 1 year ago

Thanks for the report. I made some changes that should fix this issue in the next beta. Let me know if it doesn't.

miberecz commented 1 year ago

Unfortunately the issue is still present in beta v3

Here is a crash report: `--- client: Jellyfin for Android TV client_version: 0.15.0-beta.3 client_repository: https://github.com/jellyfin/jellyfin-androidtv type: crash_report format: markdown

Logs

Stack Trace:

java.lang.RuntimeException: Unable to start activity ComponentInfo{org.jellyfin.androidtv/org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Integer org.jellyfin.sdk.model.api.MediaSourceInfo.getDefaultSubtitleStreamIndex()' on a null object reference
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2914)
    at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3049)
    at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
    at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
    at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1809)
    at android.os.Handler.dispatchMessage(Handler.java:106)
    at android.os.Looper.loop(Looper.java:193)
    at android.app.ActivityThread.main(ActivityThread.java:6680)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Integer org.jellyfin.sdk.model.api.MediaSourceInfo.getDefaultSubtitleStreamIndex()' on a null object reference
    at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.adaptExternalSubtitles(ExternalPlayerActivity.java:455)
    at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.startExternalActivity(ExternalPlayerActivity.java:418)
    at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.launchExternalPlayer(ExternalPlayerActivity.java:309)
    at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.onCreate(ExternalPlayerActivity.java:121)
    at android.app.Activity.performCreate(Activity.java:7144)
    at android.app.Activity.performCreate(Activity.java:7135)
    at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1271)
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2894)
    ... 11 more

Logcat:

--------- beginning of main
12-13 20:10:51.250 D/ACRA    (12591): onActivityPaused class org.jellyfin.androidtv.ui.browsing.MainActivity
12-13 20:10:51.269 W/ActivityThread(12591): handleWindowVisibility: no activity for token android.os.BinderProxy@193896a
12-13 20:10:51.278 D/ACRA    (12591): onActivityCreated class org.jellyfin.androidtv.ui.preference.PreferencesActivity
12-13 20:10:51.283 I/AuthenticatedUserCallbacks(12591): Activity org.jellyfin.androidtv.ui.preference.PreferencesActivity is ignored
12-13 20:10:51.300 D/ACRA    (12591): onActivityStarted class org.jellyfin.androidtv.ui.preference.PreferencesActivity
12-13 20:10:51.342 D/ACRA    (12591): onActivityResumed class org.jellyfin.androidtv.ui.preference.PreferencesActivity
12-13 20:11:53.978 W/InputEventReceiver(12591): Attempted to finish an input event but the input event receiver has already been disposed.
12-13 20:11:57.429 D/OpenGLRenderer(12591): endAllActiveAnimators on 0xc8575980 (RippleDrawable) with handle 0xd0fc4b30
12-13 20:11:58.473 D/ACRA    (12591): onActivityPaused class org.jellyfin.androidtv.ui.preference.PreferencesActivity
12-13 20:11:58.506 D/ACRA    (12591): onActivityResumed class org.jellyfin.androidtv.ui.browsing.MainActivity
12-13 20:11:58.510 D/BackgroundServiceFragment(12591): Restoring active backgrounds
12-13 20:11:58.511 D/BackgroundServiceFragment(12591): Restoring background drawable
12-13 20:11:58.515 I/HomeRowsFragment(12591): Updating audio queue in HomeFragment (onResume)
12-13 20:11:58.558 D/ACRA    (12591): onActivityStopped class org.jellyfin.androidtv.ui.preference.PreferencesActivity
12-13 20:11:58.562 D/ACRA    (12591): onActivityDestroyed class org.jellyfin.androidtv.ui.preference.PreferencesActivity
12-13 20:12:00.309 D/ItemLauncher(12591): Item selected: 1 - Sorozatok (CollectionFolder)
12-13 20:12:00.312 D/ItemLauncher(12591): **** Collection type: tvshows
12-13 20:12:00.327 D/NavigationRepositoryImpl(12591): Navigating to Fragment(fragment=class org.jellyfin.androidtv.ui.browsing.BrowseGridFragment (Kotlin reflection is not available), arguments=Bundle[{folder={"Name":"Sorozatok","ServerId":"bac587f75c5e4373a6f4a5076e8f63e1","Id":"ec15ab15-7fb4-eba9-76f8-2e99b85c778d","Etag":"0b65934c15e804229b12806a51377e3d","DateCreated":"2022-02-27T16:03:54+01:00","CanDelete":false,"CanDownload":false,"SupportsSync":false,"SortName":"sorozatok","ExternalUrls":[],"Path":"/config/data/root/default/Sorozatok","EnableMediaSourceDisplay":false,"Taglines":[],"Genres":[],"PlayAccess":"Full","RemoteTrailers":[],"ProviderIds":{},"IsFolder":true,"ParentId":"e9d5075a-555c-1cbc-394e-ec4cef295274","Type":"CollectionFolder","People":[],"Studios":[],"GenreItems":[],"LocalTrailerCount":0,"UserData":{"PlaybackPositionTicks":0,"PlayCount":0,"IsFavorite":false,"Played":false,"Key":"ec15ab15-7fb4-eba9-76f8-2e99b85c778d"},"ChildCount":8,"SpecialFeatureCount":0,"DisplayPreferencesId":"ec15ab157fb4eba976f82e99b85c778d","Tags":[],"PrimaryImageAspectRatio":1.7777777777777777,"CollectionType":"tvshows","ImageTags":{"Primary":"4388d11a9af5f3a3fbf8295cc972823a"},"BackdropImageTags":[],"ImageBlurHashes":{"Primary":{"4388d11a9af5f3a3fbf8295cc972823a":"WGB:T.agE0f*RjaKEibFWAR,kCj?4UWY%MR+xukVM_affmn%jbn+"}},"LocationType":"FileSystem","LockedFields":[],"LockData":false}}])
12-13 20:12:00.345 D/BrowseGridFragment(12591): numCardsScreen <0>
12-13 20:12:00.376 D/MediaManager(12591): Added event listener.  Total listeners: 2
12-13 20:12:00.379 D/BrowseGridFragment(12591): buildAdapter cardHeight <379> getCardWidthBy <252> chunks <25> type <Items>
12-13 20:12:00.382 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items?ParentId=ec15ab15-7fb4-eba9-76f8-2e99b85c778d&SortBy=SortName&recursive=true&Fields=PrimaryImageAspectRatio%2CChildCount%2CMediaSources%2CMediaStreams%2CDisplayPreferencesId&sortOrder=Ascending&Limit=25&IncludeItemTypes=Series&format=json
12-13 20:12:00.454 D/BrowseGridFragment(12591): row selected position -1
12-13 20:12:00.462 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items?ParentId=ec15ab15-7fb4-eba9-76f8-2e99b85c778d&SortBy=SortName&recursive=true&Fields=PrimaryImageAspectRatio%2CChildCount%2CMediaSources%2CMediaStreams%2CDisplayPreferencesId&sortOrder=Ascending&Limit=25&IncludeItemTypes=Series&format=json
12-13 20:12:00.473 D/ItemRowAdapterHelperKt(12591): Creating items from 0 existing and 17 new, adapter size is 0
12-13 20:12:00.504 D/BrowseGridFragment(12591): row selected position 0
12-13 20:12:01.332 I/lyfin.androidt(12591): NativeAlloc concurrent copying GC freed 91850(4MB) AllocSpace objects, 21(784KB) LOS objects, 27% free, 32MB/44MB, paused 251us total 460.237ms
12-13 20:12:01.345 W/System  (12591): A resource failed to call end. 
12-13 20:12:02.330 D/ItemLauncher(12591): Item selected: 0 - 1899 (Series)
12-13 20:12:02.334 D/NavigationRepositoryImpl(12591): Navigating to Fragment(fragment=class org.jellyfin.androidtv.ui.itemdetail.FullDetailsFragment (Kotlin reflection is not available), arguments=Bundle[{ItemId=ddc6096c-389d-194a-764b-94186f6edf8d}])
12-13 20:12:02.375 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items/ddc6096c-389d-194a-764b-94186f6edf8d?format=json
12-13 20:12:02.391 D/MediaManager(12591): Added event listener.  Total listeners: 3
12-13 20:12:02.410 W/RecyclerView(12591): No adapter attached; skipping layout
12-13 20:12:02.416 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items/ddc6096c-389d-194a-764b-94186f6edf8d?format=json
12-13 20:12:02.557 D/FullDetailsFragment(12591): Item type: Series
12-13 20:12:02.558 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Shows/NextUp?Fields=PrimaryImageAspectRatio%2CChildCount&SeriesId=ddc6096c389d194a764b94186f6edf8d&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
12-13 20:12:02.560 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Shows/ddc6096c389d194a764b94186f6edf8d/Seasons?Fields=PrimaryImageAspectRatio%2CDisplayPreferencesId%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
12-13 20:12:02.564 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Shows/Upcoming?Fields=PrimaryImageAspectRatio%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
12-13 20:12:02.571 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Items/ddc6096c389d194a764b94186f6edf8d/Similar?Fields=PrimaryImageAspectRatio%2CDisplayPreferencesId%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&Limit=20&format=json
12-13 20:12:02.642 I/ViewTarget(12591): Glide treats LayoutParams.WRAP_CONTENT as a request for an image the size of this device's screen dimensions. If you want to load the original image and are ok with the corresponding memory cost and OOMs (depending on the input size), use override(Target.SIZE_ORIGINAL). Otherwise, use LayoutParams.MATCH_PARENT, set layout_width and layout_height to fixed dimension, or use .override() with fixed dimensions.
12-13 20:12:02.643 I/ViewTarget(12591): Glide treats LayoutParams.WRAP_CONTENT as a request for an image the size of this device's screen dimensions. If you want to load the original image and are ok with the corresponding memory cost and OOMs (depending on the input size), use override(Target.SIZE_ORIGINAL). Otherwise, use LayoutParams.MATCH_PARENT, set layout_width and layout_height to fixed dimension, or use .override() with fixed dimensions.
12-13 20:12:02.655 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Shows/NextUp?Fields=PrimaryImageAspectRatio%2CChildCount&SeriesId=ddc6096c389d194a764b94186f6edf8d&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
12-13 20:12:02.659 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items?ParentId=1b76cddd-9f13-8e4b-dd5a-04bb5b694602&StartIndex=3&recursive=false&Fields=PrimaryImageAspectRatio%2COverview%2CItemCounts%2CDisplayPreferencesId%2CChildCount&format=json
12-13 20:12:02.660 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Shows/ddc6096c389d194a764b94186f6edf8d/Seasons?Fields=PrimaryImageAspectRatio%2CDisplayPreferencesId%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
12-13 20:12:02.663 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Shows/Upcoming?Fields=PrimaryImageAspectRatio%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
12-13 20:12:02.668 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Items/ddc6096c389d194a764b94186f6edf8d/Similar?Fields=PrimaryImageAspectRatio%2CDisplayPreferencesId%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&Limit=20&format=json
12-13 20:12:02.754 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items?ParentId=1b76cddd-9f13-8e4b-dd5a-04bb5b694602&StartIndex=3&recursive=false&Fields=PrimaryImageAspectRatio%2COverview%2CItemCounts%2CDisplayPreferencesId%2CChildCount&format=json
12-13 20:12:02.885 D/MediaManager(12591): Removed event listener.  Total listeners: 2
12-13 20:12:03.152 D/FullDetailsFragment(12591): current time 1670958723151 last playback event time 1670958640086 last refresh time 1670958722556
12-13 20:12:03.552 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Shows/NextUp?SeriesId=ddc6096c389d194a764b94186f6edf8d&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
12-13 20:12:03.575 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Shows/NextUp?SeriesId=ddc6096c389d194a764b94186f6edf8d&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
12-13 20:12:03.579 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Shows/ddc6096c-389d-194a-764b-94186f6edf8d/Episodes?Fields=MediaSources%2CMediaStreams%2CPath%2CChapters%2COverview%2CPrimaryImageAspectRatio%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&SeasonId=1b76cddd-9f13-8e4b-dd5a-04bb5b694602&IsMissing=false&IsVirtualUnaired=false&format=json
12-13 20:12:03.698 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Shows/ddc6096c-389d-194a-764b-94186f6edf8d/Episodes?Fields=MediaSources%2CMediaStreams%2CPath%2CChapters%2COverview%2CPrimaryImageAspectRatio%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&SeasonId=1b76cddd-9f13-8e4b-dd5a-04bb5b694602&IsMissing=false&IsVirtualUnaired=false&format=json
12-13 20:12:03.738 D/NavigationRepositoryImpl(12591): Navigating to Activity(activity=class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity (Kotlin reflection is not available), extras=Bundle[{Position=0}])
12-13 20:12:03.752 D/NavigationRepositoryImpl$navigate$action(12591): Navigating to nothing
12-13 20:12:03.755 D/ACRA    (12591): onActivityPaused class org.jellyfin.androidtv.ui.browsing.MainActivity
12-13 20:12:03.774 W/ActivityThread(12591): handleWindowVisibility: no activity for token android.os.BinderProxy@12c9995
12-13 20:12:03.779 D/ACRA    (12591): onActivityCreated class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
12-13 20:12:03.790 I/BackgroundService(12591): Adding BackgroundServiceFragment to activity
12-13 20:12:03.791 E/ExternalPlayerActivity(12591): Error playback path is null/empty.
12-13 20:12:03.815 D/ACRA    (12591): onActivityResumed class org.jellyfin.androidtv.ui.browsing.MainActivity
12-13 20:12:03.818 D/BackgroundServiceFragment(12591): Restoring active backgrounds
12-13 20:12:03.819 D/BackgroundServiceFragment(12591): Restoring background drawable
12-13 20:12:03.841 D/ACRA    (12591): onActivityDestroyed class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
12-13 20:12:04.573 D/FullDetailsFragment(12591): current time 1670958724572 last playback event time 1670958640086 last refresh time 1670958722556
12-13 20:12:05.911 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Shows/NextUp?SeriesId=ddc6096c389d194a764b94186f6edf8d&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
12-13 20:12:05.928 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Shows/NextUp?SeriesId=ddc6096c389d194a764b94186f6edf8d&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&format=json
12-13 20:12:05.934 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Shows/ddc6096c-389d-194a-764b-94186f6edf8d/Episodes?Fields=MediaSources%2CMediaStreams%2CPath%2CChapters%2COverview%2CPrimaryImageAspectRatio%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&SeasonId=1b76cddd-9f13-8e4b-dd5a-04bb5b694602&IsMissing=false&IsVirtualUnaired=false&format=json
12-13 20:12:06.041 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Shows/ddc6096c-389d-194a-764b-94186f6edf8d/Episodes?Fields=MediaSources%2CMediaStreams%2CPath%2CChapters%2COverview%2CPrimaryImageAspectRatio%2CChildCount&UserId=25fc68de-4aca-429c-9d32-dc0f92026ffc&SeasonId=1b76cddd-9f13-8e4b-dd5a-04bb5b694602&IsMissing=false&IsVirtualUnaired=false&format=json
12-13 20:12:06.079 D/NavigationRepositoryImpl(12591): Navigating to Activity(activity=class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity (Kotlin reflection is not available), extras=Bundle[{Position=0}])
12-13 20:12:06.093 D/NavigationRepositoryImpl$navigate$action(12591): Navigating to nothing
12-13 20:12:06.094 D/ACRA    (12591): onActivityPaused class org.jellyfin.androidtv.ui.browsing.MainActivity
12-13 20:12:06.112 W/ActivityThread(12591): handleWindowVisibility: no activity for token android.os.BinderProxy@7d5638a
12-13 20:12:06.119 D/ACRA    (12591): onActivityCreated class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
12-13 20:12:06.130 I/BackgroundService(12591): Adding BackgroundServiceFragment to activity
12-13 20:12:06.131 E/ExternalPlayerActivity(12591): Error playback path is null/empty.
12-13 20:12:06.164 D/ACRA    (12591): onActivityResumed class org.jellyfin.androidtv.ui.browsing.MainActivity
12-13 20:12:06.168 D/BackgroundServiceFragment(12591): Restoring active backgrounds
12-13 20:12:06.170 D/BackgroundServiceFragment(12591): Restoring background drawable
12-13 20:12:06.190 D/ACRA    (12591): onActivityDestroyed class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
12-13 20:12:06.923 D/FullDetailsFragment(12591): current time 1670958726922 last playback event time 1670958640086 last refresh time 1670958722556
12-13 20:12:07.557 D/jellyfin-apiclient(12591): Adding request to queue: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items?SortBy=SortName&recursive=true&IncludeItemTypes=Episode%2CMovie%2CVideo&IsMissing=false&IsVirtualUnaired=false&ParentId=ddc6096c-389d-194a-764b-94186f6edf8d&Fields=MediaSources%2CMediaStreams%2CChapters%2CPath%2COverview%2CPrimaryImageAspectRatio%2CChildCount&Limit=150&format=json
12-13 20:12:07.681 I/jellyfin-apiclient(12591): Response received from: http://192.168.0.108:8096/Users/25fc68de-4aca-429c-9d32-dc0f92026ffc/Items?SortBy=SortName&recursive=true&IncludeItemTypes=Episode%2CMovie%2CVideo&IsMissing=false&IsVirtualUnaired=false&ParentId=ddc6096c-389d-194a-764b-94186f6edf8d&Fields=MediaSources%2CMediaStreams%2CChapters%2CPath%2COverview%2CPrimaryImageAspectRatio%2CChildCount&Limit=150&format=json
12-13 20:12:07.726 D/NavigationRepositoryImpl(12591): Navigating to Activity(activity=class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity (Kotlin reflection is not available), extras=Bundle[{Position=0}])
12-13 20:12:07.739 D/NavigationRepositoryImpl$navigate$action(12591): Navigating to nothing
12-13 20:12:07.741 D/ACRA    (12591): onActivityPaused class org.jellyfin.androidtv.ui.browsing.MainActivity
12-13 20:12:07.760 W/ActivityThread(12591): handleWindowVisibility: no activity for token android.os.BinderProxy@cbb5e1f
12-13 20:12:07.765 D/ACRA    (12591): onActivityCreated class org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity
12-13 20:12:07.775 I/BackgroundService(12591): Adding BackgroundServiceFragment to activity
12-13 20:12:07.778 D/AndroidRuntime(12591): Shutting down VM
--------- beginning of crash
12-13 20:12:07.779 E/AndroidRuntime(12591): FATAL EXCEPTION: main
12-13 20:12:07.779 E/AndroidRuntime(12591): Process: org.jellyfin.androidtv, PID: 12591
12-13 20:12:07.779 E/AndroidRuntime(12591): java.lang.RuntimeException: Unable to start activity ComponentInfo{org.jellyfin.androidtv/org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Integer org.jellyfin.sdk.model.api.MediaSourceInfo.getDefaultSubtitleStreamIndex()' on a null object reference
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2914)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3049)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1809)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.os.Handler.dispatchMessage(Handler.java:106)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.os.Looper.loop(Looper.java:193)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.app.ActivityThread.main(ActivityThread.java:6680)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at java.lang.reflect.Method.invoke(Native Method)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
12-13 20:12:07.779 E/AndroidRuntime(12591): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Integer org.jellyfin.sdk.model.api.MediaSourceInfo.getDefaultSubtitleStreamIndex()' on a null object reference
12-13 20:12:07.779 E/AndroidRuntime(12591):     at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.adaptExternalSubtitles(ExternalPlayerActivity.java:455)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.startExternalActivity(ExternalPlayerActivity.java:418)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.launchExternalPlayer(ExternalPlayerActivity.java:309)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.onCreate(ExternalPlayerActivity.java:121)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.app.Activity.performCreate(Activity.java:7144)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.app.Activity.performCreate(Activity.java:7135)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1271)
12-13 20:12:07.779 E/AndroidRuntime(12591):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2894)
12-13 20:12:07.779 E/AndroidRuntime(12591):     ... 11 more
12-13 20:12:07.780 E/ACRA    (12591): ACRA caught a RuntimeException for org.jellyfin.androidtv
12-13 20:12:07.780 E/ACRA    (12591): java.lang.RuntimeException: Unable to start activity ComponentInfo{org.jellyfin.androidtv/org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Integer org.jellyfin.sdk.model.api.MediaSourceInfo.getDefaultSubtitleStreamIndex()' on a null object reference
12-13 20:12:07.780 E/ACRA    (12591):   at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2914)
12-13 20:12:07.780 E/ACRA    (12591):   at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3049)
12-13 20:12:07.780 E/ACRA    (12591):   at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
12-13 20:12:07.780 E/ACRA    (12591):   at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
12-13 20:12:07.780 E/ACRA    (12591):   at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
12-13 20:12:07.780 E/ACRA    (12591):   at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1809)
12-13 20:12:07.780 E/ACRA    (12591):   at android.os.Handler.dispatchMessage(Handler.java:106)
12-13 20:12:07.780 E/ACRA    (12591):   at android.os.Looper.loop(Looper.java:193)
12-13 20:12:07.780 E/ACRA    (12591):   at android.app.ActivityThread.main(ActivityThread.java:6680)
12-13 20:12:07.780 E/ACRA    (12591):   at java.lang.reflect.Method.invoke(Native Method)
12-13 20:12:07.780 E/ACRA    (12591):   at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
12-13 20:12:07.780 E/ACRA    (12591):   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
12-13 20:12:07.780 E/ACRA    (12591): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Integer org.jellyfin.sdk.model.api.MediaSourceInfo.getDefaultSubtitleStreamIndex()' on a null object reference
12-13 20:12:07.780 E/ACRA    (12591):   at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.adaptExternalSubtitles(ExternalPlayerActivity.java:455)
12-13 20:12:07.780 E/ACRA    (12591):   at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.startExternalActivity(ExternalPlayerActivity.java:418)
12-13 20:12:07.780 E/ACRA    (12591):   at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.launchExternalPlayer(ExternalPlayerActivity.java:309)
12-13 20:12:07.780 E/ACRA    (12591):   at org.jellyfin.androidtv.ui.playback.ExternalPlayerActivity.onCreate(ExternalPlayerActivity.java:121)
12-13 20:12:07.780 E/ACRA    (12591):   at android.app.Activity.performCreate(Activity.java:7144)
12-13 20:12:07.780 E/ACRA    (12591):   at android.app.Activity.performCreate(Activity.java:7135)
12-13 20:12:07.780 E/ACRA    (12591):   at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1271)
12-13 20:12:07.780 E/ACRA    (12591):   at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2894)
12-13 20:12:07.780 E/ACRA    (12591):   ... 11 more
12-13 20:12:07.780 D/ACRA    (12591): Building report
12-13 20:12:07.782 D/ACRA    (12591): Starting collectors with priority FIRST
12-13 20:12:07.783 D/ACRA    (12591): Calling collector org.acra.collector.DropBoxCollector
12-13 20:12:07.784 D/ACRA    (12591): Calling collector org.acra.collector.LogCatCollector
12-13 20:12:07.784 D/ACRA    (12591): Collector org.acra.collector.DropBoxCollector completed
12-13 20:12:07.784 D/ACRA    (12591): Calling collector org.acra.collector.StacktraceCollector
12-13 20:12:07.788 D/ACRA    (12591): Collector org.acra.collector.StacktraceCollector completed
12-13 20:12:07.792 D/ACRA    (12591): Retrieving logcat output (buffer:default)...

App information

App version: 0.15.0-beta.3 (150003)
Package name: org.jellyfin.androidtv
Build:

{"BOARD":"oneday","BOOTLOADER":"unknown","BRAND":"Xiaomi","CPU_ABI":"armeabi-v7a","CPU_ABI2":"armeabi","DEVICE":"oneday","DISPLAY":"PI.3933 release-keys","FINGERPRINT":"Xiaomi\/oneday\/oneday:9\/PI\/3933:user\/release-keys","HARDWARE":"amlogic","HOST":"c5-mitv-bsp-build04.bj","ID":"PI","IS_DEBUGGABLE":false,"IS_EMULATOR":false,"MANUFACTURER":"Xiaomi","MODEL":"MIBOX4","PERMISSIONS_REVIEW_REQUIRED":false,"PRODUCT":"oneday","RADIO":"unknown","SUPPORTED_32_BIT_ABIS":["armeabi-v7a","armeabi"],"SUPPORTED_64_BIT_ABIS":[],"SUPPORTED_ABIS":["armeabi-v7a","armeabi"],"TAGS":"release-keys","TIME":1632823795000,"TYPE":"user","UNKNOWN":"unknown","USER":"jenkins","VERSION":{"ACTIVE_CODENAMES":[],"BASE_OS":"","CODENAME":"REL","FIRST_SDK_INT":28,"INCREMENTAL":"3933","PREVIEW_SDK_INT":0,"RELEASE":"9","RESOURCES_SDK_INT":28,"SDK":"28","SDK_INT":28,"SECURITY_PATCH":"2021-07-05"}}

Build config:

{"APPLICATION_ID":"org.jellyfin.androidtv","BUILD_TYPE":"release","DEBUG":false,"DEVELOPMENT":false,"VERSION_CODE":150003,"VERSION_NAME":"0.15.0-beta.3"}

Device information

Android version: 9
Device brand: Xiaomi
Device product: oneday
Device model: MIBOX4

Crash information

Start time: 2022-12-10T21:57:54.144+01:00
Crash time: 2022-12-13T20:12:07.847+01:00

`

nielsvanvelzen commented 1 year ago

Thanks for the update. We've discussed this and apparently it was decided a while back that the direct path option is deprecated and will be removed at some point. That's why I've opted to remove the feature from the client as it's broken now anyway. Next beta should work again (behaves just like now with the option turned off).

miberecz commented 1 year ago

Okay, let me raise a concern about removing this option. In my usecase, I do have to download subtitles for my media( mostly done by Bazarr automagically). If the subtitle file name does not mach the movie file, VLC does not loads it automatically, so I have go into the shitty filebrowser of VLC to select it. Its hassel but works. For this to work, VLC has to know exactly where my movie files is on the storage. If the 'pass direct path' option is off, or not present, I just do not have an option to manually select subtitle file. The built in player and the libvlc one also cannot do this, thats the reason I use an external one (apart from the fact, that those are really slow with skipping forward or backward in a movie)

nielsvanvelzen commented 1 year ago

I'm sorry that this breaks your usecase. I'd advise to revisit your library structure so Jellyfin can correctly find the subtitle files. You can find our recommended structures in the documentation:

Most organizing software should be able to name all files correctly, it just might need some additional configuration. If you need help with that our community will be able to help on Matrix/Reddit/Discord/etc.

miberecz commented 1 year ago

Its not that Jellyfin does not find the subtitle files, but it just doesn't forwards it to external players. https://github.com/jellyfin/jellyfin-android/issues/587 https://www.reddit.com/r/jellyfin/comments/j68v5b/comment/g7x1bm3/ https://www.reddit.com/r/jellyfin/comments/s6h557/how_to_share_a_stream_url_with_subtitles/ Actually its a known issueof the Android VLC implementation https://code.videolan.org/videolan/vlc-android/-/issues/1903

Only way I could circumvent this is to manually load the sub-file, but for this, VLC need the exact network share address where my movie file is, not an http URL Not to mention, its wasted processing power to stream my media through the jellyfin server when I can stream them directly from my NAS

Please reconsider deprecating this feature.

nielsvanvelzen commented 1 year ago

So the problem isn't the deprecation of passing the direct path, it's the lack of external subtitle support in a specific video player app (VLC). At that point you should switch to another external player, embed your subtitles or just use the built-in player.

miberecz commented 1 year ago

Okay, these are valid recommendations. But still does not apply for my other point: why stream media through the Jellyfin server, when can be done directly from the NAS. Jellyfin only used as file-browser and episode tracker of some sort.

nielsvanvelzen commented 1 year ago

Jellyfin is a media server, not a media browser. It's supposed to always serve the media via Jellyfin itself.

raylapse commented 4 months ago

Jellyfin is a media server, not a media browser. It's supposed to always serve the media via Jellyfin itself.

You guys developed this so your words win. But, it's really really stupid to move this feature out! There are a lot people want to see native rip without any transcoding and the transcoding has too many problems not solved until today!