This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author dmaurer
Recipients
Date 2002-08-14.19:34:06
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
asynchat.async_chat.push has two problems when
used in an application where the pusher and the
main loop are run by different threads.

1.  A "push" does not wake up the main loop. This may 
result in long delays (the loop, by default, uses a timeout 
of 30 s). The work around is an explicit wakeup on the 
loop. I do not have a solution for Windows (more 
generally an OS where select does not work for pipes).
When select does work for pipes, a simple "wakeup"
can be implemented by writing to a pipe the main loop
is waiting for.

2. The "self.initiate_send" can lead to two identical
sends (which should be only one!) under the condition
above. Workaround is to remove the call. 
History
Date User Action Args
2007-08-23 14:04:54adminlinkissue595217 messages
2007-08-23 14:04:54admincreate