Skip to content

Play movies instead of showing them as unavailable - #52

Open
driesenj wants to merge 1 commit into
add-ons:masterfrom
driesenj:fix/movies
Open

driesenj wants to merge 1 commit into
add-ons:masterfrom
driesenj:fix/movies

Conversation

@driesenj

Copy link
Copy Markdown

Selecting a movie shows "This program is not available in the catalogue." instead of playing it.

For movies, /tv/v2/programs/<uuid> returns type: MOVIE with an empty playlists list, so the add-on finds no seasons. The movie's own video is in nextVideo. For example, program b8e69a6f-6048-46ed-846b-d3e9a3ffe1b1 (A Home Built With Blood) has nextVideo d4bf5cc2-51cf-43a4-bc71-7e640866fd5b, and /tv/v1/videos/long-form/ returns that video with the same title.

With this change, _parse_program_data stores nextVideo as Program.video when a program has no seasons. show_program then lists it as a single playable item (mediatype movie, with poster) instead of showing the dialog. Programs with seasons are unchanged.

Tested on Kodi 21.3 (LibreELEC 12.2.1, ARM64):

  • Three movies now open as a playable item, and one played normally (SSAI stream).
  • Series still list their seasons and episodes.
  • pylint with the repo's .pylintrc rates the changed files 10/10.

🤖 Generated with Claude Code

Movies on Play have no playlists: the program's nextVideo is the movie
itself. Show it as a single playable item instead of the 'not available
in the catalogue' dialog.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@driesenj

Copy link
Copy Markdown
Author

The CI failure is unrelated to this change. pull_request_target checks out the base commit (8e29a03), not this branch, and the tests stop at login: Cognito answers Missing required parameter USERNAME, so ADDON_USERNAME seems to be empty for this run. Login still worked in the August and September runs, so the secret may have expired or been removed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant