From 7775449f2b12bf72d5ca11bacf4854ade70f1bfb Mon Sep 17 00:00:00 2001 From: Mathias Ertl Date: Wed, 27 Dec 2023 17:44:28 +0100 Subject: [PATCH] add support for Django 5.0 and acme 2.8 --- .github/workflows/tests.yml | 7 ++++++- devscripts/validation/state.py | 4 ++-- docs/source/changelog.rst | 2 ++ pyproject.toml | 5 +++-- tox.ini | 5 ++++- 5 files changed, 17 insertions(+), 6 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index f6b8b1a0f..25838d08e 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -13,8 +13,13 @@ jobs: matrix: os: [ ubuntu-latest ] python-version: [ "3.8", "3.9", "3.10", "3.11", "3.12" ] - django-version: [ "4.2" ] + django-version: [ "4.2", "5.0", ] cryptography-version: [ "41.0" ] + exclude: + - python-version: 3.8 + django-version: 5.0 + - python-version: 3.9 + django-version: 5.0 name: Python ${{ matrix.python-version }}, Django ${{ matrix.django-version }}, cryptography ${{ matrix.cryptography-version }} steps: diff --git a/devscripts/validation/state.py b/devscripts/validation/state.py index 497f9f358..63efe6f82 100644 --- a/devscripts/validation/state.py +++ b/devscripts/validation/state.py @@ -28,7 +28,7 @@ from devscripts import config from devscripts.commands import CommandError, DevCommand -from devscripts.out import err, ok +from devscripts.out import err, info, ok if typing.TYPE_CHECKING: # pragma: only py<3.10 # remove TYPE_CHECKING check once support for 3.9 is dropped # protected by TYPE_CHECKING as ParamSpec is new in Python 3.10. @@ -138,7 +138,7 @@ def check_tox() -> int: # pylint: enable=consider-using-f-string # Check disabled as long as different Django versions support different Python versions if expected_env_list not in tox_config["tox"]["envlist"].splitlines(): - errors += err(f"Expected envlist item not found: {expected_env_list}") + info(f"(disabled) Expected envlist item not found: {expected_env_list}") # Check that conditional dependencies are up-to-date for component in ["django", "cryptography", "acme"]: diff --git a/docs/source/changelog.rst b/docs/source/changelog.rst index 8977bb942..67116eeae 100644 --- a/docs/source/changelog.rst +++ b/docs/source/changelog.rst @@ -10,6 +10,8 @@ ChangeLog 1.28.0 (TBR) ************ +* Add support for ``Django~=5.0`` and ``acme==2.8.0``. + REST API changes ================ diff --git a/pyproject.toml b/pyproject.toml index 2bf983712..6c5231199 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -9,9 +9,9 @@ build-backend = "setuptools.build_meta" # https://devguide.python.org/versions/#versions python = ["3.8", "3.9", "3.10", "3.11", "3.12"] # https://www.djangoproject.com/download/ -django = ["4.2"] +django = ["4.2", "5.0"] cryptography = ["41.0"] -acme = ["2.7"] +acme = ["2.7", "2.8"] # https://alpinelinux.org/releases/ alpine = [ @@ -70,6 +70,7 @@ description = "A Django app providing a TLS certificate authority." classifiers = [ "Development Status :: 5 - Production/Stable", "Framework :: Django :: 4.2", + "Framework :: Django :: 5.0", "Framework :: Django", "Intended Audience :: Developers", "Intended Audience :: System Administrators", diff --git a/tox.ini b/tox.ini index 4df62453c..d0e6ebbf8 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,7 @@ [tox] envlist = pylint,docs,lint,mypy,demo,dist-test - py{38,39,310,311,312}-dj{4.2}-cg{41.0}-acme{2.7} + py{310,311,312}-dj{5.0}-cg{41.0}-acme{2.7,2.8} + py{38,39,310,311,312}-dj{4.2}-cg{41.0}-acme{2.7,2.8} [testenv] skipsdist = True @@ -8,8 +9,10 @@ deps = -r requirements.txt -r requirements/requirements-test.txt dj4.2: Django~=4.2 + dj5.0: Django~=5.0 cg41.0: cryptography~=41.0 acme2.7: acme~=2.7 + acme2.8: acme~=2.8 setenv = COVERAGE_FILE = {envdir}/.coverage commands =