Support for Python 3.10 and Django 4.0, drop Python 3.5, Python 3.6, Django 1.9,... 22.4
authorRadek Czajka <rczajka@rczajka.pl>
Thu, 21 Apr 2022 12:11:34 +0000 (14:11 +0200)
committerRadek Czajka <rczajka@rczajka.pl>
Thu, 21 Apr 2022 12:11:34 +0000 (14:11 +0200)
cas_provider/attribute_formatters.py
setup.py
tox.ini

index 45a2403..405f2c1 100644 (file)
@@ -17,7 +17,7 @@ def jasig(auth_success, attrs):
     style = etree.SubElement(attributes, CAS + 'attraStyle')
     style.text = 'Jasig'
     for name, value in sorted(attrs.items()):
     style = etree.SubElement(attributes, CAS + 'attraStyle')
     style.text = 'Jasig'
     for name, value in sorted(attrs.items()):
-        if isinstance(value, collections.Iterable) and not isinstance(value, basestring):
+        if isinstance(value, collections.abc.Iterable) and not isinstance(value, basestring):
             for e in value:
                 element = etree.SubElement(attributes, CAS + name)
                 element.text = e
             for e in value:
                 element = etree.SubElement(attributes, CAS + name)
                 element.text = e
@@ -30,7 +30,7 @@ def ruby_cas(auth_success, attrs):
     style = etree.SubElement(auth_success, CAS + 'attraStyle')
     style.text = 'RubyCAS'
     for name, value in sorted(attrs.items()):
     style = etree.SubElement(auth_success, CAS + 'attraStyle')
     style.text = 'RubyCAS'
     for name, value in sorted(attrs.items()):
-        if isinstance(value, collections.Iterable) and not isinstance(value, basestring):
+        if isinstance(value, collections.abc.Iterable) and not isinstance(value, basestring):
             for e in value:
                 element = etree.SubElement(auth_success, CAS + name)
                 element.text = e
             for e in value:
                 element = etree.SubElement(auth_success, CAS + name)
                 element.text = e
@@ -42,7 +42,7 @@ def ruby_cas(auth_success, attrs):
 def name_value(auth_success, attrs):
     etree.SubElement(auth_success, CAS + 'attribute', name='attraStyle', value='Name-Value')
     for name, value in sorted(attrs.items()):
 def name_value(auth_success, attrs):
     etree.SubElement(auth_success, CAS + 'attribute', name='attraStyle', value='Name-Value')
     for name, value in sorted(attrs.items()):
-        if isinstance(value, collections.Iterable) and not isinstance(value, basestring):
+        if isinstance(value, collections.abc.Iterable) and not isinstance(value, basestring):
             for e in value:
                 etree.SubElement(auth_success, CAS + 'attribute', name=name, value=e)
         else:
             for e in value:
                 etree.SubElement(auth_success, CAS + 'attribute', name=name, value=e)
         else:
index b895eca..75570e1 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -6,7 +6,7 @@ def read(fname):
 
 setup(
     name='django-cas-provider',
 
 setup(
     name='django-cas-provider',
-    version='0.3.2',
+    version='22.4',
     description='A "provider" for the Central Authentication Service (http://jasig.org/cas)',
     author='(Chris Williams), Sebastian Annies',
     author_email='(chris@nitron.org), sebastian.annies@googlemail.com',
     description='A "provider" for the Central Authentication Service (http://jasig.org/cas)',
     author='(Chris Williams), Sebastian Annies',
     author_email='(chris@nitron.org), sebastian.annies@googlemail.com',
@@ -17,7 +17,7 @@ setup(
     long_description=read('README.rst'),
     zip_safe=False,
     install_requires=[
     long_description=read('README.rst'),
     zip_safe=False,
     install_requires=[
-        'Django>=1.10,<4.0',
+        'Django>=1.11,<4.1',
         'lxml',
         ],
     classifiers = [
         'lxml',
         ],
     classifiers = [
diff --git a/tox.ini b/tox.ini
index d09ada8..4969b0c 100644 (file)
--- a/tox.ini
+++ b/tox.ini
@@ -1,18 +1,17 @@
 [tox]
 envlist=clear,
 [tox]
 envlist=clear,
-    d110-py{35},
-    d111-py{35,36,37},
-    d20-py{35,36,37},
-    d21-py{35,36,37},
-    d22-py{35,36,37,38,39}
-    d{30,31,32}-py{36,37,38,39}
+    d111-py{37},
+    d20-py{37},
+    d21-py{37},
+    d22-py{37,38,39},
+    d{30,31}-py{37,38,39},
+    d32-py{37,38,39,310},
+    d40-py{38,39,310},
     stats
 
 [testenv]
 commands=coverage run --source=cas_provider --append --branch cas_provider_examples/manage.py test simple
 deps=
     stats
 
 [testenv]
 commands=coverage run --source=cas_provider --append --branch cas_provider_examples/manage.py test simple
 deps=
-    d19: Django>=1.9,<1.10
-    d110: Django>=1.10,<1.11
     d111: Django>=1.11,<2.0
     d20: Django>=2.0,<2.1
     d21: Django>=2.1,<2.2
     d111: Django>=1.11,<2.0
     d20: Django>=2.0,<2.1
     d21: Django>=2.1,<2.2
@@ -20,6 +19,7 @@ deps=
     d30: Django>=3.0,<3.1
     d31: Django>=3.1,<3.2
     d32: Django>=3.2,<4.0
     d30: Django>=3.0,<3.1
     d31: Django>=3.1,<3.2
     d32: Django>=3.2,<4.0
+    d40: Django>=4.0,<4.1
     coverage
 usedevelop=True
 
     coverage
 usedevelop=True