Gentoo Archives: gentoo-dev

From: "Michał Górny" <mgorny@g.o>
To: gentoo-dev <gentoo-dev@l.g.o>
Cc: python <python@g.o>
Subject: [gentoo-dev] [RFC] Python 2.7 & PyPy 2.7
Date: Tue, 19 Nov 2019 14:30:40
Message-Id: 94ed9a2e16d2d42949cdf6dc0f9915624e099f12.camel@gentoo.org
1 Hi,
2
3 TL;DR: I'd like to propose starting to eliminate PyPy2.7 support
4 in packages soonish, and non-critical features for Python 2.7.
5
6
7 As you probably already know, Python 2.7 is going EOL by the end
8 of the year [1]. Upstream is planning to make one more security release
9 mid-April but that's it. I don't think we're going to remove
10 the interpreter itself anytime soon but...
11
12 A growing number of projects are dropping support for Python 2
13 and starting to be 3-only [2]. Of big influential packages this
14 includes IPython, pytest, sphinx, tox. The packages in the middle have
15 huge numbers of revdeps. Right now, their users are usually preventing
16 from downgrading due to py2 revdeps, and our work is becoming
17 increasingly harder.
18
19 Now, PyPy upstream is not planning to kill PyPy2.7 anytime soon [3].
20 However, it will still be affected by packages losing support
21 for Python 2, and given its compatibility problems existing already,
22 this will become even worse. PyPy3 is actually better in both regards.
23
24
25 All this considered, I'd like to propose the following:
26
27 1. We'd keep Python 2.7 and PyPy 2.7 interpreters for as long as we can
28 feasibly can. Even after the last upstream release, we should be able
29 to keep it as long as people supply patches to keep it working.
30
31 2. We'd start sunsetting PyPy 2.7 support in packages real soon. It's
32 quite a hassle already, due to its incompatibilities with CPython 2.7,
33 and we just don't have the manpower to keep supporting it. PyPy 3.*
34 target will continue being supported.
35
36 3. We'd start sunsetting Python 2.7 for non-critical features. For
37 example, packages using Sphinx to build documentation will slowly start
38 requiring Python 3.x to do that. This will make it possible for more
39 people to upgrade to newer package versions, without py2 revdeps holding
40 them back.
41
42 4. Once PyPy2.7 target is gone and more packages lose py2 support, we'd
43 remove Python 2.7 from default PYTHON_TARGETS. Py2-only packages will
44 now get 2.7 implicitly enabled via IUSE defaults (as the only target
45 available), and their deps can have them enabled via package.use in
46 profils.
47
48
49 WDYT?
50
51
52 [1] https://www.python.org/dev/peps/pep-0373/#update
53 [2] https://python3statement.org/#sections40-timeline
54 [3] https://pypy.readthedocs.io/en/latest/faq.html#how-long-will-pypy-support-python2
55
56 --
57 Best regards,
58 Michał Górny

Attachments

File name MIME type
signature.asc application/pgp-signature