Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Environment:
- Request Method: GET
- Request URL: http://127.0.0.1:8000/articles/all/
- Django Version: 1.6.2
- Python Version: 2.7.5
- Installed Applications:
- ('django.contrib.admin',
- 'django.contrib.auth',
- 'django.contrib.contenttypes',
- 'django.contrib.sessions',
- 'django.contrib.messages',
- 'django.contrib.staticfiles',
- 'article')
- Installed Middleware:
- ('django.contrib.sessions.middleware.SessionMiddleware',
- 'django.middleware.common.CommonMiddleware',
- 'django.middleware.csrf.CsrfViewMiddleware',
- 'django.contrib.auth.middleware.AuthenticationMiddleware',
- 'django.contrib.messages.middleware.MessageMiddleware',
- 'django.middleware.clickjacking.XFrameOptionsMiddleware')
- Template error:
- In template /Users/bradfordli/Development/django_tutorial/bin/django_test/templates/base.html, error at line 8
- 'tuple' object has no attribute 'rsplit'
- 1 : {% load staticfiles %}
- 2 :
- 3 : <!DOCTYPE html>
- 4 : <html lang="en">
- 5 : <head>
- 6 : <title>{% block title %} My Base Template {% endblock %}</title>
- 7 :
- 8 : <link rel="stylesheet" type="text/css" href=" {% static '/css/default.css' %} ">
- 9 :
- 10 : </head?
- 11 :
- 12 : <body>
- 13 : <div id="page">
- 14 : <div id="sidebar">
- 15 : {% block sidebar %}
- 16 : <ul>
- 17 : <li><a href="/articles/all">Articles</a></li>
- 18 : <li><a href="/admin/">Admin</a></li>
- Traceback:
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/core/handlers/base.py" in get_response
- 114. response = wrapped_callback(request, *callback_args, **callback_kwargs)
- File "/Users/bradfordli/Development/django_tutorial/bin/django_test/article/views.py" in articles
- 11. {'articles' : Article.objects.all() })
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/shortcuts/__init__.py" in render_to_response
- 29. return HttpResponse(loader.render_to_string(*args, **kwargs), **httpresponse_kwargs)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/template/loader.py" in render_to_string
- 164. return t.render(Context(dictionary))
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/template/base.py" in render
- 140. return self._render(context)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/template/base.py" in _render
- 134. return self.nodelist.render(context)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/template/base.py" in render
- 840. bit = self.render_node(node, context)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/template/debug.py" in render_node
- 78. return node.render(context)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/template/loader_tags.py" in render
- 123. return compiled_parent._render(context)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/template/base.py" in _render
- 134. return self.nodelist.render(context)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/template/base.py" in render
- 840. bit = self.render_node(node, context)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/template/debug.py" in render_node
- 78. return node.render(context)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/templatetags/static.py" in render
- 106. url = self.url(context)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/contrib/staticfiles/templatetags/staticfiles.py" in url
- 12. return staticfiles_storage.url(path)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/utils/functional.py" in inner
- 213. self._setup()
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/contrib/staticfiles/storage.py" in _setup
- 311. self._wrapped = get_storage_class(settings.STATICFILES_STORAGE)()
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/core/files/storage.py" in get_storage_class
- 282. return import_by_path(import_path or settings.DEFAULT_FILE_STORAGE)
- File "/Users/bradfordli/Development/django_tutorial/lib/python2.7/site-packages/Django-1.6.2-py2.7.egg/django/utils/module_loading.py" in import_by_path
- 16. module_path, class_name = dotted_path.rsplit('.', 1)
- Exception Type: AttributeError at /articles/all/
- Exception Value: 'tuple' object has no attribute 'rsplit'
Advertisement
Add Comment
Please, Sign In to add comment