Tutorial :How do you debug (trace execution) of a pylons web application?



Question:

How do you debug (trace execution) of a pylons web application?

(using a mac with textmate)


Solution:1

It's really easy

To sum it up, import the python logging module and send debug messages to the terminal on your Mac where you have the paste server running.

import logging  log = logging.getLogger(__name__)  log.debug('Your trace message')  

This will show up in whatever terminal your paste server is running in as:

17:14:51,060 DEBUG [your_app.controllers.your_controller] Your trace message


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »