From ad709519214dda690324cf0d3f1ca344b484e740 Mon Sep 17 00:00:00 2001 From: Jelmer Draaijer Date: Thu, 26 Oct 2023 14:21:46 +0200 Subject: [PATCH 1/5] Add Python 3.12 to test matrix and add classifiers --- setup.py | 1 + tox.ini | 1 + 2 files changed, 2 insertions(+) diff --git a/setup.py b/setup.py index d910b5ff..488db677 100644 --- a/setup.py +++ b/setup.py @@ -97,6 +97,7 @@ def get_version(package): 'Programming Language :: Python :: 3.9', 'Programming Language :: Python :: 3.10', 'Programming Language :: Python :: 3.11', + 'Programming Language :: Python :: 3.12', 'Topic :: Internet :: WWW/HTTP', 'Topic :: Documentation', 'Topic :: Software Development :: Code Generators', diff --git a/tox.ini b/tox.ini index 46153116..a0615917 100644 --- a/tox.ini +++ b/tox.ini @@ -5,6 +5,7 @@ envlist = {py37,py38,py39}-django{3.2}-drf{3.11,3.12}, {py38,py39,py310}-django{4.0,4.1}-drf{3.13,3.14}, {py311}-django{4.1, 4.2}-drf{3.14}, + {py312}-django{4.2}-drf{3.14}, py310-django4.2-drfmaster py310-djangomaster-drf3.14 py310-drfmaster-djangomaster From 8d4493f3e8d5be168cc2a4c24b5b5c451d86d82f Mon Sep 17 00:00:00 2001 From: Jelmer Draaijer Date: Thu, 26 Oct 2023 14:26:54 +0200 Subject: [PATCH 2/5] Add allauth.account.middleware.AccountMiddleware to middleware --- tests/conftest.py | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/conftest.py b/tests/conftest.py index c46e4892..c4d53a89 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -70,6 +70,7 @@ def pytest_configure(config): 'django.middleware.common.CommonMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.middleware.locale.LocaleMiddleware', + 'allauth.account.middleware.AccountMiddleware', ), INSTALLED_APPS=( 'django.contrib.auth', From acd2fae19c9d74fe2e0b80fb54b2bdb3fb104175 Mon Sep 17 00:00:00 2001 From: Jelmer Draaijer Date: Mon, 20 Nov 2023 11:00:26 +0100 Subject: [PATCH 3/5] Add setuptools required for packaging --- requirements/optionals.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/requirements/optionals.txt b/requirements/optionals.txt index 7ce28e34..cb70779e 100644 --- a/requirements/optionals.txt +++ b/requirements/optionals.txt @@ -2,6 +2,7 @@ django-allauth<0.55.0 # breaking change breaking dj-rest-auth drf-jwt>=0.13.0 dj-rest-auth>=1.0.0 djangorestframework-simplejwt>=4.4.0 +setuptools django-polymorphic>=2.1 django-rest-polymorphic>=0.1.8 django-oauth-toolkit>=1.2.0 From 156a1e0df1373c7f911e41ed3cd50c0a29f4c858 Mon Sep 17 00:00:00 2001 From: Jelmer Draaijer Date: Mon, 20 Nov 2023 11:00:48 +0100 Subject: [PATCH 4/5] Set JWTTokenUserAuthentication to None when missing --- tests/contrib/test_simplejwt.py | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/contrib/test_simplejwt.py b/tests/contrib/test_simplejwt.py index 1c3ea864..bb7b8ad2 100644 --- a/tests/contrib/test_simplejwt.py +++ b/tests/contrib/test_simplejwt.py @@ -15,6 +15,7 @@ ) except ImportError: JWTAuthentication = None + JWTTokenUserAuthentication = None class XSerializer(serializers.Serializer): From c515633d1816a917c21fa1e26e0637eb230b3e34 Mon Sep 17 00:00:00 2001 From: Jelmer Draaijer Date: Mon, 20 Nov 2023 11:03:59 +0100 Subject: [PATCH 5/5] Undo adding middleware --- tests/conftest.py | 1 - 1 file changed, 1 deletion(-) diff --git a/tests/conftest.py b/tests/conftest.py index c4d53a89..c46e4892 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -70,7 +70,6 @@ def pytest_configure(config): 'django.middleware.common.CommonMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.middleware.locale.LocaleMiddleware', - 'allauth.account.middleware.AccountMiddleware', ), INSTALLED_APPS=( 'django.contrib.auth',