I may have ran into a web2py bug:

this is the requested controller:
def index():
    if request.ajax:
        raise HTTP(500, "cant do it")

this is the error handler function errors.py:
def index():
    # dd(response.toolbar())
    return "cant do it from error.py"

and i get a 400 BAD REQUEST error for response.

This is the server stacktrace:
ERROR:Rocket.Errors.Thread-2:Traceback (most recent call last):

  File "C:\Users\Stark\Desktop\myapp\gluon\rocket.py", line 1319, in run
    self.run_app(conn)

  File "C:\Users\Stark\Desktop\myapp\gluon\rocket.py", line 1820, in run_app
    output = self.app(environ, self.start_response)

  File "C:\Users\Stark\Desktop\myapp\gluon\main.py", line 650, in 
app_with_lo
gging
    ret[0] = wsgiapp(environ, responder2)

  File "C:\Users\Stark\Desktop\myapp\gluon\main.py", line 561, in wsgibase
    return wsgibase(new_environ, responder)

  File "C:\Users\Stark\Desktop\myapp\gluon\main.py", line 531, in wsgibase
    if request.body:

  File "C:\Users\Stark\Desktop\myapp\gluon\globals.py", line 278, in body
    raise HTTP(400, "Bad Request - HTTP body is incomplete")

HTTP: 400 BAD REQUEST


-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to