[Python-Dev] Internal representation of strings and Micropython

Nick Coghlan ncoghlan at gmail.com
Fri Jun 6 01:36:09 CEST 2014


On 6 Jun 2014 05:13, "Glenn Linderman" <v+python at g.nevcal.com> wrote:
>
> On 6/5/2014 11:41 AM, Daniel Holth wrote:
>>
>> discover new things
>> like dance-encoded strings, bytes decoded using an incorrect encoding
>> intended to be transcoded into the correct encoding later, surrogates
>> that work perfectly until .encode(), str(bytes), APIs that disagree
>> with you about whether the result should be str or bytes, APIs that
>> return either string or bytes depending on their initializers and so
>> on. Unicode can still be complicated in Python 3 independent of any
>> judgement about whether it is worse, better, or different than Python
>> 2.
>
> Yes, people can find ways to write bad code in any language.

Note that several of the issues Daniel mentions here are due to the lack of
reliable encoding settings on Linux and the challenges of the Py2->3
migration, rather than users writing bad code. Several of them represent
bugs to be fixed or serve as indicators of missing features that would make
it easier to work around an imperfect world.

Cheers,
Nick.

>
> _______________________________________________
> Python-Dev mailing list
> Python-Dev at python.org
> https://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe:
https://mail.python.org/mailman/options/python-dev/ncoghlan%40gmail.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20140606/8e5e0c4f/attachment.html>


More information about the Python-Dev mailing list