From 88d80c2ecc7fd7bee70cde472230af2ed2a2db59 Mon Sep 17 00:00:00 2001 From: Ben Konrath Date: Mon, 4 Nov 2024 15:31:17 +0100 Subject: [PATCH 1/5] Update test matrix for new Python and Django versions --- .github/workflows/tests.yml | 5 ++++- .pre-commit-config.yaml | 2 +- CHANGELOG.md | 6 ++++-- setup.py | 1 + tox.ini | 16 ++++++++++------ 5 files changed, 20 insertions(+), 10 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index b35c32e..c711a9e 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -13,7 +13,7 @@ jobs: - uses: actions/checkout@v3 - uses: actions/setup-python@v4 with: - python-version: '3.12' + python-version: '3.13' - name: Install tox run: | python -m pip install --upgrade pip @@ -48,6 +48,9 @@ jobs: - '3.10' - '3.11' - '3.12' + - '3.13' + - 'py3.9' + - 'py3.10' name: Python ${{ matrix.python-version }} steps: - uses: actions/checkout@v3 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 679d95d..bc60fd8 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,5 +1,5 @@ default_language_version: - python: python3.12 + python: python3.13 minimum_pre_commit_version: 2.4.0 repos: - repo: https://github.com/pre-commit/pre-commit-hooks diff --git a/CHANGELOG.md b/CHANGELOG.md index fbf7e1f..341b558 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,10 +11,12 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. - Use Model.__str__() for related fields. In 1.x the primary key was used for related fields. ### Added -- Test on Django 3.2, 4.0, 4.1 and 4.2. -- Test on Python 3.9, 3.10 and 3.11 (for Django versions with support). - Add `verbose_names` option to control whether to use capitalized verbose column names in the header. The default is `True` which matches the behaviour in 1.x. +- Test on Django 3.2, 4.0, 4.1, 4.2, 5.0 and 5.1 +- Test on Python 3.9, 3.10, 3.11, 3.12 and 3.13. +- Remove tests using Pypy for Django >= 4.1. There is a Pypy bug preventing Django from working: + https://code.djangoproject.com/ticket/33889 ### Removed - Drop support for Python 2, 3.4 and 3.5. diff --git a/setup.py b/setup.py index c5c0007..56603a0 100644 --- a/setup.py +++ b/setup.py @@ -67,6 +67,7 @@ def get_version(): "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", + "Programming Language :: Python :: 3.13", "Topic :: Utilities", ], ) diff --git a/tox.ini b/tox.ini index 7175766..ee8d042 100644 --- a/tox.ini +++ b/tox.ini @@ -1,11 +1,12 @@ [tox] envlist = - {py36,py37,py38,py39,py310,pypy39}-django-3.2 - {py38,py39,py310,pypy39}-django-4.0 - {py38,py39,py310,py311,pypy39}-django-4.1 - {py38,py39,py310,py311,pypy39}-django-4.2 + {py36,py37,py38,py39,py310,pypy39,pypy310}-django-3.2 + {py38,py39,py310,pypy39,pypy310}-django-4.0 + {py38,py39,py310,py311}-django-4.1 + {py38,py39,py310,py311}-django-4.2 {py310,py311,py312}-django-5.0 - {py310,py311,py312}-django-main + {py310,py311,py312,py313}-django-5.1 + {py310,py311,py312,py313}-django-main skip_missing_interpreters = true [testenv] @@ -17,13 +18,16 @@ basepython = py310: python3.10 py311: python3.11 py312: python3.12 + py313: python3.13 pypy39: pypy3.9 + pypy310: pypy3.10 deps= django-3.2: Django>=3.2,<3.3 django-4.0: Django>=4.0,<4.1 django-4.1: Django>=4.1,<4.2 django-4.2: Django>=4.2,<4.3 django-5.0: Django>=5.0,<5.1 + django-5.1: Django>=5.1,<5.2 django-main: https://github.com/django/django/archive/main.tar.gz backports.zoneinfo;python_version<"3.9" coverage @@ -37,6 +41,6 @@ commands = [testenv:pre-commit] deps = pre-commit -basepython = python3.12 +basepython = python3.13 commands = pre-commit run --all-files --show-diff-on-failure From 2a2e070a04d83dae00ec82c80bd7fff2050c2336 Mon Sep 17 00:00:00 2001 From: Ben Konrath Date: Mon, 4 Nov 2024 15:32:07 +0100 Subject: [PATCH 2/5] Update pre-commit hooks --- .pre-commit-config.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index bc60fd8..9a3aa9a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -3,7 +3,7 @@ default_language_version: minimum_pre_commit_version: 2.4.0 repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.6.0 + rev: v5.0.0 hooks: - id: check-yaml - id: check-json @@ -20,13 +20,13 @@ repos: - id: isort - repo: https://github.com/psf/black - rev: 24.4.2 + rev: 24.10.0 hooks: - id: black # Flake8 includes pyflakes, pycodestyle, mccabe, pydocstyle, bandit - repo: https://github.com/pycqa/flake8 - rev: 7.1.0 + rev: 7.1.1 hooks: - id: flake8 additional_dependencies: ["flake8-bandit"] From b7ab0243f431d3ef61fc80910d24e9210fc2e244 Mon Sep 17 00:00:00 2001 From: Ben Konrath Date: Mon, 4 Nov 2024 15:40:44 +0100 Subject: [PATCH 3/5] Fix github actions pypy --- .github/workflows/tests.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index c711a9e..f58aef3 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -42,15 +42,15 @@ jobs: strategy: matrix: python-version: - - 3.7 - - 3.8 - - 3.9 + - '3.7' + - '3.8' + - '3.9' - '3.10' - '3.11' - '3.12' - '3.13' - - 'py3.9' - - 'py3.10' + - 'pypy3.9' + - 'pypy3.10' name: Python ${{ matrix.python-version }} steps: - uses: actions/checkout@v3 @@ -64,4 +64,4 @@ jobs: python -m pip install --upgrade pip python -m pip install --upgrade 'tox>=4.0' - name: Run tests - run: tox run -f py$(echo ${{ matrix.python-version }} | tr -d .) + run: tox run -f py$(echo ${{ matrix.python-version }} | sed "s/^py//" | tr -d .) From d1a6aaafc6aaf5cf2f7d472ff3a5096dfa808d43 Mon Sep 17 00:00:00 2001 From: Ben Konrath Date: Mon, 4 Nov 2024 15:50:43 +0100 Subject: [PATCH 4/5] Fix changelog --- CHANGELOG.md | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 341b558..64e9961 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,18 +5,24 @@ The format of this changelog is based on [Keep a Changelog](http://keepachangelo and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). ## [Unreleased] +### Added +- Test on Django 5.0 and 5.1. +- Test on Python 3.12 and 3.13 (for Django versions with support). +- Testing with Pypy 3.10 on Django < 4.1 (see note about Pypy in 'Removed' section). + +### Removed +- Remove testing with Pypy for Django >= 4.1. There is a Pypy bug preventing Django from working: + https://code.djangoproject.com/ticket/33889 ## [2.0.0] ### Changed - Use Model.__str__() for related fields. In 1.x the primary key was used for related fields. ### Added +- Test on Django 3.2, 4.0, 4.1 and 4.2. +- Test on Python 3.9, 3.10 and 3.11 (for Django versions with support). - Add `verbose_names` option to control whether to use capitalized verbose column names in the header. The default is `True` which matches the behaviour in 1.x. -- Test on Django 3.2, 4.0, 4.1, 4.2, 5.0 and 5.1 -- Test on Python 3.9, 3.10, 3.11, 3.12 and 3.13. -- Remove tests using Pypy for Django >= 4.1. There is a Pypy bug preventing Django from working: - https://code.djangoproject.com/ticket/33889 ### Removed - Drop support for Python 2, 3.4 and 3.5. From b156236ae8052c10c2d1644e9c56370c05e1398b Mon Sep 17 00:00:00 2001 From: Ben Konrath Date: Mon, 4 Nov 2024 15:52:03 +0100 Subject: [PATCH 5/5] Changelog tweak --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 64e9961..f6be25c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. - Testing with Pypy 3.10 on Django < 4.1 (see note about Pypy in 'Removed' section). ### Removed +- Stop building a universal wheel. - Remove testing with Pypy for Django >= 4.1. There is a Pypy bug preventing Django from working: https://code.djangoproject.com/ticket/33889