F. added the comment:

IMAP polling hurts, just merge imaplib2 into standard library as imaplib.

Piers Lauder authored imaplib IMAP4 client, part of python standard library, 
back in December 1997 based on RFC 2060. In 2003 RFC 2060 was made obsolete by 
RFC 3501 adding important features and Piers released imaplib2 which receives 
feature updates since.
Last feature updates to the standard library imaplib were before Piers retired 
from Sydney University a decade ago.

imaplib2 presents an almost identical API as that provided by the standard 
library imaplib, the main difference being that imaplib2 allows parallel 
execution of commands on the IMAP4 server, and implements the IDLE extension, 
so NO POLLING IS REQUIRED. IMAP server will push new mail notifications to the 
client. Imaplib2 also supports COMPRESS, ID, better timeout handling etc. There 
is 975 more lines of code all doing useful things a modern IMAP client needs.

imaplib2 can be substituted for imaplib in existing clients with no changes in 
the code apart from required logout call to shutdown the threads.

Old imaplib was ported to Python 3 with the rest of the standard library. I am 
working to port imaplib2 to py3, stuck on receiving bytes v strings.

References:

imaplib2 code and docs
http://sourceforge.net/p/imaplib2/code/ci/master/tree/
also http://sydney.edu.au/engineering/it/~piers/python/imaplib2.html

imaplib
https://hg.python.org/cpython/file/3.4/Lib/imaplib.py

Ruby stdlib support for idle (not that it hurts python performance, just my 
pride)
http://ruby-doc.org/stdlib-2.0.0/libdoc/net/imap/rdoc/Net/IMAP.html#method-i-idle

----------
nosy: +Malina

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue11245>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to