9e07e7d971
TranslationHook was using a threading.local() to store an error message however the threading.local() was being created in __init__ of the Hook. Hooks are not per request, so this wasn't really working as planned. Now, instead of using threading.local() at all, we just modify the environ held by pecan (and later used by the ParsableErrorMiddleware). environ is request-local. This change feels a bit crufty because it is but because of the way Exceptions are managed in the app there's not really any good way to do it. We could consider changing the way Exceptions related to error messages, but that would be a very large change. Change-Id: I463059df28f291cea0644b1a9908a907f146ba1f Closes-Bug: #1481244 |
||
---|---|---|
.. | ||
api | ||
cmd | ||
evaluator | ||
hacking | ||
locale | ||
notifier | ||
openstack | ||
storage | ||
tests | ||
__init__.py | ||
coordination.py | ||
i18n.py | ||
keystone_client.py | ||
messaging.py | ||
opts.py | ||
rpc.py | ||
service.py | ||
utils.py |