[PATCH] More detailed error output on corrupt UID mapping files

Sebastian Spaeth Sebastian at SSpaeth.de
Tue May 3 14:58:21 BST 2011


On Tue, 3 May 2011 04:30:51 -0700 (PDT), chris coleman wrote:

> But it didn't output any further details on the filename/line number where any bad data is.  

No, because there is no bad filename/line number as the bad data is
coming in the form of a reply from the IMAP server.

> Must get better info on where the bad data is located, and repair these 2 username's data, ASAP.

The bad data is either a bad email or a bad reply from the IMAP server
that we cannot cope with. Therefore it would be good to know *what* that
IMAP reply is.
 
> I see the actual error message gets output in the file offlineimap/accounts.py, function syncfolder, line 380:
>     except:
>         ui.warn("ERROR in syncfolder for %s folder %s: %s" % \
>                 (accountname,remotefolder.getvisiblename(),sys.exc_info()[1]))
> 
> These are available: localrepos, localfolder, remoterepos, remotefolder.  
> 
> How about we output details of the line number and filename right here in the call to ui.warn ????

6.3.3 outputs more information, giving us the full traceback (ie in
which line the call failed). However that won't help you here, as we
know that it fails in that one "long()" call. It's just triggered from a
specific reply from the IMAP server. And as we have changed the code
From 6.3.2 to 6.3.3, I think it would be worthwhile checking it out.

It's as easy as downloading and untaring
https://github.com/nicolas33/offlineimap/tarball/v6.3.3

going into the directory and issueing "python offlineimap.py" in
there. No installation required.

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/20110503/71905663/attachment-0001.sig>


More information about the OfflineIMAP-project mailing list