[Python-bugs-list] [ python-Bugs-453489 ] Using deiconify() hangs on exit
noreply@sourceforge.net
noreply@sourceforge.net
Wed, 05 Sep 2001 11:32:05 -0700
Bugs item #453489, was opened at 2001-08-20 13:38
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=453489&group_id=5470
Category: Tkinter
>Group: Platform-specific
Status: Open
Resolution: None
Priority: 5
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: Using deiconify() hangs on exit
Initial Comment:
If you run the following script, and iconize the
window before the after() timer, it'll restore and
raise the window as it should, but then you can't
exit. You have to kill winoldap with ctrl+alt+del and
wait.
I ran into this trying to write a portable jabber
client using tkinter.
This is with 2.1.1 on Windows 98. Does it every
time. May be related to bug #216289.
from Tkinter import *
import sys
def foo():
print 'foo'
sys.stdout.flush()
root.deiconify()
print 'bar'
sys.stdout.flush()
root=Tk()
Button(root, text='Quit', command=root.quit).pack()
root.after(5000, foo)
root.mainloop()
----------------------------------------------------------------------
Comment By: Howard Lightstone (hlightstone)
Date: 2001-09-05 11:31
Message:
Logged In: YES
user_id=66570
Since I was also looking at #216289:
Data using pythonw.exe (Taskinfo2000):
Handles while running (before quit)
4 : Process 4 PID:FFF6F92D, C:\PYTHON20\PYTHONW.EXE
C : Event 1
10 : Event 1
1C : Mutex 17 OLESCMLOCKMUTEX
20 : Event 1
24 : Event 1
--------------------------------------------------------
Handles while running Python.exe (before quit)
|Handle||Type| |Refs||Name|
4 : Process 7 PID:FFF50719, C:\PYTHON20\PYTHON.EXE
8 : Console 3
C : Screen Buff 3
10 : Screen Buff 3
18 : Event 1
1C : Event 1
20 : Event 1
24 : Event 2
28 : Mutex 19 OLESCMLOCKMUTEX
2C : Event 1
30 : Event 1
34 : Thread 1 ThID:FFF79069, PID:FFF50719,
C:\PYTHON20\PYTHON.EXE
38 : Event 1
3C : Event 2
40 : Thread 1 ThID:FFF52B8D, PID:FFF50719,
C:\PYTHON20\PYTHON.EXE
44 : Event 1
48 : Event 2
4C : Thread 1 ThID:FFF53539, PID:FFF50719,
C:\PYTHON20\PYTHON.EXE
----------------------------------------------------------
Handles AFTER trying to quit
|Handle||Type| |Refs||Name|
4 : Process 4 PID:FFF50719, C:\PYTHON20\PYTHON.EXE
8 : Console 3
C : Screen Buff 3
10 : Screen Buff 3
18 : Event 1
1C : Event 1
20 : Event 1
24 : Event 1
28 : Mutex 19 OLESCMLOCKMUTEX
2C : Event 1
30 : Event 1
34 : Thread 1
38 : Event 1
3C : Event 1
40 : Thread 2 ThID:FFF52B8D, PID:FFF50719,
C:\PYTHON20\PYTHON.EXE
It appears that there is a thread NOT terminating. I just
don't know how to go about finding it.
----------------------------------------------------------------------
Comment By: Guido van Rossum (gvanrossum)
Date: 2001-08-20 19:39
Message:
Logged In: YES
user_id=6380
I agree that this is likely the same as #216289.
AFAIK it's a Tcl bug and we don't know what to do about it.
----------------------------------------------------------------------
Comment By: Nobody/Anonymous (nobody)
Date: 2001-08-20 15:51
Message:
Logged In: NO
Interestingly enough, if you add a print statement after
the mainloop(), it gets printed, showing the event loop
exits properly.
----------------------------------------------------------------------
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=453489&group_id=5470