Problem with auto-refresh widget on new content
Closed this issue · 1 comments
Hello !
Since the last update ,I noticed a problem with the auto-refresh of the widgets (I use Embuary+Embycon).
Before that ,when I added a new content to my Emby server ,the movie/tv show appear in the "added recently" widget on my homepage in approximately 10 or 15 seconds but now I noticed than the widget never refresh automatically on new content. After waiting some minutes I decided to go to the movie HUB (or TVShow) and here ,the new content added are showed correctly but just because the widget are refresh when the HUBs are opened ,if I stay here and then I add a new content I got the same problem than on the homepage.
So the widgets are not refresh correctly on new content added but works correctly if I force the refresh when I opening a HUB.
So, I check the changelog and I see than the version 18.7.0 change something with the widget (tweaked refresh widget) so that confirm than the problem come from this version. Finally I go back to the version available on the kodi repo (18.6.25) and the problem are gone ,all works correctly and the widgets refresh automatically when new content are added.
So I disabled the auto-update for now but if you can take a look on this problem that would be awesome.
Thank you in advance :)
The tweaked mechanism only applies for real Kodi database items. EmbyCon isn't affected by this at all, because I always used "VideoLibary.onUpdate()" as trigger. Since EmbyCon is not syncing anything to the DB it has nothing to do with it.
And the only "tweaked" mechanism is, that I force widget containers to be visible if they were empty before (on a library update). And this one is set by the script.embuary.helper addon, not by the skin that you have downgraded. So it works for you again "by accident" because you have still the same helper addon installed.
EmbyCon stuff is handled similar, but the property to force Kodi to reload the widget container is set by the addon and not by me.
To be sure I just added a movie to Emby and it was shown after ~10s in the widget (Emby for Kodi addon)
Edit -> For a better understanding:
Kodi only refreshes non-library containers (widgets) if the path of the content has been changed. So skinners are using a workaround by adding an useless argument to the path.
<content>plugin://plugin.video.embycon/..........&reload=MYRELOADTRIGGER</content>
In the case of EmyCon it uses a property called "plugin.video.embycon-embycon_widget_reload".
<content>plugin://plugin.video.embycon/..........&reload=$INFO[Window(home).Property(plugin.video.embycon-embycon_widget_reload)]</content>
This trigger information has stored a timestamp for example, or a ongoing number.
So let's assume the container was loaded with this resolved paramenter:
<content>plugin://plugin.video.embycon/..........&reload=1234</content>
Kodi won't update this widget path until it's going to be changed by EmbyCon or after 10 minutes, which I force in Embuary with a service script.
Now you have added new movie to Emby and the EmbyCon service is noticing it by itself (not me) and changes to reload trigger to 1235 for example.
Now the container path is going to be changed automatically to:
<content>plugin://plugin.video.embycon/..........&reload=1235</content>
This makes Kodi think that it's a complete new widget path and forces it to refresh.
That's basically how it works and I hope that helps you to understand that it's not me that is causing your issue. It's something different :)