fsmosca / Python-Easy-Chess-GUI

A Chess GUI based from Python using PySimpleGUI and Python-Chess.
GNU Lesser General Public License v3.0
160 stars 51 forks source link

Bad attribute error on Ubuntu when trying to select any menu item #49

Closed alex4200 closed 1 year ago

alex4200 commented 1 year ago

Using ubuntu 20.04.5 and python 3.8 I was able to install this code and start it, and I see the GUI. But when I select any menu item, no matter what, the code crashes with the following error message:

Traceback (most recent call last):
  File "python_easy_chess_gui.py", line 3578, in <module>
    main()
  File "python_easy_chess_gui.py", line 3574, in main
    pecg.main_loop()
  File "python_easy_chess_gui.py", line 3443, in main_loop
    window.Disable()
  File "/home/user/Chess/venv_Python-Easy-Chess-GUI/lib/python3.8/site-packages/PySimpleGUI/PySimpleGUI.py", line 10999, in disable
    self.TKroot.attributes('-disabled', 1)
  File "/usr/lib/python3.8/tkinter/__init__.py", line 1976, in wm_attributes
    return self.tk.call(args)
_tkinter.TclError: bad attribute "-disabled": must be -alpha, -topmost, -zoomed, -fullscreen, or -type
fsmosca commented 1 year ago

This is the current fix, if you are interested. It involves revising the pysimplegui.py

https://github.com/fsmosca/Python-Easy-Chess-GUI/issues/35#issuecomment-824499803

fsmosca commented 1 year ago

There is new commit to fix this issue at 41a4ae236dc0c8ba0644b8eb7cde7ad55acf8977.

Use the latest code.