jellyfin / jellyfin-roku

The Official Roku Client for Jellyfin
https://jellyfin.org
GNU General Public License v2.0
461 stars 146 forks source link

Crash when playing video: roAssociativeArray "Extend size exceeds max_wrap_allocation" #2015

Open jmacmahon opened 1 month ago

jmacmahon commented 1 month ago

Software Versions

Describe the bug

When playing a certain video file, the playback stops and the app reverts to the home screen. The logs from the Roku device show:

ERROR file:///home/<user>/jellyfin-roku/components/video/VideoPlayerView.bs:630 -3 An unexpected problem (but not server timeout or HTTP error) has been detected. buffer loop exception:Extend size (2136981 + 23310887) exceeds max_wrap_allocation (20553728):extra:etype:buffer -3
<Component: roAssociativeArray> =
{
    category: "mediaplayer"
    clipid: 2
    dbgmsg: "buffer loop exception:Extend size (2136981 + 23310887) exceeds max_wrap_allocation (20553728):extra:etype:buffer"
    drmerrcode: 0
    errcode: 0
    ignored: false
    source: "buffer:loop:"
}

The Jellyfin server logs show nothing interesting, just debug messages saying transcoding is ongoing, and then after the crash saying that it is stopping transcoding, and some authentication messages, presumably as the Roku app reloads the home screen.

This happens with a particular video file and not any others that I have tested. The file is being transcoded (video direct, audio encoded to AAC), and ffprobe has the following to say about the transcode files in the Jellyfin server cache:

Input #0, mpegts, from 'b58a0afaa38649756ff639660bc8587e150.ts':
  Duration: 00:00:04.90, start: 1157.103500, bitrate: 7329 kb/s
  Program 1
    Metadata:
      service_name    : Service01
      service_provider: FFmpeg
  Stream #0:0[0x100]: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p(tv, bt709, progressive), 1918x808, 24 fps, 24 tbr, 90k tbn
  Stream #0:1[0x101]: Audio: aac (LC) ([15][0][0][0] / 0x000F), 48000 Hz, 5.1, fltp, 642 kb/s

I will try to investigate further as to if there is anything special about these transcoded files that might cause a crash like this, but I would appreciate any pointers or other help.

Thanks

Thandden commented 5 days ago

Same issue is happening to me. Also doesn't effect every file. Only a few in my library. Can't seem to pinpoint the issue. Were you able to fix it @jmacmahon? Tried different Roku devices and the issue persists.

jmacmahon commented 5 days ago

I couldn't pin it down, sorry.