add-ons / plugin.video.vrt.nu

Kodi add-on to watch content from VRT MAX
https://www.facebook.com/groups/kodivlaanderen
GNU General Public License v3.0
110 stars 20 forks source link

Error when opening Koningin Elisabethwedstrijd #996

Closed maanwater closed 2 years ago

maanwater commented 2 years ago

Describe the bug

When trying to open "Koningin Elisabethwedstrijd" on VRT NU, an error is shown

To Reproduce

Steps to reproduce the behavior:

  1. Go to all programs
  2. Scroll down to "Koningin Elisabethwedstrijd" and click
  3. See error

Expected behavior

See the available content.

Additional context

Log (if available)


2022-05-31 20:45:03.691 T:23946 WARNING <general>: [plugin.video.vrt.nu] Access: plugin://plugin.video.vrt.nu/programs/koningin-elisabethwedstrijd
2022-05-31 20:45:03.696 T:23946 WARNING <general>: [plugin.video.vrt.nu] Got item from cache '/storage/.kodi/userdata/addon_data/plugin.video.vrt.nu/cache/favorites.json'
2022-05-31 20:45:03.698 T:23946 WARNING <general>: [plugin.video.vrt.nu] Cache '/storage/.kodi/userdata/addon_data/plugin.video.vrt.nu/cache/favorites.json' has not changed, updating mtime only.
2022-05-31 20:45:03.717 T:23946 WARNING <general>: [plugin.video.vrt.nu] Got item from cache '/storage/.kodi/userdata/addon_data/plugin.video.vrt.nu/cache/resume_points.json'
2022-05-31 20:45:03.719 T:23946 WARNING <general>: [plugin.video.vrt.nu] Got item from cache '/storage/.kodi/userdata/addon_data/plugin.video.vrt.nu/cache/watchlater.json'
2022-05-31 20:45:03.724 T:23946 WARNING <general>: [plugin.video.vrt.nu] Got item from cache '/storage/.kodi/userdata/addon_data/plugin.video.vrt.nu/tokens/vrtloginat.tkn'
2022-05-31 20:45:03.734 T:23946 WARNING <general>: [plugin.video.vrt.nu] URL get: https://www.vrt.be/vrtnu-api/rest/lists/vrtnu-watchLater?tileType=mixed-content&tileContentType=episode&tileOrientation=landscape&layout=slider&title=Later+kijken
2022-05-31 20:45:03.899 T:23946 WARNING <general>: [plugin.video.vrt.nu] Cache '/storage/.kodi/userdata/addon_data/plugin.video.vrt.nu/cache/watchlater.json' has not changed, updating mtime only.
2022-05-31 20:45:03.901 T:23946 WARNING <general>: [plugin.video.vrt.nu] Got item from cache '/storage/.kodi/userdata/addon_data/plugin.video.vrt.nu/cache/continue.json'
2022-05-31 20:45:03.903 T:23946 WARNING <general>: [plugin.video.vrt.nu] Cache '/storage/.kodi/userdata/addon_data/plugin.video.vrt.nu/cache/continue.json' has not changed, updating mtime only.
2022-05-31 20:45:03.912 T:23946 WARNING <general>: [plugin.video.vrt.nu] URL get: https://search7.vrt.be/search?i=video&size=300&available=true&orderBy=episodeId&order=desc&q=koningin elisabethwedstrijd
2022-05-31 20:45:04.212 T:23946 WARNING <general>: [plugin.video.vrt.nu] URL get: https://www.vrt.be/vrtnu/a-z/koningin-elisabethwedstrijd.model.json
2022-05-31 20:45:04.435 T:23946   ERROR <general>: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                                    - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                                   Error Type: <class 'IndexError'>
                                                   Error Contents: Cannot choose from an empty sequence
                                                   Traceback (most recent call last):
                                                     File "/storage/.kodi/addons/plugin.video.vrt.nu/resources/lib/addon_entry.py", line 14, in <module>
                                                       run(argv)
                                                     File "/storage/.kodi/addons/plugin.video.vrt.nu/resources/lib/addon.py", line 362, in run
                                                       plugin.run(argv)
                                                     File "/storage/.kodi/addons/script.module.routing/lib/routing.py", line 130, in run
                                                       self._dispatch(self.path)
                                                     File "/storage/.kodi/addons/script.module.routing/lib/routing.py", line 141, in _dispatch
                                                       view_func(**kwargs)
                                                     File "/storage/.kodi/addons/plugin.video.vrt.nu/resources/lib/addon.py", line 166, in programs
                                                       VRTPlayer().show_episodes_menu(program=program, season=season)
                                                     File "/storage/.kodi/addons/plugin.video.vrt.nu/resources/lib/vrtplayer.py", line 276, in show_episodes_menu
                                                       episode_items, sort, ascending, content = self._apihelper.list_episodes(program=program, season=season)
                                                     File "/storage/.kodi/addons/plugin.video.vrt.nu/resources/lib/apihelper.py", line 141, in list_episodes
                                                       return self.__map_seasons(program, seasons, episodes)
                                                     File "/storage/.kodi/addons/plugin.video.vrt.nu/resources/lib/apihelper.py", line 182, in __map_seasons
                                                       episode = random.choice(episodes)
                                                     File "/usr/lib/python3.8/random.py", line 290, in choice
                                                   IndexError: Cannot choose from an empty sequence
                                                   -->End of Python script error report<--

2022-05-31 20:45:05.785 T:23946    INFO <general>: Python interpreter stopped
2022-05-31 20:45:05.799 T:23948    INFO <general>: Skipped 1 duplicate messages..
2022-05-31 20:45:05.799 T:23948   ERROR <general>: GetDirectory - Error getting plugin://plugin.video.vrt.nu/programs/koningin-elisabethwedstrijd
2022-05-31 20:45:05.808 T:852     ERROR <general>: CGUIMediaWindow::GetDirectory(plugin://plugin.video.vrt.nu/programs/koningin-elisabethwedstrijd) failed
mediaminister commented 2 years ago

I fixed it. Please test: Kodi 18 Leia: plugin.video.vrt.nu-2.5.12-api-6a663b5.zip Kodi 19 Matrix: plugin.video.vrt.nu-2.5.12+matrix.1-api-6a663b5.zip

maanwater commented 2 years ago

Yes, I confirm that this fixes the issue. Thank you very much.