I'm writing a python editor with support to debugging. I have to debug interactively a python code from my application like a IDE, but without many options.
I know bdb and pdb, but I have to execute this script saved into a file and send commands like step over, continue, quit, etc.
I'm trying something using subprocess lib with pdb but I didn't achive a good result.
p = subprocess.Popen(args=[sys.executable, '-m', 'pdb', 'mide.py'],
stdin=subprocess.PIPE,
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
universal_newlines=True)
p.communicate('s')
p.communicate('s')# I know why this line doesn't work, it's just a example how i wanted to do it.
How to make this works in python 3.x? I just need a path to follow, but preferably just with python 3 without external dependences.
P.S. I'm using PyQt5.