tunarr icon indicating copy to clipboard operation
tunarr copied to clipboard

Stream stops at the end of a episode

Open ItsNoted opened this issue 10 months ago • 12 comments

When a show episode ends the stream stops and buffers. Otherwise it plays just fine. If I reload the stream channel it works fine again until the end of the episode. Seems to do this for every show and channel I create. Using default settings for channels. Let me know is if there's anything you need.

ItsNoted avatar Jan 24 '25 03:01 ItsNoted

Can you enable the experimental ffmpeg pipeline and try with that?

Logs would also help - it's really hard to diagnose stream issues without them. Preferably debug level logs (can set this in tunarr) and ffmpeg logs (can also turn these on in tunarr)

chrisbenincasa avatar Jan 24 '25 12:01 chrisbenincasa

It would also be helpful to know which client you are using to watch the stream

chrisbenincasa avatar Jan 24 '25 12:01 chrisbenincasa

Ok, so I enabled the experimental ffmpeg pipeline, restarted the container and I am using Emby to pull the IPTV source. I watched on the emby firestick app and tried emby theater (which I never really use).

It's continuing to happen. It will stream the entire episode but then just pauses at the end like its not sure what to do next. It continues to work if I reload the stream though but that defeats the purpose.

I attahced the logs below.

tunarr-logs.txt

ItsNoted avatar Jan 24 '25 13:01 ItsNoted

I see the remnants of the error at the top of the log file but the file doesn't look complete. What is your media source? Jellyfin?

chrisbenincasa avatar Jan 24 '25 14:01 chrisbenincasa

What is your media source? Jellyfin?

Yes. I'll compare my settings to ErsatzTV because that seems to work seamlessly without stopping between episodes but I love the simplicity of Tunarr much more!

ItsNoted avatar Jan 24 '25 15:01 ItsNoted

After changing the bitrate to 2000 and buffer size to 4000, it seems to work. This is copying the settings from Ersatztv. The quality is still really great too. Interesting.

EDIT: I was wrong, Still doing it dang it

ItsNoted avatar Jan 24 '25 15:01 ItsNoted

Did you add Tunarr as an HDHR source or an M3U source in Emby?

chrisbenincasa avatar Jan 24 '25 17:01 chrisbenincasa

I think the complete logs might help as well; and the ffmpeg ones too, if possible.

chrisbenincasa avatar Jan 24 '25 17:01 chrisbenincasa

This was enabled by default. Should I disable it? I added the m3u link in emby though.

Image

ItsNoted avatar Jan 25 '25 13:01 ItsNoted

This is just for the mocked HDHR auto-discovery, it is not related to streaming

chrisbenincasa avatar Jan 26 '25 13:01 chrisbenincasa

Hey, sorry for the delay here. I think a natural next step here would be to try a different client, if possible. Something simple, like VLC or MPV on your computer, to see if the same thing happens (assuming you haven't done this yet). I have also tried with just software decoding/encoding in VLC (and other clients) and haven't yet been able to reproduce this issue

chrisbenincasa avatar Jan 30 '25 20:01 chrisbenincasa

Hey there- I've seen a few other reports of something similar with JF as the client. My assumption is that this probably works similarly to Emby in this area, still. I am not able to reproduce myself yet, but it seems to be related to JF transcoding and/or remuxing the stream (sometimes unnecessarily). I unfortunately cannot test in Emby because I don't have a premiere subscription, but the symptoms seem the same between it and JF>

chrisbenincasa avatar May 20 '25 11:05 chrisbenincasa

Some new developments here; this is likely an underlying issue in FFmpeg not properly handling discontinuities (transitions) in HLS streams. See: https://trac.ffmpeg.org/ticket/5419 and (JF specific): https://github.com/jellyfin/jellyfin-ffmpeg/issues/57

If you are still willing to try, I think hooking up Tunarr as an HDHR tuner to Emby/JF should work.

chrisbenincasa avatar May 29 '25 16:05 chrisbenincasa

Hello, I'm having this exact same issue using the m3u link with Jellyfin and Tunarr.

Episode plays, then when it's supposed to switch to filler it buffers instead endlessly. If I back out and play the channel again, either the filler or next episode begin playing just fine. @chrisbenincasa Nice to see your response on this, I will give the spoofed HDHR tuner fix a try.

Please let me know if there's any other info I can provide with regard to this issue.

EDIT: Just to provide an update, switching to the spoofed HDHR does fix the issue.

wodencafe avatar Jun 02 '25 21:06 wodencafe

Going to close this out since there is a known workaround for now and the bug seems to be upstream to Jellyfin (and really FFmpeg to some degree)

chrisbenincasa avatar Jul 21 '25 00:07 chrisbenincasa