From 283996cff6b5e7cad38a9448c6f9ea55afd821e4 Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Mon, 25 Nov 2024 15:30:00 +0100 Subject: [PATCH 01/17] Use relative path in gen_dockerfile --- .github/docker/gen_dockerfile.sh | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/docker/gen_dockerfile.sh b/.github/docker/gen_dockerfile.sh index ba382a792..462e5b758 100755 --- a/.github/docker/gen_dockerfile.sh +++ b/.github/docker/gen_dockerfile.sh @@ -20,19 +20,20 @@ SYSTEM_TYPE=$2 ARCH=$3 -SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd ) +SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd -P ) +REL_DIR=${SCRIPT_DIR##*/dlite/} if [ $SYSTEM = "manylinux" -a ${SYSTEM_TYPE:0:1} = "_" ]; then - template=${SCRIPT_DIR}/Dockerfile-${SYSTEM}_x_y.template + template=${REL_DIR}/Dockerfile-${SYSTEM}_x_y.template else - template=${SCRIPT_DIR}/Dockerfile-${SYSTEM}.template + template=${REL_DIR}/Dockerfile-${SYSTEM}.template fi EXTRA_PRE="" EXTRA_POST="" if [ ${SYSTEM_TYPE} == "2010" ]; then - EXTRA_PRE="COPY ${SCRIPT_DIR}/pgdg-91_${ARCH}.repo /etc/yum.repos.d/pgdg-91.repo" + EXTRA_PRE="COPY ${REL_DIR}/pgdg-91_${ARCH}.repo /etc/yum.repos.d/pgdg-91.repo" EXTRA_POST="ENV PATH=\$PATH:/usr/pgsql-9.1/bin" fi From ffb39dd8294f2c5c911eb0384d0e5d895e661391 Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Mon, 25 Nov 2024 18:13:39 +0100 Subject: [PATCH 02/17] Included python versions in the generated dockerfiles --- .github/docker/Dockerfile-manylinux.template | 17 +++-- .../docker/Dockerfile-manylinux_x_y.template | 19 +++--- .github/docker/Dockerfile-musllinux.template | 7 +- .github/docker/gen_dockerfile.sh | 13 ++-- .github/workflows/container_builds_weekly.yml | 64 ++++++++++++------- 5 files changed, 74 insertions(+), 46 deletions(-) diff --git a/.github/docker/Dockerfile-manylinux.template b/.github/docker/Dockerfile-manylinux.template index c90bb0376..ebc682b9f 100644 --- a/.github/docker/Dockerfile-manylinux.template +++ b/.github/docker/Dockerfile-manylinux.template @@ -6,7 +6,10 @@ # # Copy this template file and replace: # - `{{ TYPE }}` major glibc version, ex: _2_24, _2_28 -# - `{{ ARCH }}` with a valid arch, ex: x86_64, i686 +# - `{{ ARCH }}` architecture, ex: x86_64, i686 +# - `{{ PY_MINORS }}` minor Python3 version numbers, ex: "8 9 10" +# - `{{ EXTRA_PRE }}` extra commands before installation +# - `{{ EXTRA_POST }}` extra commands after installation # Remove the `.template` suffix from the copy. # # Examples @@ -14,28 +17,28 @@ # # Generate dockerfile: # -# .github/docker/gen_dockerfile.sh manylinux 2014 i686 > \ -# .github/docker/dockerfiles/Dockerfile-manylinux2014_i686 +# .github/docker/gen_dockerfile.sh manylinux 2014 x86_64 > \ +# .github/docker/dockerfiles/Dockerfile-manylinux2014_x86_64 # # Build: # # cd dlite # cd to DLite root directory -# docker build -t dlite-manylinux2014_i686 \ -# -f .github/docker/dockerfiles/Dockerfile-manylinux2014_i686 . +# docker build -t dlite-manylinux2014_x86_64 \ +# -f .github/docker/dockerfiles/Dockerfile-manylinux2014_x86_64 . # # Run (for debugging): # # docker run --rm -it \ # --volume $PWD:/io \ # --user $(id -u):$(id -g) \ -# dlite-manylinux2014_i686 \ +# dlite-manylinux2014_x86_64 \ # /bin/bash # # Reference: https://github.com/pypa/manylinux#manylinux2014-centos-7-based FROM quay.io/pypa/manylinux{{ TYPE }}_{{ ARCH }}:latest -ARG PY_MINORS="8 9 10 11 12" +ARG PY_MINORS="{{ PY_MINORS }}" COPY requirements_full.txt requirements_dev.txt /tmp/ diff --git a/.github/docker/Dockerfile-manylinux_x_y.template b/.github/docker/Dockerfile-manylinux_x_y.template index 048a4a875..d1687b572 100644 --- a/.github/docker/Dockerfile-manylinux_x_y.template +++ b/.github/docker/Dockerfile-manylinux_x_y.template @@ -5,8 +5,11 @@ # Usage: # # Copy this template file and replace: -# - `{{ TYPE }}` major glibc version, ex: _2_24, _2_28 -# - `{{ ARCH }}` with a valid arch, ex: x86_64, i686 +# - `{{ TYPE }}` major glibc version, ex: _2_24, _2_28, _2_34 +# - `{{ ARCH }}` architecture, ex: x86_64, i686 +# - `{{ PY_MINORS }}` minor Python3 version numbers, ex: "8 9 10 11 12 13" +# - `{{ EXTRA_PRE }}` extra commands before installation +# - `{{ EXTRA_POST }}` extra commands after installation # Remove the `.template` suffix from the copy. # # Examples @@ -14,28 +17,28 @@ # # Generate dockerfile: # -# .github/docker/gen_dockerfile.sh manylinux _2_24 x86_64 > \ -# .github/docker/dockerfiles/Dockerfile-manylinux_2_24_x86_64 +# .github/docker/gen_dockerfile.sh manylinux _2_34 x86_64 > \ +# .github/docker/dockerfiles/Dockerfile-manylinux_2_34_x86_64 # # Build: # # cd dlite # cd to DLite root directory -# docker build -t dlite-manylinux \ -# -f .github/docker/dockerfiles/Dockerfile-manylinux_2_24_x86_64 . +# docker build -t dlite-manylinux_2_34_x86_64 \ +# -f .github/docker/dockerfiles/Dockerfile-manylinux_2_34_x86_64 . # # Run (for debugging): # # docker run --rm -it \ # --volume $PWD:/io \ # --user $(id -u):$(id -g) \ -# dlite-manylinux_2_24_x86_64 \ +# dlite-manylinux_2_34_x86_64 \ # /bin/bash # # Reference: https://github.com/pypa/manylinux FROM quay.io/pypa/manylinux{{ TYPE }}_{{ ARCH }}:latest -ARG PY_MINORS="8 9 10 11 12" +ARG PY_MINORS="{{ PY_MINORS }}" {{ EXTRA_PRE }} diff --git a/.github/docker/Dockerfile-musllinux.template b/.github/docker/Dockerfile-musllinux.template index 136a730c8..96c219695 100644 --- a/.github/docker/Dockerfile-musllinux.template +++ b/.github/docker/Dockerfile-musllinux.template @@ -5,7 +5,10 @@ # # Copy this template file and replace: # - `{{ TYPE }}` with a valid musllinux type, e.g. '_1_1' or '_1_2' -# - `{{ ARCH }}` with a valid arch, e.g., x86_64 or i686 +# - `{{ ARCH }}` architecture, ex: x86_64, i686 +# - `{{ PY_MINORS }}` minor Python3 version numbers, ex: "8 9 10 11 12" +# - `{{ EXTRA_PRE }}` extra commands before installation +# - `{{ EXTRA_POST }}` extra commands after installation # Remove the `.template` suffix from the copy. # # Examples @@ -32,7 +35,7 @@ # FROM quay.io/pypa/musllinux{{ TYPE }}_{{ ARCH }}:latest -ARG PY_MINORS="8 9 10 11 12" +ARG PY_MINORS="{{ PY_MINORS }}" COPY requirements_full.txt requirements_dev.txt /tmp/ diff --git a/.github/docker/gen_dockerfile.sh b/.github/docker/gen_dockerfile.sh index 462e5b758..15e55026f 100755 --- a/.github/docker/gen_dockerfile.sh +++ b/.github/docker/gen_dockerfile.sh @@ -3,21 +3,23 @@ # # Usage: # -# gen_dockerfile.sh SYSTEM SYSTEM_TYPE ARCH +# gen_dockerfile.sh SYSTEM SYSTEM_TYPE ARCH [PY_MINORS] # # Arguments: -# SYSTEM: system type. Ex: manylinux, musllinux -# SYSTEM_TYPE: Ex: 2010, 2014, _2_24, _2_28 (manylinux), _1_1, _1_2 (musllinux) -# ARCH: Ex: x86_64, i686 +# SYSTEM: system. Ex: manylinux, musllinux +# SYSTEM_TYPE: System type. Ex: 2010, 2014, _2_24, _2_28 (manylinux), _1_1, _1_2 (musllinux) +# ARCH: Architecture. Ex: x86_64, i686 +# PY_MINORS: Optional list of Python3 minor version numbers. Default: "8 9 10 11 12" set -eu -if [[ $# -ne 3 ]]; then +if [[ $# -lt 3 ]]; then echo "Usage: gen_dockerfile.sh SYSTEM SYSTEM_TYPE ARCH" exit 1 fi SYSTEM=$1 SYSTEM_TYPE=$2 ARCH=$3 +PY_MINORS="${4:=8 9 10 11 12}" SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd -P ) @@ -40,6 +42,7 @@ fi sed \ -e "s|{{ ARCH }}|${ARCH}|" \ -e "s|{{ TYPE }}|${SYSTEM_TYPE}|" \ + -e "s|{{ PY_MINORS }}|${PY_MINORS}|" \ -e "s|{{ EXTRA_PRE }}|${EXTRA_PRE}|" \ -e "s|{{ EXTRA_POST }}|${EXTRA_POST}|" \ $template diff --git a/.github/workflows/container_builds_weekly.yml b/.github/workflows/container_builds_weekly.yml index 23dc892e7..4ee21e857 100644 --- a/.github/workflows/container_builds_weekly.yml +++ b/.github/workflows/container_builds_weekly.yml @@ -22,45 +22,61 @@ jobs: fail-fast: false matrix: include: - # 64-bit linux + # 64-bit manylinux - system: "manylinux" - type: "2010" - arch: "x86_64" - py_minors: "8 9" - - system: "manylinux" - type: "2014" - arch: "x86_64" - py_minors: "8 9 10 11 12" - - system: "manylinux" - type: "_2_28" + type: "_2_34" arch: "x86_64" + #py_minors: "8 9 10 11 12 13" py_minors: "8 9 10 11 12" - - system: "musllinux" - type: "_1_1" - arch: "x86_64" - py_minors: "8 9 10 11" + #- system: "manylinux" + # type: "_2_28" + # arch: "x86_64" + # py_minors: "8 9 10 11 12" + #- system: "manylinux" + # type: "2014" + # arch: "x86_64" + # py_minors: "8 9 10 11 12" + #- system: "manylinux" + # type: "2010" + # arch: "x86_64" + # py_minors: "8 9" + + # 64-bit musllinux - system: "musllinux" type: "_1_2" arch: "x86_64" + #py_minors: "8 9 10 11 12 13" py_minors: "8 9 10 11" + #- system: "musllinux" + # type: "_1_1" + # arch: "x86_64" + # py_minors: "8 9 10 11" + #- system: "musllinux" + # type: "_1_2" + # arch: "x86_64" + # py_minors: "8 9 10 11" - # 32-bit linux - - system: "manylinux" - type: "2010" - arch: "i686" - py_minors: "8 9" + # 32-bit manylinux - system: "manylinux" type: "2014" arch: "i686" + #py_minors: "8 9 10 11 12 13" py_minors: "8 9 10 11 12" - - system: "musllinux" - type: "_1_1" - arch: "i686" - py_minors: "8 9 10 11" + #- system: "manylinux" + # type: "2010" + # arch: "i686" + # py_minors: "8 9" + + # 32-bit musllinux - system: "musllinux" type: "_1_2" arch: "i686" + #py_minors: "8 9 10 11 12 13" py_minors: "8 9 10 11" + #- system: "musllinux" + # type: "_1_1" + # arch: "i686" + # py_minors: "8 9 10 11" steps: - name: Checkout repository @@ -95,7 +111,7 @@ jobs: if: env.BUILD_NEW_IMAGE == 'true' run: | mkdir -p docker_build_wheel - bash .github/docker/gen_dockerfile.sh ${{ matrix.system }} ${{ matrix.type }} ${{ matrix.arch }} \ + bash .github/docker/gen_dockerfile.sh ${{ matrix.system }} ${{ matrix.type }} ${{ matrix.arch }} "${{ matrix.py_minors }}" \ > docker_build_wheel/Dockerfile-${{ matrix.system }}${{ matrix.type }}_${{ matrix.arch }} - name: Login to GitHub Container Registry From ed9bcbdbe9c411857f65863c8a89008b784da10f Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Mon, 25 Nov 2024 18:49:08 +0100 Subject: [PATCH 03/17] Updated dockerfile templates --- .github/docker/Dockerfile-manylinux.template | 12 +++++++----- .github/docker/Dockerfile-manylinux_x_y.template | 14 ++++++++------ .github/docker/Dockerfile-musllinux.template | 8 +++++--- 3 files changed, 20 insertions(+), 14 deletions(-) diff --git a/.github/docker/Dockerfile-manylinux.template b/.github/docker/Dockerfile-manylinux.template index ebc682b9f..74ae2cd2e 100644 --- a/.github/docker/Dockerfile-manylinux.template +++ b/.github/docker/Dockerfile-manylinux.template @@ -38,9 +38,7 @@ # Reference: https://github.com/pypa/manylinux#manylinux2014-centos-7-based FROM quay.io/pypa/manylinux{{ TYPE }}_{{ ARCH }}:latest -ARG PY_MINORS="{{ PY_MINORS }}" - -COPY requirements_full.txt requirements_dev.txt /tmp/ +COPY requirements.txt requirements_full.txt requirements_dev.txt /tmp/ {{ EXTRA_PRE }} @@ -81,7 +79,11 @@ RUN \ -e '/scikit-image/d' \ -e '/ncempy/d' \ -e '/h5py/d' \ - -i /tmp/requirements_full.txt && \ + -i /tmp/requirements_full.txt + +ARG PY_MINORS="{{ PY_MINORS }}" + +RUN \ # Install required Python packages mkdir -p /ci/pip_cache && \ for minor in ${PY_MINORS}; do \ @@ -89,7 +91,7 @@ RUN \ python3.${minor} -m pip install --cache-dir=/ci/pip_cache \ -U setuptools wheel && \ python3.${minor} -m pip install --cache-dir=/ci/pip_cache \ - oldest-supported-numpy \ + -r /tmp/requirements.txt \ -r /tmp/requirements_dev.txt \ -r /tmp/requirements_full.txt; \ done && \ diff --git a/.github/docker/Dockerfile-manylinux_x_y.template b/.github/docker/Dockerfile-manylinux_x_y.template index d1687b572..23271f986 100644 --- a/.github/docker/Dockerfile-manylinux_x_y.template +++ b/.github/docker/Dockerfile-manylinux_x_y.template @@ -38,11 +38,9 @@ # Reference: https://github.com/pypa/manylinux FROM quay.io/pypa/manylinux{{ TYPE }}_{{ ARCH }}:latest -ARG PY_MINORS="{{ PY_MINORS }}" - {{ EXTRA_PRE }} -COPY requirements_full.txt requirements_dev.txt /tmp/ +COPY requirements.txt requirements_full.txt requirements_dev.txt /tmp/ # Enable rpmfusion for additional packages RUN \ @@ -62,21 +60,25 @@ RUN \ # It's necessary to be in /opt/_internal because the internal libraries # exist here. cd /opt/_internal && \ - tar -Jxvf static-libs-for-embedding-only.tar.xz && \ + tar -Jxvf static-libs-for-embedding-only.tar.xz # Filter out challenging packages from requirements_full.txt #sed \ # -e '/pyarrow/d' \ # -e '/tables/d' \ # -e '/scikit-image/d' \ # -i /tmp/requirements_full.txt && \ - # Install required Python packages + # Install required Python packages + +ARG PY_MINORS="{{ PY_MINORS }}" + +RUN \ mkdir -p /ci/pip_cache && \ for minor in ${PY_MINORS}; do \ python3.${minor} -m pip install --cache-dir=/ci/pip_cache -U pip && \ python3.${minor} -m pip install --cache-dir=/ci/pip_cache \ -U setuptools wheel && \ python3.${minor} -m pip install --cache-dir=/ci/pip_cache \ - oldest-supported-numpy \ + -r /tmp/requirements.txt \ -r /tmp/requirements_dev.txt \ -r /tmp/requirements_full.txt; \ done && \ diff --git a/.github/docker/Dockerfile-musllinux.template b/.github/docker/Dockerfile-musllinux.template index 96c219695..b5d97f354 100644 --- a/.github/docker/Dockerfile-musllinux.template +++ b/.github/docker/Dockerfile-musllinux.template @@ -35,8 +35,6 @@ # FROM quay.io/pypa/musllinux{{ TYPE }}_{{ ARCH }}:latest -ARG PY_MINORS="{{ PY_MINORS }}" - COPY requirements_full.txt requirements_dev.txt /tmp/ {{ EXTRA_PRE }} @@ -70,8 +68,12 @@ RUN \ -e '/scikit-image/d' \ -e '/ncempy/d' \ -e '/h5py/d' \ - -i /tmp/requirements_full.txt && \ + -i /tmp/requirements_full.txt #-e 's/^pydantic.*/pydantic<2/' \ + +ARG PY_MINORS="{{ PY_MINORS }}" + +RUN \ # Install required Python packages mkdir -p /ci/pip_cache && \ for minor in ${PY_MINORS}; do \ From ab68f350ac16f61b4d8b3e37bd02747b6dae6601 Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Mon, 25 Nov 2024 19:04:59 +0100 Subject: [PATCH 04/17] Also remove requirement on oldest-supported-numpy for musllinux --- .github/docker/Dockerfile-musllinux.template | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/docker/Dockerfile-musllinux.template b/.github/docker/Dockerfile-musllinux.template index b5d97f354..55fd251b7 100644 --- a/.github/docker/Dockerfile-musllinux.template +++ b/.github/docker/Dockerfile-musllinux.template @@ -35,7 +35,7 @@ # FROM quay.io/pypa/musllinux{{ TYPE }}_{{ ARCH }}:latest -COPY requirements_full.txt requirements_dev.txt /tmp/ +COPY requirements.txt requirements_full.txt requirements_dev.txt /tmp/ {{ EXTRA_PRE }} @@ -81,7 +81,7 @@ RUN \ python3.${minor} -m pip install --cache-dir=/ci/pip_cache \ -U setuptools wheel && \ python3.${minor} -m pip install --cache-dir=/ci/pip_cache \ - oldest-supported-numpy \ + -r /tmp/requirements.txt \ -r /tmp/requirements_dev.txt \ -r /tmp/requirements_full.txt; \ done && \ From deb1888b742629b3a6b1c9615df6c4f37d2f9d26 Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Mon, 25 Nov 2024 19:35:17 +0100 Subject: [PATCH 05/17] Updated requirement filters for musllinux --- .github/docker/Dockerfile-musllinux.template | 9 +++++++-- requirements_full.txt | 2 +- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/docker/Dockerfile-musllinux.template b/.github/docker/Dockerfile-musllinux.template index 55fd251b7..70f5b2289 100644 --- a/.github/docker/Dockerfile-musllinux.template +++ b/.github/docker/Dockerfile-musllinux.template @@ -58,6 +58,7 @@ RUN \ cd /opt/_internal && \ tar -Jxvf static-libs-for-embedding-only.tar.xz && \ # Filter out challenging packages from requirements_full.txt + #-e 's/^pydantic.*/pydantic<2/' \ sed \ -e '/pandas/d' \ -e '/pyarrow/d' \ @@ -68,8 +69,12 @@ RUN \ -e '/scikit-image/d' \ -e '/ncempy/d' \ -e '/h5py/d' \ - -i /tmp/requirements_full.txt - #-e 's/^pydantic.*/pydantic<2/' \ + -e '/pymongo/d' \ + -e '/fortran-language-server/d' \ + -i /tmp/requirements_full.txt && \ + sed \ + -e '/mongomock/d' \ + -i /tmp/requirements_dev.txt ARG PY_MINORS="{{ PY_MINORS }}" diff --git a/requirements_full.txt b/requirements_full.txt index f05ca3bba..e34db4b04 100644 --- a/requirements_full.txt +++ b/requirements_full.txt @@ -22,7 +22,7 @@ pymongo>=4.4.0,<5 # Utilities pydantic>=1.10.0,<2.9.3 -typing_extensions>=4.1,<5 +typing_extensions>=4.1,<5; python_version<'3.9' fortran-language-server>=1.12.0,<1.13 # For TEM demo From 43f7a195bec89253334eac2e2c059b4e426b547e Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Mon, 25 Nov 2024 19:50:12 +0100 Subject: [PATCH 06/17] Install rust and cargo in musllinux container --- .github/docker/Dockerfile-musllinux.template | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/docker/Dockerfile-musllinux.template b/.github/docker/Dockerfile-musllinux.template index 70f5b2289..308bd9199 100644 --- a/.github/docker/Dockerfile-musllinux.template +++ b/.github/docker/Dockerfile-musllinux.template @@ -51,7 +51,9 @@ RUN \ hdf5-dev \ openssl-dev \ openblas-dev \ - swig && \ + swig \ + rust \ + cargo && \ # Unpack static libraries # It's necessary to be in /opt/_internal because the internal libraries # exist here. From 2084dc35ca5d64035a9c37c0b1552afb9afde20a Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Mon, 25 Nov 2024 21:45:55 +0100 Subject: [PATCH 07/17] Install rust and cargo on manylinux2014 --- .github/docker/Dockerfile-manylinux.template | 4 +++- .github/docker/gen_dockerfile.sh | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/docker/Dockerfile-manylinux.template b/.github/docker/Dockerfile-manylinux.template index 74ae2cd2e..5012aecc0 100644 --- a/.github/docker/Dockerfile-manylinux.template +++ b/.github/docker/Dockerfile-manylinux.template @@ -55,7 +55,9 @@ RUN \ libcurl-devel \ libxslt-devel \ libxml2-devel \ - libffi-devel && \ + libffi-devel \ + rust \ + cargo && \ # hdf5-devel is needed for building the hdf5 plugin yum install -y hdf5-devel || true && \ # Unpack static libraries diff --git a/.github/docker/gen_dockerfile.sh b/.github/docker/gen_dockerfile.sh index 15e55026f..d54cf98dc 100755 --- a/.github/docker/gen_dockerfile.sh +++ b/.github/docker/gen_dockerfile.sh @@ -13,7 +13,7 @@ set -eu if [[ $# -lt 3 ]]; then - echo "Usage: gen_dockerfile.sh SYSTEM SYSTEM_TYPE ARCH" + echo "Usage: gen_dockerfile.sh SYSTEM SYSTEM_TYPE ARCH [PY_MINORS]" exit 1 fi SYSTEM=$1 From 05241bf099c3ec6936f3c92ed7a9526c63b89eee Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Mon, 25 Nov 2024 22:08:57 +0100 Subject: [PATCH 08/17] Updated build wheel to match the containers that are build --- .github/workflows/ci_build_wheels.yml | 97 ++++++++++++++------------- 1 file changed, 51 insertions(+), 46 deletions(-) diff --git a/.github/workflows/ci_build_wheels.yml b/.github/workflows/ci_build_wheels.yml index 9bbad55db..0fc45e6c2 100644 --- a/.github/workflows/ci_build_wheels.yml +++ b/.github/workflows/ci_build_wheels.yml @@ -17,62 +17,60 @@ jobs: fail-fast: false matrix: include: - # 32-bit linux - - os: ubuntu-20.04 - system_type: ["manylinux", "2010"] - arch: i686 - py_minors: 8,9 - # Python 3.12 often fails with segfault during shutdown for - # manylinux2014_i686 - should be debugged - - os: ubuntu-20.04 - system_type: ["manylinux", "2014"] - arch: i686 - py_minors: 8,11 - # Python 3.12 fails since cibuildwheel still depends on distutils - # for musllinux + + # 64-bit manylinux - os: ubuntu-20.04 - system_type: ["musllinux", "_1_1"] - arch: i686 - py_minors: 8,11 - # Python 3.12 fails since cibuildwheel still depends on distutils - # for musllinux + system_type: ["manylinux", "_2_34"] + arch: x86_64 + py_minors: 8,12 + #- os: ubuntu-20.04 + # system_type: ["manylinux", "_2_28"] + # arch: x86_64 + # py_minors: 8,12 + #- os: ubuntu-20.04 + # system_type: ["manylinux", "2014"] + # arch: x86_64 + # py_minors: 8,12 + #- os: ubuntu-20.04 + # system_type: ["manylinux", "2010"] + # arch: x86_64 + # py_minors: 8,9 + + # 64-bit musllinux - os: ubuntu-20.04 system_type: ["musllinux", "_1_2"] - arch: i686 + arch: x86_64 py_minors: 8,11 + # Python 3.12 fails since cibuildwheel still depends on distutils + # for musllinux + #- os: ubuntu-20.04 + # system_type: ["musllinux", "_1_1"] + # arch: x86_64 + # py_minors: 8,11 - # 64-bit linux - - os: ubuntu-20.04 - system_type: ["manylinux", "2010"] - arch: x86_64 - py_minors: 8,9 + # 32-bit manylinux - os: ubuntu-20.04 system_type: ["manylinux", "2014"] - arch: x86_64 - py_minors: 8,12 - - os: ubuntu-20.04 - system_type: ["manylinux", "_2_28"] - arch: x86_64 + arch: i686 py_minors: 8,12 - # Python 3.12 fails since cibuildwheel still depends on distutils - # for musllinux - - os: ubuntu-20.04 - system_type: ["musllinux", "_1_1"] - arch: x86_64 - py_minors: 8,11 - # Python 3.12 fails since cibuildwheel still depends on distutils - # for musllinux + # Python 3.12 fails since cibuildwheel still depends on distutils + # for musllinux + #- os: ubuntu-20.04 + # system_type: ["manylinux", "2010"] + # arch: i686 + # py_minors: 8,9 + + # 32-bit musllinux - os: ubuntu-20.04 system_type: ["musllinux", "_1_2"] - arch: x86_64 + arch: i686 py_minors: 8,11 - - # See issue #220: https://github.com/SINTEF/dlite/issues/220 - # # 32-bit Windows - # - os: windows-2019 - # system_type: ["win32", ""] - # arch: "" - # py_minors: 7,10 + # Python 3.12 fails since cibuildwheel still depends on distutils + # for musllinux + #- os: ubuntu-20.04 + # system_type: ["musllinux", "_1_1"] + # arch: i686 + # py_minors: 8,11 # 64-bit Windows - os: windows-2019 @@ -80,8 +78,15 @@ jobs: arch: amd64 py_minors: 8,12 + # 32-bit Windows + # See issue #220: https://github.com/SINTEF/dlite/issues/220 + # - os: windows-2019 + # system_type: ["win32", ""] + # arch: "" + # py_minors: 7,10 + + # 64-bit (Intel) macOS # See issue #221: https://github.com/SINTEF/dlite/issues/221 - # # 64-bit (Intel) macOS # - os: macos-10.15 # system_type: ["macosx", ""] # arch: x86_64 From 3f48e43fd6ab1357f1791b501c369bedd1e0f3ae Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Tue, 26 Nov 2024 08:09:47 +0100 Subject: [PATCH 09/17] Filter out pumongo, redis and minio on manylinux 2014 --- .github/docker/Dockerfile-manylinux.template | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/docker/Dockerfile-manylinux.template b/.github/docker/Dockerfile-manylinux.template index 5012aecc0..c752126a1 100644 --- a/.github/docker/Dockerfile-manylinux.template +++ b/.github/docker/Dockerfile-manylinux.template @@ -81,6 +81,9 @@ RUN \ -e '/scikit-image/d' \ -e '/ncempy/d' \ -e '/h5py/d' \ + -e '/pymongo/d' \ + -e '/redis/d' \ + -e '/minio/d' \ -i /tmp/requirements_full.txt ARG PY_MINORS="{{ PY_MINORS }}" From 39de9e3556478a23d6a7f349cbef546f77f3630a Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Wed, 27 Nov 2024 09:53:12 +0100 Subject: [PATCH 10/17] Avoid double definition of HAVE_SETENV --- src/config-paths.h.in | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/config-paths.h.in b/src/config-paths.h.in index 28f9ee936..33e9237ab 100644 --- a/src/config-paths.h.in +++ b/src/config-paths.h.in @@ -25,9 +25,17 @@ /* dlite-pyembed.c does not imports config.h to avoid conflicts with Python .h Include configurations needed by dlite-pyembed.c here */ +#ifndef HAVE_SETENV #cmakedefine HAVE_SETENV +#endif + +#ifndef HAVE__PUTENV_S #cmakedefine HAVE__PUTENV_S +#endif + +#ifndef HAVE_UNSETENV #cmakedefine HAVE_UNSETENV +#endif From a6eda606c880e6659bb64456ce6ce1399ceb7b6b Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Wed, 27 Nov 2024 10:07:14 +0100 Subject: [PATCH 11/17] Added swig to swig requirements_dev.txt --- .github/docker/Dockerfile-manylinux.template | 1 - .github/docker/Dockerfile-manylinux_x_y.template | 1 - .github/workflows/cd_docs.yml | 14 +++++++------- .github/workflows/ci_tests.yml | 1 - doc/contributors_guide/tips_and_tricks.md | 2 +- python/setup.py | 10 ++++++++-- requirements_dev.txt | 3 ++- 7 files changed, 18 insertions(+), 14 deletions(-) diff --git a/.github/docker/Dockerfile-manylinux.template b/.github/docker/Dockerfile-manylinux.template index c90bb0376..8b3742f93 100644 --- a/.github/docker/Dockerfile-manylinux.template +++ b/.github/docker/Dockerfile-manylinux.template @@ -48,7 +48,6 @@ RUN \ https://mirrors.rpmfusion.org/free/el/rpmfusion-free-release-$(rpm --eval %{centos_ver}).noarch.rpm \ https://mirrors.rpmfusion.org/nonfree/el/rpmfusion-nonfree-release-$(rpm --eval %{centos_ver}).noarch.rpm && \ yum install -y \ - swig \ redland-devel \ rasqal-devel \ libcurl-devel \ diff --git a/.github/docker/Dockerfile-manylinux_x_y.template b/.github/docker/Dockerfile-manylinux_x_y.template index 048a4a875..a3c355af0 100644 --- a/.github/docker/Dockerfile-manylinux_x_y.template +++ b/.github/docker/Dockerfile-manylinux_x_y.template @@ -50,7 +50,6 @@ RUN \ dnf install -y \ redland-devel \ rasqal-devel \ - swig \ libcurl-devel \ libxslt-devel \ libxml2-devel \ diff --git a/.github/workflows/cd_docs.yml b/.github/workflows/cd_docs.yml index 8984813d5..dd6cc1d1a 100644 --- a/.github/workflows/cd_docs.yml +++ b/.github/workflows/cd_docs.yml @@ -46,7 +46,6 @@ jobs: libxml2-dev \ libxslt-dev \ libhdf5-dev \ - swig4.0 \ doxygen \ graphviz \ python3 \ @@ -56,19 +55,20 @@ jobs: python3-yaml #python3 -m pip install psycopg2-binary==2.9.5 + - name: Install Python dependencies + run: | + pip install --upgrade pip + pip install -U setuptools wheel + pip install -r requirements.txt -r requirements_doc.txt -r requirements_dev.txt + - name: Available version of installed programs run: | python --version swig -version + cmake -version doxygen --version dot -V - - name: Install Python dependencies - run: | - pip install --upgrade pip - pip install -U setuptools wheel - pip install -r requirements.txt -r requirements_doc.txt - - name: Run CMAKE run: | mkdir -p build diff --git a/.github/workflows/ci_tests.yml b/.github/workflows/ci_tests.yml index a4d9d3f01..6a10df7a0 100644 --- a/.github/workflows/ci_tests.yml +++ b/.github/workflows/ci_tests.yml @@ -42,7 +42,6 @@ jobs: libxml2-dev \ libxslt-dev \ libhdf5-dev \ - swig4.0 \ doxygen \ graphviz \ python3 \ diff --git a/doc/contributors_guide/tips_and_tricks.md b/doc/contributors_guide/tips_and_tricks.md index cb59a91c4..a163b1360 100644 --- a/doc/contributors_guide/tips_and_tricks.md +++ b/doc/contributors_guide/tips_and_tricks.md @@ -127,7 +127,7 @@ Debugging tests failing inside docker on GitHub ls /tmp/cibuildwheel/repaired_wheel/DLite_Python-*.whl - pip install /tmp/cibuildwheel/repaired_wheel/DLite_Python-0.3.18-cp312-cp312m-manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl + pip install /tmp/cibuildwheel/repaired_wheel/DLite_Python-*.whl 8. Now we can run the Python tests with diff --git a/python/setup.py b/python/setup.py index 91e04c267..fa95fdf9a 100644 --- a/python/setup.py +++ b/python/setup.py @@ -67,6 +67,12 @@ raise NotImplementedError(f"Unsupported platform: {platform.system()}") +requirements = [line.strip() for line in open("requirements.txt", "rt")] +requirements_dev = [ + line.strip() for line in open("requirements_dev.txt", "rt") +] + + class CMakeExtension(Extension): """ setuptools.Extension for cmake @@ -209,8 +215,8 @@ def run(self): "Programming Language :: Python :: 3.12", "Topic :: Software Development :: Libraries :: Python Modules", ], - install_requires="numpy>=1.14.5,<1.27.0", - #install_requires=requirements, + build_requires=requirements_dev, + install_requires=requirements, #extras_require=extra_requirements, packages=["DLite-Python"], scripts=[ diff --git a/requirements_dev.txt b/requirements_dev.txt index 7c3f4051b..2b5bb3a34 100644 --- a/requirements_dev.txt +++ b/requirements_dev.txt @@ -1,5 +1,6 @@ # Requirements building -cmake>=1.21.6 +swig==4.2.1 +cmake==3.31.1 # Requirements for running tests mongomock>=4.1.2,<5 From 51e3943568322bf92a5734b7ad9146b205c24ed4 Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Wed, 27 Nov 2024 10:24:18 +0100 Subject: [PATCH 12/17] Corrected directory path --- python/setup.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/python/setup.py b/python/setup.py index fa95fdf9a..fcc0dcab6 100644 --- a/python/setup.py +++ b/python/setup.py @@ -20,7 +20,7 @@ # Based on # https://github.com/galois-advertising/cmake_setup/blob/master/cmake_setup/cmake/__init__.py -SETUP_DIR = Path(__file__).parent.resolve() +SETUP_DIR = Path(__file__).resolve().parent SOURCE_DIR = SETUP_DIR.parent if platform.system() == "Linux": @@ -67,9 +67,11 @@ raise NotImplementedError(f"Unsupported platform: {platform.system()}") -requirements = [line.strip() for line in open("requirements.txt", "rt")] +requirements = [ + line.strip() for line in open(SOURCE_DIR/"requirements.txt", "rt") +] requirements_dev = [ - line.strip() for line in open("requirements_dev.txt", "rt") + line.strip() for line in open(SOURCE_DIR/"requirements_dev.txt", "rt") ] From d778f44da890ad3c24ac2cc7c4192a28e1670e18 Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Wed, 27 Nov 2024 14:03:29 +0100 Subject: [PATCH 13/17] Support restricted variable assignment in bash --- .github/docker/gen_dockerfile.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/docker/gen_dockerfile.sh b/.github/docker/gen_dockerfile.sh index d54cf98dc..376c22f91 100755 --- a/.github/docker/gen_dockerfile.sh +++ b/.github/docker/gen_dockerfile.sh @@ -19,7 +19,11 @@ fi SYSTEM=$1 SYSTEM_TYPE=$2 ARCH=$3 -PY_MINORS="${4:=8 9 10 11 12}" +if [[ $# -ge 4 ]]; then + PY_MINORS="$4" +else + PY_MINORS="8 9 10 11 12" +fi SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd -P ) From 65018b4867a8d288afab31f0750003018d3a6dc0 Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Wed, 27 Nov 2024 16:13:47 +0100 Subject: [PATCH 14/17] Removed requirements_full from manylinux i686 container --- .github/docker/Dockerfile-manylinux.template | 39 ++++++-------------- 1 file changed, 11 insertions(+), 28 deletions(-) diff --git a/.github/docker/Dockerfile-manylinux.template b/.github/docker/Dockerfile-manylinux.template index 8cb707e5a..3980c43cd 100644 --- a/.github/docker/Dockerfile-manylinux.template +++ b/.github/docker/Dockerfile-manylinux.template @@ -1,6 +1,8 @@ # -*- Mode: Dockerfile -*- -# Template Dockerfile for building Python pypi package. Going to be -# superseeded by Dockerfile-manylinux_x_y.template +# Template Dockerfile for manylinux 2010 and 2014 for building Python pypi package. +# Is superseeded by the Dockerfile-manylinux_x_y.template, but will continue to be used to support i686 architectures. +# +# On these old systems we do not install requirements_full.txt # # Usage: # @@ -17,21 +19,21 @@ # # Generate dockerfile: # -# .github/docker/gen_dockerfile.sh manylinux 2014 x86_64 > \ -# .github/docker/dockerfiles/Dockerfile-manylinux2014_x86_64 +# .github/docker/gen_dockerfile.sh manylinux 2014 i686 > \ +# .github/docker/dockerfiles/Dockerfile-manylinux2014_i686 # # Build: # # cd dlite # cd to DLite root directory -# docker build -t dlite-manylinux2014_x86_64 \ -# -f .github/docker/dockerfiles/Dockerfile-manylinux2014_x86_64 . +# docker build -t dlite-manylinux2014_i686 \ +# -f .github/docker/dockerfiles/Dockerfile-manylinux2014_i686 . # # Run (for debugging): # # docker run --rm -it \ # --volume $PWD:/io \ # --user $(id -u):$(id -g) \ -# dlite-manylinux2014_x86_64 \ +# dlite-manylinux2014_i686 \ # /bin/bash # @@ -54,9 +56,7 @@ RUN \ libcurl-devel \ libxslt-devel \ libxml2-devel \ - libffi-devel \ - rust \ - cargo && \ + libffi-devel && \ # hdf5-devel is needed for building the hdf5 plugin yum install -y hdf5-devel || true && \ # Unpack static libraries @@ -67,23 +67,7 @@ RUN \ # Filter out challenging packages from requirements sed \ -e '/mongomock/d' \ - -i /tmp/requirements_dev.txt && \ - sed \ - -e '/pandas/d' \ - -e '/pyarrow/d' \ - -e '/tables/d' \ - -e '/openpyxl/d' \ - -e '/jinja2/d' \ - -e '/pydantic/d' \ - -e '/fortran-language-server/d' \ - -e '/matplotlib/d' \ - -e '/scikit-image/d' \ - -e '/ncempy/d' \ - -e '/h5py/d' \ - -e '/pymongo/d' \ - -e '/redis/d' \ - -e '/minio/d' \ - -i /tmp/requirements_full.txt + -i /tmp/requirements_dev.txt ARG PY_MINORS="{{ PY_MINORS }}" @@ -97,7 +81,6 @@ RUN \ python3.${minor} -m pip install --cache-dir=/ci/pip_cache \ -r /tmp/requirements.txt \ -r /tmp/requirements_dev.txt \ - -r /tmp/requirements_full.txt; \ done && \ rm -rf /ci/pip_cache From 9b10e5ec5fbda156fd7a042c6e38b2e9e7a3523a Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Wed, 27 Nov 2024 16:49:15 +0100 Subject: [PATCH 15/17] Fixed typo and updated table of pre-build binaries --- .github/docker/Dockerfile-manylinux.template | 2 +- doc/getting_started/installation.md | 36 ++++++-------------- 2 files changed, 11 insertions(+), 27 deletions(-) diff --git a/.github/docker/Dockerfile-manylinux.template b/.github/docker/Dockerfile-manylinux.template index 3980c43cd..cda258815 100644 --- a/.github/docker/Dockerfile-manylinux.template +++ b/.github/docker/Dockerfile-manylinux.template @@ -80,7 +80,7 @@ RUN \ -U setuptools wheel && \ python3.${minor} -m pip install --cache-dir=/ci/pip_cache \ -r /tmp/requirements.txt \ - -r /tmp/requirements_dev.txt \ + -r /tmp/requirements_dev.txt; \ done && \ rm -rf /ci/pip_cache diff --git a/doc/getting_started/installation.md b/doc/getting_started/installation.md index 91e339a43..6bce1f04f 100644 --- a/doc/getting_started/installation.md +++ b/doc/getting_started/installation.md @@ -30,30 +30,16 @@ The complete list of extra requirements is as follows: ### Supported binary releases DLite uses [cibuildwheel] for providing binary releases for Linux and Windows on various platforms and versions of Python. The provided -wheels are shown in the following two tables. +wheels are shown in the following table. -#### 32-bit - -| Python version | 3.8 | 3.9 | 3.10 | 3.11 | 3.12 | -| ---------------- | --- | --- | ---- | ---- | ---- | -| [musllinux_1_1] | x | x | x | x | | -| [musllinux_1_2] | x | x | x | x | | -| [manylinux2010] | x | x | | | | -| [manylinux2014] | x | x | x | x | | -| [manylinux_2_28] | | | | | | -| windows | | | | | | - -#### 64-bit - -| Python version | 3.8 | 3.9 | 3.10 | 3.11 | 3.12 | -| ---------------- | --- | --- | ---- | ---- | ---- | -| [musllinux_1_1] | x | x | x | x | | -| [musllinux_1_2] | x | x | x | x | | -| [manylinux2010] | x | x | | | | -| [manylinux2014] | x | x | x | x | x | -| [manylinux_2_28] | x | x | x | x | x | -| windows | x | x | x | x | x | +| Platform | Arch | 3.8 | 3.9 | 3.10 | 3.11 | 3.12 | +|------------------|--------|-----|-----|------|------|------| +| [manylinux_2_34] | x86_64 | x | x | x | x | x | +| [manylinux2014] | i686 | x | x | x | x | x | +| [musllinux_1_2] | x86_64 | x | x | x | x | | +| [musllinux_1_2] | i686 | x | x | x | x | | +| windows | x86_64 | x | x | x | x | x | Development installation @@ -80,8 +66,6 @@ pip install DLite-Python[doc] [runtime dependencies]: https://sintef.github.io/dlite/getting_started/build/runtime_dependencies.html [build from source]: https://sintef.github.io/dlite/getting_started/build/build.html [cibuildwheel]: https://github.com/pypa/cibuildwheel -[musllinux_1_1]: https://peps.python.org/pep-0656/ -[musllinux_1_2]: https://peps.python.org/pep-0656/ -[manylinux2010]: https://github.com/pypa/manylinux?tab=readme-ov-file#manylinux2014-centos-7-based [manylinux2014]: https://github.com/pypa/manylinux?tab=readme-ov-file#manylinux2014-centos-7-based -[manylinux_2_28]: https://github.com/pypa/manylinux?tab=readme-ov-file#manylinux_2_28-almalinux-8-based +[manylinux_2_34]: https://github.com/pypa/manylinux?tab=readme-ov-file#manylinux_2_34-almalinux-9-base +[musllinux_1_2]: https://peps.python.org/pep-0656/ From 4ba7cc65be8dc567b5b87361f8c1d098cc99fd93 Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Wed, 27 Nov 2024 18:12:24 +0100 Subject: [PATCH 16/17] Bumbed down requirement on swig to v4.1.1 --- requirements_dev.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements_dev.txt b/requirements_dev.txt index 2b5bb3a34..6ac8a04ba 100644 --- a/requirements_dev.txt +++ b/requirements_dev.txt @@ -1,5 +1,5 @@ # Requirements building -swig==4.2.1 +swig==4.1.1 cmake==3.31.1 # Requirements for running tests From df73889c36498778058805c07ed75e03af73cbff Mon Sep 17 00:00:00 2001 From: Jesper Friis Date: Wed, 27 Nov 2024 23:51:52 +0100 Subject: [PATCH 17/17] Avoid failure with swig 4.3.0 --- bindings/python/dlite-misc.i | 25 +++++++++++++++-------- doc/contributors_guide/tips_and_tricks.md | 8 ++++---- 2 files changed, 20 insertions(+), 13 deletions(-) diff --git a/bindings/python/dlite-misc.i b/bindings/python/dlite-misc.i index 77aa46fd5..d4d6758f3 100644 --- a/bindings/python/dlite-misc.i +++ b/bindings/python/dlite-misc.i @@ -10,18 +10,24 @@ return dlite_get_uuid(buff, id); } - status_t split_url(char *url, char **driver, char **location, + void split_meta_uri(const char *uri, char **name, char **version, + char **namespace) { + dlite_split_meta_uri(uri, name, version, namespace); + } + + void split_url(char *url, char **driver, char **location, char **options, char **fragment) { - status_t retval=0; + char *url2, *drv=NULL, *loc=NULL, *opt=NULL, *frg=NULL; - if (!(url2 = strdup(url))) return dlite_err(1, "allocation failure"); - retval = dlite_split_url(url, &drv, &loc, &opt, &frg); + if ((url2 = strdup(url))) + dlite_split_url(url2, &drv, &loc, &opt, &frg); + else + dlite_err(dliteMemoryError, "allocation failure"); if (driver) *driver = strdup((drv) ? drv : ""); if (location) *location = strdup((loc) ? loc : ""); if (options) *options = strdup((opt) ? opt : ""); if (fragment) *fragment = strdup((frg) ? frg : ""); - free(url2); - return retval; + if (url2) free(url2); } bool asbool(const char *str) { @@ -115,8 +121,8 @@ Returns (name, version, namespace)-tuplet from valid metadata `uri`. %cstring_output_allocate(char **name, if (*$1) free(*$1)); %cstring_output_allocate(char **version, if (*$1) free(*$1)); %cstring_output_allocate(char **namespace, if (*$1) free(*$1)); -status_t dlite_split_meta_uri(const char *uri, char **name, char **version, - char **namespace); +void split_meta_uri(const char *uri, char **name, char **version, + char **namespace); //int dlite_option_parse(char *options, DLiteOpt *opts, int modify); @@ -139,11 +145,12 @@ Returns a (driver, location, options, fragment)-tuplet by splitting into four parts. ") split_url; +%feature("numoutputs", "0") split_url; %cstring_output_allocate(char **driver, if (*$1) free(*$1)); %cstring_output_allocate(char **location, if (*$1) free(*$1)); %cstring_output_allocate(char **options, if (*$1) free(*$1)); %cstring_output_allocate(char **fragment, if (*$1) free(*$1)); -status_t split_url(char *url, char **driver, char **location, +void split_url(char *url, char **driver, char **location, char **options, char **fragment); diff --git a/doc/contributors_guide/tips_and_tricks.md b/doc/contributors_guide/tips_and_tricks.md index a163b1360..971653f14 100644 --- a/doc/contributors_guide/tips_and_tricks.md +++ b/doc/contributors_guide/tips_and_tricks.md @@ -63,7 +63,7 @@ Debugging tests failing inside docker on GitHub 3. To list all manylinux images for Python 3.12, do cd dlite # Root of DLite source directory - CIBW_MANYLINUX_X86_64_IMAGE=ghcr.io/sintef/dlite-python-manylinux_2_28_x86_64:latest \ + CIBW_MANYLINUX_X86_64_IMAGE=ghcr.io/sintef/dlite-python-manylinux_2_34_x86_64:latest \ CIBW_BUILD=cp312-manylinux_* \ python -m cibuildwheel \ --print-build-identifiers \ @@ -77,7 +77,7 @@ Debugging tests failing inside docker on GitHub 4. Run image. For example, to run the image `cp312-manylinux_x86_64` do - CIBW_MANYLINUX_X86_64_IMAGE=ghcr.io/sintef/dlite-python-manylinux_2_28_x86_64:latest \ + CIBW_MANYLINUX_X86_64_IMAGE=ghcr.io/sintef/dlite-python-manylinux_2_34_x86_64:latest \ CIBW_BUILD=cp312-manylinux_x86* \ python -m cibuildwheel \ --output-dir wheelhouse \ @@ -92,7 +92,7 @@ Debugging tests failing inside docker on GitHub the previous command: CIBW_BEFORE_TEST=cat \ - CIBW_MANYLINUX_X86_64_IMAGE=ghcr.io/sintef/dlite-python-manylinux_2_28_x86_64:latest \ + CIBW_MANYLINUX_X86_64_IMAGE=ghcr.io/sintef/dlite-python-manylinux_2_34_x86_64:latest \ CIBW_BUILD=cp312-manylinux_x86* \ python -m cibuildwheel \ --output-dir wheelhouse \ @@ -146,7 +146,7 @@ and get its IP with You can then rerun `cibuildwheel` with the CIBW_BUILD_FRONTEND="pip; args: --index-url http://$ip:3141/root/pypi/" \ - CIBW_MANYLINUX_X86_64_IMAGE=ghcr.io/sintef/dlite-python-manylinux_2_28_x86_64:latest \ + CIBW_MANYLINUX_X86_64_IMAGE=ghcr.io/sintef/dlite-python-manylinux_2_34_x86_64:latest \ CIBW_BUILD=cp312-manylinux_x86* \ python -m cibuildwheel \ --output-dir wheelhouse \