Kodi Community Forum

Full Version: Light IMDb Ratings Update 5.1.3
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi guys,

After more than one month, I'm pleased to announce that the new version of Light IMDb Ratings Update is finally available! I'm sorry for the long wait, but I hope you will enjoy the new release as much as I enjoyed to develop it...well, honestly I had some (big) issues, but it seems that I've reached the target!

Hereafter the changelog of version 2.0.0 (main features are in bold):
  • Added support for Ubuntu, Debian, LibreELEC and Android
  • Added automatic PHP installation
  • Revised Top 250 update for Movies
  • Revised scheduled update information save
  • Added option to disable scheduled update
  • Fixed deprecated constructor in PHP 7.0.x
Before the installation, please just take a look to the first post of this thread for further information about the new release.

I would like to thank voyagertm and Mario S. for their precious help and support during the testing phase. Thanks guys!

I'm looking forward for your feedbacks.

Ciao!
It was no problem to help you with testing Smile

I am gonna put this final release on my box now!
Hello axlt2002,

Thank you for your work on this addon. I installed it today and started using it. I have a large movie collection (4700+) and I was running the update manually, just for movies. The update did not complete, and I see the following in the kodi log:

10:31:44.514 T:4256 ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <type 'exceptions.ValueError'>
Error Contents: No JSON object could be decoded
Traceback (most recent call last):
File "C:\Users\Bart\AppData\Roaming\Kodi\addons\service.light.imdb.ratings.update/resources/library/update.py", line 228, in <module>
perform_update()
File "C:\Users\Bart\AppData\Roaming\Kodi\addons\service.light.imdb.ratings.update/resources/library/update.py", line 222, in perform_update
if onMovies == "true": Movies()
File "C:\Users\Bart\AppData\Roaming\Kodi\addons\service.light.imdb.ratings.update/resources/library/update.py", line 22, in __init__
self.doUpdate()
File "C:\Users\Bart\AppData\Roaming\Kodi\addons\service.light.imdb.ratings.update/resources/library/update.py", line 63, in doUpdate
jSonData = jSon.loads( jSonData )
File "C:\Program Files (x86)\Kodi\system\python\Lib\json\__init__.py", line 339, in loads
return _default_decoder.decode(s)
File "C:\Program Files (x86)\Kodi\system\python\Lib\json\decoder.py", line 364, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "C:\Program Files (x86)\Kodi\system\python\Lib\json\decoder.py", line 382, in raw_decode
raise ValueError("No JSON object could be decoded")
ValueError: No JSON object could be decoded
-->End of Python script error report<--

Is there an issue with movies with accented characters in them? The update stopped in a folder where I have all 8 parts of Goddard's Histoir(es) du cinéma. The IMDb ID is correct in all of the NFOs. Please let me know. Thanks.

Regards,

Bart

EDIT: I figured it out, there was an extraneous character in the IMDB ID for the movie where it stopped. I fixed the NFO, refreshed the movie and the update continued past it. It is still running, I will post if I run into any other problems.
Thanks! Great stuff!
(2017-07-31, 16:37)bsoriano Wrote: [ -> ]Hello axlt2002,

Thank you for your work on this addon. I installed it today and started using it. I have a large movie collection (4700+) and I was running the update manually, just for movies. The update did not complete, and I see the following in the kodi log:

10:31:44.514 T:4256 ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <type 'exceptions.ValueError'>
Error Contents: No JSON object could be decoded
Traceback (most recent call last):
File "C:\Users\Bart\AppData\Roaming\Kodi\addons\service.light.imdb.ratings.update/resources/library/update.py", line 228, in <module>
perform_update()
File "C:\Users\Bart\AppData\Roaming\Kodi\addons\service.light.imdb.ratings.update/resources/library/update.py", line 222, in perform_update
if onMovies == "true": Movies()
File "C:\Users\Bart\AppData\Roaming\Kodi\addons\service.light.imdb.ratings.update/resources/library/update.py", line 22, in __init__
self.doUpdate()
File "C:\Users\Bart\AppData\Roaming\Kodi\addons\service.light.imdb.ratings.update/resources/library/update.py", line 63, in doUpdate
jSonData = jSon.loads( jSonData )
File "C:\Program Files (x86)\Kodi\system\python\Lib\json\__init__.py", line 339, in loads
return _default_decoder.decode(s)
File "C:\Program Files (x86)\Kodi\system\python\Lib\json\decoder.py", line 364, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "C:\Program Files (x86)\Kodi\system\python\Lib\json\decoder.py", line 382, in raw_decode
raise ValueError("No JSON object could be decoded")
ValueError: No JSON object could be decoded
-->End of Python script error report<--

Is there an issue with movies with accented characters in them? The update stopped in a folder where I have all 8 parts of Goddard's Histoir(es) du cinéma. The IMDb ID is correct in all of the NFOs. Please let me know. Thanks.

Regards,

Bart

EDIT: I figured it out, there was an extraneous character in the IMDB ID for the movie where it stopped. I fixed the NFO, refreshed the movie and the update continued past it. It is still running, I will post if I run into any other problems.

Hi bsoriano,

Thanks for writing. I take the occasion to make a clarification that can be useful for the other users.

During the update phase, any error that may happen is not depending on the add-on itself: if the update works for a movie, why should not work for another? Therefore, one of the following issues have happened:

- Internet connection drop
- Problems related to the IMDb site (e.g. offline)
- The IMDb in the info file is not in the correct format (the add-on just check if it begins with "tt" or if it is missing) and therefore there is an error when making the query to the IMDb site
- The IMDb of a movie has been replaced and deleted on the IMDb site (it happened once to me...)

Having said that, I wish you all a great summer time!
axlt2002,

tvshow update takes 2 seconds, not sure it is updating. I have a total of 30 shows...
Hi,

just tried your addon with LibreELEC and it seems to be working pretty well. Thanks a lot.

But I noticed that my tv show episodes rating and votes are not being updated.
The shows itself are getting updated properly. I checked to include the episodes in the settings so this shouldn't be the issue.

What I also noticed is that you can't start the update manually by just "running" the addon. You always have to enter the addon settings to do so.
Is it possible to implement this in a future release?
Ok, I've uninstalled the previous version and also deleted the folder in addon_data. I installed the addon through your repository. Once installed, I then ran the php installation and everything installed successfully. I then attempted to run the manual update and after a few seconds I receive a message that says Addon-Error. Can you please take a look at my LOG and tell me what I need to do to fix this.

LOG
@axlt2002

I tried installing the addon on my Nvidia SHIELD 5.2 experience patch (latest) and pops-up a message saying "system not supported at this time, etc etc" or something like that. So, altough it's android...it doesn't work. I have 64bit arch.

It's running KODI Krypton 17.3 from the Google Playstore.

here is the debug log as suggested in #1 post: https://pastebin.com/2rk3J6fQ

(all i can see is this):
19:00:19.231 T:138829358160 DEBUG: [Light IMDb Ratings Update] - PHP installation completed
19:00:19.231 T:138829358160 INFO: CPythonInvoker(23, /storage/emulated/0/Android/data/org.xbmc.kodi/files/.kodi/addons/service.light.imdb.ratings.update/resources/support/autoconf.py): script successfully run
19:00:19.252 T:138830677072 DEBUG: RunQuery took 163 ms for 2 items query: select * from movie_view JOIN sets ON movie_view.idSet = sets.idSet WHERE sets.idSet=244 ORDER BY sets.idSet
19:00:19.366 T:138829358160 INFO: Python script stopped


Anyway I would like to add some input/requests as I have already installed it on my Libreelec machines:

1 - Regarding IDs, well I dont use EMM nor do I use .nfo files. I use EMBY server (because I have a big NAS) and it does all the scraping for me. Then via the EMBY for KODI addon i have all my libraries updated. With maxim addon, we could manually set the ID of each new file to a .db file that his addon created on the user_data folder (RUdatabase or something like that)

Are you planning on adding/using that system? When a new TV show or Movie was detected during scan on his addon, a prompt window would come up, giving us the choice to choose which movie and/or TV Show was it. Then we could access the table of IDs inside the addon settings.

So far, and altough I dont have .nfos as I said, I have not come up with any kind of ID related errors while scanning (maybe your addon really works with EMBY). But I still didnt update the movies, just the TV Shows. Thing is, as far as I read in the first post, your dealing with the IMDB Ids is different from maxims addon?

2 - Can you think about the possibility of including this addon in the Context Menu? That way, when I add 2 or 3 new movies I can manually update their ratings without the need to manually run the addon (i have over 5000 movies and 600 TV SHows...). Again just like maxim addon did.

3 - In the future, are you considering to make addon a "program" ? Currently the only way of making manual updates/access the addon is via settings, addons, and addon...a little bit boring. I dont want to schedule anything Tongue

Thanks and I LOVE THIS
Hi guys,

I'm actually on vacation, so my support is really reduced at the minimum. I will be back at the end of the month...nevertheless, please find hereafter some feedbacks to your posts.

Cheers,

Alex

(2017-08-02, 03:28)Edworld Wrote: [ -> ]axlt2002,

tvshow update takes 2 seconds, not sure it is updating. I have a total of 30 shows...

Did you check the correct format of the .nfo files related to the TV Show and the Episodes? In particular the .nfo files must have the following labels:

Code:
<id>121361</id>
<uniqueid type="imdb" default="false">tt0944947</uniqueid>
<uniqueid type="tmdb" default="false">1399</uniqueid>
<uniqueid type="tvdb" default="true">121361</uniqueid>

If the label uniqueid type="imdb" is missing, the add-on can not retrieve the information from the IMDb site.

Having checked the point above, please provide a begub log (see the first post of this thread) related to the update of TV Shows/Episodes. Thanks. Blush

(2017-08-02, 11:21)Maaarv Wrote: [ -> ]Hi,

just tried your addon with LibreELEC and it seems to be working pretty well. Thanks a lot.

But I noticed that my tv show episodes rating and votes are not being updated.
The shows itself are getting updated properly. I checked to include the episodes in the settings so this shouldn't be the issue.

What I also noticed is that you can't start the update manually by just "running" the addon. You always have to enter the addon settings to do so.
Is it possible to implement this in a future release?

For the TV Shows/Episodes issue, please follow what I have answered just above. Nod

The add-on was conceived to run as a service on a scheduled basis. The manual update was added on a second stage. I take anyway a note of your request, even if I can not promise anything at the moment. Smile

(2017-08-02, 21:37)blackreign66 Wrote: [ -> ]Ok, I've uninstalled the previous version and also deleted the folder in addon_data. I installed the addon through your repository. Once installed, I then ran the php installation and everything installed successfully. I then attempted to run the manual update and after a few seconds I receive a message that says Addon-Error. Can you please take a look at my LOG and tell me what I need to do to fix this.

LOG

Thanks for the log! A question: was the previous version of the add-on working without any issue? Maybe the issue is related to the fact that the add-on is actually using the version 7 of php while before was the 5... Undecided

Anyway, would you be so kind to run again the PHP installation (manual installation is available through the add-on settings) with the debug log enabled and after that try again the Movies update too?

(2017-08-02, 23:33)djhifi Wrote: [ -> ]@axlt2002

I tried installing the addon on my Nvidia SHIELD 5.2 experience patch (latest) and pops-up a message saying "system not supported at this time, etc etc" or something like that. So, altough it's android...it doesn't work. I have 64bit arch.

It's running KODI Krypton 17.3 from the Google Playstore.

here is the debug log as suggested in #1 post: https://pastebin.com/2rk3J6fQ

(all i can see is this):
19:00:19.231 T:138829358160 DEBUG: [Light IMDb Ratings Update] - PHP installation completed
19:00:19.231 T:138829358160 INFO: CPythonInvoker(23, /storage/emulated/0/Android/data/org.xbmc.kodi/files/.kodi/addons/service.light.imdb.ratings.update/resources/support/autoconf.py): script successfully run
19:00:19.252 T:138830677072 DEBUG: RunQuery took 163 ms for 2 items query: select * from movie_view JOIN sets ON movie_view.idSet = sets.idSet WHERE sets.idSet=244 ORDER BY sets.idSet
19:00:19.366 T:138829358160 INFO: Python script stopped


Anyway I would like to add some input/requests as I have already installed it on my Libreelec machines:

1 - Regarding IDs, well I dont use EMM nor do I use .nfo files. I use EMBY server (because I have a big NAS) and it does all the scraping for me. Then via the EMBY for KODI addon i have all my libraries updated. With maxim addon, we could manually set the ID of each new file to a .db file that his addon created on the user_data folder (RUdatabase or something like that)

Are you planning on adding/using that system? When a new TV show or Movie was detected during scan on his addon, a prompt window would come up, giving us the choice to choose which movie and/or TV Show was it. Then we could access the table of IDs inside the addon settings.

So far, and altough I dont have .nfos as I said, I have not come up with any kind of ID related errors while scanning (maybe your addon really works with EMBY). But I still didnt update the movies, just the TV Shows. Thing is, as far as I read in the first post, your dealing with the IMDB Ids is different from maxims addon?

2 - Can you think about the possibility of including this addon in the Context Menu? That way, when I add 2 or 3 new movies I can manually update their ratings without the need to manually run the addon (i have over 5000 movies and 600 TV SHows...). Again just like maxim addon did.

3 - In the future, are you considering to make addon a "program" ? Currently the only way of making manual updates/access the addon is via settings, addons, and addon...a little bit boring. I dont want to schedule anything Tongue

Thanks and I LOVE THIS

For the Nvidia SHIELD issue, I can provide you an updated autoconf.py privatly and you can try if it works. The php-binary for Android that is actually used by the add-on is for sure compatible with a 32bit architecture...lets see if the 64bit version can manage it without issues... Huh

Lets go to the requests:

1 - Sorry, the add-on doesn't work with EMBY...if the IMDb ID is not found, the Movie/TV Show/Episode is just skipped without giving any error. Moreover, as written in the first post, the add-on doesn't use any database...this was a design choice that I have made to differentiate by the maxim add-on and that is why it has the keyword "Light" in its name. Can you post me a log related to Movies/TV Shows/Episodes update (all the options enabled in the add-on settings) so that I can at least understand the information in the responses to the JSON-RPC queries? I take anyway a note of your request, even if is going to have the lowest priority... Angel

2 - Again a design decision...as written previously, being the add-on conceived as a service, this should run without the intervention of the user. Using the scheduled update (and disabling the notification and progress update) the user will have always ALL the Movies/TV Shows/Episodes updated to the latest ratings without taking care of it (from my perspective there is no point to have just some movies updated and the others not). Again, I will take anyway into consideration your request...maybe not through a contest menu but using an option that will update only the latest added Movies/TV Shows/Episodes...would it make sense for you? Smile

3 - I have already taken a note... Wink
(2017-08-03, 23:13)axlt2002 Wrote: [ -> ]For the Nvidia SHIELD issue, I can provide you an updated autoconf.py privatly and you can try if it works. The php-binary for Android that is actually used by the add-on is for sure compatible with a 32bit architecture...lets see if the 64bit version can manage it without issues... Huh

Lets go to the requests:

1 - Sorry, the add-on doesn't work with EMBY...if the IMDb ID is not found, the Movie/TV Show/Episode is just skipped without giving any error. Moreover, as written in the first post, the add-on doesn't use any database...this was a design choice that I have made to differentiate by the maxim add-on and that is why it has the keyword "Light" in its name. Can you post me a log related to Movies/TV Shows/Episodes update (all the options enabled in the add-on settings) so that I can at least understand the information in the responses to the JSON-RPC queries? I take anyway a note of your request, even if is going to have the lowest priority... Angel

2 - Again a design decision...as written previously, being the add-on conceived as a service, this should run without the intervention of the user. Using the scheduled update (and disabling the notification and progress update) the user will have always ALL the Movies/TV Shows/Episodes updated to the latest ratings without taking care of it (from my perspective there is no point to have just some movies updated and the others not). Again, I will take anyway into consideration your request...maybe not through a contest menu but using an option that will update only the latest added Movies/TV Shows/Episodes...would it make sense for you? Smile

3 - I have already taken a note... Wink

OK so, with the autoconf.py replacement I can get to a part where the PHP binaries are installed OK. BUT, when I try to run the manual scan, the same error appears again.
You need another debug log?


1 - Are you you sure it doesn't work with EMBY? As I said, I ran movies and TV Shows update yesterday and I got results on all of them. OK I may need to check if really every movie and TV Show got updated but at least the ratings seem to be updated. I mean, I have a centralized .db in EMBY server side, maybe the addon is correctly getting the IDs? Because I have IDs on everything. Then the EMBY for KODI addon manages my database on kodi side. Or are you plain saying that the addon only works with .nfo files in each media folder for sure?

2 - It would make sense to me yes Big Grin

3 - Thank you so much for, at least, taking note Smile
(2017-08-03, 23:39)djhifi Wrote: [ -> ]1 - Are you you sure it doesn't work with EMBY? As I said, I ran movies and TV Shows update yesterday and I got results on all of them. OK I may need to check if really every movie and TV Show got updated but at least the ratings seem to be updated. I mean, I have a centralized .db in EMBY server side, maybe the addon is correctly getting the IDs? Because I have IDs on everything. Then the EMBY for KODI addon manages my database on kodi side. Or are you plain saying that the addon only works with .nfo files in each media folder for sure?

Hey, what a quick answer! Wink

Ok, lets put like this: the add-on retrieve the Movies/TV Shows/Episodes information directly from the Kodi database. So, if the Kodi database is updated by the EMBY for KODI add-on respecting the uniqueid formats, there is no issue for the ratings update. That is why I was asking you to provide my the log, just to check that aspect. Having said this, maybe I dind't understand correctly what you were asking...sorry, my brain is on vacation! Cool So, the .nfo files are not mandatory from this point of view...
OK so, with the autoconf.py replacement I can get to a part where the PHP binaries are installed OK. BUT, when I try to run the manual scan, the same error appears again.
You need another debug log?

(2017-08-03, 23:57)axlt2002 Wrote: [ -> ]
(2017-08-03, 23:39)djhifi Wrote: [ -> ]1 - Are you you sure it doesn't work with EMBY? As I said, I ran movies and TV Shows update yesterday and I got results on all of them. OK I may need to check if really every movie and TV Show got updated but at least the ratings seem to be updated. I mean, I have a centralized .db in EMBY server side, maybe the addon is correctly getting the IDs? Because I have IDs on everything. Then the EMBY for KODI addon manages my database on kodi side. Or are you plain saying that the addon only works with .nfo files in each media folder for sure?

Hey, what a quick answer! Wink

Ok, lets put like this: the add-on retrieve the Movies/TV Shows/Episodes information directly from the Kodi database. So, if the Kodi database is updated by the EMBY for KODI add-on respecting the uniqueid formats, there is no issue for the ratings update. That is why I was asking you to provide my the log, just to check that aspect. Having said this, maybe I dind't understand correctly what you were asking...sorry, my brain is on vacation! Cool


Yes, EMBY is actually modifying the KODI.db indeed and maybe thats why it Works, because my EMBY server scrapes everything OK, and what it doesnt, I make sure it is scrapped ok Big Grin.

The debug log you want is from your addon running the ratings update on all my library items, correct?
(2017-08-03, 23:57)djhifi Wrote: [ -> ]OK so, with the autoconf.py replacement I can get to a part where the PHP binaries are installed OK. BUT, when I try to run the manual scan, the same error appears again.
You need another debug log?

(2017-08-03, 23:57)axlt2002 Wrote: [ -> ]
(2017-08-03, 23:39)djhifi Wrote: [ -> ]1 - Are you you sure it doesn't work with EMBY? As I said, I ran movies and TV Shows update yesterday and I got results on all of them. OK I may need to check if really every movie and TV Show got updated but at least the ratings seem to be updated. I mean, I have a centralized .db in EMBY server side, maybe the addon is correctly getting the IDs? Because I have IDs on everything. Then the EMBY for KODI addon manages my database on kodi side. Or are you plain saying that the addon only works with .nfo files in each media folder for sure?

Hey, what a quick answer! Wink

Ok, lets put like this: the add-on retrieve the Movies/TV Shows/Episodes information directly from the Kodi database. So, if the Kodi database is updated by the EMBY for KODI add-on respecting the uniqueid formats, there is no issue for the ratings update. That is why I was asking you to provide my the log, just to check that aspect. Having said this, maybe I dind't understand correctly what you were asking...sorry, my brain is on vacation! Cool


Yes, EMBY is actually modifying the KODI.db indeed and maybe thats why it Works, because my EMBY server scrapes everything OK, and what it doesnt, I make sure it is scrapped ok Big Grin.

The debug log you want is from your addon running the ratings update on all my library items, correct?

Exactly! In case everything is confirmed, I will update the first post considering also EMBY.
(2017-08-03, 23:39)djhifi Wrote: [ -> ]OK so, with the autoconf.py replacement I can get to a part where the PHP binaries are installed OK. BUT, when I try to run the manual scan, the same error appears again.
You need another debug log?

Sounds strange to receive the same error...before was something related to the fact that the system was not supported...now it should be different...of course a debug log would be useful! Wink