Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kodi stuck on loading My list #359

Open
Bart80-1 opened this issue Jun 30, 2023 · 3 comments
Open

Kodi stuck on loading My list #359

Bart80-1 opened this issue Jun 30, 2023 · 3 comments

Comments

@Bart80-1
Copy link

Describe the bug
When opening My list, it happens (not consistently) that the items in My List don't appear on the screen, but the circle icon remains running for several minutes. The only way to get out of this is by pushing the "Back" button in Core remote (probably several times) and then after some time you go beck to the standard addon screen (showing menu items like "Files" etc.).
As mentioned, this happens inconsistently.
Also, I have seen the same behavior for other actions as well (such as opening the PVR video stream or other menu options, eg. "Magnum PI").

To Reproduce
Steps to reproduce the behavior:
1.Open any menu item, but for this case, take "My list"
2.There is a chance that the list items don't appear, but only the "moving circle" icon. The process seems stuck.

Expected behavior
A clear and concise description of what you expected to happen.
To see the menu items appear, after an acceptable delay.

Screenshots
If applicable, add screenshots to help explain your problem.

Logs
Add debug logs to help troubleshoot the issue. See https://kodi.wiki/view/Log_file/Easy for more info.
https://drive.google.com/file/d/1E5OG0hEWhZIYb3_WWh3O27VN8fieC2UH/view?usp=sharing

System

  • Addon version:1.4.1-matrix-1
  • Kodi version:20.1
  • Inputstream adaptive version:20.3.9.1
  • Operating System (Windows / Mac OS / Android / LibreElec / OSMC / ...):LibreElec 11.0.1
  • Special Hardware (RPI / Vero4K+ / ...):Raspberry Pi 4

Additional context
Add any other context about the problem here.

@Bart80-1
Copy link
Author

Bart80-1 commented Jul 1, 2023

Did some investigation. This part of the log seems interesting:

2023-06-30 19:02:36.630 T:928     debug <general>: [plugin.video.vtm.go] [resources.lib.vtmgo.util] Got response (status=200): {"abroad":false,"id":"e892cf10-5100-42ce-8d59-6b5c03cc2b96","type":"PROGRAM","name":"Aspe","description":"Herbert Flack in de rol van hoofdinspecteur Pieter Van In, die samen met zijn gedreven team misdaden in en rond Brugge oplost. Gebaseerd op de boeken van Pieter Aspe.","shortDescription":null,"backgroundImageUrl":"https://images2.persgroep.net/rcs/1IjWWB7OXQX-9xdOqDHkN8C5wFo/diocontent/165295349/_fitwidth/1400?appId=038a353bad43ac27fd436dc5419c256b&quality=0.8","landscapeTeaserImageUrl":"https://images4.persgroep.net/rcs/ign8dYebo_BhIQfHRQpI2dHmRo8/diocontent/220180551/_fitwidth/426?appId=038a353bad43ac27fd436dc5419c256b&quality=0.8","portraitTeaserImageUrl":"https://images1.persgroep.net/rcs/7q_na0jqAGfa2oAhjiyi7Wd4unw/diocontent/220180549/_fitwidth/320?appId=038a353bad43ac27fd436dc5419c256b&quality=0.8","availability":null,"durationSeconds":null,"channelLogoUrl":null,"broadcastTimestamp":null,"seasonIndices":[1,2,3,4,5,6,7,8,9,10],"blockedFor":null,"ratingIcons":["PG_16","PP"],"addedToMyList":true,"down
2023-06-30 19:02:36.643 T:928      info <general>: Skipped 2 duplicate messages..
2023-06-30 19:02:36.643 T:928   warning <general>: Setting most video properties through ListItem.setInfo() is deprecated and might be removed in future Kodi versions. Please use the respective setter in InfoTagVideo.
2023-06-30 19:02:36.645 T:928      info <general>: Skipped 8 duplicate messages..
2023-06-30 19:02:36.645 T:928     debug <general>: CPythonInvoker(14, /storage/.kodi/addons/plugin.video.vtm.go/addon_entry.py): script successfully run
2023-06-30 19:03:03.742 T:935      info <general>: PVR Manager: Starting cleanup of cached images.

Meaning: notification that the script run succesfully and then nothing happens anymore for 30 seconds, the parts after that don't seem relevant anymore. Also, "Aspe" is the last item to appear in the list I'm seeing on the screen so it makes sense that it is also the last one to appear in the log. It seems like Kodi is waiting for some kind of finalization before showing the list, but it doesn't come.

As I am interpreting the code (and keep in mind I'm new in it), codewise the following happens:

  • addon.py.Catalog.show_mylist, which just calls ...
  • catalog.py.show_mylist, which calls the API to retrieve the list (somewhere deep down there is also the code that causes the logging to record its GET and RESPONSE events). It deserializes the JSON responses into data structures, turns those into title item objects and adds them to a list, which is then passed to...
  • kodiutils.py.show_listing, which converts the passed list with title items into directory items doing some logic on the properties. Most important is the last line ("xbmcplugin.endOfDirectory") which should be the finalization for Kodi to show the list. As far as I see this code, it should be called unconditionally except in case of an exception - but then I would expect to see something in the logs, which is not the case.

So, to be honest, I'm kind of stuck here. Fact that it does not consistently happen also makes things difficult. Any ideas?

@michaelarnauts
Copy link
Collaborator

Your investigation is correct. You could try adding debugging statements to the code with _LOGGER.debug("something"), of even debug the result of the success variable that is returned by the endOfDirectory call. Use _LOGGER.debug(success) for that. Note that you need to match the indenting of the other lines.

But anyway, this more seems like a Kodi issue.

@Bart80-1
Copy link
Author

Bart80-1 commented Jul 6, 2023

Ok, thanks for your answer. I put some debug log statements in the code.
I was able to retrieve this log: https://drive.google.com/file/d/1_Alf9e9Sj81wYvt3vAmFU-bfWr_lkFv4/view?usp=sharing
Interesting line:
2023-07-05 21:26:36.311 T:938 debug <general>: [plugin.video.vtm.go] [resources.lib.kodiutils] kodiutils.py.show_listing 20 - addDirectoryItems call completed - Success False
So, the addDirectoryItems call returned "False".
Sadly, I see no error in the logging...
If the issue is in the xbmcplugin.addDirectoryItems it is probably more a Kodi than a VTM Go issue indeed, but still... any ideas?

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

No branches or pull requests

2 participants