When should Python 3.3 become the default?

Scott Kitterman ubuntu at kitterman.com
Thu Oct 18 21:35:13 UTC 2012

On Thursday, October 18, 2012 05:04:35 PM Barry Warsaw wrote:
> Since we're all raring to go now, this seems like a good time to ask for
> feedback on some Python 3 decisions for 13.04.  Yes, we have a UDS-R session
> on this[1] but I expect the archive will open before UDS, so it would be
> better to have some direction earlier if possible.  I've chatted briefly
> with Matthias and Scott K, but I don't want to accidentally misrepresent
> their opinions.  Instead, I'll express my own and let them follow up. 
> Please let us know what you think.
> Some quick background: Python 3.2 is the default in 12.10.  Python 3.3 is
> available but it is not a supported version, which effectively means that
> pure-Python packages installed for 3.2 should be importable[2] in 3.3, but
> no extension modules are built.  So for example, `import gi.repository`
> will fail in 3.3 on 12.10.
> Continuing on discussions we've had at previous UDSes, and looking ahead to
> the probably schedule for Python 3.4, it is almost certain that we'll carry
> Python 3.3 as the default Python 3 for the next LTS (14.04).  Whether we'll
> also have Python 3.2 or 3.4 in 14.04 LTS is an open question we don't need
> to decide right now.
> Clearly we're going to enable Python 3.3 as a supported Python 3 version
> when the 'raring' archive opens up.  The question is whether 3.3 should be
> the default Python 3 as soon as the archive opens, or whether we should
> keep 3.2 as the default, enable 3.3, and watch for any fallout before
> making the switch later in the 13.04 cycle.
> There are good arguments on both sides, and I can probably convince myself
> to be either aggressive or conservative.  One of my biggest concerns
> against switching early is that we still have a lot of code that needs to
> be ported to Python 3 (any version)[3].  If fixing problems related to
> Python 3.3 significantly detracts from the porting effort, then it might be
> better to wait.  Then the question becomes, wait until what?
> I am slightly leaning toward switching early, so that we can begin to take
> advantage of some of features[4] of Python 3.3 that will benefit Ubuntu (and
> Debian of course).  Two big ones are PEP 420 (namespace packages) and PEP
> 393 (flexible string representations).  Others that could prove quite
> useful include: PEP 414 (reinstatement of explicit Unicode literals), PEP
> 405 (built-in virtual environments), PEP 417 (mock in the standard
> library), and PEP 3151 (Reworking the OS and IO exceptions).
> What do you think?
> Cheers,
> -Barry
> [1] https://blueprints.launchpad.net/ubuntu/+spec/foundations-r-python33
> [2] which is different than 'works' since of course the package itself must
> be compatible with Python 3.3
> [3] http://tinyurl.com/8rvx67m
> [4] http://python.org/dev/peps/pep-0398/

One further issue to consider is limited support for multiple python3 versions 
in dh_python3.  It has a hard coded default value to rewrite extensions for 
(python-qt4 needs this) to get the PEP whatevery it was binary file names with 
the version number encoded in them.  Any package depending on this will likely 
misbuild if we have more than one python3 supported.

Scott K

More information about the ubuntu-devel mailing list