Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed #16531 -- Fixed various instances of "undefined name" issues. T…

…hanks, Bruno Renié.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16557 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit dc2bfae1e57089675c76ae77fd6ecc38d976ccd9 1 parent db594f9
@jezdez jezdez authored
View
2  django/contrib/gis/db/backends/base.py
@@ -121,7 +121,7 @@ def spatial_aggregate_sql(self, agg):
raise NotImplementedError('Aggregate support not implemented for this spatial backend.')
def spatial_lookup_sql(self, lvalue, lookup_type, value, field):
- raise NotImplmentedError
+ raise NotImplementedError
# Routines for getting the OGC-compliant models.
def geometry_columns(self):
View
2  django/db/models/fields/__init__.py
@@ -967,7 +967,7 @@ def get_prep_value(self, value):
if value and ':' in value:
try:
return clean_ipv6_address(value, self.unpack_ipv4)
- except ValidationError:
+ except exceptions.ValidationError:
pass
return value
View
3  django/views/debug.py
@@ -5,6 +5,7 @@
import types
from django.conf import settings
+from django.core.exceptions import ImproperlyConfigured
from django.http import (HttpResponse, HttpResponseServerError,
HttpResponseNotFound, HttpRequest, build_request_repr)
from django.template import (Template, Context, TemplateDoesNotExist,
@@ -79,7 +80,7 @@ def get_exception_reporter_filter(request):
try:
default_exception_reporter_filter = getattr(mod, classname)()
except AttributeError:
- raise exceptions.ImproperlyConfigured('Default exception reporter filter module "%s" does not define a "%s" class' % (modname, classname))
+ raise ImproperlyConfigured('Default exception reporter filter module "%s" does not define a "%s" class' % (modname, classname))
if request:
return getattr(request, 'exception_reporter_filter', default_exception_reporter_filter)
else:
View
6 django/views/generic/dates.py
@@ -210,9 +210,9 @@ def get_date_list(self, queryset, date_type):
date_list = queryset.dates(date_field, date_type)[::-1]
if date_list is not None and not date_list and not allow_empty:
- raise Http404(_(u"No %(verbose_name_plural)s available") % {
- 'verbose_name_plural': force_unicode(qs.model._meta.verbose_name_plural)
- })
+ name = force_unicode(queryset.model._meta.verbose_name_plural)
+ raise Http404(_(u"No %(verbose_name_plural)s available") %
+ {'verbose_name_plural': name})
return date_list
Please sign in to comment.
Something went wrong with that request. Please try again.