-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Labels
Description
It seems to be possible to debug both C# and Python code at the same time and allow the debuggers to attach automatically, using this launch json:
launch.json:
{
"version": "0.2.0",
"configurations": [
{
"name": "Start Editor",
"type": "coreclr",
"request": "launch",
"program": "${workspaceFolder}/bin/Editor.dll",
"console": "internalConsole",
"presentation": {
"hidden": true,
"group": "",
"order": 1
},
},
{
"name": "Python Debugger: Remote Attach",
"type": "debugpy",
"request": "attach",
"connect": {
"host": "localhost",
"port": 5678
},
"pathMappings": [
{
"localRoot": "${workspaceFolder}/..",
"remoteRoot": "."
}
],
"preLaunchTask": "waitForDebugger"
}
],
"compounds": [
{
"name": "Start Editor and Attach Debugger",
"configurations": [
"Start Editor",
"Python Debugger: Remote Attach",
],
"stopAll": true,
}]
}
We need a pre launch task to wait for the debugger.
task.json:
{
"version": "2.0.0",
"tasks": [
{
"type": "shell",
"command":"bin/tap",
"args": ["wait-for-port", "--port", "5678"],
"problemMatcher": [],
"label": "waitForDebugger",
"options": {
"env": {
"NODEBUGSERVER": "true"
}
}
}
]
}Reactions are currently unavailable