Open gabriel-v opened 1 year ago
Actually you can have function tracing and REPL all the time. i use tracing to detect infinite loop when porting code. REPL is not so usefull while running a game.
pdb style break could work in async functions ( spinlock + yield ) allowing variable inspection. That would be more interesting for REPL use and not very hard to use when code reloading is implemented.
breaking in non async is not always possible on worker-less cpython ( afaik only WaPy can do that on main thread) so it's not worth the work since in the future python code will get more and more compiled to wasm ( mypyc ).
I get it that
pdb
doesn't work in browsers because we don't havesubprocess
and we apparently need it. We also don't havestdin
, which I think is used for the pdb REPL.But I can't figure out how to obtain a debugger workflow where I can python shell myself in the middle of anything, anywhere.
Somebody, somewhere, worked around this - maybe we can field some quick hack in the pythonrc to get some kind of debugger shell / breakpoint REPL?