Skip to content

Instantly share code, notes, and snippets.

@nod
Created September 15, 2010 03:52
Show Gist options
  • Save nod/580210 to your computer and use it in GitHub Desktop.
Save nod/580210 to your computer and use it in GitHub Desktop.
class BaseHandler(RequestHandler):
# .... other stuff ....
def _handle_request_exception(self, e):
RequestHandler._handle_request_exception(self,e)
import pdb
pdb.post_mortem()
def bp():
import pdb
pdb.set_trace()
"""
The above allows you to drop into an interactive pdb
session upon exception or at any point where bp() is reached.
"""
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment