Brushshe
Brushshe copied to clipboard
Error with message about exiting Brushshe
PS C:\Users\maksi\Downloads\Brushshe> python -m Brushshe.main
Exception in Tkinter callback
Traceback (most recent call last):
File "C:\Users\maksi\AppData\Local\Programs\Python\Python314\Lib\tkinter\__init__.py", line 2093, in __call__
return self.func(*args)
~~~~~~~~~^^^^^^^
File "C:\Users\maksi\Downloads\Brushshe\Brushshe\logic\common.py", line 56, in when_closing
msg = messagebox.leave_brushshe(self.ui)
File "C:\Users\maksi\Downloads\Brushshe\Brushshe\ui\messagebox.py", line 541, in leave_brushshe
leave_brushshe_msg = Messagebox(
master,
...<5 lines>...
icon="question",
)
File "C:\Users\maksi\Downloads\Brushshe\Brushshe\ui\messagebox.py", line 214, in __init__
self.icon = self.load_icon(icon, icon_size) if icon else None
~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
File "C:\Users\maksi\Downloads\Brushshe\Brushshe\ui\messagebox.py", line 485, in load_icon
self.ICON_BITMAP[icon] = ImageTk.PhotoImage(file=image_path)
^^^^^^^
NameError: name 'ImageTk' is not defined. Did you mean: 'Image'?
Hi, I would like to work on this issue.
I just checked the code and since ImageTk is already being imported in the messagebox.py file the issue might just be with the environment setup, the python version or Pillow/Tkinter compatibility. I'll be happy to help with the error handling or the documentation intstead.
In the latest finished version (2.7.0 codename 'Zviahel') there’s no such error, it appeared after the new commits were added to the develop branch, just so you know.