Skip to content

WIP - initial work to support django 2.0 #5442

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 6 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ env:
- DJANGO=1.9
- DJANGO=1.10
- DJANGO=1.11
- DJANGO=2.0
- DJANGO=master

matrix:
Expand All @@ -21,6 +22,8 @@ matrix:
env: DJANGO=master
- python: "3.6"
env: DJANGO=1.11
- python: "3.6"
env: DJANGO=2.0
- python: "3.3"
env: DJANGO=1.8
- python: "2.7"
Expand All @@ -30,11 +33,14 @@ matrix:
exclude:
- python: "2.7"
env: DJANGO=master
- python: "2.7"
env: DJANGO=2.0
- python: "3.4"
env: DJANGO=master

allow_failures:
- env: DJANGO=master
- env: DJANGO=2.0

install:
- pip install tox tox-travis
Expand Down
4 changes: 2 additions & 2 deletions requirements/requirements-codestyle.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# PEP8 code linting, which we run on all commits.
flake8==2.4.0
pep8==1.5.7
flake8==3.4.1
pep8==1.7.0

# Sort and lint imports
isort==4.2.5
2 changes: 1 addition & 1 deletion requirements/requirements-documentation.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
# MkDocs to build our documentation.
mkdocs==0.16.2
mkdocs==0.16.3
4 changes: 2 additions & 2 deletions requirements/requirements-optionals.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Optional packages which may be used with REST framework.
pytz==2017.2
markdown==2.6.4
django-guardian==1.4.8
django-guardian==1.4.9
django-filter==1.0.4
coreapi==2.2.4
coreapi==2.3.1
coreschema==0.0.4
4 changes: 2 additions & 2 deletions requirements/requirements-packaging.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Wheel for PyPI installs.
wheel==0.29.0
wheel==0.30.0

# Twine for secured PyPI uploads.
twine==1.6.5
twine==1.9.1

# Transifex client for managing translation resources.
transifex-client==0.11
Expand Down
4 changes: 2 additions & 2 deletions requirements/requirements-testing.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# PyTest for running the tests.
pytest==3.0.5
pytest==3.2.2
pytest-django==3.1.2
pytest-cov==2.4.0
pytest-cov==2.5.1
6 changes: 4 additions & 2 deletions rest_framework/compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,13 @@

try:
from django.urls import (
NoReverseMatch, RegexURLPattern, RegexURLResolver, ResolverMatch, Resolver404, get_script_prefix, reverse, reverse_lazy, resolve
NoReverseMatch, URLResolver, ResolverMatch, Resolver404,
get_script_prefix, reverse, reverse_lazy, resolve, URLPattern
)
except ImportError:
from django.core.urlresolvers import ( # Will be removed in Django 2.0
NoReverseMatch, RegexURLPattern, RegexURLResolver, ResolverMatch, Resolver404, get_script_prefix, reverse, reverse_lazy, resolve
NoReverseMatch, RegexURLPattern, RegexURLResolver, ResolverMatch,
Resolver404, get_script_prefix, reverse, reverse_lazy, resolve
)


Expand Down
3 changes: 3 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ envlist =
{py27,py33,py34,py35}-django18,
{py27,py34,py35}-django{19,110},
{py27,py34,py35,py36}-django111,
{py34,py35,py36}-django20,
{py35,py36}-djangomaster
lint,docs

Expand All @@ -15,6 +16,7 @@ DJANGO =
1.9: django19
1.10: django110
1.11: django111
2.0: django20
master: djangomaster

[testenv]
Expand All @@ -27,6 +29,7 @@ deps =
django19: Django>=1.9,<1.10
django110: Django>=1.10,<1.11
django111: Django>=1.11,<2.0
django20: Django>=2.0a1,<2.1
djangomaster: https://github.com/django/django/archive/master.tar.gz
-rrequirements/requirements-testing.txt
-rrequirements/requirements-optionals.txt
Expand Down