TomSchimansky / TomSchimansky/CustomTkinter
AttributeError: '_tkinter.tkapp' object has no attribute 'block_update_dimensions_event'
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 13.6k
- Forks
- 1.2k
- PR merge metrics
- No merged PRs in 30d
Description
I have an application that opens multiple windows, and when running on Windows 10 with Python3.9, opening a second window causes this error:
Exception in Tkinter callback
Traceback (most recent call last):
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3568.0_x64__qbz5n2kfra8p0\lib\tkinter\__init__.py", line 1892, in __call__
return self.func(*args)
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3568.0_x64__qbz5n2kfra8p0\lib\tkinter\__init__.py", line 814, in callit
func(*args)
File "C:\Users\Zico\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\customtkinter\windows\widgets\scaling\scaling_tracker.py", line 186, in check_dpi_scaling
window.block_update_dimensions_event()
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3568.0_x64__qbz5n2kfra8p0\lib\tkinter\__init__.py", line 2354, in __getattr__
return getattr(self.tk, attr)
AttributeError: '_tkinter.tkapp' object has no attribute 'block_update_dimensions_event'
I've tried researching this, but I can't find anything. To my knowledge, I'm not missing any packages. I've uninstalled and reinstalled python, as well as tried this on multiple computers.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the traceback location in customtkinter/windows/widgets/scaling/scaling_tracker.py at line 186 and inspect how windows are tracked during DPI-scaling checks. Reproduce the reported Windows 10/Python 3.9 case by opening a second window, then determine what allows the callback to call the missing method; done means the callback no longer raises this AttributeError.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- desktop, frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100