From 80bebe00d412f0c5220127d65410fec8f6f517c6 Mon Sep 17 00:00:00 2001 From: Adam Johnson Date: Thu, 26 Oct 2023 16:07:13 +0100 Subject: [PATCH] Test on Python 3.12 and Django 5.0 --- .github/workflows/test.yml | 7 ++++++- Makefile | 2 +- docs/changelog.rst | 5 +++++ setup.py | 2 ++ tests/requirements.txt | 4 ++-- tests/settings.py | 2 ++ tox.ini | 7 +++++-- 7 files changed, 23 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 19fb7a5..b0873a5 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -9,7 +9,12 @@ jobs: fail-fast: false max-parallel: 5 matrix: - python-version: ['3.8', '3.9', '3.10', '3.11'] + python-version: + - '3.8' + - '3.9' + - '3.10' + - '3.11' + - '3.12' steps: - uses: actions/checkout@v4 diff --git a/Makefile b/Makefile index 98929a6..dd931cc 100644 --- a/Makefile +++ b/Makefile @@ -22,7 +22,7 @@ docs: test: @flake8 @isort --check-only --diff formtools tests - @ coverage run `which django-admin` test tests + @ python -W error::DeprecationWarning -W error::PendingDeprecationWarning -m coverage run `which django-admin` test tests @coverage report @coverage xml diff --git a/docs/changelog.rst b/docs/changelog.rst index 29b2d96..f93183a 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -3,6 +3,11 @@ Changelog This page details the changes in the various ``django-formtools`` releases. +Unreleased +---------- + +- Confirmed support for Python 3.12 and Django 5.0. + 2.4.1 (2023-05-13) ------------------ diff --git a/setup.py b/setup.py index 0b7c642..42cd4a9 100644 --- a/setup.py +++ b/setup.py @@ -34,6 +34,7 @@ def read(*parts): "Framework :: Django :: 4.0", "Framework :: Django :: 4.1", "Framework :: Django :: 4.2", + "Framework :: Django :: 5.0", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", @@ -44,6 +45,7 @@ def read(*parts): "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", + "Programming Language :: Python :: 3.12", "Topic :: Internet :: WWW/HTTP", ], zip_safe=False, diff --git a/tests/requirements.txt b/tests/requirements.txt index 2ed361c..e0c7a88 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -1,3 +1,3 @@ -coverage==4.5.4 +coverage==7.3.2 flake8 -isort>=5.11.1, <6.0 \ No newline at end of file +isort>=5.11.1, <6.0 diff --git a/tests/settings.py b/tests/settings.py index 82b0125..f3df07e 100644 --- a/tests/settings.py +++ b/tests/settings.py @@ -40,3 +40,5 @@ STATIC_ROOT = 'static' DEFAULT_AUTO_FIELD = 'django.db.models.AutoField' + +USE_TZ = True diff --git a/tox.ini b/tox.ini index 2505e0d..4d817c8 100644 --- a/tox.ini +++ b/tox.ini @@ -1,9 +1,10 @@ [tox] args_are_paths = false envlist = - py{37,38,39,310,311}-django32 + py{38,39,310,311}-django32 py{38,39,310,311}-django{40,41,42} - py{310,311}-djangomain + py{310,311,312}-django50 + py{310,311,312}-djangomain [testenv] usedevelop = true @@ -15,6 +16,7 @@ deps = django40: Django>=4.0,<4.1 django41: Django>=4.1,<4.2 django42: Django>=4.2,<5.0 + django50: Django>=5.0a1,<5.1 djangomain: https://github.com/django/django/archive/main.tar.gz -r{toxinidir}/tests/requirements.txt ignore_outcome = @@ -28,3 +30,4 @@ python = 3.9: py39 3.10: py310 3.11: py311 + 3.12: py312