3 ms·
Open source developers work on what they like to do. Guido was the primary developer of asyncio, funded by dropbox, as I understand. The asyncio library depen
by nas 11y ago
Open source developers work on what they like to do. Guido was the primary developer of asyncio, funded by dropbox, as I understand. The asyncio library depends on some Python 3 features that other developers have implemented. I believe there is some kind of 2.7 backport of asyncio. No one is stopping development but the core Python team is not interested in releasing new versions of the 2.x line.
The gap has been getting smaller. Python 3.5 will include %-style formatting for byte strings. I helped implement that feature since I feel it will make porting code easier (plus it makes some programming tasks, like network protocols, easier). The strict handling of bytes/unicode is what really trips up people from porting and there is just no good way to further smooth that path, IMHO.
I feel the upgrade path has been handled badly. People were wildly optimistic about how fast people could port code and much more effort should have been spent on making the transition easier. A little too much purity instead of practicality. For example, u'foo' style strings were not accepted until Python 3.3. That just made porting more difficult for great reason.
Given the massive amount of Python 2.x code in the world, I fully expect that version to live much longer than most people expect. There is still old Fortran and Cobol code out there for example. Businesses don't want to rewrite a working system. Someone is going to keep making releases of the 2.x branch. Maybe it will be a fork.
At this point, I'd bet money on Python 3 succeeding. The vast majority of users still use 2.7 but there is steady progress of porting. The 3.x branch has received a lot of new and useful improvements and that is where all the development is happening. The memory savings from the new string representation will help my projects a lot. As I said elsewhere, asyncio is really sweet. The core team needs to keep the improvements coming. More carrots and less sticks, IMHO.
- deleted 11y ago[deleted]
- shadowmint 11y agoThis. A lot of new python programmers learn python3 first, and are extremely hostile to people using python2. It doesn't help at all. If you love python3, the best thing you can do is help make it more awesome! Shouting at people using python2 or telling them to 'deal with it' makes you look like a jerk. Don't be a jerk, it's bad karma.
- xorcist 11y agoBut it is not old code that is somehow stuck with Python 2. Lots of new code is written with Python 2 every day. It wouldn't surprise me if there were more lines of Python 2 than Python 3 produced today. With many important code bases such as Ansible and Django you still need to keep a Python 2 around. (Yes, I know Django works on 3, but less people use it and performance is slightly lower.) So you are dual stacked for the forseeable future if you choose the Python 3 route. So the Python ecosystem is a little more complicated than "old" Python 2 code versus "new" Python 3 code. Should I put my consultant hat on I would still advise people to start new developments with Python 2, but to keep an eye out for future compatibility issues. That recommendation hasn't changed in five years.
- mherrmann 11y agoYou're probably right that more lines of Python 2 are written today than are Python 3. But I bet it's like that for virtually every latest version of a programming language today. Python 2 will be kept around until 2020. Obviously there will still be companies using it after that date. But they have been given ample notice. I use Django with Python 3 and it's great. Admittedly, I don't need a lot of performance though. I really like Python 3 mainly for its more explicit treatment of Unicode. I believe the only way for Python to remain a success is if the community adopts Python 3 and puts in the effort to migrate away from 2. Once the community is there, organizations will follow.