upgraded working existing django site with no admin from 1.0 to 1.1.1.
Added admin.  went to localhost:8000/admin/. logged in. and after
login got this bug



TemplateSyntaxError at /admin/

Caught an exception while rendering: dict objects are unhashable

Original Traceback (most recent call last):
  File "/Library/Python/2.5/site-packages/django/template/debug.py",
line 71, in render_node
    result = node.render(context)
  File "/Library/Python/2.5/site-packages/django/template/
defaulttags.py", line 370, in render
    url = reverse(self.view_name, args=args, kwargs=kwargs,
current_app=context.current_app)
  File "/Library/Python/2.5/site-packages/django/core/
urlresolvers.py", line 350, in reverse
    *args, **kwargs)))
  File "/Library/Python/2.5/site-packages/django/core/
urlresolvers.py", line 275, in reverse
    possibilities = self.reverse_dict.getlist(lookup_view)
  File "/Library/Python/2.5/site-packages/django/core/
urlresolvers.py", line 195, in _get_reverse_dict
    self._populate()
  File "/Library/Python/2.5/site-packages/django/core/
urlresolvers.py", line 188, in _populate
    lookups.appendlist(pattern.name, (bits, p_pattern))
  File "/Library/Python/2.5/site-packages/django/utils/
datastructures.py", line 275, in appendlist
    self.setlistdefault(key, [])
  File "/Library/Python/2.5/site-packages/django/utils/
datastructures.py", line 269, in setlistdefault
    if key not in self:
TypeError: dict objects are unhashable

Request Method:         GET
Request URL:    http://localhost:8000/admin/
Exception Type:         TemplateSyntaxError
Exception Value:

Caught an exception while rendering: dict objects are unhashable

Original Traceback (most recent call last):
  File "/Library/Python/2.5/site-packages/django/template/debug.py",
line 71, in render_node
    result = node.render(context)
  File "/Library/Python/2.5/site-packages/django/template/
defaulttags.py", line 370, in render
    url = reverse(self.view_name, args=args, kwargs=kwargs,
current_app=context.current_app)
  File "/Library/Python/2.5/site-packages/django/core/
urlresolvers.py", line 350, in reverse
    *args, **kwargs)))
  File "/Library/Python/2.5/site-packages/django/core/
urlresolvers.py", line 275, in reverse
    possibilities = self.reverse_dict.getlist(lookup_view)
  File "/Library/Python/2.5/site-packages/django/core/
urlresolvers.py", line 195, in _get_reverse_dict
    self._populate()
  File "/Library/Python/2.5/site-packages/django/core/
urlresolvers.py", line 188, in _populate
    lookups.appendlist(pattern.name, (bits, p_pattern))
  File "/Library/Python/2.5/site-packages/django/utils/
datastructures.py", line 275, in appendlist
    self.setlistdefault(key, [])
  File "/Library/Python/2.5/site-packages/django/utils/
datastructures.py", line 269, in setlistdefault
    if key not in self:
TypeError: dict objects are unhashable

Exception Location:     /Library/Python/2.5/site-packages/django/template/
debug.py in render_node, line 81
Python Executable:      /System/Library/Frameworks/Python.framework/
Versions/2.5/Resources/Python.app/Contents/MacOS/Python
Python Version:         2.5.1
Python Path:    ['/Users/ashishgupta/dev/pmc', '/Library/Python/2.5/site-
packages/setuptools-0.6c8-py2.5.egg', '/Library/Python/2.5/site-
packages/MySQL_python-1.2.2-py2.5-macosx-10.5-i386.egg', '/Library/
Python/2.5/site-packages/pytz-2009g-py2.5.egg', '/Library/Python/2.5/
site-packages/pycountry-0.10-py2.5.egg', '/Library/Python/2.5/site-
packages/PIL-1.1.6-py2.5-macosx-10.5-i386.egg', '/System/Library/
Frameworks/Python.framework/Versions/2.5/lib/python25.zip', '/System/
Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5', '/
System/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/
plat-darwin', '/System/Library/Frameworks/Python.framework/Versions/
2.5/lib/python2.5/plat-mac', '/System/Library/Frameworks/
Python.framework/Versions/2.5/lib/python2.5/plat-mac/lib-
scriptpackages', '/System/Library/Frameworks/Python.framework/Versions/
2.5/Extras/lib/python', '/System/Library/Frameworks/Python.framework/
Versions/2.5/lib/python2.5/lib-tk', '/System/Library/Frameworks/
Python.framework/Versions/2.5/lib/python2.5/lib-dynload', '/Library/
Python/2.5/site-packages', '/System/Library/Frameworks/
Python.framework/Versions/2.5/Extras/lib/python/PyObjC']
Server time:    Sun, 31 Jan 2010 02:56:41 +0000

In template /Library/Python/2.5/site-packages/django/contrib/admin/
templates/admin/base.html, error at line 30
Caught an exception while rendering: dict objects are unhashable
20      <!-- Header -->
21      <div id="header">
22      <div id="branding">
23      {% block branding %}{% endblock %}
24      </div>
25      {% if user.is_authenticated and user.is_staff %}
26      <div id="user-tools">
27      {% trans 'Welcome,' %}
28      <strong>{% firstof user.first_name user.username %}</strong>.
29      {% block userlinks %}
30      {% url django-admindocs-docroot as docsroot %}
31      {% if docsroot %}
32      <a href="{{ docsroot }}">{% trans 'Documentation' %}</a> /
33      {% endif %}
34      {% url admin:password_change as password_change_url %}
35      {% if password_change_url %}
36      <a href="{{ password_change_url }}">
37      {% else %}
38      <a href="{{ root_path }}password_change/">
39      {% endif %}
40      {% trans 'Change password' %}</a> /

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To post to this group, send email to django-develop...@googlegroups.com.
To unsubscribe from this group, send email to 
django-developers+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-developers?hl=en.

Reply via email to