mirror of
https://github.com/jazzband/django-axes.git
synced 2026-05-08 15:44:46 +00:00
Merge pull request #408 from jazzband/development
Add six imports for Django master compatibility
This commit is contained in:
commit
f36cf2d3d1
2 changed files with 12 additions and 1 deletions
10
axes/conf.py
10
axes/conf.py
|
|
@ -1,3 +1,13 @@
|
|||
# TODO: Remove these imports after django-appconf does not depend on django.utils.six
|
||||
try:
|
||||
from django.utils import six # noqa
|
||||
except ImportError: # pragma: no cover
|
||||
import sys
|
||||
import warnings
|
||||
|
||||
sys.modules['django.utils.six'] = __import__('six')
|
||||
warnings.warn('django.utils.six was patched for django-appconf backwards compatibility', ImportWarning)
|
||||
|
||||
from django.conf import settings
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
|
||||
|
|
|
|||
3
setup.py
3
setup.py
|
|
@ -34,10 +34,11 @@ setup(
|
|||
package_dir={'axes': 'axes'},
|
||||
python_requires='~=3.5',
|
||||
install_requires=[
|
||||
'pytz',
|
||||
'django',
|
||||
'django-appconf',
|
||||
'django-ipware>=2.0.2',
|
||||
'pytz',
|
||||
'six',
|
||||
],
|
||||
include_package_data=True,
|
||||
packages=find_packages(),
|
||||
|
|
|
|||
Loading…
Reference in a new issue