Explanation of attach to process in PyCharm?

250 views Asked by At

What is going on in the background in PyCharm whenever you run these PyCharm instructions to "attach to a local process", that makes it possible to then set breakpoints and debug. (A Chalice/Flask app lets say...)

1

There are 1 answers

2
bad_coder On

Often the PyCharm debugger pydev.py will be launched first and spawn the process that runs the code you want to debug.

When an application/process is launched separately "Attach to Process" means the debugger process will be launched in parallel and be attached to an already running process that the debugger did not spawn (like Chalice/Flask or other applications that use their own spawning process).