Skip to content

Latest commit

 

History

History
96 lines (74 loc) · 4.46 KB

0007-python3.md

File metadata and controls

96 lines (74 loc) · 4.46 KB
layout status adr title deciders date
page
accepted
0007
Refactor to Python 3
Justin Simpson, Sarah Romkey, Darren Craze, Joel Simpson, David Juhasz, Jesús García Crespo, Pieter Van Garderen, Sara Allain, Ashley Blewer, Santiago Rodríguez Collazo, Miguel Angel Medinilla Luque, José Raddaoui Marín, Cole Maclean, Ross Spencer, Douglas Cerna.
2019-07-22

Context and problem statement

Python 2 will not be supported by the Python development team past January 1, 2020. Operating system vendors will provide bugfix support for some number of years, depending on the OS:

Archivematica is not fully compatible with Python 3 yet. Archivematica and all of its required components will eventually need to run in a Python 3 environment, especially as downstream dependencies begin to drop support for Python 2 (i.e. Django).

Components:

Decision drivers

  • Archivematica is built on Python 2
  • Python 2 will no longer be supported after January 1, 2020
  • Archivematica should be refactored to use Python 3 (3.5 at minimum)

Considered options

  1. Refactor to Python 3 (3.5 at minimum)

Decision outcome

Chosen option: 1, because refactoring Archivematica and all required components to Python 3 is the only option to ensure that Archivematica continues to be a safe, stable environment.

Python 3.5 has been set as the minimum version for the following reasons:

  • Python 3.4 has already been retired
  • Python 3.5 is the oldest version this is still supported
  • Ubuntu 16.04 ships Python 3.5
  • Ubuntu 18.04 ships Python 3.6
  • For CentOS 7, The Software Collections Repository provides packages for Python 3.5 and up

During the course of the project, a higher version of Python may be selected.

Epic for Python 3 refactoring

Positive consequences

  • Archivematica will be upgraded to a maintained version of Python.
  • Archivematica developers will be able to take advantage of new features in Python.
  • Python 3 support will be maintained for many years (for example, the latest stable release is 3.7, which will be maintained until 2023; further releases are expected).

Negative consequences

  • This is a very large task and components need to be tackled in priority order, so it will take a considerable amount of time to get everything refactored.
  • Releasing the Python 3 work once all components are refactored will take the place of a feature release, leaving some development work unreleased for at least 4 extra months (note: all code resides in public branches).
  • We will need to support Archivematica running Python 2.7 for some time because users will need time to upgrade. This results in a dual support burden.
  • Development work currently in progress may need to be refactored to Python 3 before it are releasable, which is unsponsored work.

Links