On 03/04/13 18:04, [email protected] wrote:
Author: gjm
Date: Wed Apr 3 17:04:50 2013
New Revision: 1464108
URL: http://svn.apache.org/r1464108
Log:
catches failure of request_factory in order to allow requires upgrade messages
to be sent - #494
Modified:
bloodhound/trunk/trac/trac/web/main.py
Modified: bloodhound/trunk/trac/trac/web/main.py
URL:
http://svn.apache.org/viewvc/bloodhound/trunk/trac/trac/web/main.py?rev=1464108&r1=1464107&r2=1464108&view=diff
==============================================================================
--- bloodhound/trunk/trac/trac/web/main.py (original)
+++ bloodhound/trunk/trac/trac/web/main.py Wed Apr 3 17:04:50 2013
@@ -466,7 +466,11 @@ def dispatch_request(environ, start_resp
env_error = e
from trac.hooks import request_factory
- factory = request_factory(global_env)
+ factory = None
+ try:
+ factory = request_factory(global_env)
+ except AttributeError:
+ pass
req = factory().create_request(env, environ, start_response) if factory \
else RequestWithSession(environ, start_response)
translation.make_activable(lambda: req.locale, env.path if env else None)
This was a quick tweak to some code that I believe was introduced in the
multiproduct merge (ticket is
https://issues.apache.org/bloodhound/ticket/494)
There may be some knock-on effects that I have not taken into account so
I will look at it again shortly.
Cheers,
Gary