[New-bugs-announce] [issue6073] threading.Timer and gtk.main are not compatible

Eric Atienza report at bugs.python.org
Wed May 20 22:42:30 CEST 2009


New submission from Eric Atienza <eric at ericaro.net>:

this simple code:
"
import gtk
from threading import Timer
from time import sleep

def p():
    print "p"

Timer(1, p).start()

#gtk.main()
sleep(10)
print "done"
does print "p" a second after it starts.
when I remove the comment of the gtk.main() line: the "p" is never printed.

It is very exposed, as Timer is a common tool to build a GUI therefore
with the gtk.main() loop active.

----------
components: Library (Lib)
messages: 88137
nosy: atienza
severity: normal
status: open
title: threading.Timer and gtk.main are not compatible
type: behavior
versions: Python 2.6

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue6073>
_______________________________________


More information about the New-bugs-announce mailing list