[Python-ideas] Py3 unicode impositions

Nick Coghlan ncoghlan at gmail.com
Sun Feb 12 07:01:42 CET 2012


On Sun, Feb 12, 2012 at 3:26 PM, Steven D'Aprano <steve at pearwood.info> wrote:
> I'm not entirely happy with the surrogateescape solution, but I can see it's
> possibly the least worst *simple* solution for the case where you don't know
> the source encoding. (Encoding guessing heuristics are awesome but hardly
> simple.) So put the recipe in the FAQs, in the docs, and the docstring for
> open[1], and let people copy and paste the recipe. That's a pretty gentle
> introduction to Unicode.

Yeah, it didn't take long for me to come back around to that point of
view, so I morphed http://bugs.python.org/issue13997 into a docs bug
about clearly articulating the absolute bare minimum knowledge of
Unicode needed to process text in a robust cross-platform manner in
Python 3 instead.

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia



More information about the Python-ideas mailing list