Skip to content

Instantly share code, notes, and snippets.

@Swizec
Created May 22, 2012 13:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Swizec/2769073 to your computer and use it in GitHub Desktop.
Save Swizec/2769073 to your computer and use it in GitHub Desktop.
an error
AttributeError at /admin/
'Settings' object has no attribute 'DATABASE_ENGINE'
Request Method: GET
Request URL: http://localhost:8000/admin/
Django Version: 1.4
Exception Type: AttributeError
Exception Value:
'Settings' object has no attribute 'DATABASE_ENGINE'
Exception Location: /usr/local/lib/python2.7/dist-packages/django/utils/functional.py in inner, line 185
Python Executable: /usr/bin/python
Python Version: 2.7.3
Python Path:
['/home/swizec/Documents/random-coding/prefetch_vs_related',
'/usr/local/lib/python2.7/dist-packages/GitPython-0.3.1-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/gitdb-0.5.2-py2.7-linux-x86_64.egg',
'/usr/local/lib/python2.7/dist-packages/async-0.6.1-py2.7-linux-x86_64.egg',
'/usr/local/lib/python2.7/dist-packages/dulwich-0.7.2-py2.7-linux-x86_64.egg',
'/usr/local/lib/python2.7/dist-packages/python_github-0.1-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/suds-0.4-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/pytz-2011g-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/soaplib-0.8.2-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/hyphenator-0.5.1-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/PyHyphen-1.0beta1-py2.7-linux-x86_64.egg',
'/usr/local/lib/python2.7/dist-packages/twilio-3.3.2-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/PyJWT-0.1.4-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/tablib-0.9.11-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/South-0.7.3-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/pymongo-2.1.1-py2.7-linux-x86_64.egg',
'/usr/local/lib/python2.7/dist-packages/stripe-1.6.1-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/requests-0.9.0-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/certifi-0.0.6-py2.7.egg',
'/usr/lib/python2.7',
'/usr/lib/python2.7/plat-linux2',
'/usr/lib/python2.7/lib-tk',
'/usr/lib/python2.7/lib-old',
'/usr/lib/python2.7/lib-dynload',
'/usr/local/lib/python2.7/dist-packages',
'/usr/lib/python2.7/dist-packages',
'/usr/lib/python2.7/dist-packages/PIL',
'/usr/lib/python2.7/dist-packages/gst-0.10',
'/usr/lib/python2.7/dist-packages/gtk-2.0',
'/usr/lib/pymodules/python2.7',
'/usr/lib/python2.7/dist-packages/ubuntu-sso-client',
'/usr/lib/python2.7/dist-packages/ubuntuone-client',
'/usr/lib/python2.7/dist-packages/ubuntuone-control-panel',
'/usr/lib/python2.7/dist-packages/ubuntuone-couch',
'/usr/lib/python2.7/dist-packages/ubuntuone-installer',
'/usr/lib/python2.7/dist-packages/ubuntuone-storage-protocol',
'/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode']
Server time: Tue, 22 May 2012 08:30:59 -0500
Error during template rendering
In template /usr/local/lib/python2.7/dist-packages/debug_toolbar/templates/debug_toolbar/base.html, error at line 48
'Settings' object has no attribute 'DATABASE_ENGINE'
38 </div>
39 {% for panel in panels %}
40 {% if panel.has_content %}
41 <div id="{{ panel.dom_id }}" class="panelContent">
42 <div class="djDebugPanelTitle">
43 <a href="" class="djDebugClose">{% trans "Close" %}</a>
44 <h3>{{ panel.title|safe }}</h3>
45 </div>
46 <div class="djDebugPanelContent">
47 <div class="scroll">
48 {{ panel.content|safe }}
49 </div>
50 </div>
51 </div>
52 {% endif %}
53 {% endfor %}
54 <div id="djDebugWindow" class="panelContent"></div>
55 </div>
56
Traceback Switch to copy-and-paste view
/usr/local/lib/python2.7/dist-packages/django/core/handlers/base.py in get_response
response = middleware_method(request, response) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/debug_toolbar/middleware.py in process_response
smart_unicode(self.debug_toolbars[request].render_toolbar() + self.tag)) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/debug_toolbar/toolbar/loader.py in render_toolbar
return render_to_string('debug_toolbar/base.html', context) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/loader.py in render_to_string
return t.render(Context(dictionary)) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in render
return self._render(context) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/test/utils.py in instrumented_test_render
return self.nodelist.render(context) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in render
bit = self.render_node(node, context) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/debug.py in render_node
return node.render(context) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/defaulttags.py in render
nodelist.append(node.render(context)) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/defaulttags.py in render
return nodelist.render(context) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in render
bit = self.render_node(node, context) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/debug.py in render_node
return node.render(context) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/debug.py in render
output = self.filter_expression.resolve(context) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in resolve
obj = self.var.resolve(context) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in resolve
value = self._resolve_lookup(context) ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in _resolve_lookup
current = current() ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/debug_toolbar/panels/sql.py in content
'is_mysql': settings.DATABASE_ENGINE == 'mysql', ...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/utils/functional.py in inner
return func(self._wrapped, *args) ...
▶ Local vars
Request information
GET
No GET data
POST
No POST data
FILES
No FILES data
COOKIES
Variable Value
csrftoken
'f7449795040e54e0aa747348f0b935a0'
_gauges_unique
'1'
_gauges_unique_year
'1'
rock_format
'json'
META
Variable Value
wsgi.version
(1, 0)
wsgi.multiprocess
False
RUN_MAIN
'true'
HTTP_COOKIE
'csrftoken=f7449795040e54e0aa747348f0b935a0; _gauges_unique_year=1; _gauges_unique=1; rock_format=json'
GNOME_DESKTOP_SESSION_ID
'this-is-deprecated'
SERVER_PROTOCOL
'HTTP/1.1'
SERVER_SOFTWARE
'WSGIServer/0.1 Python/2.7.3'
SCRIPT_NAME
u''
LESSOPEN
'| /usr/bin/lesspipe %s'
REQUEST_METHOD
'GET'
LOGNAME
'swizec'
USER
'swizec'
PATH
'/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games'
QUERY_STRING
''
GNOME_KEYRING_CONTROL
'/tmp/keyring-YqTY6a'
DISPLAY
':0'
SSH_AGENT_PID
'5163'
LANG
'en_US.UTF-8'
HTTP_ACCEPT_CHARSET
'ISO-8859-1,utf-8;q=0.7,*;q=0.3'
TERM
'xterm'
SHELL
'/bin/bash'
XDG_SESSION_PATH
'/org/freedesktop/DisplayManager/Session0'
XAUTHORITY
'/home/swizec/.Xauthority'
SERVER_NAME
'localhost'
SESSION_MANAGER
'local/Lestat:@/tmp/.ICE-unix/5118,unix/Lestat:/tmp/.ICE-unix/5118'
SHLVL
'1'
MANDATORY_PATH
'/usr/share/gconf/ubuntu.mandatory.path'
wsgi.url_scheme
'http'
COMPIZ_CONFIG_PROFILE
'ubuntu'
WINDOWID
'94376750'
SERVER_PORT
'8000'
GPG_AGENT_INFO
'/tmp/keyring-YqTY6a/gpg:0:1'
HOME
'/home/swizec'
REMOTE_ADDR
'127.0.0.1'
CONTENT_LENGTH
''
HTTP_CONNECTION
'keep-alive'
CONTENT_TYPE
'text/plain'
SSH_AUTH_SOCK
'/tmp/keyring-YqTY6a/ssh'
wsgi.multithread
True
GDMSESSION
'ubuntu'
HTTP_CACHE_CONTROL
'max-age=0'
HTTP_USER_AGENT
'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.19 (KHTML, like Gecko) Ubuntu/12.04 Chromium/18.0.1025.151 Chrome/18.0.1025.151 Safari/535.19'
HTTP_HOST
'localhost:8000'
GNOME_KEYRING_PID
'5107'
XDG_SEAT_PATH
'/org/freedesktop/DisplayManager/Seat0'
LESSCLOSE
'/usr/bin/lesspipe %s %s'
CSRF_COOKIE_USED
True
XDG_CURRENT_DESKTOP
'Unity'
DBUS_SESSION_BUS_ADDRESS
'unix:abstract=/tmp/dbus-H77A3PHyMt,guid=789abd1946f0034ff0dcdc8d00000022'
_
'./manage.py'
XDG_SESSION_COOKIE
'5049fee9d35b6dedefc4c60100000006-1337627623.862756-748154256'
HTTP_ACCEPT
'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8'
DESKTOP_SESSION
'ubuntu'
wsgi.file_wrapper
''
XDG_CONFIG_DIRS
'/etc/xdg/xdg-ubuntu:/etc/xdg'
DEFAULTS_PATH
'/usr/share/gconf/ubuntu.default.path'
UBUNTU_MENUPROXY
'libappmenu.so'
wsgi.run_once
False
CSRF_COOKIE
'f7449795040e54e0aa747348f0b935a0'
OLDPWD
'/home/swizec/Documents/random-coding/prefetch_vs_related/prefetch_vs_related'
GATEWAY_INTERFACE
'CGI/1.1'
HTTP_ACCEPT_LANGUAGE
'en-US,en;q=0.8'
wsgi.input
<socket._fileobject object at 0x7fc6e442cb50>
wsgi.errors
<open file '<stderr>', mode 'w' at 0x7fc6f64fc270>
GTK_MODULES
'canberra-gtk-module:canberra-gtk-module'
XDG_DATA_DIRS
'/usr/share/ubuntu:/usr/share/gnome:/usr/local/share/:/usr/share/'
PWD
'/home/swizec/Documents/random-coding/prefetch_vs_related'
DJANGO_SETTINGS_MODULE
'prefetch_vs_related.settings'
TZ
'America/Chicago'
COLORTERM
'gnome-terminal'
LS_COLORS
'rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arj=01;31:*.taz=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.dz=01;31:*.gz=01;31:*.lz=01;31:*.xz=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.jpg=01;35:*.jpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.axv=01;35:*.anx=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.axa=00;36:*.oga=00;36:*.spx=00;36:*.xspf=00;36:'
REMOTE_HOST
''
HTTP_ACCEPT_ENCODING
'gzip,deflate,sdch'
PATH_INFO
u'/admin/'
Settings
Using settings module prefetch_vs_related.settings
Setting Value
USE_L10N
True
USE_THOUSAND_SEPARATOR
False
CSRF_COOKIE_SECURE
False
LANGUAGE_CODE
'en-us'
ROOT_URLCONF
'prefetch_vs_related.urls'
MANAGERS
()
DEFAULT_CHARSET
'utf-8'
STATIC_ROOT
''
MESSAGE_STORAGE
'django.contrib.messages.storage.fallback.FallbackStorage'
EMAIL_SUBJECT_PREFIX
'[Django] '
FILE_UPLOAD_PERMISSIONS
None
URL_VALIDATOR_USER_AGENT
'Django/1.4 (https://www.djangoproject.com)'
STATICFILES_FINDERS
('django.contrib.staticfiles.finders.FileSystemFinder',
'django.contrib.staticfiles.finders.AppDirectoriesFinder',
'django.contrib.staticfiles.finders.DefaultStorageFinder')
SESSION_COOKIE_DOMAIN
None
SESSION_COOKIE_NAME
'sessionid'
ADMIN_FOR
()
TIME_INPUT_FORMATS
('%H:%M:%S', '%H:%M')
DATABASES
{'default': {'ENGINE': 'django.db.backends.mysql',
'HOST': '',
'NAME': 'random',
'OPTIONS': {},
'PASSWORD': u'********************',
'PORT': '',
'TEST_CHARSET': None,
'TEST_COLLATION': None,
'TEST_MIRROR': None,
'TEST_NAME': None,
'TIME_ZONE': 'UTC',
'USER': 'random'}}
SERVER_EMAIL
'root@localhost'
FILE_UPLOAD_HANDLERS
('django.core.files.uploadhandler.MemoryFileUploadHandler',
'django.core.files.uploadhandler.TemporaryFileUploadHandler')
DEFAULT_CONTENT_TYPE
'text/html'
APPEND_SLASH
True
FIRST_DAY_OF_WEEK
0
DATABASE_ROUTERS
[]
YEAR_MONTH_FORMAT
'F Y'
STATICFILES_STORAGE
'django.contrib.staticfiles.storage.StaticFilesStorage'
CACHES
{'default': {'BACKEND': 'django.core.cache.backends.locmem.LocMemCache',
'LOCATION': ''}}
SESSION_COOKIE_PATH
'/'
USE_X_FORWARDED_HOST
False
MIDDLEWARE_CLASSES
('django.middleware.common.CommonMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'debug_toolbar.middleware.DebugToolbarMiddleware')
USE_I18N
True
THOUSAND_SEPARATOR
','
SECRET_KEY
u'********************'
LANGUAGE_COOKIE_NAME
'django_language'
DEFAULT_INDEX_TABLESPACE
''
TRANSACTIONS_MANAGED
False
LOGGING_CONFIG
'django.utils.log.dictConfig'
SEND_BROKEN_LINK_EMAILS
False
TEMPLATE_LOADERS
('django.template.loaders.filesystem.Loader',
'django.template.loaders.app_directories.Loader')
WSGI_APPLICATION
'prefetch_vs_related.wsgi.application'
TEMPLATE_DEBUG
True
X_FRAME_OPTIONS
'SAMEORIGIN'
AUTHENTICATION_BACKENDS
('django.contrib.auth.backends.ModelBackend',)
FORCE_SCRIPT_NAME
None
CACHE_BACKEND
'locmem://'
SIGNING_BACKEND
'django.core.signing.TimestampSigner'
SESSION_COOKIE_SECURE
False
CSRF_COOKIE_DOMAIN
None
FILE_CHARSET
'utf-8'
DEBUG
True
SESSION_FILE_PATH
None
DEFAULT_FILE_STORAGE
'django.core.files.storage.FileSystemStorage'
INSTALLED_APPS
('django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.sites',
'django.contrib.messages',
'django.contrib.staticfiles',
'django.contrib.admin',
'debug_toolbar')
LANGUAGES
(('ar', 'Arabic'),
('az', 'Azerbaijani'),
('bg', 'Bulgarian'),
('bn', 'Bengali'),
('bs', 'Bosnian'),
('ca', 'Catalan'),
('cs', 'Czech'),
('cy', 'Welsh'),
('da', 'Danish'),
('de', 'German'),
('el', 'Greek'),
('en', 'English'),
('en-gb', 'British English'),
('eo', 'Esperanto'),
('es', 'Spanish'),
('es-ar', 'Argentinian Spanish'),
('es-mx', 'Mexican Spanish'),
('es-ni', 'Nicaraguan Spanish'),
('et', 'Estonian'),
('eu', 'Basque'),
('fa', 'Persian'),
('fi', 'Finnish'),
('fr', 'French'),
('fy-nl', 'Frisian'),
('ga', 'Irish'),
('gl', 'Galician'),
('he', 'Hebrew'),
('hi', 'Hindi'),
('hr', 'Croatian'),
('hu', 'Hungarian'),
('id', 'Indonesian'),
('is', 'Icelandic'),
('it', 'Italian'),
('ja', 'Japanese'),
('ka', 'Georgian'),
('kk', 'Kazakh'),
('km', 'Khmer'),
('kn', 'Kannada'),
('ko', 'Korean'),
('lt', 'Lithuanian'),
('lv', 'Latvian'),
('mk', 'Macedonian'),
('ml', 'Malayalam'),
('mn', 'Mongolian'),
('nb', 'Norwegian Bokmal'),
('ne', 'Nepali'),
('nl', 'Dutch'),
('nn', 'Norwegian Nynorsk'),
('pa', 'Punjabi'),
('pl', 'Polish'),
('pt', 'Portuguese'),
('pt-br', 'Brazilian Portuguese'),
('ro', 'Romanian'),
('ru', 'Russian'),
('sk', 'Slovak'),
('sl', 'Slovenian'),
('sq', 'Albanian'),
('sr', 'Serbian'),
('sr-latn', 'Serbian Latin'),
('sv', 'Swedish'),
('sw', 'Swahili'),
('ta', 'Tamil'),
('te', 'Telugu'),
('th', 'Thai'),
('tr', 'Turkish'),
('tt', 'Tatar'),
('uk', 'Ukrainian'),
('ur', 'Urdu'),
('vi', 'Vietnamese'),
('zh-cn', 'Simplified Chinese'),
('zh-tw', 'Traditional Chinese'))
COMMENTS_ALLOW_PROFANITIES
False
STATICFILES_DIRS
()
PREPEND_WWW
False
SECURE_PROXY_SSL_HEADER
None
SESSION_COOKIE_HTTPONLY
True
DEBUG_PROPAGATE_EXCEPTIONS
False
MONTH_DAY_FORMAT
'F j'
LOGIN_URL
'/accounts/login/'
SESSION_EXPIRE_AT_BROWSER_CLOSE
False
TIME_FORMAT
'P'
DATE_INPUT_FORMATS
('%Y-%m-%d',
'%m/%d/%Y',
'%m/%d/%y',
'%b %d %Y',
'%b %d, %Y',
'%d %b %Y',
'%d %b, %Y',
'%B %d %Y',
'%B %d, %Y',
'%d %B %Y',
'%d %B, %Y')
CSRF_COOKIE_NAME
'csrftoken'
EMAIL_HOST_PASSWORD
u'********************'
PASSWORD_RESET_TIMEOUT_DAYS
u'********************'
CACHE_MIDDLEWARE_ALIAS
'default'
SESSION_SAVE_EVERY_REQUEST
False
NUMBER_GROUPING
0
SESSION_ENGINE
'django.contrib.sessions.backends.db'
CSRF_FAILURE_VIEW
'django.views.csrf.csrf_failure'
CSRF_COOKIE_PATH
'/'
LOGIN_REDIRECT_URL
'/accounts/profile/'
LOGGING
{'disable_existing_loggers': False,
'filters': {'require_debug_false': {'()': 'django.utils.log.RequireDebugFalse'}},
'handlers': {'mail_admins': {'class': 'django.utils.log.AdminEmailHandler',
'filters': ['require_debug_false'],
'level': 'ERROR'}},
'loggers': {'django.request': {'handlers': ['mail_admins'],
'level': 'ERROR',
'propagate': True}},
'version': 1}
IGNORABLE_404_URLS
()
LOCALE_PATHS
()
TEMPLATE_STRING_IF_INVALID
''
LOGOUT_URL
'/accounts/logout/'
EMAIL_USE_TLS
False
FIXTURE_DIRS
()
EMAIL_HOST
'localhost'
DATE_FORMAT
'N j, Y'
MEDIA_ROOT
''
DEFAULT_EXCEPTION_REPORTER_FILTER
'django.views.debug.SafeExceptionReporterFilter'
ADMINS
()
FORMAT_MODULE_PATH
None
DEFAULT_FROM_EMAIL
'webmaster@localhost'
MEDIA_URL
''
DATETIME_FORMAT
'N j, Y, P'
TEMPLATE_DIRS
('/home/swizec/Documents/random-coding/prefetch_vs_related/templates',)
SITE_ID
1
DISALLOWED_USER_AGENTS
()
ALLOWED_INCLUDE_ROOTS
()
STATIC_DOC_ROOT
'/home/swizec/Documents/random-coding/prefetch_vs_related/static'
DECIMAL_SEPARATOR
'.'
SHORT_DATE_FORMAT
'm/d/Y'
TEST_RUNNER
'django.test.simple.DjangoTestSuiteRunner'
CACHE_MIDDLEWARE_KEY_PREFIX
u'********************'
TIME_ZONE
'America/Chicago'
FILE_UPLOAD_MAX_MEMORY_SIZE
2621440
EMAIL_BACKEND
'django.core.mail.backends.smtp.EmailBackend'
DEFAULT_TABLESPACE
''
TEMPLATE_CONTEXT_PROCESSORS
('django.contrib.auth.context_processors.auth',
'django.core.context_processors.debug',
'django.core.context_processors.i18n',
'django.core.context_processors.media',
'django.core.context_processors.static',
'django.core.context_processors.tz',
'django.contrib.messages.context_processors.messages')
SESSION_COOKIE_AGE
1209600
SETTINGS_MODULE
'prefetch_vs_related.settings'
USE_ETAGS
False
LANGUAGES_BIDI
('he', 'ar', 'fa')
FILE_UPLOAD_TEMP_DIR
None
INTERNAL_IPS
('127.0.0.1',)
STATIC_URL
'assets/'
EMAIL_PORT
25
USE_TZ
True
SHORT_DATETIME_FORMAT
'm/d/Y P'
PASSWORD_HASHERS
u'********************'
ABSOLUTE_URL_OVERRIDES
{}
CACHE_MIDDLEWARE_SECONDS
600
DATETIME_INPUT_FORMATS
('%Y-%m-%d %H:%M:%S',
'%Y-%m-%d %H:%M:%S.%f',
'%Y-%m-%d %H:%M',
'%Y-%m-%d',
'%m/%d/%Y %H:%M:%S',
'%m/%d/%Y %H:%M:%S.%f',
'%m/%d/%Y %H:%M',
'%m/%d/%Y',
'%m/%d/%y %H:%M:%S',
'%m/%d/%y %H:%M:%S.%f',
'%m/%d/%y %H:%M',
'%m/%d/%y')
EMAIL_HOST_USER
''
PROFANITIES_LIST
u'********************'
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.
DEBUG = True
TEMPLATE_DEBUG = DEBUG
ADMINS = (
# ('Your Name', 'your_email@example.com'),
)
MANAGERS = ADMINS
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'.
'NAME': 'random', # Or path to database file if using sqlite3.
'USER': 'random', # Not used with sqlite3.
'PASSWORD': 'random', # Not used with sqlite3.
'HOST': '', # Set to empty string for localhost. Not used with sqlite3.
'PORT': '', # Set to empty string for default. Not used with sqlite3.
}
}
# Local time zone for this installation. Choices can be found here:
# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
# although not all choices may be available on all operating systems.
# On Unix systems, a value of None will cause Django to use the same
# timezone as the operating system.
# If running in a Windows environment this must be set to the same as your
# system time zone.
TIME_ZONE = 'America/Chicago'
# Language code for this installation. All choices can be found here:
# http://www.i18nguy.com/unicode/language-identifiers.html
LANGUAGE_CODE = 'en-us'
SITE_ID = 1
# If you set this to False, Django will make some optimizations so as not
# to load the internationalization machinery.
USE_I18N = True
# If you set this to False, Django will not format dates, numbers and
# calendars according to the current locale.
USE_L10N = True
# If you set this to False, Django will not use timezone-aware datetimes.
USE_TZ = True
# Absolute filesystem path to the directory that will hold user-uploaded files.
# Example: "/home/media/media.lawrence.com/media/"
MEDIA_ROOT = ''
# URL that handles the media served from MEDIA_ROOT. Make sure to use a
# trailing slash.
# Examples: "http://media.lawrence.com/media/", "http://example.com/media/"
MEDIA_URL = ''
# Absolute path to the directory static files should be collected to.
# Don't put anything in this directory yourself; store your static files
# in apps' "static/" subdirectories and in STATICFILES_DIRS.
# Example: "/home/media/media.lawrence.com/static/"
STATIC_ROOT = ''
STATIC_DOC_ROOT = '/home/swizec/Documents/random-coding/prefetch_vs_related/static'
# URL prefix for static files.
# Example: "http://media.lawrence.com/static/"
STATIC_URL = 'assets/'
# Additional locations of static files
STATICFILES_DIRS = (
# Put strings here, like "/home/html/static" or "C:/www/django/static".
# Always use forward slashes, even on Windows.
# Don't forget to use absolute paths, not relative paths.
)
# List of finder classes that know how to find static files in
# various locations.
STATICFILES_FINDERS = (
'django.contrib.staticfiles.finders.FileSystemFinder',
'django.contrib.staticfiles.finders.AppDirectoriesFinder',
'django.contrib.staticfiles.finders.DefaultStorageFinder',
)
# Make this unique, and don't share it with anybody.
SECRET_KEY = 'h^o(p2ne-ldx9kofnkoin-sjdox6^**zf9pt%9stkj0=6&amp;__hd'
# List of callables that know how to import templates from various sources.
TEMPLATE_LOADERS = (
'django.template.loaders.filesystem.Loader',
'django.template.loaders.app_directories.Loader',
# 'django.template.loaders.eggs.Loader',
)
MIDDLEWARE_CLASSES = (
'django.middleware.common.CommonMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
# Uncomment the next line for simple clickjacking protection:
# 'django.middleware.clickjacking.XFrameOptionsMiddleware',
'debug_toolbar.middleware.DebugToolbarMiddleware',
)
ROOT_URLCONF = 'prefetch_vs_related.urls'
# Python dotted path to the WSGI application used by Django's runserver.
WSGI_APPLICATION = 'prefetch_vs_related.wsgi.application'
TEMPLATE_DIRS = (
# Put strings here, like "/home/html/django_templates" or "C:/www/django/templates".
# Always use forward slashes, even on Windows.
# Don't forget to use absolute paths, not relative paths.
'/home/swizec/Documents/random-coding/prefetch_vs_related/templates'
)
INSTALLED_APPS = (
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.sites',
'django.contrib.messages',
'django.contrib.staticfiles',
# Uncomment the next line to enable the admin:
'django.contrib.admin',
# Uncomment the next line to enable admin documentation:
# 'django.contrib.admindocs',
'debug_toolbar',
)
# A sample logging configuration. The only tangible logging
# performed by this configuration is to send an email to
# the site admins on every HTTP 500 error when DEBUG=False.
# See http://docs.djangoproject.com/en/dev/topics/logging for
# more details on how to customize your logging configuration.
LOGGING = {
'version': 1,
'disable_existing_loggers': False,
'filters': {
'require_debug_false': {
'()': 'django.utils.log.RequireDebugFalse'
}
},
'handlers': {
'mail_admins': {
'level': 'ERROR',
'filters': ['require_debug_false'],
'class': 'django.utils.log.AdminEmailHandler'
}
},
'loggers': {
'django.request': {
'handlers': ['mail_admins'],
'level': 'ERROR',
'propagate': True,
},
}
}
INTERNAL_IPS = ('127.0.0.1',)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment