tkinter, threads and asyncore together

duane voth duanev at io.com
Thu Mar 18 17:48:36 EST 2004


> #to control asyncore
> while 1:
>     asyncore.loop(.1)
>     if not fromgui.empty():
>         #handle messages from GUI

The above doesn't work for me - asyncore.loop(<anything>) always blocks.
The asyncore.poll(timeout=0.01) functions however works fine.  Thus I have:

        while 1:
            tkinter.dooneevent(tkinter.DONT_WAIT)
            asyncore.poll(0.01)

--
Duane Voth
duanev at io.com
--
djv at djv.net





More information about the Python-list mailing list