gmail
gmail copied to clipboard
Encoding and mailbox attrs
This is a "small" yet useful PR, with several features:
- Allow for complex, custom IMAP queries using new
custom_query
parameter - Store mailbox attributes. This is better for i18n, since "All Mail" only exists on english GMail (and the only way to retrieve the "all mail" name is to look for "\All" in the attributes)
- Parse
from
andto
headers (quoted printable content) - Encode
body
andtext
from mail_encoding to unicode
Sorry, should have broken this into several smaller PR.
EDIT: this has grown of its own to handle all special cases i kept seeing. This may not be good to merge now. The choice is yours.