4 ms·
Why no python3 version? Django depending on other components which have not been ported to python3 yet and python3 being backward incompatible it takes time to
by teebot 15y ago
Why no python3 version?
Django depending on other components which have not been ported to python3 yet and python3 being backward incompatible it takes time to port them all of course.
But as python beginner, I want to start by learning python3 which was released on December 3rd, 2008
- ch0wn 15y agoAn experimental port of Django to Python 3 that passes all regression tests on Python 2.5 to 2.7 as well as Python 3.2 is available here: https://bitbucket.org/vinay.sajip/django/ https://bitbucket.org/vinay.sajip/django/
- asto 15y agoLearn on python 2.x. You don't want to start with a version that has fewer compatible packages.
- kibwen 15y agoI mostly concur with this sentiment. I jumped straight into Python 3, and the amount of incompatibility was almost frustrating enough to make me drop the language entirely. However, if you're stubborn enough to power through (and not afraid to roll up your sleeves and manually correct any errors you encounter (which is actually quite a good way to learn the nuances of a new language)) your reward is a language that is more forward-thinking and consistent. Sometimes it's worth the frustration (but only sometimes :) ).
- AUmrysh 15y agoYou want to use Python 2.X for now. There has been a lot of concern about the backwards compatibility between old libraries and the new python. Feel free to use 3.X, but don't expect a lot of the python libs that make it such a great language to hit the ground running in to work.
- reuser 15y agoYou are right. It isn't your job to learn on old versions of Python just so that Django does not have to release a port yet. Many projects have been waiting on other projects to port, thankfully the progress in library porting has picked up speed and the available library for Python 3 is very usable. And Python 3 actually is a reasonable decision for a beginner. It is more consistent and does a better job of exposing the 'right' way to do many things. Python 2 is reaching the end of its life and has little purpose except to support legacy libraries and apps and ease the transition. It is not the users of Python 3, but people insisting on using Python 2 to the EXCLUSION of Python 3, who are fragmenting Python
- jacobian 15y agoIt's available; see https://bitbucket.org/vinay.sajip/django/ https://bitbucket.org/vinay.sajip/django/. This is in "ready to merge" status, i.e. it's technically ready to the point we want to merge it into Django proper. I hope to do so soon, possibly as soon as next month at the PyCon sprints. However we decided not to merge this in for 1.4 for a couple of reasons: 1. As you might imagine, it's a big patch, and potentially destabilizing. Although it's in a good state now, it go there fairly late in the 1.4 cycle. If we'd merged it there wouldn't have been enough time to be sure we didn't break anything for 2.X users. So we held off the merge to make sure that 1.4 was as stable as possible. 2. The approach Vinay took (and the one we're sticking with) is a single-source approach. That is, a single source tree to support both Py2 and Py3, no 2to3 translation needed. The difficulty of this approach is directly proportional to how far back in the 2.X line you want to go. We promised that Django 1.4 would support Python 2.5, but single-source including 2.5 is a lot harder (and makes MUCH uglier code) than single-source for 2.6+. So we made the call to make the Py3 support depend on dropping support for 2.5, which we'll do for Django 1.5. So, all in all, time timing wasn't right for Py3 support in 1.4, but it is right for Django 1.5. Which is why I expect to see this branch merged shortly after the final 1.4 release.