Update URLs to Django 1.8+ style
Django 1.8 altered and deprecated the existing pattern for defining URLs. This will be removed in 1.10, meaning that many deprecation warnings show up under Django 1.9. We should fix the URLs promptly to avoid logspam, and to support Django 1.10 in Newton. See https://docs.djangoproject.com/en/1.9/releases/1.8/#django-conf-urls-patterns Change-Id: I074d20850de59bfe678a3bc72e9f0f25bd743cbf Partially-Implements: blueprint dj110
This commit is contained in:
@@ -10,12 +10,10 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
from horizon.test.test_dashboards.cats.kittens.views import IndexView # noqa
|
||||
|
||||
urlpatterns = patterns(
|
||||
'',
|
||||
urlpatterns = [
|
||||
url(r'^$', IndexView.as_view(), name='index'),
|
||||
)
|
||||
]
|
||||
|
||||
@@ -10,12 +10,10 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
from horizon.test.test_dashboards.cats.tigers.views import IndexView # noqa
|
||||
|
||||
urlpatterns = patterns(
|
||||
'',
|
||||
urlpatterns = [
|
||||
url(r'^$', IndexView.as_view(), name='index'),
|
||||
)
|
||||
]
|
||||
|
||||
@@ -10,14 +10,12 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
from horizon.test.test_dashboards.dogs.puppies.views import IndexView # noqa
|
||||
from horizon.test.test_dashboards.dogs.puppies.views import TwoTabsView # noqa
|
||||
|
||||
urlpatterns = patterns(
|
||||
'',
|
||||
urlpatterns = [
|
||||
url(r'^$', IndexView.as_view(), name='index'),
|
||||
url(r'^tabs/$', TwoTabsView.as_view(), name='tabs'),
|
||||
)
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user