Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: bump the minimum python version to 3.9 #818

Merged
merged 2 commits into from
Jun 4, 2024
Merged

Conversation

almet
Copy link
Member

@almet almet commented May 24, 2024

Bump the minimum python version to 3.9 when installing from source, and to 3.8 when installing in Debian-related distributions.

The minimum python version when installing from source is now python
3.9, as Pyside6 6.7.1 dropped support for python 3.8 (see #780 for more
information).

On Debian-derivatives distributions, the minimum Python version is now
set to 3.8. In practice, because Pyside6 is not packaged for Debian, we
use Pyside2 [0], which is why we can relax the python version requirement.

In practice, when installing from source on an environment where
python3.9 is not the default python, poetry will look for it and use it
if available

For various reasons, this Python version might not be compatible with
the python range supported by the project. In this case, Poetry will
try to find one that is and use it.

Poetry docs

On Ubuntu Focal (20.04) where Python 3.9 is not installed by default,
it is possible to install it using the python3.9 package.

[0] More information on how Pyside6 packaging affects dangerzone on #221
[1] See the current status of Pyside6 packaging

@almet almet force-pushed the minimum-python-3.9 branch 2 times, most recently from 180a20b to 9f2fb9c Compare May 28, 2024 14:43
@almet almet marked this pull request as ready for review May 29, 2024 08:03
@apyrgio apyrgio added this to the 0.7.0 milestone Jun 3, 2024
BUILD.md Outdated Show resolved Hide resolved
poetry.lock Outdated Show resolved Hide resolved
@almet almet force-pushed the minimum-python-3.9 branch 5 times, most recently from 4fc74a2 to 2689774 Compare June 4, 2024 17:46
almet added 2 commits June 4, 2024 19:57
The minimum python version when installing from source is now python
3.9, as Pyside6 6.7.1 dropped support for python 3.8 (see #780 for more
information).

On Debian-derivatives distributions, the minimum Python version is now
set to 3.8. In practice, because Pyside6 is not packaged for Debian, we
use Pyside2 [0], which is why we can relax the python version requirement.

In practice, when installing from source on an environment where
python3.9 is not the default python, poetry will look for it and use it
if available

> For various reasons, this Python version might not be compatible with
> the python range supported by the project. In this case, Poetry will
> try to find one that is and use it.
>
> [Poetry docs](https://python-poetry.org/docs/managing-environments/)

On Ubuntu Focal (20.04) where Python 3.9 is not installed by default,
it is possible to install it using the `python3.9` package.

Additionally, In version 1.24.3, PyMuPDF changed its package name from `fitz`
to `pymupdf` [2], resulting in a breakage on how it is installed in our
container. This is now fixed.

[0] More information on how Pyside6 packaging affects dangerzone on #221
[1] See [the current status of Pyside6 packaging](https://repology.org/
project/python:pyside6/packages)
[2] PyMuPDF changelog: https://pymupdf.readthedocs.io/en/latest/changes.html#change-log
@almet almet force-pushed the minimum-python-3.9 branch from 2689774 to 850199c Compare June 4, 2024 17:57
Copy link
Contributor

@apyrgio apyrgio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great Alexis! Feel free to merge once the CI tests pass.

tests/test_docs/unsafe/sample-bmp.bmp Outdated Show resolved Hide resolved
@almet almet merged commit 850199c into main Jun 4, 2024
54 checks passed
@almet almet deleted the minimum-python-3.9 branch June 4, 2024 18:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants