"Python 3 is unarguably a better language than Python 2."
I would say that's unarguably marginally better. What provides Python 3 that I miss in Python 2? For me nothing at all. Ok, dealing with Unicode it's easier. So what? Optional type annotations, that's something I would miss.
Unarguably marginally better is still unarguably better.
Set and dict comprehensions are pretty rad. Ordered dicts are useful. The new unittest module is great.
Of course, all of these have been back-ported to 2.7, but even if they hadn't, Python 2 is still a very capable language. Don't have dict comprehensions? Well, you can build an equivalent loop without too much difficulty, and you're used to doing that.
So there's not a great value proposition when it comes to moving from Python 2 to Python 3. You're used to working around the warts, and the workarounds aren't that painful. But what about going from 3 to 2? Once you're used to range() being efficient, to dict comprehensions, to a cleaned up stdlib, and to sane Unicode handling? You won't be crippled, but I'm fairly certain you won't find it quite as pleasant.
I believe that's the measure that matters, in the long run. Would the old thing feel worse than the new thing, from the perspective of the new thing? If the answer is, to any degree, unambiguously "yes," then it only makes sense to plan on making that move.
Python3 core has a better design: strict separation between bytes and characters, no more short integer type, no more
old style class, etc. The stdlib is there. The rocky bits are being fixed all the time. The other important modules all have strong development communities.
Upstream numpy works with Python 3 already. PyGObject is also working on Py3 support.
The point is python2.7 is the last 2.x version. It will be supported, bugs will be fixed but no new feature will be added. Core devs will concentrate on python 3.x. You can still use 2.x, no one is stopping you. But assume that it is stagnant now. After some time only security related bugs will be fixed. Sooner or later you will have to switch.
What you will miss is 3rd party libraries. Some like numpy are ported, but many like mechanize needs to be ported. Google App Engine doesn't yet work on Python3. Not many hosting providers have Python3 as option.
However, i must agree that many of the points people bring up for not switching to Python3 are real. People ARE stuck in limbo right now and there is no good direction to go... Stick with 2.x and have all the 3rd party support but soon enough you will need to do a major bug fixing, or move to 3.x -- oh wait i can't move to 3.x because module xxyy is not 3.x compatible!
Is there really a limbo though or is that just a perception? I am starting to learn Python. I am learning Python 3. I believe that close to 95% (or maybe more) of the skills I am learning still apply to Python 2. The move to Python 3 will come. It was a 5 year plan of which we are half way there. Chillax. Really.
A lot of the more visible features from 3 have been added into new versions of 2.x. Off the top of my head, dictionary comprehensions and new set literals are two nice ones.
Comments
"Python 3 is unarguably a better language than Python 2."
I would say that's unarguably marginally better. What provides Python 3 that I miss in Python 2? For me nothing at all. Ok, dealing with Unicode it's easier. So what? Optional type annotations, that's something I would miss.
Unarguably marginally better is still unarguably better.
Set and dict comprehensions are pretty rad. Ordered dicts are useful. The new unittest module is great.
Of course, all of these have been back-ported to 2.7, but even if they hadn't, Python 2 is still a very capable language. Don't have dict comprehensions? Well, you can build an equivalent loop without too much difficulty, and you're used to doing that.
So there's not a great value proposition when it comes to moving from Python 2 to Python 3. You're used to working around the warts, and the workarounds aren't that painful. But what about going from 3 to 2? Once you're used to range() being efficient, to dict comprehensions, to a cleaned up stdlib, and to sane Unicode handling? You won't be crippled, but I'm fairly certain you won't find it quite as pleasant.
I believe that's the measure that matters, in the long run. Would the old thing feel worse than the new thing, from the perspective of the new thing? If the answer is, to any degree, unambiguously "yes," then it only makes sense to plan on making that move.
> Well, you can build an equivalent loop without too much difficulty, and you're used to doing that.
You can build an equivalent list or generator comprehension (just generate tuples and feed that to `dict`). It's just ugly.
I believe that was the OP's point.
Python3 core has a better design: strict separation between bytes and characters, no more short integer type, no more old style class, etc. The stdlib is there. The rocky bits are being fixed all the time. The other important modules all have strong development communities. Upstream numpy works with Python 3 already. PyGObject is also working on Py3 support.
The point is python2.7 is the last 2.x version. It will be supported, bugs will be fixed but no new feature will be added. Core devs will concentrate on python 3.x. You can still use 2.x, no one is stopping you. But assume that it is stagnant now. After some time only security related bugs will be fixed. Sooner or later you will have to switch.
What you will miss is 3rd party libraries. Some like numpy are ported, but many like mechanize needs to be ported. Google App Engine doesn't yet work on Python3. Not many hosting providers have Python3 as option.
However, i must agree that many of the points people bring up for not switching to Python3 are real. People ARE stuck in limbo right now and there is no good direction to go... Stick with 2.x and have all the 3rd party support but soon enough you will need to do a major bug fixing, or move to 3.x -- oh wait i can't move to 3.x because module xxyy is not 3.x compatible!
Is there really a limbo though or is that just a perception? I am starting to learn Python. I am learning Python 3. I believe that close to 95% (or maybe more) of the skills I am learning still apply to Python 2. The move to Python 3 will come. It was a 5 year plan of which we are half way there. Chillax. Really.
Great that you are learning Python 3. :)
The issue is if you need to write something you may need 3rd party library and few great ones are not available for Python3. It kind of cripples you.
A lot of the more visible features from 3 have been added into new versions of 2.x. Off the top of my head, dictionary comprehensions and new set literals are two nice ones.