Hacker News new | past | comments | ask | show | jobs | submit login

Practically speaking, if you want to leverage a lot of those libraries/frameworks you mentioned, 2.x is the way to go. However, the major syntactical and core differences that break backwards compatibility in Python 3000 (http://docs.python.org/3.0/whatsnew/3.0.html, http://docs.python.org/3.1/whatsnew/3.1.html) should be in the back of the your mind.

After working in a bit of py3k, I've found that "small things" such as using print() as a function rather than a statement comes more naturally than in Python 2.x, mostly because the latter doesn't complain about it.

Other things like xrange()'s departure in py3k as range() becomes a true iterator -- that's something you'll have to be cognizant of.

My advice is if you want to get a large project done, with support from popular and existing frameworks, go with the 2.x branch. If you're whipping up some disposable scripts, practice with py3k. And even if you're not, fire up py3k anyway.

One of the great Google Summer of Code projects this year is the inverse to the 2to3 tool -- 3to2 -- with the forward-thinking intention of making it easier to maintain one branch of code in py3k. It isn't a magic bullet by any means, but should definitely encourage the transition from Python 2.x to 3000.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: