I use pdb.
It's pretty straightforward. Here's how you can try it.

1. import pdb

2. call pdb.set_trace() wherever you need to have a closer look at how
stuff works.
This will pause the thread serving your request and open the pdb
interactive shell.

3. http://www.google.com/search?q=using+pdb

However, I rarely find myself using a debugger. I'll usually print some
info on STDERR or, more even more convenient through an uncaught
exception. :)  raise Exception(info)



This is an interesting topic. I will, if you don't mind, post two more
questions.
1.  Is there a way to get IPython's ipdb instead of the normal pdb
shell? Basically, I'd love pdb with tab-auto-completion.

2.  Is there a way to put, say STDOUT, directly on the HTML output?
I think this was *very convenient* in the PHP world. It is a lot easier
to alt-tab, refresh and see some debugging output instead of switching
to a 3rd window.

It would be nice to actually have a pre-defined template-var so you can
throw it anywhere in the layout.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/turbogears
-~----------~----~----~----~------~----~------~--~---

Reply via email to