[SUSPICIOUS MESSAGE] Re: Cult-like behaviour [was Re: Kindness]

Antoon Pardon antoon.pardon at vub.be
Mon Jul 16 08:12:06 EDT 2018


On 15-07-18 09:33, Marko Rauhamaa wrote:
> Paul Rubin <no.email at nospam.invalid>:
>> Py3's unicode picture is described here and it isn't pretty:
>> http://secure-web.cisco.com/1IcToGhkZqGKNSVqMv5ljEo0GVPh0uuAPgKzSBMCkoNElVbHgu4uHpyfdyIj8PrqISD2JssJJnw1yWSFp13DBGOiCdp_Mk9wI4ph_RJ63PeRB_HErunPFzgNvsDR5SDgVe66MmpAG7A4O1NO-NKKjf_5KwnmaAxd5FK89NvKf06tU6H_UmjMt8uYj4487Hc4WDmMhewkSSC86Bu6Eh9Ga_yuzYAMuTpiEftZb30M3pMdyhhTCVGK0KGz4kGPFkgGhaN2hGrNfjYZTdo-CUDcWPw/http%3A%2F%2Flucumr.pocoo.org%2F2014%2F5%2F12%2Feverything-about-unicode%2F
> From the link:
>
>    The much more likely thing to happen is that people stick to Python 2
>    or build broken stuff on Python 3. Or they go with Go. Which uses an
>    even simpler model than Python 2: everything is a byte string. The
>    assumed encoding is UTF-8. End of the story.
>
> I have similar feelings, except that I'm not convinced Go is the answer.

I really don't understand why the author of that article didn't just copy
his python2 program but used sys.stdin.buffer and sys.sydout.buffer instead
of plain sys.stdin and stdout.

AFAIU that would have worked like he wanted to, since it would have copied
bytes just as he wanted to. I have searched for an explanation for why
that wouldn't have worked and didn't find it.

-- 
Antoon.




More information about the Python-list mailing list