r/Python • u/YouNorker • May 14 '13
It's time to migrate to Python 3.x guys, seriously.
Enough of this "I'm still waiting for Python 3 to be good." It is good. Use a migration tool and upgrade to 3.3 (as of 2013)
10
u/retrojoe May 14 '13
Why are you advocating this now? As opposed to a month ago or a year from now?
2
u/moor-GAYZ May 15 '13
Look at his userpage, it answers that question in the most definitive manner.
2
u/retrojoe May 15 '13
Are you implying that stoners prefer Python 3 to earlier versions? Is it b/c it's a higher version?
1
u/moor-GAYZ May 15 '13
More like, switching to Python 3 is one of those ideas that seem absolutely brilliant while you're high ;)
10
u/ketralnis May 15 '13
Yeah, how dare all those people have different real-life requirements than you? The nerve!
25
u/PCBEEF May 15 '13
Stop telling people to migrate. You make it sound like it's so easy. It isn't. I maintain a 10 year old python application and only just recently moved to Python 2.7 from 2.4. Migrating isn't easy and extremely expensive.
Instead you should encourage people to start using python 3 for new projects and pressuring people to update their tutorials to be targeted at python 3.
6
May 15 '13
This. Legacy apps are legacy apps and it's useless to try and push them forward without a valid reason from the proprietor. Instead we need to ensure everything new in Python is built on 3x. Let's focus on making 2x look like a legacy-strapped ancestor of the "real" Python.
8
u/maryjayjay May 15 '13
I write sysadmin tools. When the distros port their tools and ship with 3, I'll be able to switch.
5
u/the_hoser May 15 '13
Exactly. When RHEL comes with Python 3, I'll be migrating to Python 3.
1
u/xiongchiamiov Site Reliability Engineer May 15 '13
3.1 is in EPEL.
1
u/the_hoser May 15 '13
EPEL isn't supported by Red Hat. There's no SLA for these packages. Might as well be the source tarball.
1
u/xiongchiamiov Site Reliability Engineer May 21 '13
This is true, but a big part of using a distro that freezes such old software is upgrading components that are important to you (and taking the associated maintenance responsibility). I'm not suggesting you haphazardly install these (particularly if you're serious enough to get a support contract from Red Hat), but it's easier to get the EPEL rpm than to do it yourself.
1
u/the_hoser May 21 '13
Right, but we do have a support contract from RedHat. Thousands of boxes. Writing python in an "enterprise" (I hate that word) environment means writing Python 2.
3
u/zynix Cpt. Code Monkey & Internet of tomorrow May 15 '13
Eh this has been on par with PHP's transition from 4 to 5 ( granted 5.0 was significantly more improved than early Python 2 -> 3.0 was ).
It's going to be a last man standing for a few extremely complex and or large projects ( OpenStack ) but eventually Python 3 will take over.
For me I think the transition plan will be to go from cpython to PyPy ( it's looking pretty good these days ).
5
u/ameoba May 15 '13
The difference being that PHP 4 was shit. Python 2 was a solid, usable language. Even if Python 3 is better, there's nothing fundamentally wrong with 2.
...and it still took forever for PHP 4 to get dropped after it was officially unsupported.
4
u/zynix Cpt. Code Monkey & Internet of tomorrow May 15 '13
PHP 4 was shit.
I was trying to stay positive, but taking that into consideration, Py2 is likely going to be a around for just a "tad".
3
u/billsil May 15 '13
Use a migration tool
For the real problems, they don't work
I have to support 2.7-3.3. There's no good way to support every version.
3
u/servercobra May 15 '13
Fabric, MySQL-python, South, nltk, boto, paramiko, sentry, django-debug-toolbar, django-social-auth.
9 packages I used in my last project, all of which don't support Python 3 (according to Python Wall of Shame). The first 3 are extremely useful and I wind up using them in almost every project. So nope, I'm waiting for Python 3 support.
5
2
May 15 '13
Maintain dozen of codebases, all deployed in different environments with dozens of python and c library dependencies which are not python 3 compatible... And then tell me why not.
2
u/m1ss1ontomars2k4 May 15 '13
No python-ldap, no upgrade. It can't be migrated automatically because it's partly in C.
3
May 15 '13
Comments like this just make it obvious that technology decisions are made based on popularity, trendiness, and peer pressure, not the actual merits.
All of the real improvements in Python 3 could have been added to Python 2. Everything else is just differently bad.
0
u/cwillu May 15 '13
Downvoted in the hopes that pressure from your peers will cause you to reconsider the importance the tracking the trends of popularity.
0
2
u/the_hoser May 15 '13
The platforms I write for still don't come with it, and getting IT to install another interpreter is like pulling teeth. I'm stuck with 2.7.3 for the forseeable future.
1
u/luckystarr at 0x7fe670a7d080 May 15 '13
OpenCV doesn't support 3 yet. But 2.7 is awesome enough for now. I'm very happy that I no longer have to use 2.4 or even 2.3!
-5
0
u/erisson May 15 '13
I started with Python 1.4, made money writing Python until 2.something, how do I migrate my brain? Is there a tutorial called "Python 3 for Python 1.5.2 addicts" ?
2
0
u/mithrandi May 15 '13
I'm going to phrase this slightly differently to the other responses.
What feature or features in Python 3.x are worth the cost of porting all of my code, and all of my dependencies, and all of my dependencies' dependencies, and all of my dependencies' dependencies' dependencies to Python 3.x?
39
u/rrrnerdrrr May 14 '13
Its not the language its the libraries... I would upgrade in a minute if I could but I have too many critical apps that depend on them...