Javascript debugger does not connect to headless instance
See original GitHub issueEnvironment (please complete the following information):
- OS: MacOS 12.1 (M1 Mac Mini)
- Extension version: 1.4.5
Describe the bug:
The Javascript debugger does not connect to headless Edge instance.
Repro steps:
- Launch web server with npm in debug shell
- Launch edge devtools in headless mode with screencast
- Debugger does not attach and breakpoints remain disabled
Expected behavior:
Debugger should attach to the instance of Edge running headless with screencast, just like it does with a separate Edge window.
Additional context:
I am attempting to launch my app using a compound configuration in launch.json
(see below for specifics). If I launch Edge using type: pwa-msedge
then my web server debugger attaches just fine and breakpoints work as expected. I can also attach the Edge DevTools in VSCode to that running instance.
However, I would ideally like a completely unified dev experience, with code, dev tools, and browser embedded within a single VSCode window. I can launch an independent, headless instance of Edge with screencast in my VSCode window, but launching the DevTools directly in this manner does not connect to my app’s debugger/breakpoints.
Snippets from launch.json
"configurations": [
{
"name": "Open App",
"request": "launch",
"type": "pwa-msedge",
"url": "http://localhost:3000",
"webRoot": "${workspaceFolder}",
},
{
"name": "Open App (Headless)",
"request": "launch",
"type": "vscode-edge-devtools.debug",
"url": "http://localhost:3000",
"webRoot": "${workspaceFolder}",
},
{
"name": "Start App",
"command": "npm run start",
"request": "launch",
"type": "node-terminal"
}
],
"compounds": [
{
"name": "Debug App (Works)",
"configurations": ["Start App", "Open App"]
},
{
"name": "Debug App (Does not work)",
"configurations": ["Start App", "Open App (Headless)"]
}
]
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:7 (3 by maintainers)
Top GitHub Comments
You can add the headless option to your launch.json and it works (at least here right now). Notice the runtimeArgs.
This is nice workaround for the time being. If I include both the headless
pwa-msedge
as well as thevscode-edge-devtools.debug
then it effectively behaves as desired. Thanks!