Singlethreading patch series
Sebastian Spaeth
Sebastian at SSpaeth.de
Wed Jan 12 09:50:49 GMT 2011
OK, this is my proposal of how to proceed. I will post my updated patch
series as a response to this email in a second. It consists of:
0001-Catch-SystemExit-and-KeyboardInterrupt-exceptions.patch
0002-Catch-KeyboardInterrupt-exceptions-explicitely.patch
0003-LocalStatus-Don-t-ignore-Exceptions-on-os.fsync.patch
0004-Clean-up-import-s.patch
0005-Implement-true-single-threading.patch
0006-Imply-single-threaded-mode-whith-d-ebug-command-line.patch
In response to Johannes and your comments, I see the following options:
a) Merge patches 1-6. They allow us to run everything in a single thread
and allow us to ctrl-c abort the run. A separate topic should be
created once this is merged that does away with the catch-it all
exceptions. We will likely need to examine each case carefully to see
which exceptions can occur and which are "expected" respectively in
which cases we can give clear error messages to the user.
b) Merge patches 1-2,4-6. Similar to the last option, but patch 3
already belongs to the new patch series examining our cases of
catch-it-all. So skip patch 3 in *this* topic and save it for the
next.
c) Merge patches 4-6. Don't touch the exception handling at all and
leave all those changes to the future topic. This has the disadvantage
that ctrl-c in single-threaded mode does nothing yet but abort
e.g. the current folder sync (only to continue with the next
mail/folder/account), so aborting the run is not easily possible in
this state.
I defer the preferred merging strategy to Nicolas...
On Mon, 10 Jan 2011 20:11:41 +0100, Nicolas Sebrecht <nicolas.s-dev at laposte.net> wrote:
> > However, whether we really want to use "account single threading" in
> > cases 2) and 3) is open to debate. I would be perfectly fine if we only
> > used it in the 1) case.
>
> I think this is going much better. Why would we need Singlethreading
> if not for debugging?
This is done in the latest version of the series that I will repost now.
> The last change would be to make the Singlethreading option the default
> in debug mode (if not already done).
Done, this makes sense. With the slight complication that we can also
invoke "-d thread" which is supposed to do thread debugging. (but was/is
still broken in python 2.6). So patch 6/6 of the new series implies
single-threading UNLESS we include "thread" as a debug option. (In this
case one can still manually select the -1 option from command line)
Sebastian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/offlineimap-project/attachments/20110112/a524f5c9/attachment-0001.sig>
More information about the OfflineIMAP-project
mailing list