python, offlineimap and wakeups (outch)

Sebastian Spaeth Sebastian at
Tue Mar 15 15:38:58 GMT 2011

On Tue, 15 Mar 2011 10:35:19 -0400, Dan Christensen <jdc at> wrote:
> Sebastian Spaeth <Sebastian at> writes:
> > With a timeout, we react to ctrl-c, but wake up every 50ms.
> How about increasing 50ms to 300ms or 500ms?  I don't think there's any
> harm in waiting 0.5s for an interrupt.  (Or, use a large timeout when in
> daemon mode and a small timeout the rest of the time?)

The 50ms comes from python's threading module, not by an arbitrary
choice from us. That having said, we can do a
sleep(0.5) combined with non-blocking checks. But that not only means a
lag when sending interrupts, but in the current architecture, also when
we finish regularly. Solving this in current python is not super-easy it

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <>

More information about the OfflineIMAP-project mailing list