Skip to content

Commit e725db3

Browse files
committed
removed python 3.6 and django 2.2 and 3.1 support
1 parent 76fdd62 commit e725db3

File tree

5 files changed

+8
-17
lines changed

5 files changed

+8
-17
lines changed

.github/workflows/python-package.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@ jobs:
1515
runs-on: ubuntu-latest
1616
strategy:
1717
matrix:
18-
python-version: ["3.8", "3.9"]
19-
django-version: ["2.2", "3.1", "3.2", "4.0"]
18+
python-version: ["3.8", "3.9", "3.10"]
19+
django-version: ["3.2", "4.0"]
2020
include:
21-
- python-version: "3.10"
22-
django-version: "4.0"
21+
- python-version: "3.7"
22+
django-version: "3.2"
2323

2424
steps:
2525
- uses: actions/checkout@v2

.pre-commit-config.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ repos:
4040
rev: 1.4.0
4141
hooks:
4242
- id: django-upgrade
43-
args: [--target-version, "2.2"]
43+
args: [--target-version, "3.2"]
4444

4545
- repo: https://github.com/pycqa/flake8
4646
rev: 4.0.1

djangosaml2/utils.py

+2-6
Original file line numberDiff line numberDiff line change
@@ -22,14 +22,10 @@
2222
from django.core.exceptions import ImproperlyConfigured
2323
from django.http import HttpResponse, HttpResponseRedirect
2424
from django.shortcuts import resolve_url
25-
from saml2.mdstore import MetaDataMDX
26-
27-
try:
28-
from django.utils.http import url_has_allowed_host_and_scheme
29-
except ImportError: # django 2.2
30-
from django.utils.http import is_safe_url as url_has_allowed_host_and_scheme
25+
from django.utils.http import url_has_allowed_host_and_scheme
3126

3227
from saml2.config import SPConfig
28+
from saml2.mdstore import MetaDataMDX
3329
from saml2.s_utils import UnknownSystemEntity
3430

3531
logger = logging.getLogger(__name__)

setup.py

-3
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,12 @@ def read(*rnames):
3535
"Development Status :: 5 - Production/Stable",
3636
"Environment :: Web Environment",
3737
"Framework :: Django",
38-
"Framework :: Django :: 2.2",
39-
"Framework :: Django :: 3.1",
4038
"Framework :: Django :: 3.2",
4139
"Framework :: Django :: 4.0",
4240
"Intended Audience :: Developers",
4341
"License :: OSI Approved :: Apache Software License",
4442
"Operating System :: OS Independent",
4543
"Programming Language :: Python",
46-
"Programming Language :: Python :: 3.6",
4744
"Programming Language :: Python :: 3.7",
4845
"Programming Language :: Python :: 3.8",
4946
"Programming Language :: Python :: 3.9",

tox.ini

+1-3
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
[tox]
22
envlist =
3-
py{3.6,3.7,3.8,3.9,3.10}-django{2.2,3.1,3.2,4.0}
3+
py{3.7,3.8,3.9,3.10}-django{3.2,4.0}
44

55
[testenv]
66
commands =
77
python tests/run_tests.py
88

99
deps =
10-
django2.2: django~=2.2
11-
django3.1: django~=3.1
1210
django3.2: django~=3.2
1311
django4.0: django~=4.0
1412
djangomaster: https://github.com/django/django/archive/master.tar.gz

0 commit comments

Comments
 (0)