# older glibc
- env: { COMPILER: "gcc", COMPILER_VERSION: "12", LINKER: "bfd", CUSTOM_PYTHON: "1" }
runner: [ ubuntu-22.04 ]
- python-version: '3.7'
+ python-version: '3.9'
env: ${{ matrix.env }}
steps:
- name: Repository checkout
gperf
docbook-xsl (optional, required for documentation)
xsltproc (optional, required for documentation)
- python >= 3.7 (required by meson too, >= 3.9 is required for ukify)
+ python >= 3.9
python-jinja2
python-pefile (optional, required for ukify)
python-lxml (optional, required to build the indices)
pymod = import('python')
python = pymod.find_installation('python3', required : true, modules : ['jinja2'])
-python_39 = python.language_version().version_compare('>=3.9')
+if not python.language_version().version_compare('>=3.9')
+ error('Python >= 3.9 is required')
+endif
#####################################################################
efi_cpu_family_alt = 'x86'
endif
-pefile = pymod.find_installation('python3', required: false, modules : ['pefile'])
-
-want_ukify = get_option('ukify').require(python_39 and pefile.found(), error_message : 'Python >= 3.9 and pefile required').allowed()
+want_ukify = pymod.find_installation('python3', required: get_option('ukify'), modules : ['pefile']).found()
conf.set10('ENABLE_UKIFY', want_ukify)
#####################################################################
-target-version = "py37"
+target-version = "py39"
line-length = 109
lint.select = ["E", "F", "I", "UP"]
[format]
quote-style = "single"
-
-[per-file-target-version]
-"src/ukify/*.py" = "py39"
-"test/**/integration-test-wrapper.py" = "py39"
-"test/test-udev.py" = "py39"
# removes the device node. After creation and removal the result is checked
# against the expected value and the result is printed.
+import dataclasses
import functools
import os
import pwd, grp
from typing import Callable, Optional
try:
- import dataclasses # requires Python >= 3.7
import pytest
except ImportError as e:
print(str(e), file=sys.stderr)