Hi Clément
I currently have a working setup for debugging with VSCode and Circuits. My setup looks very similar to yours with some exceptions :
I use pyenv rather then venv
I don't specify a python path for my run configuration
I use python setup.py develop to load in fn_utilities in editable mode
This is my run config
{
"name": "Python: Run Resilient Circuits",
"type": "python",
"request": "launch",
"program": "/Users/rg-ibm/.pyenv/versions/3.6.0/lib/python3.6/site-packages/resilient_circuits/app.py",
"console": "internalConsole"
}
This setup currently lets me set breakpoints when running in Debug Window. Happy to work with you to try figure this out so you can debug. Is it possible that your pythonPath is hitting a different python location than where you have your integration installed?
------------------------------
Ryan Gordon
Security Software Engineer
IBM
------------------------------
Original Message:
Sent: Fri May 24, 2019 03:11 AM
From: Clément Fouque
Subject: Debugging with Visual Studio Code
Hi,
I have some issues to use breakpoints on a custom component with Visual Studio code. Do you know if it's working ?
This is what I've done :
- Create a new virtual environment (Python 2.7)
- pip install resilient-circuits
- pip install -e ./fn_utilities (to have it in editable mode)
- Add a new debug configuration
{
"name": "Run resilien-circuits",
"type": "python",
"request": "attach",
"pythonPath": "${workspaceFolder}/.venv/Scripts/python.exe",
"program": "${workspaceFolder}/lib/sites-packages/resilient_circuits/app.py",
"console": "integratedTerminal"
},
When I set a beakpoint and start the debugging, the breakpoint is not hit. Do you have an idea ?
Thank you.
------------------------------
Clément Fouque
------------------------------