Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

This will make some people to switch to other distributions, because in some cases making your software compatible with Python 3 is harder than changing distributions.


I don't think so because it is really easy to install Python 2 and have both versions installed.

I'm already doing that, the difference is that "python" for me is Python 2 and I have to run "python3" to use Python 3. Other than that, I can't see any problem. You can install packages for both versions, the distros usually add a number (ie. python-django, python3-django).


That will still be the case. As the proposal makes clear, this will make the system tools use Python3, but "python" (/usr/bin/python) will still point to python2.7


That may be so, but this is the sort of mentality that was responsible for IE6 being maintained after the release of IE8.

In the long run, switching to python3 will be better.


Why isn't installing Python 2 an option?


The system might use python for other task, making python 2. as default may bring issues. I remember that installing python 3 on a version of ubuntu an making a symbolic link /usr/bin/python to python3 wrecked apt and the updating system.


> making python 2. as default may bring issues.

Who's suggesting that you change the system default? If you want to make your python scripts run on a certain python version, set their shebang accordingly. Changing the default interpreter for system scripts because you want your scripts to run on a different version is crazy.

If your lamp is too bright, do you swap the transformer supplying the whole street's mains electricity supply for one with a different voltage and hope your neighbour's computer doesn't break, or do you turn your lamp down?


You can install both at the same time. "Default" here refers to what is installed by by default, and what the distro internal scripts are written in.

/usr/bin/python should remain symlinked to python2, and never python3: http://www.python.org/dev/peps/pep-0394/

But in any case, all scripts should reference the actual required version in the #! line.


The PEP actually says "recommended" and "for the time being" -- there's no mandate that it be done one way or another:

"For the time being, it is recommended that python should refer to python2 (however, some distributions have already chosen otherwise; see the Rationale and Migration Notes below)."


And this is why I cringe every time someone puts:

  #!/usr/bin/python
...at the top of their script instead of being specific like:

  #!/usr/bin/python2.6
Developers need to stop assuming that /usr/bin/python is a specific version!

As long as that's done, and the packaging is done right, there shouldn't be any major issues for the vast majority of programs.


Installing python 3 as default on current centos reportedly breaks yum.


<flamebait flavour="apt-get">Two birds, one stone?</flamebait>


On Arch, the only issue I run into is typing python2/pip2 vs python/pip. The transition was smooth and nothing broke for me.


Let those people go




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

Search: