[issue42491] Tkinter wait_visibility hanging when used in thread

2021-08-19 Thread Steve Carll
Steve Carll added the comment: This is a Tkinter problem and not a TK problem. I ended up working around the problem by forcing garbage collection before opening and after closing any Tkinter windows that are created from other Tkinter windows. Since adding this code I have not had the proble

[issue42491] Tkinter wait_visibility hanging when used in thread

2021-08-18 Thread Terry J. Reedy
Terry J. Reedy added the comment: tcl/tk can be compiled without or with thread support. For 8.5, the default was without. For 8.6, the default is with. The Windows and macOS installers include 8.6 compiled with the default. I have not previously heard of problems with thread when it is

[issue42491] Tkinter wait_visibility hanging when used in thread

2020-11-28 Thread E. Paine
E. Paine added the comment: You make very good points but sadly it is not that simple. The issue is described in detail in the comment found in Modules/_tkinter.c:178. A good summary is probably the comment for Tkapp_Call (Modules/_tkinter.c:1522). -- ___

[issue42491] Tkinter wait_visibility hanging when used in thread

2020-11-28 Thread Steve Carll
Steve Carll added the comment: Thank you to epaine for the quick reply. IMHO this should be elevated and addressed. TKinter not working well with threads appears to be a well known problem that a lot of developers have encountered and have had to work around. The use of threads is not somethin

[issue42491] Tkinter wait_visibility hanging when used in thread

2020-11-28 Thread E. Paine
E. Paine added the comment: I agree this is a race condition, and have narrowed the issue down to wait_visibility with the following also hanging indefinitely (tested against the master branch): import threading import tkinter as tk def create_tp(): t = tk.Toplevel() t.wait_visibilit