2024-01-03, 08:40 PM
(This post was last modified: 2024-01-07, 06:21 PM by ElCapitanTV. Edited 15 times in total.)
Hello,
My setup is Jellyfin running in Docker, also TVHeadend 4.3 in Docker and I have set up Jellyfin LiveTV to use M3U channels.
However attempting to play back live TV channels, result is only black screen and nothing happens, no audio or video.
There are two separate issues:
1) (Server issue) For TV live stream Docker internal address is used: Jellyfin Mediaplayer log
This IP accessed is incorrect since my Jellyfin is in dedicated Docker network and the issue can be "fixed" in source code SharedHttpStream by hardcoding actual host IP here in place of _appHost.GetApiUrlForLocalAccess() :
2) (Andoird client issue) After fixing issue 1) Jellyfin Mediaplayer works fine and correct IP and stream is played. However Android client + external MPV player still fails, in the adb logcat can be seen Accessing this URL just hangs and does not respond anything, even when accessed in browser. I would expect it to return error if it is about illegal state or call.
I strongly feel that this is a bug in Android client and the correct URL accessed should be http://192.168.1.1:8096/LiveTv/LiveStrea.../stream.ts like in Jellyfin Mediaplayer.
I was unable to figure out why Android client resolves to wrong URL instead of LiveStream.
For ExoPlayer I see in adb logs
and server side looks fine, I don't know what URL it is requesting. I'm a bit surprised how broken basic stuff is.
My setup is Jellyfin running in Docker, also TVHeadend 4.3 in Docker and I have set up Jellyfin LiveTV to use M3U channels.
However attempting to play back live TV channels, result is only black screen and nothing happens, no audio or video.
There are two separate issues:
1) (Server issue) For TV live stream Docker internal address is used: Jellyfin Mediaplayer log
Code:
ffmpeg: Opening http://172.18.0.7:8096/LiveTv/LiveStreamFiles/..id../stream.ts.
This IP accessed is incorrect since my Jellyfin is in dedicated Docker network and the issue can be "fixed" in source code SharedHttpStream by hardcoding actual host IP here in place of _appHost.GetApiUrlForLocalAccess() :
Code:
MediaSource.Path = _appHost.GetApiUrlForLocalAccess() + "/LiveTv/LiveStreamFiles/" + UniqueId + "/stream.ts";
2) (Andoird client issue) After fixing issue 1) Jellyfin Mediaplayer works fine and correct IP and stream is played. However Android client + external MPV player still fails, in the adb logcat can be seen
Code:
mpv : [ffmpeg:v] Opening http://192.168.1.1:8096/Videos/..id../stream?static=true&playSessionId=..id..&mediaSourceId=..id..&streamOptions=%7B%7D
I strongly feel that this is a bug in Android client and the correct URL accessed should be http://192.168.1.1:8096/LiveTv/LiveStrea.../stream.ts like in Jellyfin Mediaplayer.
I was unable to figure out why Android client resolves to wrong URL instead of LiveStream.
For ExoPlayer I see in adb logs
Code:
ExoPlayerImplInternal: Playback error
ExoPlayerImplInternal: com.google.android.exoplayer2.ExoPlaybackException: Source error
ExoPlayerImplInternal: at o5.o0.k(SourceFile:17)
ExoPlayerImplInternal: at o5.o0.handleMessage(SourceFile:382)
ExoPlayerImplInternal: at android.os.Handler.dispatchMessage(Handler.java:102)
ExoPlayerImplInternal: at android.os.Looper.loopOnce(Looper.java:226)
ExoPlayerImplInternal: at android.os.Looper.loop(Looper.java:313)
ExoPlayerImplInternal: at android.os.HandlerThread.run(HandlerThread.java:67)
ExoPlayerImplInternal: Caused by: com.google.android.exoplayer2.ParserException: Input does not start with the #EXTM3U header.{contentIsMalformed=true, dataType=4}
ExoPlayerImplInternal: at y6.n.f(SourceFile:259)
ExoPlayerImplInternal: at l7.i0.a(SourceFile:30)
ExoPlayerImplInternal: at l7.d0.run(SourceFile:41)
ExoPlayerImplInternal: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
ExoPlayerImplInternal: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:644)
ExoPlayerImplInternal: at java.lang.Thread.run(Thread.java:1012)
and server side looks fine, I don't know what URL it is requesting. I'm a bit surprised how broken basic stuff is.