You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I'm connecting to GMail account on Python 3 and getting UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb3 in position 5: invalid start byte while trying to get messages via for uid, message in inbox.messages(unread=True):.
The value at hand is b'Zosta\xb3 w\xb3\xb1czony dost\xeap dla mniej bezpiecznych aplikacji'. and from what I can tell is encoded in ISO 8859-2 instead of UTF-8.
Don't really know what to do here and what should be done in the code. Is there a way to make GMail 'give' us mails encoded with UTF-8? Should we maybe try a couple of encodings within str_decode?
I can do a PR after deciding what to do here.
Cheers,
Paweł
The text was updated successfully, but these errors were encountered:
Hi,
I'm connecting to GMail account on Python 3 and getting
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb3 in position 5: invalid start byte
while trying to get messages viafor uid, message in inbox.messages(unread=True):
.The value at hand is
b'Zosta\xb3 w\xb3\xb1czony dost\xeap dla mniej bezpiecznych aplikacji'.
and from what I can tell is encoded inISO 8859-2
instead ofUTF-8
.Don't really know what to do here and what should be done in the code. Is there a way to make GMail 'give' us mails encoded with
UTF-8
? Should we maybe try a couple of encodings withinstr_decode
?I can do a PR after deciding what to do here.
Cheers,
Paweł
The text was updated successfully, but these errors were encountered: