I am new to cherrypy, and can't seem to figure out how to have cherrypy emit a stacktrace or error message to my browser when an error occurs.
I am running cherrypy on apache with mod_wsgi, so its particularly annoying to dig through the apache error logs during development.
I am used to PHP, where errors are nicely output to the browser when your script crashes. It is a useful feature when debugging. How does one do this in CherryPy?
This section on logging in CherryPy doesn't seem to cover that, unless I'm missing something obvious.
The most important config setting which governs tracebacks in the browser is request.show_tracebacks
. Set it to True
to get tracebacks. Note that using the "production" config environment sets this to False
. There may be other WSGI components you're using, or some feature of mod_wsgi or Apache which is also getting in the way, but I can't speak to those.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With