From 2e6ed1141fb4859f0a7d93e70a5546f1eecbe471 Mon Sep 17 00:00:00 2001 From: Marius Gedminas Date: Wed, 29 Oct 2025 09:18:36 +0200 Subject: [PATCH 1/3] Add Python 3.14 support, drop 3.8 and 3.9 --- .github/workflows/build.yml | 3 +-- CHANGES.rst | 4 +++- appveyor.yml | 3 +-- setup.py | 5 ++--- tox.ini | 2 +- 5 files changed, 8 insertions(+), 9 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index eda2790..7785f88 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -20,12 +20,11 @@ jobs: strategy: matrix: python-version: - - "3.8" - - "3.9" - "3.10" - "3.11" - "3.12" - "3.13" + - "3.14" - "pypy3.10" steps: diff --git a/CHANGES.rst b/CHANGES.rst index f16f939..be150b8 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -4,7 +4,9 @@ Changes 1.9.0 (unreleased) ------------------ -- Drop Python 3.7 support. +- Add Python 3.14 support. + +- Drop Python 3.7, 3.8 and 3.9 support. 1.8.0 (2024-10-09) diff --git a/appveyor.yml b/appveyor.yml index 4293584..d46c7fe 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -4,12 +4,11 @@ environment: matrix: # https://www.appveyor.com/docs/installed-software#python lists available # versions - - PYTHON: "C:\\Python38-x64" - - PYTHON: "C:\\Python39-x64" - PYTHON: "C:\\Python310-x64" - PYTHON: "C:\\Python311-x64" - PYTHON: "C:\\Python312-x64" - PYTHON: "C:\\Python313-x64" + - PYTHON: "C:\\Python314-x64" init: - "echo %PYTHON%" diff --git a/setup.py b/setup.py index 6b5a441..e1186cf 100755 --- a/setup.py +++ b/setup.py @@ -49,17 +49,16 @@ def get_description(): 'Intended Audience :: End Users/Desktop', 'License :: OSI Approved :: MIT License', 'Operating System :: OS Independent', - 'Programming Language :: Python :: 3.8', - 'Programming Language :: Python :: 3.9', 'Programming Language :: Python :: 3.10', 'Programming Language :: Python :: 3.11', 'Programming Language :: Python :: 3.12', 'Programming Language :: Python :: 3.13', + 'Programming Language :: Python :: 3.14', 'Programming Language :: Python :: Implementation :: CPython', 'Programming Language :: Python :: Implementation :: PyPy', 'Topic :: Multimedia :: Graphics', ], - python_requires=">=3.8", + python_requires=">=3.10", py_modules=['imgdiff'], zip_safe=False, install_requires=['Pillow'], diff --git a/tox.ini b/tox.ini index 6f4c796..49de3f0 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,6 @@ [tox] envlist = - py38,py39,py310,py311,py312,py313,pypy3 + py310,py311,py312,py313,py314,pypy3 [testenv] extras = test From dce8dcf05d191ffbb96df42e219f54190aac8647 Mon Sep 17 00:00:00 2001 From: Marius Gedminas Date: Wed, 29 Oct 2025 09:19:48 +0200 Subject: [PATCH 2/3] Drop Appveyor, add Windows builds to GHA --- .github/workflows/build.yml | 22 ++++++++++------------ appveyor.yml | 31 ------------------------------- 2 files changed, 10 insertions(+), 43 deletions(-) delete mode 100644 appveyor.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 7785f88..3306580 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -14,8 +14,8 @@ on: jobs: build: - name: Python ${{ matrix.python-version }} - runs-on: ubuntu-latest + name: Python ${{ matrix.python-version }} on ${{ matrix.os }} + runs-on: ${{ matrix.os }} strategy: matrix: @@ -26,6 +26,9 @@ jobs: - "3.13" - "3.14" - "pypy3.10" + os: + - ubuntu-latest + - windows-latest steps: - name: Git clone @@ -35,15 +38,10 @@ jobs: uses: actions/setup-python@v5 with: python-version: "${{ matrix.python-version }}" - - - name: Pip cache - uses: actions/cache@v4 - with: - path: ~/.cache/pip - key: ${{ runner.os }}-pip-${{ matrix.python-version }}-${{ hashFiles('setup.py') }} - restore-keys: | - ${{ runner.os }}-pip-${{ matrix.python-version }}- - ${{ runner.os }}-pip- + cache: pip + cache-dependency-path: | + setup.py + tox.ini - name: Install OS-level dependencies (Linux) if: runner.os == 'Linux' && matrix.python-version == 'pypy3.10' @@ -55,7 +53,7 @@ jobs: python -m pip install -U pip python -m pip install -U setuptools wheel python -m pip install -U coverage - python -m pip install -e .[test] + python -m pip install -e '.[test]' - name: Run tests run: coverage run tests.py diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644 index d46c7fe..0000000 --- a/appveyor.yml +++ /dev/null @@ -1,31 +0,0 @@ -version: build-{build}-{branch} - -environment: - matrix: - # https://www.appveyor.com/docs/installed-software#python lists available - # versions - - PYTHON: "C:\\Python310-x64" - - PYTHON: "C:\\Python311-x64" - - PYTHON: "C:\\Python312-x64" - - PYTHON: "C:\\Python313-x64" - - PYTHON: "C:\\Python314-x64" - -init: - - "echo %PYTHON%" - -install: - - ps: | - if (-not (Test-Path $env:PYTHON)) { - curl -o install_python.ps1 https://raw.githubusercontent.com/matthew-brett/multibuild/11a389d78892cf90addac8f69433d5e22bfa422a/install_python.ps1 - .\install_python.ps1 - } - - ps: if (-not (Test-Path $env:PYTHON)) { throw "No $env:PYTHON" } - - "set PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%" - - python --version - - pip install -U virtualenv # upgrade pip in tox's virtualenvs - - pip install tox - -build: off - -test_script: - - tox -e py From 42e57fef949a8b22c7eae699ac6e1430b59668b2 Mon Sep 17 00:00:00 2001 From: Marius Gedminas Date: Wed, 29 Oct 2025 09:31:26 +0200 Subject: [PATCH 3/3] Do not test PyPy on Windows I've no idea how one automates downloading and installing zlib and libjpeg development headers on this OS. --- .github/workflows/build.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3306580..2aec68a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -25,10 +25,15 @@ jobs: - "3.12" - "3.13" - "3.14" - - "pypy3.10" os: - ubuntu-latest - windows-latest + include: + # pypy on windows has trouble building Pillow from source because + # how are you going to apt-get install -y zlib-dev libjpeg-dev + # when you're on Windows, eh? + - python-version: "pypy3.10" + os: ubuntu-latest steps: - name: Git clone