racker/falcon — pull request #202 by sudorandom (2013-11-14 23:11:14+00:00)
Title: Adds an Exception Handler Mechanism

An attempt at implementing #55. This currently fails the flake8 tests due to too much complexity in falcon.api.API.__call__().

How to use:

```python
def handler(ex, req, resp, params):
log_error(req, ex)
resp.status = falcon.HTTP_500
resp.body = "I regret to inform you that an unfortunate error has occured."

app.add_error_handler(ValueError, handler)
```