FS#34838 - offlineimap will failed with "ERROR: command: UID => socket error: <type 'exceptions.IOError'> - To"

Attached to Project: Community Packages
Opened by Madper Xie (Madper) - Thursday, 18 April 2013, 05:45 GMT
Last edited by Gaetan Bisson (vesath) - Monday, 22 April 2013, 16:39 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Jaroslav Lichtblau (Dragonlord)
Gaetan Bisson (vesath)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description:
Hi all. When I try to fetch my file from Gmail with offlineimap, will get following errors:

-------------------------
madper@madper ~ % offlineimap
OfflineIMAP 6.5.4
Licensed under the GNU GPL v2+ (v2 or any later version)
Account sync Gmail:
*** Processing account Gmail
Establishing connection to imap.gmail.com:993
Folder [Gmail]/Drafts [acc: Gmail]:
Syncing [Gmail]/Drafts: Gmail -> Maildir
Folder INBOX [acc: Gmail]:
Syncing INBOX: Gmail -> Maildir
Copy message 7852 (1 of 1338) Gmail-Remote:INBOX -> Gmail-Local
Folder [Gmail]/Drafts [acc: Gmail]:
Copy message 257 (1 of 72) Gmail-Remote:[Gmail]/Drafts -> Gmail-Local
Folder INBOX [acc: Gmail]:
Copy message 7843 (2 of 1338) Gmail-Remote:INBOX -> Gmail-Local
Folder [Gmail]/Drafts [acc: Gmail]:
Copy message 701 (2 of 72) Gmail-Remote:[Gmail]/Drafts -> Gmail-Local
Copy message from Gmail-Remote:[Gmail]/Drafts:
Establishing connection to imap.gmail.com:993
ERROR: command: UID => socket error: <type 'exceptions.IOError'> - Too many read 0
Establishing connection to imap.gmail.com:993
ERROR: command: UID => socket error: <type 'exceptions.IOError'> - Too many read 0
ERROR: command: UID => socket error: <type 'exceptions.IOError'> - Too many read 0
Folder INBOX [acc: Gmail]:
Copy message 8199 (3 of 1338) Gmail-Remote:INBOX -> Gmail-Local
Folder [Gmail]/Drafts [acc: Gmail]:
Copy message 3 (3 of 72) Gmail-Remote:[Gmail]/Drafts -> Gmail-Local
Thread 'Copy message from Gmail-Remote:[Gmail]/Drafts' terminated with exception:
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/offlineimap/threadutil.py", line 156, in run
Thread.run(self)
File "/usr/lib/python2.7/threading.py", line 763, in run
self.__target(*self.__args, **self.__kwargs)
File "/usr/lib/python2.7/site-packages/offlineimap/folder/Base.py", line 330, in copymessageto
message = self.getmessage(uid)
File "/usr/lib/python2.7/site-packages/offlineimap/folder/IMAP.py", line 228, in getmessage
raise e
abort: command: UID => socket error: <type 'exceptions.IOError'> - Too many read 0


Last 3 debug messages logged for Copy message from Gmail-Remote:[Gmail]/Drafts prior to exception:
thread: Register new thread 'Copy message from Gmail-Remote:[Gmail]/Drafts' (account 'Gmail')
imap: Attempting plain authentication
imap: Attempting plain authentication
ERROR: Exceptions occurred during the run!
ERROR: command: UID => socket error: <type 'exceptions.IOError'> - Too many read 0
ERROR: command: UID => socket error: <type 'exceptions.IOError'> - Too many read 0
ERROR: command: UID => socket error: <type 'exceptions.IOError'> - Too many read 0
------------------------------

I have tried delete some of my mails. And it can continue now. But it will appear soon. So I think there must be some mails blocking offlineimap in my Gmail. I have searched google, I'm not the only one who meet this issue.

Additional info:
* package version(s)
madper@madper ~ % offlineimap --version
6.5.4
* config and/or log files etc.


Steps to reproduce:
I'm not sure if you can reproduce it. it seems need some magic mails in your mailbox. (with some special encoding? or some magic attach?)
This task depends upon

Closed by  Gaetan Bisson (vesath)
Monday, 22 April 2013, 16:39 GMT
Reason for closing:  Upstream
Comment by Madper Xie (Madper) - Thursday, 18 April 2013, 05:55 GMT
I have tried compiling the git version. But still failed:
-----
madper@madper ~ % offlineimap
OfflineIMAP 6.5.5-rc2
Licensed under the GNU GPL v2+ (v2 or any later version)
Account sync Gmail:
*** Processing account Gmail
Establishing connection to imap.gmail.com:993
Folder INBOX [acc: Gmail]:
Syncing INBOX: Gmail -> Maildir
Copy message 2906 (1 of 31) Gmail-Remote:INBOX -> Gmail-Local
Copy message 1886 (2 of 31) Gmail-Remote:INBOX -> Gmail-Local
Copy message from Gmail-Remote:INBOX:
Establishing connection to imap.gmail.com:993
ERROR: command: UID => socket error: <type 'exceptions.IOError'> - Too many read 0
-----------------------------

The only way is delete some of my mail. It will run well if the message 1886 was deleted. (but I don't know how to choose it on Gmail. So I just delete some mails randomly.)
Comment by Madper Xie (Madper) - Saturday, 20 April 2013, 02:49 GMT
any update? please let my know if you need any output. Thanks~
Comment by Jelle van der Waa (jelly) - Monday, 22 April 2013, 14:47 GMT
Ask offlineimap upstream, dear mailing list is active
Comment by Gaetan Bisson (vesath) - Monday, 22 April 2013, 16:39 GMT
Please ask upstream; we are far less knowledgeable than them to provide proper support. Let us know when a fix is known that we can incorporate in our package. Thanks.

Loading...