[tor-bugs] #33949 [Internal Services/Tor Sysadmin Team]: python 2 end of life coordination

Tor Bug Tracker & Wiki blackhole at torproject.org
Tue Apr 21 15:40:25 UTC 2020


#33949: python 2 end of life coordination
-----------------------------------------------------+-----------------
     Reporter:  anarcat                              |      Owner:  tpa
         Type:  project                              |     Status:  new
     Priority:  Low                                  |  Milestone:
    Component:  Internal Services/Tor Sysadmin Team  |    Version:
     Severity:  Major                                |   Keywords:
Actual Points:                                       |  Parent ID:
       Points:                                       |   Reviewer:
      Sponsor:                                       |
-----------------------------------------------------+-----------------
 Python 2.7.18 has just been released. It is the last Python 2 release that
 will ever happen, and Python 2 is now unsupported, end of life,
 [https://www.enricozini.org/blog/2020/python/python-2-is-dead/ dead].

 It is likely that the next Debian release (bullseye) will not support
 Python 2 at all. It's also possible the current release (buster) does not
 support Python 2 for security issues forever. So we have *some* time, in
 practice, to handle this problem. But we definitely will need to finish
 this migration before some time around 2022, and the sooner the better.

 Until then, we need to figure out a strategy on how to handle that
 transition. Some of our code has been written for Python 3, but we have a
 large amount of Python-2-only code that is running, in multiple places.
 Some of it is TPA's responsibility, but other code is ran by teams or
 service admins.

 Since we run stretch or buster everywhere, we're in a good position to
 *not* have to support both Python 2 and Python 3 at once: we can just
 *migrate* to python 3. Stretch has Python 3.5 so we could target that as a
 minimum version. But we could also assume we will have completed the
 Buster upgrade by then and just target the more featureful Python 3.7.

 In any case, we need a plan for this and it would be wise to do it before
 we're backed into a corner.

 Some resources:

  * http://python3porting.com/ - python 3 porting book, freely available
  * https://python3statement.org/practicalities/ - some more advice on
 porting
  * https://docs.python.org/3/howto/pyporting.html - upstream guide, which
 still recommends supporting python 2.7

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/33949>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list