From 11a61d6f653a8e357ba919463e2865154f6166b8 Mon Sep 17 00:00:00 2001 From: mayeut Date: Tue, 3 Sep 2024 16:30:41 +0200 Subject: [PATCH] Drop CPython 3.6 --- README.rst | 2 +- docker/Dockerfile | 7 +-- docker/build_scripts/build-cpython.sh | 5 -- docker/build_scripts/requirements3.6.txt | 60 ------------------------ tests/forty-two/setup.py | 2 +- tests/run_tests.sh | 18 +++---- 6 files changed, 12 insertions(+), 82 deletions(-) delete mode 100644 docker/build_scripts/requirements3.6.txt diff --git a/README.rst b/README.rst index 100d56a28..0f38dc7b0 100644 --- a/README.rst +++ b/README.rst @@ -210,7 +210,7 @@ Image content All supported images currently contain: -- CPython 3.6, 3.7, 3.8, 3.9, 3.10, 3.11, 3.12, 3.13, 3.13t and PyPy 3.7, 3.8, 3.9, 3.10 installed in +- CPython 3.7, 3.8, 3.9, 3.10, 3.11, 3.12, 3.13, 3.13t and PyPy 3.7, 3.8, 3.9, 3.10 installed in ``/opt/python/-``. The directories are named after the PEP 425 tags for each environment -- e.g. ``/opt/python/cp37-cp37m`` contains a CPython 3.7 build, and diff --git a/docker/Dockerfile b/docker/Dockerfile index 3d3ccbf5a..77d3be7d1 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -105,10 +105,6 @@ RUN export OPENSSL_ROOT=openssl-3.0.15 && \ manylinux-entrypoint /build_scripts/build-openssl.sh -FROM build_cpython_system_ssl AS build_cpython36 -COPY build_scripts/cpython-pubkeys.txt /build_scripts/cpython-pubkeys.txt -RUN manylinux-entrypoint /build_scripts/build-cpython.sh 3.6.15 - FROM build_cpython_system_ssl AS build_cpython37 COPY build_scripts/cpython-pubkeys.txt /build_scripts/cpython-pubkeys.txt RUN manylinux-entrypoint /build_scripts/build-cpython.sh 3.7.17 @@ -147,8 +143,7 @@ FROM runtime_base COPY --from=build_git /manylinux-rootfs / COPY --from=build_cpython_system_ssl /manylinux-rootfs / COPY build_scripts /opt/_internal/build_scripts/ -RUN --mount=type=bind,target=/build_cpython36,from=build_cpython36 \ - --mount=type=bind,target=/build_cpython37,from=build_cpython37 \ +RUN --mount=type=bind,target=/build_cpython37,from=build_cpython37 \ --mount=type=bind,target=/build_cpython38,from=build_cpython38 \ --mount=type=bind,target=/build_cpython39,from=build_cpython39 \ --mount=type=bind,target=/build_cpython310,from=build_cpython310 \ diff --git a/docker/build_scripts/build-cpython.sh b/docker/build_scripts/build-cpython.sh index 0eae0e626..312ff680b 100755 --- a/docker/build_scripts/build-cpython.sh +++ b/docker/build_scripts/build-cpython.sh @@ -40,11 +40,6 @@ if [ "${2:-}" == "nogil" ]; then CONFIGURE_ARGS="${CONFIGURE_ARGS} --disable-gil" fi -if [ "${CPYTHON_VERSION}" == "3.6.15" ]; then - # https://github.com/python/cpython/issues/89863 - # gcc-12+ uses these 2 flags in -O2 but they were only enabled in -O3 with gcc-11 - CFLAGS_EXTRA="${CFLAGS_EXTRA} -fno-tree-loop-vectorize -fno-tree-slp-vectorize" -fi if [ "${AUDITWHEEL_POLICY}" == "manylinux2014" ] ; then # Python 3.11+ export TCLTK_LIBS="-ltk8.6 -ltcl8.6" diff --git a/docker/build_scripts/requirements3.6.txt b/docker/build_scripts/requirements3.6.txt deleted file mode 100644 index 50ab3de1e..000000000 --- a/docker/build_scripts/requirements3.6.txt +++ /dev/null @@ -1,60 +0,0 @@ -# -# This file is autogenerated by pip-compile with python 3.6 -# To update, run: -# -# nox -s update_python_dependencies-3.6 -# -build==0.9.0 \ - --hash=sha256:1a07724e891cbd898923145eb7752ee7653674c511378eb9c7691aab1612bc3c \ - --hash=sha256:38a7a2b7a0bdc61a42a0a67509d88c71ecfc37b393baba770fae34e20929ff69 - # via -r requirements.in -importlib-metadata==4.8.3 \ - --hash=sha256:65a9576a5b2d58ca44d133c42a241905cc45e34d2c06fd5ba2bafa221e5d7b5e \ - --hash=sha256:766abffff765960fcc18003801f7044eb6755ffae4521c8e8ce8e83b9c9b0668 - # via - # build - # pep517 -packaging==21.3 \ - --hash=sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb \ - --hash=sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522 - # via - # -r requirements.in - # build -pep517==0.13.1 \ - --hash=sha256:1b2fa2ffd3938bb4beffe5d6146cbcb2bda996a5a4da9f31abffd8b24e07b317 \ - --hash=sha256:31b206f67165b3536dd577c5c3f1518e8fbaf38cbc57efff8369a392feff1721 - # via build -pyparsing==3.1.2 \ - --hash=sha256:a1bac0ce561155ecc3ed78ca94d3c9378656ad4c94c1270de543f621420f94ad \ - --hash=sha256:f9db75911801ed778fe61bb643079ff86601aca99fcae6345aa67292038fb742 - # via packaging -tomli==1.2.3 \ - --hash=sha256:05b6166bff487dc068d322585c7ea4ef78deed501cc124060e0f238e89a9231f \ - --hash=sha256:e3069e4be3ead9668e21cb9b074cd948f7b3113fd9c8bba083f48247aab8b11c - # via - # build - # pep517 -typing-extensions==4.1.1 \ - --hash=sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42 \ - --hash=sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2 - # via importlib-metadata -wheel==0.37.1 \ - --hash=sha256:4bdcd7d840138086126cd09254dc6195fb4fc6f01c050a1d7236f2630db1d22a \ - --hash=sha256:e9a504e793efbca1b8e0e9cb979a249cf4a0a7b5b8c9e8b65a5e39d49529c1c4 - # via -r requirements.in -zipp==3.6.0 \ - --hash=sha256:71c644c5369f4a6e07636f0aa966270449561fcea2e3d6747b8d23efaa9d7832 \ - --hash=sha256:9fe5ea21568a0a70e50f273397638d39b03353731e6cbbb3fd8502a33fec40bc - # via - # importlib-metadata - # pep517 - -# The following packages are considered to be unsafe in a requirements file: -pip==21.3.1 \ - --hash=sha256:deaf32dcd9ab821e359cd8330786bcd077604b5c5730c0b096eda46f95c24a2d \ - --hash=sha256:fd11ba3d0fdb4c07fbc5ecbba0b1b719809420f25038f8ee3cd913d3faa3033a - # via -r requirements.in -setuptools==59.6.0 \ - --hash=sha256:22c7348c6d2976a52632c67f7ab0cdf40147db7789f9aed18734643fe9cf3373 \ - --hash=sha256:4ce92f1e1f8f01233ee9952c04f6b81d1e02939d6e1b488428154974a4d0783e - # via -r requirements.in diff --git a/tests/forty-two/setup.py b/tests/forty-two/setup.py index 1458b2979..9756f968a 100644 --- a/tests/forty-two/setup.py +++ b/tests/forty-two/setup.py @@ -3,6 +3,6 @@ setup( name="forty_two", version="0.1.0", - python_requires=">=3.6", + python_requires=">=3.7", ext_modules=[Extension("forty_two", sources=["forty-two.c"])], ) diff --git a/tests/run_tests.sh b/tests/run_tests.sh index f7dccd53e..a2e217c30 100755 --- a/tests/run_tests.sh +++ b/tests/run_tests.sh @@ -7,18 +7,18 @@ set -exuo pipefail MY_DIR=$(dirname "${BASH_SOURCE[0]}") if [ "${AUDITWHEEL_POLICY:0:10}" == "musllinux_" ]; then - EXPECTED_PYTHON_COUNT=9 - EXPECTED_PYTHON_COUNT_ALL=9 + EXPECTED_PYTHON_COUNT=8 + EXPECTED_PYTHON_COUNT_ALL=8 else if [ "${AUDITWHEEL_ARCH}" == "x86_64" ] || [ "${AUDITWHEEL_ARCH}" == "aarch64" ]; then - EXPECTED_PYTHON_COUNT=10 - EXPECTED_PYTHON_COUNT_ALL=14 - elif [ "${AUDITWHEEL_ARCH}" == "i686" ]; then - EXPECTED_PYTHON_COUNT=10 + EXPECTED_PYTHON_COUNT=9 EXPECTED_PYTHON_COUNT_ALL=13 - else + elif [ "${AUDITWHEEL_ARCH}" == "i686" ]; then EXPECTED_PYTHON_COUNT=9 - EXPECTED_PYTHON_COUNT_ALL=9 + EXPECTED_PYTHON_COUNT_ALL=12 + else + EXPECTED_PYTHON_COUNT=8 + EXPECTED_PYTHON_COUNT_ALL=8 fi fi @@ -97,7 +97,7 @@ for PYTHON in /opt/python/*/bin/python; do echo "invalid answer, expecting 42" exit 1 fi - if [ "${PYVERS}" != "3.6" ] && [ "${PYVERS}" != "3.7" ] && [ "${IMPLEMENTATION}" != "graalpy" ] && [ "${AUDITWHEEL_POLICY:0:9}_${AUDITWHEEL_ARCH}" != "musllinux_s390x" ] && [ "${AUDITWHEEL_ARCH}" != "ppc64le" ] && [ "${AUDITWHEEL_ARCH}" != "armv7l" ] && [ "${AUDITWHEEL_ARCH}" != "riscv64" ]; then + if [ "${PYVERS}" != "3.7" ] && [ "${IMPLEMENTATION}" != "graalpy" ] && [ "${AUDITWHEEL_POLICY:0:9}_${AUDITWHEEL_ARCH}" != "musllinux_s390x" ] && [ "${AUDITWHEEL_ARCH}" != "ppc64le" ] && [ "${AUDITWHEEL_ARCH}" != "armv7l" ] && [ "${AUDITWHEEL_ARCH}" != "riscv64" ]; then # no uv on musllinux s390x # FIXME, armv7l test fails on Travis CI but works with qemu (maybe armv8l vs armv7l ?) # FIXME, ppc64le test fails on Travis CI but works with qemu