3

Differences between revisions 5 and 43 (spanning 38 versions)
Revision 5 as of 2012-04-20 17:22:37
Size: 1991
Editor: mail
Comment:
Revision 43 as of 2016-02-26 01:40:43
Size: 3502
Editor: localhost
Comment: Note: this page is out of date. The latest info is on [[Python]].
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
= Out of Date =

This page is out of date. The latest info can be found on [[https://wiki.ubuntu.com/Python|the main Python page]].
Line 3: Line 7:
It is a release goal for Ubuntu 12.10 to have only Python 3 on the installation CD images. We have a [[https://blueprints.launchpad.net/ubuntu/+spec/foundations-q-python-versions|Q-series]] blueprint for discussion of this goal at [[http://uds.ubuntu.com/|UDS-Q]] in Oakland, California, in May of 2012. There is a [[https://wiki.ubuntu.com/Python/FoundationsQPythonVersions|more detailed spec]] for this effort and a publicly shared [[http://tinyurl.com/7dsyywo|Google docs spreadsheet]] to track this effort. This is an ambitious effort that will only succeed with help from the greater Ubuntu, Debian, and Python communities. In other words, we need '''you'''! For both Ubuntu and [[http://www.debian.org|Debian]], we have [[https://lists.debian.org/debian-python/2014/05/msg00037.html|ongoing]] [[https://lists.launchpad.net/ubuntu-phone/msg07934.html|project goals]] to make Python 3 the default, preferred Python version in the distros. This means:
Line 5: Line 9:
At the bottom of this page, you will find various resources for diving more into aspects of supporting Python 3, from the pure-Python, C extension module, Debian packaging, and other perspectives. The intent of ''this'' page is to provide specific guidelines in a quick reference format, so that you only need to go here once you're familiar with the basic concepts and approaches, but need a refresher on specific coding techniques. This is a wiki page, and you are encouraged to contribute, but try to keep your recommendations tightly focused on accomplishing the release goal of Python 3 only on the 12.10 CDs.  * Python 3 will be the only Python version installed by default.
 * Python 3 will be the only Python version in any installation media (i.e. image ISOs)
 * Only Python 3 will be allowed on the Ubuntu touch images.
 * All upstream libraries that support Python 3 will have their Python 3 version available in the archive.
 * All applications that run under Python 3 will use Python 3 by default.
 * All system scripts in the archive will use Python 3.
Line 7: Line 16:
== Resources == What this '''does not''' mean:
Line 9: Line 18:
 * [[http://wiki.debian.org/Python/LibraryStyleGuide|Debian Python packaging style guide (covers Python 2 and Python 3)]]
 * [[http://getpython3.com/|Python community portal to Python 3]]
 * [[http://python3porting.com/|in-depth Python 3 porting guide]]
 * [[http://python3wos.appspot.com/|Python 3 "Wall of Shame"]]
 * [[http://pypi.python.org/pypi?:action=browse&c=533&show=all|Cheeseshop packages explicitly claiming Python 3 support]]
 * [[http://wiki.python.org/moin/PortingPythonToPy3k|Python wiki porting guide (pure-Python)]]
 * [[http://wiki.python.org/moin/PortingExtensionModulesToPy3k|Python wiki porting guide (extension modules)]]
 
 * {{{/usr/bin/python}}} will point to Python 3. '''No, this is not going to happen''' (unless [[http://legacy.python.org/dev/peps/pep-0394/|PEP 394]] advocates otherwise, which is doubtful for the foreseeable future). {{{/usr/bin/python}}} and {{{/usr/bin/python2}}} will point to Python 2.7 and {{{/usr/bin/python3}}} will point to the latest supported Python 3 version.
 * Python 2 will be removed from the archive. '''No, this is not going to happen.''' We expect Python 2.7 to remain supported and available in Ubuntu for quite a long time, given that [[http://legacy.python.org/dev/peps/pep-0373/|PEP 373]] promises upstream bug fix maintenance support until 2020. It would be nice if we could demote Python 2 to universe, but that's currently problematic for technical reasons relating to multi-Python version support in Debian/Ubuntu.

== Status ==

At the time of this writing (2014-05-08), Ubuntu 14.04 LTS has recently been released. We made great progress toward these goals, but we must acknowledge that it is a daunting, multi-cycle process. A top goal for 14.04 was to remove Python 2 from the touch images, and sadly we ''almost'' but didn't quite make it. There were still a few [[https://launchpad.net/autopilot|autopilot]] tests for which the Python 3 ports did not land in time, thus keeping Python 2 autopilot support on the base touch image. This work is being completed for Utopic and we expect to remove Python 2 from the touch images early in the 14.10 cycle (actually, any day now).

On the desktop and server, we have this [[https://wiki.ubuntu.com/Python/FoundationsTPythonVersions|page]] tracking results. We're much closer on the server images than we are on the desktop. This [[https://blueprints.launchpad.net/ubuntu/+spec/core-1311-python3-roadmap|Trusty]] blueprint tracks work for the touch images. An [[http://people.canonical.com/~ubuntu-archive/transitions/onlypy3oncd.html|official transition tracker]] and a publicly shared [[http://tinyurl.com/kgx7hsc|Google docs spreadsheet]] to track this effort. (''Note: these documents likely need updating for the Utopic cycle.'') This is an ambitious effort that will only succeed with help from the greater Ubuntu, Debian, and Python communities. In other words, we need '''you'''!

We'll track Ubuntu (and some Debian) related tasks here. This page used to contain a lot of good quick references for porting to Python 3, but that information has now moved [[http://wiki.python.org/moin/PortingToPy3k/BilingualQuickRef|to wiki.python.org]].

Out of Date

This page is out of date. The latest info can be found on the main Python page.

Python 3 on Ubuntu

For both Ubuntu and Debian, we have ongoing project goals to make Python 3 the default, preferred Python version in the distros. This means:

  • Python 3 will be the only Python version installed by default.
  • Python 3 will be the only Python version in any installation media (i.e. image ISOs)
  • Only Python 3 will be allowed on the Ubuntu touch images.
  • All upstream libraries that support Python 3 will have their Python 3 version available in the archive.
  • All applications that run under Python 3 will use Python 3 by default.
  • All system scripts in the archive will use Python 3.

What this does not mean:

  • /usr/bin/python will point to Python 3. No, this is not going to happen (unless PEP 394 advocates otherwise, which is doubtful for the foreseeable future). /usr/bin/python and /usr/bin/python2 will point to Python 2.7 and /usr/bin/python3 will point to the latest supported Python 3 version.

  • Python 2 will be removed from the archive. No, this is not going to happen. We expect Python 2.7 to remain supported and available in Ubuntu for quite a long time, given that PEP 373 promises upstream bug fix maintenance support until 2020. It would be nice if we could demote Python 2 to universe, but that's currently problematic for technical reasons relating to multi-Python version support in Debian/Ubuntu.

Status

At the time of this writing (2014-05-08), Ubuntu 14.04 LTS has recently been released. We made great progress toward these goals, but we must acknowledge that it is a daunting, multi-cycle process. A top goal for 14.04 was to remove Python 2 from the touch images, and sadly we almost but didn't quite make it. There were still a few autopilot tests for which the Python 3 ports did not land in time, thus keeping Python 2 autopilot support on the base touch image. This work is being completed for Utopic and we expect to remove Python 2 from the touch images early in the 14.10 cycle (actually, any day now).

On the desktop and server, we have this page tracking results. We're much closer on the server images than we are on the desktop. This Trusty blueprint tracks work for the touch images. An official transition tracker and a publicly shared Google docs spreadsheet to track this effort. (Note: these documents likely need updating for the Utopic cycle.) This is an ambitious effort that will only succeed with help from the greater Ubuntu, Debian, and Python communities. In other words, we need you!

We'll track Ubuntu (and some Debian) related tasks here. This page used to contain a lot of good quick references for porting to Python 3, but that information has now moved to wiki.python.org.

Python/3 (last edited 2016-02-26 01:40:43 by localhost)