diff --git a/.travis.yml b/.travis.yml index e74e491..e49b17f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -22,7 +22,6 @@ env: - TOX_ENV=py35-dj20 - TOX_ENV=py35-dj21 - TOX_ENV=py35-dj22 - - TOX_ENV=py35-djmaster matrix: include: - python: "3.6" @@ -33,6 +32,8 @@ matrix: env: TOX_ENV=py36-dj21 - python: "3.6" env: TOX_ENV=py36-dj22 + - python: "3.6" + env: TOX_ENV=py36-dj30 - python: "3.6" env: TOX_ENV=py36-djmaster - python: "3.7" @@ -41,12 +42,20 @@ matrix: env: TOX_ENV=py37-dj21 - python: "3.7" env: TOX_ENV=py37-dj22 + - python: "3.7" + env: TOX_ENV=py37-dj30 - python: "3.7" env: TOX_ENV=py37-djmaster + - python: "3.8" + env: TOX_ENV=py38-dj22 + - python: "3.8" + env: TOX_ENV=py38-dj30 + - python: "3.8" + env: TOX_ENV=py38-djmaster allow_failures: - - env: TOX_ENV=py35-djmaster - env: TOX_ENV=py36-djmaster - env: TOX_ENV=py37-djmaster + - env: TOX_ENV=py38-djmaster install: - pip install tox script: diff --git a/README.md b/README.md index 1a9be34..f5aeb48 100644 --- a/README.md +++ b/README.md @@ -15,8 +15,8 @@ It works at application level, so your django instance should be up. It doesn't use database and doesn't prevent database access. ## Requirements -- Python 2.7, 3.4, 3.5, 3.6, 3.7 -- Django 1.7, 1.8, 1.9, 1.10, 1.11, 2.0, 2.1, 2.2 +- Python 2.7, 3.4, 3.5, 3.6, 3.7, 3.8 +- Django 1.7, 1.8, 1.9, 1.10, 1.11, 2.0, 2.1, 2.2, 3.0 ## Installation diff --git a/maintenance_mode/core.py b/maintenance_mode/core.py index 41df486..d36d3bc 100644 --- a/maintenance_mode/core.py +++ b/maintenance_mode/core.py @@ -4,7 +4,7 @@ from django.core.exceptions import ImproperlyConfigured try: - from django.utils.decorators import ContextDecorator + from contextlib import ContextDecorator except ImportError: # ContextDecorator was introduced in Django 1.8 from django.utils.decorators import available_attrs diff --git a/setup.py b/setup.py index 94789db..a0960bf 100644 --- a/setup.py +++ b/setup.py @@ -44,6 +44,7 @@ 'Framework :: Django :: 2.0', 'Framework :: Django :: 2.1', 'Framework :: Django :: 2.2', + 'Framework :: Django :: 3.0', 'Intended Audience :: Developers', 'License :: OSI Approved :: MIT License', 'Natural Language :: English', @@ -55,6 +56,7 @@ 'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.6', 'Programming Language :: Python :: 3.7', + 'Programming Language :: Python :: 3.8', 'Topic :: Software Development :: Build Tools', ], license='MIT', diff --git a/tox.ini b/tox.ini index 779acd1..fb7c30f 100644 --- a/tox.ini +++ b/tox.ini @@ -2,9 +2,10 @@ envlist = py27-{dj17,dj18,dj19,dj110,dj111}, py34-{dj17,dj18,dj19,dj110,dj111,dj20}, - py35-{dj18,dj19,dj110,dj111,dj20,dj21,dj22,djmaster}, - py36-{dj18,dj19,dj110,dj111,dj20,dj21,dj22,djmaster}, - py37-{dj20,dj21,dj22,djmaster}, + py35-{dj18,dj19,dj110,dj111,dj20,dj21,dj22}, + py36-{dj18,dj19,dj110,dj111,dj20,dj21,dj22,dj30,djmaster}, + py37-{dj20,dj21,dj22,dj30,djmaster}, + py38-{dj22,dj30,djmaster}, [testenv] passenv = CI TRAVIS TRAVIS_* deps = @@ -16,6 +17,7 @@ deps = dj20: Django >= 2.0, < 2.1 dj21: Django >= 2.1, < 2.2 dj22: Django >= 2.2, < 2.3 + dj30: Django >= 3.0, < 3.1 djmaster: https://github.com/django/django/archive/master.tar.gz coverage codecov