Hello everyone,

I'm having quite a lot of pain installing django-cms 2.0, which is
available at http://github.com/digi604/django-cms-2.0/tree/master.

When I visit /admin/, I get a "TemplateSyntaxError at /admin/" with
the subtitle "Caught an exception while rendering: u'user'
." I suck at reading tracebacks, so I was hoping someone could help me
figure out what's wrong. The traceback is below. I should clarify that
the error is only thrown when you are logged-in.

Thanks,
Chris

Environment:

Request Method: GET
Request URL: http://127.0.0.1:8000/admin/
Django Version: 1.2 pre-alpha SVN-11429
Python Version: 2.5.1
Installed Applications:
['django.contrib.auth',
 'django.contrib.contenttypes',
 'django.contrib.sessions',
 'django.contrib.sites',
 'django.contrib.admin',
 'django.contrib.admindocs',
 'cms',
 'cms.plugins.text',
 'cms.plugins.picture',
 'cms.plugins.link',
 'cms.plugins.file',
 'cms.plugins.snippet',
 'cms.plugins.googlemap',
 'mptt',
 'publisher']
Installed Middleware:
('django.middleware.common.CommonMiddleware',
 'django.contrib.sessions.middleware.SessionMiddleware',
 'django.contrib.auth.middleware.AuthenticationMiddleware',
 'cms.middleware.page.CurrentPageMiddleware',
 'cms.middleware.user.CurrentUserMiddleware')


Template error:
In template /Library/Python/2.5/site-packages/django/contrib/admin/
templates/admin/index.html, error at line 56
   Caught an exception while rendering: u'user'
   46 : {% endif %}


   47 : </div>


   48 : {% endblock %}


   49 :


   50 : {% block sidebar %}


   51 : <div id="content-related">


   52 :     <div class="module" id="recent-actions-module">


   53 :         <h2>{% trans 'Recent Actions' %}</h2>


   54 :         <h3>{% trans 'My Actions' %}</h3>


   55 :             {% load log %}


   56 :              {% get_admin_log 10 as admin_log for_user user
%}


   57 :             {% if not admin_log %}


   58 :             <p>{% trans 'None available' %}</p>


   59 :             {% else %}


   60 :             <ul class="actionlist">


   61 :             {% for entry in admin_log %}


   62 :             <li class="{% if entry.is_addition %}addlink{%
endif %}{% if entry.is_change %}changelink{% endif %}{% if
entry.is_deletion %}deletelink{% endif %}">


   63 :                 {% if entry.is_deletion %}


   64 :                     {{ entry.object_repr }}


   65 :                 {% else %}


   66 :                     <a href="{{ entry.get_admin_url }}">
{{ entry.object_repr }}</a>


Traceback:
File "/Library/Python/2.5/site-packages/django/core/handlers/base.py"
in get_response
  92.                 response = callback(request, *callback_args,
**callback_kwargs)
File "/Library/Python/2.5/site-packages/django/contrib/admin/sites.py"
in wrapper
  196.                 return self.admin_view(view, cacheable)(*args,
**kwargs)
File "/Library/Python/2.5/site-packages/django/views/decorators/
cache.py" in _wrapped_view_func
  44.         response = view_func(request, *args, **kwargs)
File "/Library/Python/2.5/site-packages/django/contrib/admin/sites.py"
in inner
  186.             return view(request, *args, **kwargs)
File "/Library/Python/2.5/site-packages/django/views/decorators/
cache.py" in _wrapped_view_func
  44.         response = view_func(request, *args, **kwargs)
File "/Library/Python/2.5/site-packages/django/contrib/admin/sites.py"
in index
  374.             context_instance=context_instance
File "/Library/Python/2.5/site-packages/django/shortcuts/__init__.py"
in render_to_response
  20.     return HttpResponse(loader.render_to_string(*args,
**kwargs), **httpresponse_kwargs)
File "/Library/Python/2.5/site-packages/django/template/loader.py" in
render_to_string
  108.     return t.render(context_instance)
File "/Library/Python/2.5/site-packages/django/template/__init__.py"
in render
  178.         return self.nodelist.render(context)
File "/Library/Python/2.5/site-packages/django/template/__init__.py"
in render
  779.                 bits.append(self.render_node(node, context))
File "/Library/Python/2.5/site-packages/django/template/debug.py" in
render_node
  71.             result = node.render(context)
File "/Library/Python/2.5/site-packages/django/template/
loader_tags.py" in render
  97.         return compiled_parent.render(context)
File "/Library/Python/2.5/site-packages/django/template/__init__.py"
in render
  178.         return self.nodelist.render(context)
File "/Library/Python/2.5/site-packages/django/template/__init__.py"
in render
  779.                 bits.append(self.render_node(node, context))
File "/Library/Python/2.5/site-packages/django/template/debug.py" in
render_node
  71.             result = node.render(context)
File "/Library/Python/2.5/site-packages/django/template/
loader_tags.py" in render
  97.         return compiled_parent.render(context)
File "/Library/Python/2.5/site-packages/django/template/__init__.py"
in render
  178.         return self.nodelist.render(context)
File "/Library/Python/2.5/site-packages/django/template/__init__.py"
in render
  779.                 bits.append(self.render_node(node, context))
File "/Library/Python/2.5/site-packages/django/template/debug.py" in
render_node
  71.             result = node.render(context)
File "/Library/Python/2.5/site-packages/django/template/
loader_tags.py" in render
  24.         result = self.nodelist.render(context)
File "/Library/Python/2.5/site-packages/django/template/__init__.py"
in render
  779.                 bits.append(self.render_node(node, context))
File "/Library/Python/2.5/site-packages/django/template/debug.py" in
render_node
  81.             raise wrapped

Exception Type: TemplateSyntaxError at /admin/
Exception Value: Caught an exception while rendering: u'user'

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/contrib/admin/
templatetags/log.py", line 19, in render
    user_id = context[self.user].id
  File "/Library/Python/2.5/site-packages/django/template/context.py",
line 44, in __getitem__
    raise KeyError(key)
KeyError: u'user'

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

Reply via email to