From patchwork Fri Oct 5 07:33:48 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ralf Baechle X-Patchwork-Id: 189423 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from ozlabs.org (localhost [IPv6:::1]) by ozlabs.org (Postfix) with ESMTP id D7BA62C034C for ; Fri, 5 Oct 2012 17:41:14 +1000 (EST) X-Greylist: delayed 436 seconds by postgrey-1.34 at bilbo; Fri, 05 Oct 2012 17:41:11 EST Received: from eddie.linux-mips.org (eddie.linux-mips.org [78.24.191.182]) by ozlabs.org (Postfix) with ESMTP id 70A6E2C0094 for ; Fri, 5 Oct 2012 17:41:11 +1000 (EST) Received: from localhost.localdomain ([127.0.0.1]:46911 "EHLO linux-mips.org" rhost-flags-OK-OK-OK-FAIL) by eddie.linux-mips.org with ESMTP id S6870278Ab2JEHdvtXfM4 (ORCPT ); Fri, 5 Oct 2012 09:33:51 +0200 Received: from scotty.linux-mips.net (localhost.localdomain [127.0.0.1]) by scotty.linux-mips.net (8.14.5/8.14.4) with ESMTP id q957Xnkb023558; Fri, 5 Oct 2012 09:33:49 +0200 Received: (from ralf@localhost) by scotty.linux-mips.net (8.14.5/8.14.5/Submit) id q957Xm2I023557; Fri, 5 Oct 2012 09:33:48 +0200 Date: Fri, 5 Oct 2012 09:33:48 +0200 From: Ralf Baechle To: patchwork@lists.ozlabs.org Subject: Patchwork breaks on Fedora 17 Message-ID: <20121005073348.GA20450@linux-mips.org> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) Cc: John Crispin X-BeenThere: patchwork@lists.ozlabs.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Patchwork development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: patchwork-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "Patchwork" An patchwork setup dies like this after upgrading the OS to Fedora 17: mod_python (pid=18233, interpreter='patchwork.dead-in-the-water.org', phase='PythonHandler', handler='django.core.handlers.modpython'): Application error ServerName: 'patchwork.dead-in-the-water.org' DocumentRoot: '/var/www/patchwork.dead-in-the-water.org/patchwork/htdocs/' URI: '/patch/3584/' Location: '/' Directory: None Filename: '/var/www/patchwork.dead-in-the-water.org/patchwork/htdocs/patch' PathInfo: '/3584/' Traceback (most recent call last): File "/usr/lib64/python2.7/site-packages/mod_python/importer.py", line 1537, in HandlerDispatch\n default=default_handler, arg=req, silent=hlist.silent) File "/usr/lib64/python2.7/site-packages/mod_python/importer.py", line 1229, in _process_target\n result = _execute_target(config, req, object, arg) File "/usr/lib64/python2.7/site-packages/mod_python/importer.py", line 1128, in _execute_target\n result = object(arg) File "/usr/lib/python2.7/site-packages/django/core/handlers/modpython.py", line 180, in handler\n return ModPythonHandler()(req) File "/usr/lib/python2.7/site-packages/django/core/handlers/modpython.py", line 158, in __call__\n response = self.get_response(request) File "/usr/lib/python2.7/site-packages/django/core/handlers/base.py", line 179, in get_response\n response = self.handle_uncaught_exception(request, resolver, sys.exc_info()) File "/usr/lib/python2.7/site-packages/django/core/handlers/base.py", line 228, in handle_uncaught_exception\n return callback(request, **param_dict) File "/usr/lib/python2.7/site-packages/django/utils/decorators.py", line 91, in _wrapped_view\n response = view_func(request, *args, **kwargs) File "/usr/lib/python2.7/site-packages/django/views/defaults.py", line 32, in server_error\n t = loader.get_template(template_name) # You need to create a 500.html template. File "/usr/lib/python2.7/site-packages/django/template/loader.py", line 145, in get_template\n template, origin = find_template(template_name) File "/usr/lib/python2.7/site-packages/django/template/loader.py", line 128, in find_template\n loader = find_template_loader(loader_name) File "/usr/lib/python2.7/site-packages/django/template/loader.py", line 101, in find_template_loader\n raise ImproperlyConfigured('Error importing template source loader %s: "%s"' % (loader, e)) ImproperlyConfigured: Error importing template source loader django.template.loaders.filesystem.load_template_source: "'module' object has no attribute 'load_template_source'" I was able to figure out that the following seems to be needed: But that leads to the following errors: mod_python (pid=20390, interpreter='patchwork.dead-in-the-water.org', phase='PythonHandler', handler='django.core.handlers.modpython'): Application error ServerName: 'patchwork.dead-in-the-water.org' DocumentRoot: '/var/www/patchwork.dead-in-the-water.org/patchwork/htdocs/' URI: '/patch/1016/' Location: '/' Directory: None Filename: '/var/www/patchwork.dead-in-the-water.org/patchwork/htdocs/patch' PathInfo: '/1016/' Traceback (most recent call last): File "/usr/lib64/python2.7/site-packages/mod_python/importer.py", line 1537, in HandlerDispatch\n default=default_handler, arg=req, silent=hlist.silent) File "/usr/lib64/python2.7/site-packages/mod_python/importer.py", line 1229, in _process_target\n result = _execute_target(config, req, object, arg) File "/usr/lib64/python2.7/site-packages/mod_python/importer.py", line 1128, in _execute_target\n result = object(arg) File "/usr/lib/python2.7/site-packages/django/core/handlers/modpython.py", line 180, in handler\n return ModPythonHandler()(req) File "/usr/lib/python2.7/site-packages/django/core/handlers/modpython.py", line 158, in __call__\n response = self.get_response(request) File "/usr/lib/python2.7/site-packages/django/core/handlers/base.py", line 179, in get_response\n response = self.handle_uncaught_exception(request, resolver, sys.exc_info()) File "/usr/lib/python2.7/site-packages/django/core/handlers/base.py", line 228, in handle_uncaught_exception\n return callback(request, **param_dict) File "/usr/lib/python2.7/site-packages/django/utils/decorators.py", line 91, in _wrapped_view\n response = view_func(request, *args, **kwargs) File "/usr/lib/python2.7/site-packages/django/views/defaults.py", line 32, in server_error\n t = loader.get_template(template_name) # You need to create a 500.html template. File "/usr/lib/python2.7/site-packages/django/template/loader.py", line 145, in get_template\n template, origin = find_template(template_name) File "/usr/lib/python2.7/site-packages/django/template/loader.py", line 138, in find_template\n raise TemplateDoesNotExist(name) TemplateDoesNotExist: 500.html And of course adding a 500.html template only makes the error look "prettier" to the use but doesn't fix anything. Do I have to dig up an older Django for Patchwork? Any help you could give would be appreciated, Thanks, Ralf diff --git a/apps/settings.py b/apps/settings.py index 7523099..06fa64f 100644 --- a/apps/settings.py +++ b/apps/settings.py @@ -49,8 +49,8 @@ SECRET_KEY = '000000000000000000000000000000000000000000000000 # List of callables that know how to import templates from various sources. TEMPLATE_LOADERS = ( - 'django.template.loaders.filesystem.load_template_source', - 'django.template.loaders.app_directories.load_template_source', + 'django.template.loaders.filesystem.Loader', + 'django.template.loaders.app_directories.Loader', # 'django.template.loaders.eggs.load_template_source', )