AttributeError: 'AskColor' object has no attribute 'wheel'
theaddonn opened this issue · 3 comments
theaddonn commented
I get the error:
Exception in Tkinter callback
Traceback (most recent call last):
File "C:\Users\user\AppData\Local\Programs\Python\Python310\lib\tkinter\__init__.py", line 1921, in __call__
return self.func(*args)
File "C:\Users\user\PycharmProjects\toys\venv\lib\site-packages\customtkinter\windows\widgets\ctk_button.py", line 553, in _clicked
self._command()
File "C:\Users\user\PycharmProjects\toys\test.py", line 14, in ask_color
pick_color = AskColor() # open the color picker
File "C:\Users\user\PycharmProjects\toys\venv\lib\site-packages\CTkColorPicker\ctk_color_picker.py", line 74, in __init__
self.img1 = Image.open(os.path.join(PATH, 'color_wheel.png')).resize((self.image_dimension, self.image_dimension), Image.Resampling.LANCZOS)
File "C:\Users\user\PycharmProjects\toys\venv\lib\site-packages\PIL\Image.py", line 3298, in open
raise UnidentifiedImageError(msg)
PIL.UnidentifiedImageError: cannot identify image file 'C:\\Users\\user\\PycharmProjects\\toys\\venv\\Lib\\site-packages\\CTkColorPicker\\color_wheel.png'
Have I done something wrong ... or is the ColorPicker broken?
Akascape commented
@Adrian8115
Try updating PIL. pip install pillow --upgrade
Also try the older version of ctkcolorpicker if this doesn't work.
Like pip install CTkColorPicker==0.3.0
theaddonn commented
the png's were corrupted I downloaded them from github and now everything works!
I am also relly thankfull, you have done a great job with this and I'm just so thankfull! <3
Akascape commented
@Adrian8115
the png's were corrupted I downloaded them from github and now everything works!
Don't know why it happened in your system while installing it via pip.
On my system it is working fine.