This is just a POC currently.
A tool for tracing bytecode execution.
Note that this tool currently works on CPython >= 3.7 only, because it relies on a new event PyTrace_OPCODE
, which is added in CPython 3.7, dispatched inside the bytecode evaluation loop (known as ceval.c::PyEval_EvalFrame
).
$ pip install git+https://github.com/naleraphael/bytetrace.git
It's simple, just like you are using pdb
.
import bytetrace
# ... your code
bytetrace.set_trace()
# ... your code
-
q(uit) Enter this command twice to quit from debugger.
-
pfl (print_f_locals) Print
f_locals
of current frame. (equivalent toinspect.currentframe().f_locals
)