Commit 4b5691d8 authored by Christos Stavrakakis's avatar Christos Stavrakakis

wheezy: urls module doesn't export defaults

parent 934feea8
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import patterns, url
try:
from django.conf.urls import patterns, url
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns, url
from snf_django.lib.api import api_endpoint_not_found
urlpatterns = patterns(
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import patterns, url, include
try:
from django.conf.urls import patterns, url, include
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns, url, include
from snf_django.lib.api import api_endpoint_not_found
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import patterns, url
try:
from django.conf.urls import patterns, url
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns, url
from astakos.im.forms import (
ExtendedPasswordResetForm,
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import patterns, url
try:
from django.conf.urls import url
except ImportError: # Django==1.2
from django.conf.urls.defaults import url
urlpatterns = (
url(r'^login$', 'astakos.im.views.target.redirect.login',
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import include, patterns
try:
from django.conf.urls import include, patterns
except ImportError: # Django==1.2
from django.conf.urls.defaults import include, patterns
from synnefo.lib import join_urls
from astakos.im.settings import (
BASE_PATH, ACCOUNTS_PREFIX, VIEWS_PREFIX, KEYSTONE_PREFIX, WEBLOGIN_PREFIX)
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import url, patterns
try:
from django.conf.urls import url, patterns
except ImportError: # Django==1.2
from django.conf.urls.defaults import url, patterns
from synnefo.admin import views
from django.http import Http404
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import patterns
try:
from django.conf.urls import patterns
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns
from django.http import HttpResponse
from django.utils import simplejson as json
from snf_django.lib import api
......
......@@ -33,7 +33,11 @@
from logging import getLogger
from django.conf.urls.defaults import patterns
try:
from django.conf.urls import patterns
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns
from django.http import HttpResponse
from django.template.loader import render_to_string
from django.utils import simplejson as json
......
......@@ -36,7 +36,11 @@ from itertools import ifilter
from dateutil.parser import parse as date_parse
from django.conf.urls.defaults import patterns
try:
from django.conf.urls import patterns
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns
from django.http import HttpResponse
from django.template.loader import render_to_string
from django.utils import simplejson as json
......
......@@ -33,7 +33,11 @@
from django.conf import settings
from django.conf.urls.defaults import patterns
try:
from django.conf.urls import patterns
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns
from django.db import transaction
from django.db.models import Q
from django.http import HttpResponse
......
......@@ -34,7 +34,11 @@
import datetime
from django import dispatch
from django.conf import settings
from django.conf.urls.defaults import patterns
try:
from django.conf.urls import patterns
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns
from django.db import transaction
from django.http import HttpResponse
from django.template.loader import render_to_string
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import include, patterns
try:
from django.conf.urls import include, patterns
except ImportError: # Django==1.2
from django.conf.urls.defaults import include, patterns
from snf_django.lib.api import api_endpoint_not_found
from synnefo.api import servers, flavors, images, networks, extensions
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import *
try:
from django.conf.urls import patterns, include
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns, include
from django.conf import settings
from snf_django.lib.api.proxy import proxy
from snf_django.lib.api.utils import prefix_pattern
......
from django.conf.urls.defaults import patterns, url
try:
from django.conf.urls import patterns, url
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns, url
urlpatterns = patterns('',
url(r'^$', 'synnefo.helpdesk.views.index', name='helpdesk-index'),
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import patterns, include
try:
from django.conf.urls import patterns, include
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns, include
from django.http import HttpResponseNotAllowed
from snf_django.lib.api import api_endpoint_not_found
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
#
from django.conf.urls.defaults import *
try:
from django.conf.urls import patterns, url
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns, url
from django.conf import settings
import os
......
......@@ -32,7 +32,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import *
try:
from django.conf.urls import patterns, url
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns, url
from synnefo.userdata import views
from django.http import Http404
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import patterns, url
try:
from django.conf.urls import patterns, url
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns, url
from snf_django.lib.api import api_endpoint_not_found
urlpatterns = patterns('synnefo.vmapi.views',
......
......@@ -33,7 +33,11 @@
from django.core import urlresolvers
from django.views.decorators import csrf
from django.conf.urls.defaults import patterns
try:
from django.conf.urls import patterns
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns
def _patch_pattern(regex_pattern):
......
......@@ -32,7 +32,11 @@
# or implied, of GRNET S.A.
from django.conf.urls.defaults import url, patterns
try:
from django.conf.urls import url, patterns
except ImportError: # Django==1.2
from django.conf.urls.defaults import url, patterns
from snf_django.lib.api.utils import prefix_pattern
from synnefo.lib.services import get_service_path
from synnefo.lib import join_urls
......
......@@ -32,7 +32,11 @@
# or implied, of GRNET S.A.
from functools import partial
from django.conf.urls.defaults import include, patterns
try:
from django.conf.urls import include, patterns
except ImportError: # Django==1.2
from django.conf.urls.defaults import include, patterns
from snf_django.lib.api.proxy import proxy
from snf_django.lib.api.utils import prefix_pattern
from snf_django.lib.api.urls import api_patterns
......
......@@ -31,7 +31,11 @@
# interpreted as representing official policies, either expressed
# or implied, of GRNET S.A.
from django.conf.urls.defaults import patterns, include
try:
from django.conf.urls import patterns, include
except ImportError: # Django==1.2
from django.conf.urls.defaults import patterns, include
from snf_django.lib.api.utils import prefix_pattern
from synnefo_stats.stats_settings import BASE_PATH
from synnefo_stats.grapher import grapher
......
......@@ -33,7 +33,13 @@
import os
from django.conf.urls.defaults import *
# Import * in order to import the http exception handlers: handler*
try:
from django.conf.urls.defaults import *
except ImportError: # Django==1.4
from django.conf.urls import *
from synnefo.util.entry_points import extend_urls
from django.utils.importlib import import_module
from django.template import Context, loader, RequestContext
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment