From 7d5e35cdb46124e2471833b9570add1a00a1d9e0 Mon Sep 17 00:00:00 2001 From: Julien Phalip Date: Thu, 14 Feb 2013 23:29:15 -0800 Subject: Fixed #19829 -- Fixed index lookups for NumPy arrays in templates. --- django/template/base.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'django') diff --git a/django/template/base.py b/django/template/base.py index 9577d586d8..f43194de4a 100644 --- a/django/template/base.py +++ b/django/template/base.py @@ -763,7 +763,7 @@ class Variable(object): for bit in self.lookups: try: # dictionary lookup current = current[bit] - except (TypeError, AttributeError, KeyError): + except (TypeError, AttributeError, KeyError, ValueError): try: # attribute lookup current = getattr(current, bit) except (TypeError, AttributeError): -- cgit v1.3