diff --git a/.travis.yml b/.travis.yml index 2acd10c..a14a66f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,13 +6,13 @@ python: - "3.3" - "3.4" - "3.5" - - "3.6" env: - DJANGO=1.6 - DJANGO=1.7 - DJANGO=1.8 - DJANGO=1.9 + - DJANGO=1.10 services: - redis-server @@ -36,16 +36,16 @@ matrix: env: DJANGO=1.8 - python: "2.6" env: DJANGO=1.9 + - python: "2.6" + env: DJANGO=1.10 - python: "3.3" env: DJANGO=1.9 + - python: "3.3" + env: DJANGO=1.10 - python: "3.5" env: DJANGO=1.6 - python: "3.5" env: DJANGO=1.7 - - python: "3.6" - env: DJANGO=1.6 - - python: "3.6" - env: DJANGO=1.7 after_success: - coveralls --verbose diff --git a/CHANGES b/CHANGES index 8f7d7ad..930a0d7 100644 --- a/CHANGES +++ b/CHANGES @@ -1,6 +1,7 @@ -0.4.x +0.4.3 ===== - Flex version requirements for dependencies +- Better support for Django 1.10 0.4.2 ===== diff --git a/README.md b/README.md index 121e0e0..fcaee5c 100644 --- a/README.md +++ b/README.md @@ -22,6 +22,7 @@ Sites using Defender: Versions ======== +- 0.4.3 - Better Support for Django 1.10 - 0.4.2 - Better support for Django 1.9 - 0.4.1 - minor refactor to make it easier to retrieve username. - 0.4.0 - added ``DEFENDER_DISABLE_IP_LOCKOUT`` and added support for Python 3.5 @@ -146,12 +147,20 @@ This started out as a fork of django-axes, and is using as much of their code as possible, and removing the parts not needed, and speeding up the lookups to improve the login. +Django 1.11 +============ +Due to a change with Django 1.11 where they deprecated the `django.contrib.auth.views.login` in favor +of `django.contrib.auth.views.LoginView` https://docs.djangoproject.com/en/1.11/topics/auth/default/#django.contrib.auth.views.LoginView + +This is currently breaking the defender middleware (FailedLoginMiddleware) we have setup, and needs to be changed to support +the LoginView Class Based View before it will work with Django 1.11. If you know up to fix it, please submit a PR. + requirements ============ -- django: 1.6.x, 1.7.x, 1.8.x, 1.9.x +- django: 1.6.x, 1.7.x, 1.8.x, 1.9.x, 1.10.x - redis -- python: 2.6.x, 2.7.x, 3.3.x, 3.4.x, PyPy +- python: 2.6.x, 2.7.x, 3.3.x, 3.4.x, 3.5.x, 3.6.x, PyPy How it works ============ diff --git a/defender/test_settings.py b/defender/test_settings.py index f776098..1746936 100644 --- a/defender/test_settings.py +++ b/defender/test_settings.py @@ -33,6 +33,17 @@ TEMPLATES = [ { 'BACKEND': 'django.template.backends.django.DjangoTemplates', 'APP_DIRS': True, + 'OPTIONS': { + 'context_processors': [ + 'django.contrib.auth.context_processors.auth', + 'django.template.context_processors.debug', + 'django.template.context_processors.i18n', + 'django.template.context_processors.media', + 'django.template.context_processors.static', + 'django.template.context_processors.tz', + 'django.contrib.messages.context_processors.messages', + ], + }, }, ] diff --git a/defender/travis_settings.py b/defender/travis_settings.py index 82bd694..6193061 100644 --- a/defender/travis_settings.py +++ b/defender/travis_settings.py @@ -33,6 +33,17 @@ TEMPLATES = [ { 'BACKEND': 'django.template.backends.django.DjangoTemplates', 'APP_DIRS': True, + 'OPTIONS': { + 'context_processors': [ + 'django.contrib.auth.context_processors.auth', + 'django.template.context_processors.debug', + 'django.template.context_processors.i18n', + 'django.template.context_processors.media', + 'django.template.context_processors.static', + 'django.template.context_processors.tz', + 'django.contrib.messages.context_processors.messages', + ], + }, }, ] diff --git a/setup.py b/setup.py index 187b08d..b8a691f 100644 --- a/setup.py +++ b/setup.py @@ -9,7 +9,7 @@ except ImportError: from distutils.core import setup -version = '0.4.2' +version = '0.4.3' def get_packages(package):