views:

36

answers:

1

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

(using a mac with textmate)

+1  A: 

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

t3k76