Will Python 3.x ever become the actual standard?

Chris Angelico rosuav at gmail.com
Thu Oct 24 02:46:32 EDT 2013


On Thu, Oct 24, 2013 at 3:57 PM, Peter Cacioppi
<peter.cacioppi at gmail.com> wrote:
> Moreover, you get a lot of the good stuff with 2.7. Along with more library support. So the smart decision is to code your project 2.7, even though the best thing for Pythonistan would be for us all to voluntarily migrate to 3.x.

I won't flame you, but I will disagree with you :)

You may get "a lot of" the good stuff with 2.7, but there are plenty
of things you won't get - and the gap will widen with every Python
release. As of 3.3, you're missing out on, among other things:

* PEP 393 strings - high performance and perfect Unicode handling
* 'yield from'
* Major improvements to 'import'
* High performance 'decimal'

When 3.4 comes out, add to the list:

* enumerations
* asyncio
* Argument Clinic (introspection)

When 3.5 comes out, your 2.7 program will additionally be unable to use:

* Who knows?
* But it'll be exciting.

If you insist on not moving to 3.x, I strongly recommend some future
imports - unicode_literals, division, print_function - to make your
2.7 program behave more like a 3.x one. That'll ease the pain of
transition, though you'll still probably run into problems with
unicode vs bytes in places where your code used to be oblivious...
which means your code will become guaranteed-correct when you move to
3.x, where the 2.7 version was merely accidentally-correct.

ChrisA



More information about the Python-list mailing list