Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #94591

Re: Gmail eats Python

From Jussi Piitulainen <jpiitula@ling.helsinki.fi>
Newsgroups comp.lang.python
Subject Re: Gmail eats Python
Date 2015-07-26 08:01 +0300
Organization A noiseless patient Spider
Message-ID <lf5egjvecmi.fsf@ling.helsinki.fi> (permalink)
References <201507251634.t6PGYUvo028820@fido.openend.se> <mailman.984.1437843118.3674.python-list@python.org> <lf5oaj0ku2h.fsf@ling.helsinki.fi> <87d1zgyqgb.fsf@elektro.pacujo.net>

Show all headers | View raw


Marko Rauhamaa writes:

> Jussi Piitulainen writes:

>> 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.

> The gnus command
>
>    C-u g
>
> displays the raw message.

Thanks! I was just typing t to see what I thought were the full headers.

> It demonstrates that the posting was sent as
>
>    Content-Type: multipart/alternative; boundary=001a1134d474c99321051bb5ef45
>
> The first part has:
>
>    Content-Type: text/plain; charset=UTF-8
>
> The second part has:
>
>    Content-Type: text/html; charset=UTF-8
>    Content-Transfer-Encoding: quoted-printable

Yes, with C-u g, I see them.

> The text/plain variant expresses the indentations with plain
> whitespace (SPC) characters. However, the text/html variant has:
>
>    <p dir=3D"ltr">=C2=A0=C2=A0 &gt;&gt;&gt; def test(): pass<br>
>    =C2=A0=C2=A0 ... <br>
>    =C2=A0=C2=A0 &gt;&gt;&gt; print(&#39;Hi world&#39;)<br>
>    =C2=A0=C2=A0 Hi world<br>
>    =C2=A0=C2=A0 &gt;&gt;&gt;</p>
>
> =C2=A0 stands for '\u00a0' (NO-BREAK SPACE).

I suppose that's a valid HTML fragment when the charset is declared, but
the Gnus version I use fails to use the charset information when it
renders the message. Annoying that it chooses text/html over text/plain
and then fails. (Probably I can customize it now that I have a precise
idea of what it is that is going wrong.)

> When I have Gnus display the HTML variant, the indentation is not
> displayed at all. I don't know why.

So many ways to fail :)

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: Gmail eats Python Jussi Piitulainen <jpiitula@ling.helsinki.fi> - 2015-07-25 20:47 +0300
  Re: Gmail eats Python Jussi Piitulainen <jpiitula@ling.helsinki.fi> - 2015-07-25 20:52 +0300
    Re: Gmail eats Python Laura Creighton <lac@openend.se> - 2015-07-25 20:05 +0200
      Re: Gmail eats Python Jussi Piitulainen <jpiitula@ling.helsinki.fi> - 2015-07-26 08:26 +0300
  Re: Gmail eats Python Jon Ribbens <jon+usenet@unequivocal.co.uk> - 2015-07-25 18:44 +0000
  Re: Gmail eats Python Marko Rauhamaa <marko@pacujo.net> - 2015-07-25 22:42 +0300
    Re: Gmail eats Python Ben Finney <ben+python@benfinney.id.au> - 2015-07-26 10:52 +1000
    Re: Gmail eats Python Chris Angelico <rosuav@gmail.com> - 2015-07-26 10:58 +1000
    Re: Gmail eats Python Jussi Piitulainen <jpiitula@ling.helsinki.fi> - 2015-07-26 08:01 +0300
      Re: Gmail eats Python Rustom Mody <rustompmody@gmail.com> - 2015-07-25 22:28 -0700
        Re: Gmail eats Python Chris Angelico <rosuav@gmail.com> - 2015-07-26 15:34 +1000
          Re: Gmail eats Python Rustom Mody <rustompmody@gmail.com> - 2015-07-25 23:15 -0700
            Re: Gmail eats Python Chris Angelico <rosuav@gmail.com> - 2015-07-26 16:25 +1000
              Re: Gmail eats Python Marko Rauhamaa <marko@pacujo.net> - 2015-07-26 09:55 +0300
                Re: Gmail eats Python Rustom Mody <rustompmody@gmail.com> - 2015-07-26 01:20 -0700
                Re: Gmail eats Python Marko Rauhamaa <marko@pacujo.net> - 2015-07-26 11:35 +0300
                Re: Gmail eats Python Rustom Mody <rustompmody@gmail.com> - 2015-07-26 01:50 -0700
                Re: Gmail eats Python alister <alister.nospam.ware@ntlworld.com> - 2015-07-26 09:21 +0000
                Re: Gmail eats Python Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-07-26 12:27 +0100
                Re: Gmail eats Python Marko Rauhamaa <marko@pacujo.net> - 2015-07-26 12:51 +0300
                Re: Gmail eats Python Chris Angelico <rosuav@gmail.com> - 2015-07-26 20:03 +1000
                Re: Gmail eats Python Marko Rauhamaa <marko@pacujo.net> - 2015-07-26 13:31 +0300
                Re: Gmail eats Python Jussi Piitulainen <jpiitula@ling.helsinki.fi> - 2015-07-26 14:30 +0300
                Re: Gmail eats Python Marko Rauhamaa <marko@pacujo.net> - 2015-07-26 14:48 +0300
                Re: Gmail eats Python random832@fastmail.us - 2015-07-29 10:51 -0400
                Re: Gmail eats Python Larry Martell <larry.martell@gmail.com> - 2015-07-29 10:53 -0400
                Re: Gmail eats Python Jussi Piitulainen <jpiitula@ling.helsinki.fi> - 2015-07-26 13:43 +0300
                Re: Gmail eats Python Rustom Mody <rustompmody@gmail.com> - 2015-07-26 06:16 -0700
                Re: Gmail eats Python Rustom Mody <rustompmody@gmail.com> - 2015-07-28 20:35 -0700
                Re: Gmail eats Python Laura Creighton <lac@openend.se> - 2015-07-29 18:32 +0200
              Re: Gmail eats Python Grant Edwards <invalid@invalid.invalid> - 2015-07-26 15:42 +0000
            Re: Gmail eats Python Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-07-26 12:25 +0100
        Re: Gmail eats Python Grant Edwards <invalid@invalid.invalid> - 2015-07-26 15:47 +0000
          Re: Gmail eats Python Rustom Mody <rustompmody@gmail.com> - 2015-07-26 08:59 -0700
            Re: Gmail eats Python Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-07-26 18:21 +0100
            Re: Gmail eats Python Steven D'Aprano <steve@pearwood.info> - 2015-07-27 03:40 +1000
              Re: Gmail eats Python Rustom Mody <rustompmody@gmail.com> - 2015-07-26 14:34 -0700
              Re: Gmail eats Python Chris Angelico <rosuav@gmail.com> - 2015-07-27 11:47 +1000
            Re: Gmail eats Python Grant Edwards <invalid@invalid.invalid> - 2015-07-26 19:45 +0000
              Re: Gmail eats Python Rustom Mody <rustompmody@gmail.com> - 2015-07-26 14:54 -0700
  Re: Gmail eats Python Steven D'Aprano <steve@pearwood.info> - 2015-07-26 14:49 +1000
    Re: Gmail eats Python Jussi Piitulainen <jpiitula@ling.helsinki.fi> - 2015-07-26 08:37 +0300

csiph-web