Perhaps thats the best way to go. I'll give it a shot.

On Aug 23, 4:58 pm, andrei <andre...@gmail.com> wrote:
> Have you tried to subclass webpy's exceptions?
>
> On Aug 24, 12:11 am, Matt Wright <m...@localprojects.net> wrote:
>
>
>
>
>
>
>
> > I'd like to map specific exceptions in my app to trigger specific HTTP
> > responses. For example, I'd like an InvalidUserException to resolve to
> > a BadReqest HTTP response. I first thought of adding a processor that
> > catches all exceptions and checks a map of exceptions to responses,
> > but I can't catch the exception from my application code within the
> > processor. I'm only able to catch the web.webapi._InternalError
> > exception.
>
> > Might anyone have an idea or hint on how I might do this?

-- 
You received this message because you are subscribed to the Google Groups 
"web.py" group.
To post to this group, send email to webpy@googlegroups.com.
To unsubscribe from this group, send email to 
webpy+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/webpy?hl=en.

Reply via email to