Error Importing Template Source Loader
Sign in Pricing Blog Support Search GitHub This repository Watch 18 Star 151 Fork 216 hw-cookbooks/graphite Code Issues 20 Pull requests 7 Projects 0 Pulse Graphs New issue ImproperlyConfigured: Error importing template source loader django.template.loaders.filesystem.load_template_source #47 Closed jschneiderhan opened this Issue Apr 9, 2013 · 4 comments Projects None yet Labels None yet Milestone No milestone Assignees No one assigned 1 participant jschneiderhan commented Apr 9, 2013 There's a very good chance that my problem lies elsewhere, but I figured I would post here in case anyone has seen this before. I just brought up a vagrant box with the graphite::default recipe in it's run_list. The chef run completes successfully but I get a 500 error when trying to access the Graphite webapp. The following appears in the /opt/graphite/storage/log/webapp/error.log log file: [Tue Apr 09 12:49:31 2013] [error] [client 10.0.2.2] ImproperlyConfigured: Error importing template source loader django.template.loaders.filesystem.load_template_source: "'module' object has no attribute 'load_template_source'" [Tue Apr 09 12:49:31 2013] [error] [client 10.0.2.2] mod_python (pid=10757, interpreter='graphite', phase='PythonHandler', handler='django.core.handlers.modpython'): Application error [Tue Apr 09 12:49:31 2013] [error] [client 10.0.2.2] ServerName: 'graphite' [Tue Apr 09 12:49:31 2013] [error] [client 10.0.2.2] DocumentRoot: '/opt/graphite/webapp' [Tue Apr 09 12:49:31 2013] [error] [client 10.0.2.2] URI: '/favicon.ico' [Tue Apr 09 12:49:31 2013] [error] [client 10.0.2.2] Location: '/' [Tue Apr 09 12:49:31 2013] [error] [client 10.0.2.2] Directory: None [Tue Apr 09 12:49:31 2013] [error] [client 10.0.2.2] Filename: '/opt/graphite/webapp/favicon.ico' [Tue Apr 09 12:49:31 2013] [error] [client 10.0.2.2] PathInfo: '' [Tue Apr 09 12:49:31 2013] [error] [client 10.0.2.2] Traceback (most recent call last): [Tue Apr 09 12:49:31 2013] [error] [client 10.0.2.2] File "/usr/lib/python2.7/dist-packages/mod_python/importer.py", line 1537, in HandlerDispatch\n default=default_handler, arg=req, silent=hlist.
von GoogleAnmeldenAusgeblendete FelderNach Gruppen oder Nachrichten suchen
Date: Sun, 24 Jun 2012 23:36:02 UTC Severity: grave Found in version dico/2.2-1 Fixed in version https://bugs.debian.org/678912 dico/2.2-2 Done: أحمد المحمودي (Ahmed El-Mahmoudy)
improperly configured. "django.core.exceptions.ImproperlyConfigured: settings.DATABASES is improperly configured. Please supply the ENGINE value. Check settings documentation for more details.in settings.py , I change ENGINE value from slqite3 todjango.db.backends.sqlite3 ( based on documentation :https://docs.djangoproject.com/en/1.4/ref/settings/#engine )because I have django 1.4.5and python 2.7on Debian wheezyCan anyone help me ?Thanks,George Veranis 4 Comments sorted by Votes Date Added Vote Up0Vote Down Aleksandar Erkalović July 2014 Posts: 207Member Hi George!I am not 100% sure but I would say you need to change to newer configuration option for engine (because you have Django 1.4).So from....DATABASE_ENGINE = 'sqlite3'DATABASE_NAME = '%s/objavi.db' % OBJAVI_DIRDATABASE_USER = ''DATABASE_PASSWORD = ''DATABASE_HOST = ''DATABASE_PORT = ''You might need to change it to:DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME':'%s/objavi.db' % OBJAVI_DIR, 'USER': '', 'PASSWORD': '', 'HOST': '', 'PORT': '' }}Aco Vote Up0Vote Down George Veranis July 2014 Posts: 6Member Hi Aco!Yes you are right , the problem fixed .When I run the url of objavi I getException Value:Error importing template source loader django.template.loaders.filesystem.load_template_source: "'module' object has no attribute 'load_template_source'"Exception Location:/usr/lib/python2.7/dist-packages/django/template/loader.py in find_template_loader, line 101It is normal ? or I must configure something else ? after bash post_install.sh I don't get an error Vote Up0Vote Down Aleksandar Erkalović July 2014 Posts: 207Member Hi George!This is another difference in configuration (Objavi was made for Django 1.3):Find:TEMPLATE_LOADERS = ( 'django.template.loaders.filesystem.load_template_source', 'django.template.loaders.app_directories.load_template_source', 'django.template