Skip to content
This repository has been archived by the owner on Jun 4, 2022. It is now read-only.

Commit

Permalink
Add Python 2.7 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
chessbr committed Jan 13, 2018
1 parent f7edc5b commit a9832d3
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 9 deletions.
5 changes: 4 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
language: python
python:
- "2.7"
- "3.4"
- "3.5"
install:
- pip install -U pip
- pip install coveralls
- pip install coveralls isort flake8
- pip install -r requirements.txt
- pip install -r dev-requirements.txt
- pip install -e .
script:
- isort -sp . --check-only rest_jwt_permission/*.py
- flake8 rest_jwt_permission
- py.test -ra -vvv --cov-config .coveragerc --cov rest_jwt_permission rest_jwt_permission_tests
after_success: coveralls
3 changes: 1 addition & 2 deletions rest_jwt_permission/providers/admin.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# -*- coding: utf-8 -*-
from functools import lru_cache

from django.utils.lru_cache import lru_cache
from django.utils.translation import ugettext_lazy as _

from .base import ScopeProviderBase
Expand Down
3 changes: 1 addition & 2 deletions rest_jwt_permission/providers/api_endpoint.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# -*- coding: utf-8 -*-
from functools import lru_cache

from django.utils.lru_cache import lru_cache
from rest_framework.schemas import EndpointInspector

from rest_jwt_permission.utils import get_role_for, get_view_role
Expand Down
3 changes: 1 addition & 2 deletions rest_jwt_permission/providers/utils.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# -*- coding: utf-8 -*-
from functools import lru_cache

from django.utils import module_loading
from django.utils.lru_cache import lru_cache

from rest_jwt_permission.settings import get_setting

Expand Down
4 changes: 2 additions & 2 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ description-file = README.md

[tool:pytest]
django_find_project = false
norecursedirs = .git venv
norecursedirs = .git venv .env

[flake8]
exclude = .git,__pycache__,docs/source/conf.py,old,build,dist
exclude = .git,__pycache__
max-complexity = 20
max-line-length = 120

Expand Down
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
classifiers=[
"Programming Language :: Python",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 2.7",
"Environment :: Web Environment",
"Topic :: Internet :: WWW/HTTP",
"Intended Audience :: Developers"
Expand Down

0 comments on commit a9832d3

Please sign in to comment.