Describe the bug
I run a typescript node app in a local docker container and attach to it for debugging.
Breakpoints are always unbound now under the new debugger, however they still get hit and open up the transpiled js file instead.
My config:
{
"type": "node",
"request": "attach",
"name": "Docker Attach",
"address": "0.0.0.0",
"port": 9995,
"localRoot": "${workspaceFolder}",
"remoteRoot": "/app",
"outFiles": [
"${workspaceFolder}/build/**/*.js"
],
"skipFiles": [
"<node_internals>/**/*.js",
]
}
Docker container ties ${workspaceFolder}/build and /app/build together as a volume mount. Same with ${workspaceFolder}/src and /app/src. So I can edit and hot reload with Nodemon.
App is started via node --inspect=0.0.0.0:9995 build/src/index.js
Log File
VS Code Version:
Version: 1.49.0
Commit: e790b931385d72cf5669fcefc51cdf65990efa5d
Date: 2020-09-10T17:39:53.251Z
Electron: 9.2.1
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Darwin x64 19.5.0
What happens if you set resolveSourceMapLocations: null? (You'll need to set the type: 'pwa-node' for this to appear as valid)
Hey yeah that makes it work again!
Ok, thanks for confirming, I'll put a fix in for the next release.
Same problem here, but the fix works for me to :+1:
Verification steps -- running the non-nightly js-debug 1.48.8 build:
yarn add typescriptCreate test.ts containing
setInterval(() => {
console.log('test')
}, 1000);
yarn tsc test.ts --sourceMap
node --inspect=19229 test.js, and make sure that port is forwarded locallyCreate a launch.json in the local folder
{
"version": "0.2.0",
"configurations": [
{
"name": "Attach to remote",
"type": "pwa-node",
"request": "attach",
"localRoot": "${workspaceFolder}",
"remoteRoot": "/workspaces/vscode-remote-try-node",
"port": 19229,
}
]
}
Set a breakpoint on line 2 and run the config. Verify that the breakpoint is hit in test.ts
Most helpful comment
Ok, thanks for confirming, I'll put a fix in for the next release.