Showing the stack trace from a running Python application

I have this Python application that gets stuck from time to time and I can’t find out where.

Is there any way to signal Python interpreter to show you the exact code that’s running?

Some kind of on-the-fly stacktrace?

Related questions:

  • Print current call stack from a method in Python code
  • Check what a running process is doing: print stack trace of an uninstrumented Python program

29 Answers
29

Leave a Comment