Gmail eats Python

Steven D'Aprano steve at
Sun Jul 26 06:49:54 CEST 2015

On Sun, 26 Jul 2015 03:47 am, Jussi Piitulainen wrote:

> Just in case anyone cares, Gnus shows me those indentations as octal
> codes, \302\240\302\240 (followed by one ASCII space). I guess a
> \302\240 is a NO-BREAK SPACE in UTF-8, and I guess Gnus does not know
> this because there is no charset specification in the headers. That
> seems to be missing whenever I see these codes instead of properly
> rendered characters and bother to check the headers.

Some of us care :-)

Zachary's post that you are referring to does have the charset declared, but
it uses individual declarations for each of the multipart/alternative

Content-Type: text/plain; charset=UTF-8

Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

On the other hand, your post sent from Gnus is lying. Despite containing
non-ASCII bytes (i.e. octal \302\240), it sends these headers:

Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 8bit

US-ASCII is 7-bit only and only defines values for ord \0 through \177 in


More information about the Python-list mailing list