top | item 18956574

NumPy 1.16 is the last release to support Python 2.7

240 points| htfy96 | 7 years ago |github.com

109 comments

order
[+] lykr0n|7 years ago|reply
Just rip the band-aid off. Some of the async stuff in Python 3 is awesome.

A bit curious that 3.4 has been dropped, as that's the stock Python 3 shipped for CentOS 7.

[+] kalefranz|7 years ago|reply
I generally try to leave the system python alone. Use pyenv or conda to get the python interpreters for your own code and apps.
[+] mrosett|7 years ago|reply
The code I've written recently relies heavily on async and data classes, both of which are recent additions. I can't imagine choosing Python 2 at this point.
[+] emddudley|7 years ago|reply
> the stock Python 3 shipped for CentOS 7.

What package are you referring to? As I understand it there is no "stock" Python 3 in CentOS 7. There is just what you can get from secondary repos, like EPEL, SCL, and IUS. Those repos now have 3.6 available.

[+] beagle3|7 years ago|reply
If you need the new numpy, get a new python. Conda makes that painless, but whichever way you get numpy, python itself is easier to build/install.
[+] coldtea|7 years ago|reply
>Just rip the band-aid off. Some of the async stuff in Python 3 is awesome.

Will that awesome async stuff help us migrate several 100s of thousands of lines of 2.7 code?

[+] blattimwind|7 years ago|reply
3.4 will reach EOL very soon.
[+] nurettin|7 years ago|reply
async stuff is a bit suspicious to me. I use an async web server to command an async websocket client and sometimes you get hard to debug problems like throwing an exception in one library causing the other to stop working. That's never happened to me in node.
[+] gammateam|7 years ago|reply
Debian also does not have anything above python 3.4 on the stable packages branch

3.6 has been dev and test since 2016

[+] anonymousCar|7 years ago|reply
When can we start calling Python 2.7 legacy code?
[+] ggm|7 years ago|reply
Now.

seriously. I think we have to treat it as legacy code now.

[+] mr_toad|7 years ago|reply
2009.

Seriously, it’s been 10 years since Python 3 came out, Python 2.x has been supporting legacy code since then.

[+] gnulinux|7 years ago|reply
EDIT: My comment is grossly misunderstood and I cannot delete my comment. I did not imply python 3 causes bad code, I was trying to tell a story about how "our" python 2 code is handsome and python 3 code is ugly; sorta implying python2 is not necessarily legacy code. I have absolutely no problem with python 3 and prefer it over python 2. I do not want to start a 2 vs 3 flamewar please just ignore this comment.

===

My company has >1 million line of python 2.7. About 1.5 year ago we managed to pass our test harness (about 80% line coverage) in python 3. At the moment we can't do that but we believe if we tried hard for a few weeks we can do it again too. I don't know how we define "legacy code" but I code in this codebase everyday and the code is actually very pretty and understandable. We also have a python 3 project (only a few thousand line of code) and god that code is definitely ugly as shit. Even after python2 goes unmaintained, I will still think our python3 code looks more like legacy.

[+] sbrother|7 years ago|reply
The only thing keeping me on Python 2.7 is Apache Beam, but it's becoming increasingly painful and I'm close to just using a different technology rather than deal with making all my code py2 compatible in 2019...
[+] MichaelMoser123|7 years ago|reply
Right now I don't think that python2.7 is very well supported in 1.16. Had to build a docker the other day that uses python2.7 and while building the docker it got numpy 1.16 from the pip mirror. Now import of numpy failed so that I had to revert to the previous version of numpy.
[+] oriol11|7 years ago|reply
"Numpy 1.16 is good enough" - Me in 2029
[+] tinus_hn|7 years ago|reply
Clinging on to the past for dear life..