python-oauth2 icon indicating copy to clipboard operation
python-oauth2 copied to clipboard

IMAP4_SSL.authenticate() wrapper should return (status, data)

Open kkurian opened this issue 13 years ago • 0 comments

in clients/imap.py:

    imaplib.IMAP4_SSL.authenticate(self, 'XOAUTH',
        lambda x: oauth2.build_xoauth_string(url, consumer, token))

should read:

    return imaplib.IMAP4_SSL.authenticate(self, 'XOAUTH',
        lambda x: oauth2.build_xoauth_string(url, consumer, token))

Without this change the oauth2 IMAP4_SSL.authenticate() method does not mimic the return behavior of its imaplib counterpart and, what's worse, the return values from imaplib are lost.

kkurian avatar Dec 11 '11 17:12 kkurian