From 6c7aa97e7d805d30f278543c410ac720f2381266 Mon Sep 17 00:00:00 2001 From: benoit74 Date: Tue, 4 Nov 2025 09:28:07 +0000 Subject: [PATCH 1/2] Upgrade CI actions --- .github/workflows/CI-wheels.yaml | 10 +++++----- .github/workflows/Publish.yaml | 20 ++++++++++---------- .github/workflows/QA.yaml | 4 ++-- .github/workflows/Tests.yaml | 6 +++--- pyproject.toml | 4 ++-- 5 files changed, 22 insertions(+), 22 deletions(-) diff --git a/.github/workflows/CI-wheels.yaml b/.github/workflows/CI-wheels.yaml index 754b925..53f1df3 100644 --- a/.github/workflows/CI-wheels.yaml +++ b/.github/workflows/CI-wheels.yaml @@ -22,7 +22,7 @@ jobs: os: [macos-13, windows-2022, ubuntu-24.04] steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Set up QEMU if: runner.os == 'Linux' @@ -31,9 +31,9 @@ jobs: platforms: all - name: Build wheels - uses: pypa/cibuildwheel@v2.22 + uses: pypa/cibuildwheel@v3.2 - - uses: actions/upload-artifact@v4 + - uses: actions/upload-artifact@v5 with: name: wheels-${{ matrix.os }} path: ./wheelhouse/*.whl @@ -42,12 +42,12 @@ jobs: name: Build source distribution runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Build sdist run: pipx run build --sdist - - uses: actions/upload-artifact@v4 + - uses: actions/upload-artifact@v5 with: name: sdist path: dist/*.tar.gz diff --git a/.github/workflows/Publish.yaml b/.github/workflows/Publish.yaml index 0330344..cb05e98 100644 --- a/.github/workflows/Publish.yaml +++ b/.github/workflows/Publish.yaml @@ -25,7 +25,7 @@ jobs: os: [ubuntu-24.04, macos-13, windows-2022] steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Set up QEMU if: runner.os == 'Linux' @@ -68,7 +68,7 @@ jobs: security unlock-keychain -p mysecretpassword ${APPLE_SIGNING_KEYCHAIN_PATH} - name: Build wheels - uses: pypa/cibuildwheel@v2.22 + uses: pypa/cibuildwheel@v3.2 - name: Cleanup Apple Keychain if: matrix.os == 'macos-13' @@ -78,7 +78,7 @@ jobs: security delete-keychain ${APPLE_SIGNING_KEYCHAIN_PATH} rm -f ${APPLE_SIGNING_KEYCHAIN_PATH} - - uses: actions/upload-artifact@v4 + - uses: actions/upload-artifact@v5 with: name: wheels-${{ matrix.os }} path: ./wheelhouse/*.whl @@ -87,12 +87,12 @@ jobs: name: Build source distribution runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Build sdist run: pipx run build --sdist - - uses: actions/upload-artifact@v4 + - uses: actions/upload-artifact@v5 with: name: sdist path: dist/*.tar.gz @@ -103,24 +103,24 @@ jobs: environment: release steps: # retrieve all artifacts - - uses: actions/download-artifact@v4 + - uses: actions/download-artifact@v6 with: name: sdist path: dist - - uses: actions/download-artifact@v4 + - uses: actions/download-artifact@v6 with: name: wheels-ubuntu-24.04 path: dist - - uses: actions/download-artifact@v4 + - uses: actions/download-artifact@v6 with: name: wheels-macos-13 path: dist - - uses: actions/download-artifact@v4 + - uses: actions/download-artifact@v6 with: name: wheels-windows-2022 path: dist - - uses: pypa/gh-action-pypi-publish@v1.9.0 + - uses: pypa/gh-action-pypi-publish@v1.13.0 with: user: __token__ # password: ${{ secrets.PYPI_TEST_API_TOKEN }} diff --git a/.github/workflows/QA.yaml b/.github/workflows/QA.yaml index 3be3e0c..cc24490 100644 --- a/.github/workflows/QA.yaml +++ b/.github/workflows/QA.yaml @@ -9,10 +9,10 @@ jobs: lint: runs-on: ubuntu-24.04 steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Set up Python - uses: actions/setup-python@v5 + uses: actions/setup-python@v6 with: python-version: "3.13" architecture: x64 diff --git a/.github/workflows/Tests.yaml b/.github/workflows/Tests.yaml index 7a8c746..9fa3682 100644 --- a/.github/workflows/Tests.yaml +++ b/.github/workflows/Tests.yaml @@ -16,10 +16,10 @@ jobs: python: ["3.9", "3.10", "3.11", "3.12", "3.13"] steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Set up Python ${{ matrix.python }} - uses: actions/setup-python@v5 + uses: actions/setup-python@v6 with: python-version: ${{ matrix.python }} architecture: x64 @@ -39,7 +39,7 @@ jobs: - name: Upload coverage report to codecov if: matrix.os == 'ubuntu-24.04' && matrix.python == '3.13' - uses: codecov/codecov-action@v4 + uses: codecov/codecov-action@v5 with: fail_ci_if_error: true token: ${{ secrets.CODECOV_TOKEN }} diff --git a/pyproject.toml b/pyproject.toml index 9d127c1..3b8397c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -3,8 +3,8 @@ requires = [ "setuptools == 74.1.1", "wheel == 0.44.0", "cython == 3.0.11", - # https://github.com/pypa/cibuildwheel/blob/v2.22/cibuildwheel/resources/constraints.txt - "delocate == 0.12.0 ; platform_system=='Windows'", + # https://github.com/pypa/cibuildwheel/blob/v3.2/cibuildwheel/resources/constraints.txt + "delocate == 0.13.0 ; platform_system=='Windows'", ] build-backend = "setuptools.build_meta" From 067fd05bdc253c72bec25a96b32deda713c510ef Mon Sep 17 00:00:00 2001 From: benoit74 Date: Tue, 4 Nov 2025 16:43:39 +0000 Subject: [PATCH 2/2] Add support for Python 3.14 --- .github/workflows/QA.yaml | 2 +- .github/workflows/Tests.yaml | 4 ++-- .readthedocs.yaml | 2 +- pyproject.toml | 11 ++++++----- 4 files changed, 10 insertions(+), 9 deletions(-) diff --git a/.github/workflows/QA.yaml b/.github/workflows/QA.yaml index cc24490..ea14c54 100644 --- a/.github/workflows/QA.yaml +++ b/.github/workflows/QA.yaml @@ -14,7 +14,7 @@ jobs: - name: Set up Python uses: actions/setup-python@v6 with: - python-version: "3.13" + python-version: "3.14" architecture: x64 - name: Install dependencies (and project) diff --git a/.github/workflows/Tests.yaml b/.github/workflows/Tests.yaml index 9fa3682..1426fb6 100644 --- a/.github/workflows/Tests.yaml +++ b/.github/workflows/Tests.yaml @@ -13,7 +13,7 @@ jobs: strategy: matrix: os: [macos-13, windows-2022, ubuntu-24.04] - python: ["3.9", "3.10", "3.11", "3.12", "3.13"] + python: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] steps: - uses: actions/checkout@v5 @@ -38,7 +38,7 @@ jobs: run: inv coverage --args "-vvv" - name: Upload coverage report to codecov - if: matrix.os == 'ubuntu-24.04' && matrix.python == '3.13' + if: matrix.os == 'ubuntu-24.04' && matrix.python == '3.14' uses: codecov/codecov-action@v5 with: fail_ci_if_error: true diff --git a/.readthedocs.yaml b/.readthedocs.yaml index c402260..05e3fdd 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -6,7 +6,7 @@ version: 2 build: os: ubuntu-24.04 tools: - python: '3.13' + python: '3.14' # custom commands to run mkdocs build within hatch, as suggested by maintainer in # https://github.com/readthedocs/readthedocs.org/issues/10706 diff --git a/pyproject.toml b/pyproject.toml index 3b8397c..fc4af70 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -11,7 +11,7 @@ build-backend = "setuptools.build_meta" [project] name = "libzim" version = "3.7.1-dev0" -requires-python = ">=3.9,<3.14" +requires-python = ">=3.9,<3.15" description = "A python-facing API for creating and interacting with ZIM files" authors = [ {name = "openZIM", email = "dev@kiwix.org"}, @@ -35,6 +35,7 @@ classifiers = [ "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", + "Programming Language :: Python :: 3.14", "Typing :: Stubs Only", "License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)", "Operating System :: MacOS", @@ -168,7 +169,7 @@ features = ["scripts", "test"] PROFILE = "1" [[tool.hatch.envs.test.matrix]] -python = ["3.9", "3.10", "3.11", "3.12", "3.13"] +python = ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] [tool.hatch.envs.test.scripts] run = "inv test --args '{args}'" @@ -206,10 +207,10 @@ all = "inv checkall --args '{args}'" [tool.black] line-length = 88 -target-version = ['py312'] +target-version = ['py314'] [tool.ruff] -target-version = "py312" +target-version = "py314" line-length = 88 src = ["src"] @@ -336,6 +337,6 @@ exclude_lines = [ [tool.pyright] include = ["libzim", "tests", "tasks.py"] exclude = [".env/**", ".venv/**"] -pythonVersion = "3.13" +pythonVersion = "3.14" typeCheckingMode="basic" disableBytesTypePromotions = true