summaryrefslogtreecommitdiff
path: root/doc/reference
diff options
context:
space:
mode:
authorOlivier Dony <odo@openerp.com>2016-06-01 12:31:57 +0200
committerOlivier Dony <odo@openerp.com>2016-06-02 00:50:36 +0200
commitef0d05b6e00736e6bb69b4f0e5a849f4d8246657 (patch)
tree5020043ee8ab44f3008255034c151d66817d5176 /doc/reference
parent57944db19a5de1b8f6eca7c0cdc4f860d6ff9e5c (diff)
[IMP] safe_eval: let AuthenticationError and werkzeug HTTPExceptions bubble up
- Werkzeug's HTTPException are useful while dispatching HTTP requests, in order to return a custom error page with an appropriate status code. The http stack should let those exceptions bubble all the way up and return the body of the exception as the HTTP response. - openerp.http.AuthenticationError may be useful while dispatching JSON requests, because the JSON error result will have error code 100 instead of the usual code 200, making it easy to distinguish in simple JSON client code. - Also slightly improved the fallback for unknown exceptions occurring during "safe evaluation", to explicitly mention the original exception type in the generic ValueError that gets raised.
Diffstat (limited to 'doc/reference')
0 files changed, 0 insertions, 0 deletions