AttributeError at /article/

'str' object has no attribute '__dict__'
Request Method: GET
Request URL: http://127.0.0.1:8000/article/
Exception Type: AttributeError
Exception Value:
'str' object has no attribute '__dict__'
Exception Location: c:\litleblog\..\litleblog\posts\views.py in article, line 44
Python Executable: C:\Python26\Python.exe
Python Version: 2.6.1
Python Path: ['c:\\litleblog', 'C:\\WINDOWS\\system32\\python26.zip', 'C:\\Python26 \\DLLs', 'C:\\Python26\\lib', 'C:\\Python26\\lib\\plat-win', 'C:\\Python26\\lib \\lib-tk', 'C:\\Python26', 'C:\\Python26\\lib\\site-packages']
Server time: Пят, 3 Апр 2009 15:30:10 +0400

Traceback Switch to copy-and-paste view



Request information

GET

Variable Value
name
u'1'

POST

No POST data

Variable Value
sessionid
'32c8c0cb1fdd97c387a376df3636378a'

META

Variable Value
ALLUSERSPROFILE
'C:\\Documents and Settings\\All Users'
APPDATA
'C:\\Documents and Settings\\Admin\\Application Data'
< /td>
CLIENTNAME
'Console'
COMMANDER_DRIVE
'C:'
COMMANDER_INI
'C:\\Program Files\\Total Commander\\wincmd.ini'
COMMANDER_PATH
'C:\\Program Files\\Total Commander'
COMMONPROGRAMFILES
'C:\\Program Files\\Common Files'
COMPUTERNAME
'YEGOR-LAPTOP'
COMSPEC
'C:\\WINDOWS\\system32\\cmd.exe'
CONTENT_LENGTH
''
CONTENT_TYPE
'text/plain'
DJANGO_SETTINGS_MODULE
'litleblog.settings'
FP_NO_HOST_CHECK
'NO'
GATEWAY_INTERFACE
'CGI/1.1'
HOMEDRIVE
'C:'
HOMEPATH
'\\Documents and Settings\\Admin'
HTTP_ACCEPT
'*/*'
HTTP_ACCEPT_CHARSET
'windows-1251,utf-8;q=0.7,*;q=0.7'
HTTP_ACCEPT_ENCODING
'gzip,deflate'
HTTP_ACCEPT_LANGUAGE
'ru,en-us;q=0.7,en;q=0.3'
HTTP_CONNECTION
'keep-alive'
HTTP_COOKIE
'sessionid=32c8c0cb1fdd97c387a376df3636378a'
HTTP_HOST
'127.0.0.1:8000'
HTTP_KEEP_ALIVE
'300'
HTTP_REFERER
'http://127.0.0.1:8000/contact/'
HTTP_USER_AGENT
'Mozilla/5.0 (Windows; U; Windows NT 5.1; ru; rv:1.9.0.8) Gecko/2009032609 Firefox/3.0.8 GTB5'
HTTP_X_REQUESTED_WITH
'XMLHttpRequest'
LOGONSERVER
'\\\\YEGOR-LAPTOP'
NUMBER_OF_PROCESSORS
'2'
OS
'Windows_NT'
PATH
'C:\\WINDOWS\\system32;C:\\WINDOWS;C:\\WINDOWS\\System32\\Wbem;C :\\Program Files\\ATI Technologies\\ATI.ACE\\;c:\\Python26\\;c:\\Python26\\Lib\\site-packages\\django \\bin\\'
PATHEXT
'.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH'
PATH_INFO
u'/article/'
PROCESSOR_ARCHITECTURE
'x86'
PROCESSOR_IDENTIFIER
'x86 Family 6 Model 14 Stepping 12, GenuineIntel'
PROCESSOR_LEVEL
'6'
PROCESSOR_REVISION
'0e0c'
PROGRAMFILES
'C:\\Program Files'
QUERY_STRING
'name=1'
REMOTE_ADDR
'127.0.0.1'
REMOTE_HOST
''
REQUEST_METHOD
'GET'
RUN_MAIN
'true'
SCRIPT_NAME
u''
SERVER_NAME
'localhost'
SERVER_PORT
'8000'
SERVER_PROTOCOL
'HTTP/1.1'
SERVER_SOFTWARE
'WSGIServer/0.1 Python/2.6.1'
SESSIONNAME
'Console'
SYSTEMDRIVE
'C:'
SYSTEMROOT
'C:\\WINDOWS'
TEMP
'C:\\DOCUME~1\\Admin\\LOCALS~1\\Temp'
TMP
'C:\\DOCUME~1\\Admin\\LOCALS~1\\Temp'
USERDOMAIN
'YEGOR-LAPTOP'
USERNAME
'Admin'
USERPROFILE
'C:\\Documents and Settings\\Admin'
WINDIR
'C:\\WINDOWS'
wsgi.errors
<open file '<stderr>', mode 'w' at 0x00A430C0 >
wsgi.file_wrapper
<class 'django.core.servers.basehttp.FileWrapper'>
wsgi.input
<socket._fileobject object at 0x010F9430>
wsgi.multiprocess
False
wsgi.multithread
True
wsgi.run_once
False
wsgi.url_scheme
'http'
wsgi.version
(1, 0)

Settings

Using settings module litleblog.settings

Setting Value
ABSOLUTE_URL_OVERRIDES
{}
ADMINS
()
ADMIN_FOR
()
ADMIN_MEDIA_PREFIX
'/media/'
ALLOWED_INCLUDE_ROOTS
()
APPEND_SLASH
True
AUTHENTICATION_BACKENDS
('django.contrib.auth.backends.ModelBackend',)
BANNED_IPS
()
CACHE_BACKEND
'locmem://'
CACHE_MIDDLEWARE_KEY_PREFIX
''
CACHE_MIDDLEWARE_SECONDS
600
COMMENTS_ALLOW_PROFANITIES
False
COMMENTS_BANNED_USERS_GROUP
None
COMMENTS_FIRST_FEW
0
COMMENTS_MODERATORS_GROUP
None
COMMENTS_SKETCHY_USERS_GROUP
None
DATABASE_ENGINE
'sqlite3'
DATABASE_HOST
''
DATABASE_NAME
'db.db'
DATABASE_OPTIONS
{}
DATABASE_PASSWORD
'********************'
DATABASE_PORT
''
DATABASE_USER
''
DATETIME_FORMAT
'N j, Y, P'
DATE_FORMAT
'N j, Y'
DEBUG
True
DEBUG_PROPAGATE_EXCEPTIONS
False
DEFAULT_CHARSET
'utf-8'
DEFAULT_CONTENT_TYPE
'text/html'
DEFAULT_FILE_STORAGE
'django.core.files.storage.FileSystemStorage'
DEFAULT_FROM_EMAIL
'webmaster@localhost'
DEFAULT_INDEX_TABLESPACE
''
DEFAULT_TABLESPACE
''
DISALLOWED_USER_AGENTS
()
EMAIL_HOST
'localhost'
EMAIL_HOST_PASSWORD
'********************'
EMAIL_HOST_USER
''
EMAIL_PORT
25
EMAIL_SUBJECT_PREFIX
'[Django] '
EMAIL_USE_TLS
False
FILE_CHARSET
'utf-8'
FILE_UPLOAD_HANDLERS
('django.core.files.uploadhandler.MemoryFileUploadHandler', 'django.core.files.uploadhandler.TemporaryFileUploadHandler')
FILE_UPLOAD_MAX_MEMORY_SIZE
2621440
FILE_UPLOAD_PERMISSIONS
None
FILE_UPLOAD_TEMP_DIR
None
FIXTURE_DIRS
()
FORCE_SCRIPT_NAME
None
IGNORABLE_404_ENDS
('mail.pl', 'mailform.pl', 'mail.cgi', 'mailform .cgi', 'favicon.ico', '.php')
IGNORABLE_404_STARTS
('/cgi-bin/', '/_vti_bin', '/_vti_inf')
INSTALLED_APPS
['django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.admin', 'litleblog.posts', 'django.contrib.flatpages']
INTERNAL_IPS
()
JING_PATH
'/usr/bin/jing'
LANGUAGES
(('ar', 'Arabic'), ('bn', 'Bengali'), ('bg', 'Bulgarian'), ('ca', 'Catalan'), ('cs', 'Czech'), ('cy', 'Welsh'), ('da', 'Danish'), ('de', 'German'), ('el', 'Greek'), ('en', 'English'), ('es', 'Spanish'), ('et', 'Estonian'), ('es-ar', 'Argentinean Spanish'), ('eu', 'Basque'), ('fa', 'Persian'), ('fi', 'Finnish'), ('fr', 'French'), ('ga', 'Irish'), ('gl', 'Galician'), ('hu', 'Hungarian'), ('he', 'Hebrew'), ('hi', 'Hindi'), ('hr', 'Croatian'), ('is', 'Icelandic'), ('it', 'Italian'), ('ja', 'Japanese'), ('ka', 'Georgian'), ('ko', 'Korean'), ('km', 'Khmer'), ('kn', 'Kannada'), ('lv', 'Latvian'), ('lt', 'Lithuanian'), ('mk', 'Macedonian'), ('nl', 'Dutch'), ('no', 'Norwegian'), ('pl', 'Polish'), ('pt', 'Portuguese'), ('pt-br', 'Brazilian Portuguese'), ('ro', 'Romanian'), ('ru', 'Russian'), ('sk', 'Slovak'), ('sl', 'Slovenian'), ('sr', 'Serbian'), ('sv', 'Swedish'), ('ta', 'Tamil'), ('te', 'Telugu'), ('th', 'Thai'), ('tr', 'Turkish'), ('uk', 'Ukrainian'), ('zh-cn', 'Simplified Chinese'), ('zh-tw', 'Traditional Chinese'))
LANGUAGES_BIDI
('he', 'ar', 'fa')
LANGUAGE_CODE
'ru'
LANGUAGE_COOKIE_NAME
'django_language'
LOCALE_PATHS
()
LOGIN_REDIRECT_URL
'/accounts/profile/'
LOGIN_URL
'/accounts/login/'
LOGOUT_URL
'/accounts/logout/'
MANAGERS
()
MEDIA_ROOT
'c:/litleblog/media'
MEDIA_URL
''
MIDDLEWARE_CLASSES
('django.middleware.common.CommonMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.flatpages.middleware.FlatpageFallbackMiddleware')
MONTH_DAY_FORMAT
'F j'
PASSWORD_RESET_TIMEOUT_DAYS
'********************'
PREPEND_WWW
False
PROFANITIES_LIST
'********************'
ROOT_URLCONF
'litleblog.urls'
SECRET_KEY
'********************'
SEND_BROKEN_LINK_EMAILS
False
SERVER_EMAIL
'root@localhost'
SESSION_COOKIE_AGE
1209600
SESSION_COOKIE_DOMAIN
None
SESSION_COOKIE_NAME
'sessionid'
SESSION_COOKIE_PATH
'/'
SESSION_COOKIE_SECURE
False
SESSION_ENGINE
'django.contrib.sessions.backends.db'
SESSION_EXPIRE_AT_BROWSER_CLOSE
False
SESSION_FILE_PATH
None
SESSION_SAVE_EVERY_REQUEST
False
SETTINGS_MODULE
'litleblog.settings'
SITE_ID
1
STATIC_DOC_ROOT
'C:/litleblog/templates'
TEMPLATE_CONTEXT_PROCESSORS
('django.core.context_processors.auth', 'django.core.context_processors.debug', 'django.core.context_processors.i18n', 'django.core.context_processors.media')
TEMPLATE_DEBUG
True
TEMPLATE_DIRS
('C:/litleblog/templates',)
TEMPLATE_LOADERS
('django.template.loaders.filesystem.load_template_source', 'django.template.loaders.app_directories.load_template_source')
TEMPLATE_STRING_IF_INVALID
''
TEST_DATABASE_CHARSET
None
TEST_DATABASE_COLLATION
None
TEST_DATABASE_NAME
None
TEST_RUNNER
'django.test.simple.run_tests'
TIME_FORMAT
'P'
TIME_ZONE
'America/Chicago'
TRANSACTIONS_MANAGED
False
URL_VALIDATOR_USER_AGENT
'Django/1.0.2 final (http://www.djangoproject.com)'
USE_ETAGS
False
USE_I18N
True
YEAR_MONTH_FORMAT
'F Y'

You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False, and Django will display a standard 500 page.