From: Radek Czajka Date: Thu, 21 Apr 2022 12:11:34 +0000 (+0200) Subject: Support for Python 3.10 and Django 4.0, drop Python 3.5, Python 3.6, Django 1.9,... X-Git-Tag: 22.4 X-Git-Url: https://git.mdrn.pl/django-cas-provider.git/commitdiff_plain/b88bb747c08269f187d6073504c7dca3568112b9?ds=sidebyside Support for Python 3.10 and Django 4.0, drop Python 3.5, Python 3.6, Django 1.9, Django 1.10. --- diff --git a/cas_provider/attribute_formatters.py b/cas_provider/attribute_formatters.py index 45a2403..405f2c1 100644 --- a/cas_provider/attribute_formatters.py +++ b/cas_provider/attribute_formatters.py @@ -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()): - 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 @@ -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()): - 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 @@ -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()): - 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: diff --git a/setup.py b/setup.py index b895eca..75570e1 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ def read(fname): 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', @@ -17,7 +17,7 @@ setup( long_description=read('README.rst'), zip_safe=False, install_requires=[ - 'Django>=1.10,<4.0', + 'Django>=1.11,<4.1', 'lxml', ], classifiers = [ diff --git a/tox.ini b/tox.ini index d09ada8..4969b0c 100644 --- a/tox.ini +++ b/tox.ini @@ -1,18 +1,17 @@ [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= - 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 @@ -20,6 +19,7 @@ deps= 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