Following issue: I'm working on the remote server to which I connect with VSCode. I want to develop my python code (mostly statistical analysis and usual matplotlib
visualization, nothing too fancy). I used to do it by running my python script in a debug mode by simply pushing 'Debug Python File' button, but currently it results in opening a new terminal on my remote. Now, I was told that we are supposed to launch a interactive job first (qsub ...
) before working on the statistical analysis. The problem is, if I launch a job through qsub
it opens me an interactive terminal in my current terminal, but if I am trying to push 'Debug Python File', it VSCode opens a new terminal, which is not in my interactive job mode.
Following the VSCode python debugging help page intructions, I tried running python -m debugpy --listen 0.0.0.0:5678 ./myscript.py
from my current terminal with interactive job. It worked in theory but it didn't recognize any of my breakpoints in the script. Is there a different way to launch a python debugger in the current terminal in VSCode so the breakpoints are recognized? Should something be specified in launch.json
? Any help is highly appreciated!