script.toolbox
script.toolbox copied to clipboard
Crashes when starting a TV channel for the first time since startup
I've been experiencing regular addon crashes since I updated to Jarvis. Here's the exception I usually get:
11:32:25 T:140667409913600 DEBUG: script.toolbox: blurred img already created: /home/brix/.kodi/userdata/addon_data/script.toolbox/3fc6aa21f93f37140d7508baf4a8a51a30.png
11:32:25 T:140667409913600 ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <type 'exceptions.IOError'>
Error Contents: cannot identify image file
Traceback (most recent call last):
File "/home/brix/.kodi/addons/script.toolbox/default.py", line 146, in <module>
Main()
File "/home/brix/.kodi/addons/script.toolbox/default.py", line 33, in __init__
image, imagecolor = Filter_Image(self.image_now, int(self.params.get("radius", 5)))
File "/home/brix/.kodi/addons/script.toolbox/resources/lib/Utils.py", line 180, in Filter_Image
img = Image.open(targetfile)
File "/usr/lib/python2.7/dist-packages/PIL/Image.py", line 2028, in open
raise IOError("cannot identify image file")
IOError: cannot identify image file
-->End of Python script error report<--
11:32:25 T:140667409913600 INFO: Python script stopped
After deleting everything from addon_data/script.toolbox I'm instead getting this:
11:33:41 T:139792889128704 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: too many values to unpack
Traceback (most recent call last):
File "/home/brix/.kodi/addons/script.toolbox/default.py", line 146, in <module>
Main()
File "/home/brix/.kodi/addons/script.toolbox/default.py", line 33, in __init__
image, imagecolor = Filter_Image(self.image_now, int(self.params.get("radius", 5)))
File "/home/brix/.kodi/addons/script.toolbox/resources/lib/Utils.py", line 177, in Filter_Image
img.save(targetfile)
File "/usr/lib/python2.7/dist-packages/PIL/Image.py", line 1468, in save
save_handler(self, fp, filename)
File "/usr/lib/python2.7/dist-packages/PIL/PngImagePlugin.py", line 578, in _save
red, green, blue = transparency
ValueError: too many values to unpack
-->End of Python script error report<--
11:33:41 T:139792889128704 INFO: Python script stopped
@phil65 do you want a complete log file?
nah I probably just put everything into a try-except there, too lazy to find the root cause. :) Seems as if PIL doesnt like some of the artwork.
Yeah it seems to work without this code, I commented it out at some point to get rid of the error but it got reintroduced when the addon updated itself at some point.