Complete.Org: Mailing Lists: Archives: offlineimap: July 2007:
Re: Offlineimap and notebook computers
Home

Re: Offlineimap and notebook computers

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Gilles Roy <groy@xxxxxxx>
Cc: offlineimap@xxxxxxxxxxxx, Raffi Khatchadourian <khatchad@xxxxxxxxxxxxxxxxxx>
Subject: Re: Offlineimap and notebook computers
From: John Goerzen <jgoerzen@xxxxxxxxxxxx>
Date: Fri, 6 Jul 2007 16:27:24 -0500

On Fri July 6 2007 3:11:23 pm Gilles Roy wrote:
> The offlineimap docs say:
>
> "If you need to schedule synchronizations, please use the autorefresh
> settings rather than cron."

That was probably true at one time, but is less relevant today.  I've updated 
the wording in the manual.

> The only problem with autorefresh is that it can exit and then you need
> to manually restart offlineimap. It would be nice if instead of exiting
> on error, in autorefresh mode, it might just sleep a bit and restart
> itself.

Yes, that would be nice.  Unfortunately, it is exceptionally complex because 
Python does not provide a way to kill threads.  Basically, all threads in 
the sync for a given account have to keep polling to see if any of the other 
threads died, and to then exit themselves if the other threads did die.  
It's complex and nasty.  And, incidentally, one of the reasons that I keep 
thinking of rewriting OfflineIMAP in Haskell (whose threads can be killed).

I am also toying with running the UI in a separate process from the backend, 
and communicating via pipes.  That would permit a backend to be killed off 
and then restarted, at least in theory.

This is probably one of the most frequently requested features.  Patches 
would be welcome.

-- John



[Prev in Thread] Current Thread [Next in Thread]