From 93f5127ac34e65c780bc182f6714173d4edbea7b Mon Sep 17 00:00:00 2001 From: Pascal F Date: Tue, 17 Oct 2023 08:38:30 +0200 Subject: [PATCH] Add Django5 support (#516) --- .github/workflows/test.yml | 11 +++++++++-- setup.py | 1 + tox.ini | 12 +++++++----- 3 files changed, 17 insertions(+), 7 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index cb588572..0a452c0e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -17,6 +17,7 @@ jobs: - '3.9' - '3.10' - '3.11' + - '3.12' env: PYTHON_VERSION: ${{ matrix.python-version }} @@ -41,11 +42,12 @@ jobs: - name: Django 3.2.x Test run: | tox -e "py${PYTHON_VERSION/\./}-django32" + if: ${{ env.PYTHON_VERSION == '3.7' || env.PYTHON_VERSION == '3.8' || env.PYTHON_VERSION == '3.9' || env.PYTHON_VERSION == '3.10' }} - name: Django 4.0.x Test run: | tox -e "py${PYTHON_VERSION/\./}-django40" - if: ${{ env.PYTHON_VERSION == '3.8' || env.PYTHON_VERSION == '3.9' || env.PYTHON_VERSION == '3.10' || env.PYTHON_VERSION == '3.11' }} + if: ${{ env.PYTHON_VERSION == '3.8' || env.PYTHON_VERSION == '3.9' || env.PYTHON_VERSION == '3.10' }} - name: Django 4.1.x Test run: | @@ -57,10 +59,15 @@ jobs: tox -e "py${PYTHON_VERSION/\./}-django42" if: ${{ env.PYTHON_VERSION == '3.8' || env.PYTHON_VERSION == '3.9' || env.PYTHON_VERSION == '3.10' || env.PYTHON_VERSION == '3.11' }} + - name: Django 5.0.x Test + run: | + tox -e "py${PYTHON_VERSION/\./}-django50" + if: ${{ env.PYTHON_VERSION == '3.10' || env.PYTHON_VERSION == '3.11' || env.PYTHON_VERSION == '3.12' }} + - name: Django main Test run: | tox -e "py${PYTHON_VERSION/\./}-djangomain" - if: ${{ env.PYTHON_VERSION == '3.10' || env.PYTHON_VERSION == '3.11' }} + if: ${{ env.PYTHON_VERSION == '3.10' || env.PYTHON_VERSION == '3.11' || env.PYTHON_VERSION == '3.12' }} - name: social-core master Test run: | diff --git a/setup.py b/setup.py index b29dff17..83977e71 100644 --- a/setup.py +++ b/setup.py @@ -55,6 +55,7 @@ def load_requirements(): "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", + "Programming Language :: Python :: 3.12", ], zip_safe=False, ) diff --git a/tox.ini b/tox.ini index 1d5e07a2..93ebed14 100644 --- a/tox.ini +++ b/tox.ini @@ -1,11 +1,12 @@ [tox] envlist = - py{37,38,39,310,311}-django32 - py{38,39,310,311}-django40 + py{37,38,39,310}-django32 + py{38,39,310}-django40 py{38,39,310,311}-django41 py{38,39,310,311}-django42 - py{310,311}-djangomain - py{310,311}-socialmaster + py{310,311,312}-django50 + py{310,311,312}-djangomain + py{310,311,312}-socialmaster [testenv] passenv = * @@ -15,7 +16,8 @@ deps = django32: Django>=3.2,<3.3 django40: Django>=4.0,<4.1 django41: Django>=4.1,<4.2 - django42: Django>=4.2a1,<4.3 + django42: Django>=4.2,<4.3 + django50: Django>=5.0a1,<5.1 djangomain: https://github.com/django/django/archive/main.tar.gz socialmaster: https://github.com/python-social-auth/social-core/archive/master.tar.gz -r{toxinidir}/requirements-dev.txt