python -m pudb <python_file>
- opens up the script in pudb window, not executed anything yet. For fire modules better to make separate script that executes the individual function of interest, difficult to debug the original main file. Need pudb in virtualenv.
Or:
from pudb import set_trace
...
set_trace()
Then run script as usual, useful for debugging unitttest
?
Gives all the keybindings, arrow keys navigates within window.
Navigate with h,j,k,l,gg,G,C-u,C-d
as per vim.
Shortcut | Description |
---|---|
n |
execute script line by line |
t |
execute up to cursor |
b |
toggle breakpoint |
c |
continue execution until breakpoint/exception/completion |
s |
step into the function call |
u |
move up execution stack |
/ |
search in file ,/. to go next/previous |
Shortcut | Description |
---|---|
`C | v` |
<space> |
expand/collapse |
t/r/s |
show type/rep/str of variable |
@ |
toggle repetition at top of pane |
n |
add a new variable to watch |
Shortcut | Description |
---|---|
m |
view module |
e |
view exception |