jellyfin / jellyfin-roku

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

Recordings that are in-process/not completed crash the app or can not be played #1692

Closed VTRunner closed 8 months ago

VTRunner commented 8 months ago

Software Versions

Describe the bug

If you have a recording that has been started, but hasn't completed, then it can not be played.

How To Reproduce

  1. Set a recording to start from Live TV.
  2. Wait for the recording to start (e.g. if you set a recording for an episode current being broadcast the recording will start immediately, or wait until the recording starts if the episode selected is in the future.)
  3. After the recording has started, from the "Home" screen use the left/right buttons on the Roku remote to select the target library for the recording. Click the "ok" button on the remote to open the library.
  4. When in the target library use the left/right buttons to select the Show for the in-process recording. Click the "ok" button to open
  5. In the Show screen select the Season for the in-process recording and click the "ok" button.
  6. In the Season screen use the up/down buttons to select the episode that is being recorded.
  7. Press the "ok" or "play" button.
  8. App crashes and returns to the Roku main screen.

Additionally, after the recording has started, if you navigate to the "Latest in ", where the graphic for the recording should be there is only a blue field with no Show information. Clicking "ok" or "play" on the episode in the "Latest" row results in the message "This type is not yet supported: Recording".

Expected behavior

  1. The app should not crash when attempting to play a recording that is in-process from the target library.
  2. The in-process recording should start playing when selected from the
  3. In the "Latest" row the Show graphics and descriptive text should be populated.
  4. The in-process recording should start playing when the "ok" or "play" button is pressed.

Logs

When populating home screen 02-06 21:49:48.417 [beacon.signal] |AppLaunchComplete ---------> Pending Render Pass 02-06 21:49:48.524 [beacon.signal] |AppLaunchComplete ---------> Duration(5694 ms) PostTask Started - Posting array to /Sessions/Capabilities/Full PostTask Finished. Response = 204 WARN //jellyfin-roku-203/components/home/HomeItem.bs(311) Unhandled Home Item Type Recording

When app crashes attempting to play a recording in process from the target library BrightScript Micro Debugger. Enter any BrightScript statement, debug commands, or HELP. Suspending threads... Thread selected: 1 ...Grid/LoadVideoContentTask.brs(88) video.chapters = meta.json.Chapters Current Function: 080: video.id = meta.json.ChannelId 081: else 082: video.id = meta.json.id 083: end if 084: end if 085: if videotype = "episode" or videotype = "series" 086: video.content.contenttype = "episode" 087: end if 088: video.chapters = meta.json.Chapters 089: video.content.title = meta.title 090: video.showID = meta.showID 091: user = AboutMe() 092: if user.Configuration.EnableNextEpisodeAutoPlay Source Digest(s): pkg: dev 2.0.3 3622f456 Jellyfin pkg: 632126 1.0.2 351fb56a libplayready 'Dot' Operator attempted with invalid BrightScript Component or interface reference. (runtime error &hec) in pkg:/components/ItemGrid/LoadVideoContentTask.brs(88) Backtrace:

2 Function loaditems_addvideocontent(video As Object, mediasourceid As Dynamic, audio_stream_idx As Integer, forcetranscoding As Boolean) As Void

file/line: pkg:/components/ItemGrid/LoadVideoContentTask.brs(88)

1 Function loaditems_videoplayer(id As String, mediasourceid As Dynamic, audio_stream_idx As Integer, forcetranscoding As Boolean) As Dynamic

file/line: pkg:/components/ItemGrid/LoadVideoContentTask.brs(55)

0 Function loaditems() As Void

file/line: pkg:/components/ItemGrid/LoadVideoContentTask.brs(47) Local Variables: video roAssociativeArray refcnt=2 count:2 mediasourceid Invalid audio_stream_idx Integer val:1 (&h1) forcetranscoding Boolean val:false global Interface:ifGlobal m roAssociativeArray refcnt=4 count:3 meta roAssociativeArray refcnt=1 count:71 subtitle_idx roInt refcnt=1 val:-2 (&hFF (ERR_OKAY) FFFFFE) videotype roString (2.1 was String) refcnt=1 val:"recording" user playbackposition currentitem defaultsubtitleindex fully_external trydirectplay transcodingreasons Threads: ID Location Source Code 0 pkg:/source/Main.brs(110) msg = wait(0, m.port) 1 pkg:/components/Clock.brs(28) m.dateTimeObject.Mark() 2 ...Grid/LoadVideoContentTask.brs(88) video.chapters = meta.json.Chapters selected

Screenshots

Jellyfin-Roku-Recording-Type-Not-Supported

Connection Information

Server is in the same lan subnet as the Roku device.

Additional context

1hitsong commented 8 months ago

Fixed by #1697