A fix for bug with IMAP server not supporting APPENDUID

Nicolas Sebrecht nicolas.s-dev at laposte.net
Sat Jan 26 16:44:50 GMT 2013


Not sure it was ever merged; resending.

On Tue, May 29, 2012 at 10:17:12AM +0200, Tomasz ┼╗ok wrote:
> Hi,
> 
> nearly a month ago (2012-04-30 10:47:23 GMT) I sent a bug report about errors
> during sync and emails being repeated. I got no response to this, so I looked
> at it myself today. I am attaching a fix and paste a diff here - it was really
> a trivial one:
> 
> In file: /usr/lib/python2.7/site-packages/offlineimap/folder/IMAP.py
> 
> 585c585
> <                 if resp == [None]:
> ---
> >                 if not resp or resp == [None]:
> 
> 
> The bug was that with my IMAP server, the resp variable was None itself, not a
> list with None inside.
> 
> Best regards,
> Tomasz Zok

> *** IMAP.py	2012-04-03 01:39:28.000000000 +0200
> --- /usr/lib/python2.7/site-packages/offlineimap/folder/IMAP.py	2012-05-29 10:04:06.606412972 +0200
> ***************
> *** 582,588 ****
>                   # often seems to return [None], even though we have
>                   # data. TODO
>                   resp = imapobj._get_untagged_response('APPENDUID')
> !                 if resp == [None]:
>                       self.ui.warn("Server supports UIDPLUS but got no APPENDUID "
>                                    "appending a message.")
>                       return 0
> --- 582,588 ----
>                   # often seems to return [None], even though we have
>                   # data. TODO
>                   resp = imapobj._get_untagged_response('APPENDUID')
> !                 if not resp or resp == [None]:
>                       self.ui.warn("Server supports UIDPLUS but got no APPENDUID "
>                                    "appending a message.")
>                       return 0


-- 
Nicolas Sebrecht
-------------- next part --------------
A non-text attachment was scrubbed...
Name: IMAP.py.patch
Type: text/x-diff
Size: 970 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/offlineimap-project/attachments/20130126/bfbb4170/attachment-0002.patch>


More information about the OfflineIMAP-project mailing list