Debug session process exited with status: exited abnormally with code 1
When I run dap-debug and select a configuration template, I see Debug session process exited with status: exited abnormally with code 1 as an echo message.
The configuration I am running:
"type": "node",
"request": "launch",
"name": "Jest Current File",
"runtimeVersion": "16.13.1",
"program": "${workspaceFolder}/node_modules/.bin/jest",
"args": ["${relativeFile}", "--verbose", "-i", "--no-cache", "--watch"],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"disableOptimisticBPs": true
check stderrr buffer and I hope that this is not the whole json file, because it is not valid json.
Thanks for the reply and apologies for not posting the complete json file before.
{
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Jest All",
"runtimeVersion": "16.13.1",
"program": "${workspaceFolder}/node_modules/.bin/jest",
"args": ["--runInBand"],
"cwd": "${workspaceRoot}",
"protocol": "inspector",
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"disableOptimisticBPs": true,
"windows": {
"program": "${workspaceFolder}/node_modules/jest/bin/jest"
}
},
{
"type": "node",
"request": "launch",
"name": "Jest Current File",
"runtimeVersion": "16.13.1",
"program": "${workspaceFolder}/node_modules/.bin/jest",
"args": ["${relativeFile}", "--verbose", "-i", "--no-cache", "--watch"],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"disableOptimisticBPs": true
}
]
}
The output from the stderr buffer,
node:internal/modules/cjs/loader:958
throw err;
^
Error: Cannot find module '/Users/p.borde/.emacs.d/.local/cache/.extension/vscode/ms-vscode.node-debug2/extension/out/src/nodeDebug.js'
at Module._resolveFilename (node:internal/modules/cjs/loader:955:15)
at Module._load (node:internal/modules/cjs/loader:803:27)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
at node:internal/main/run_main_module:18:47 {
code: 'MODULE_NOT_FOUND',
requireStack: []
}
Node.js v18.8.0
Process Jest Current File stderr finished
I am using doom emacs and i have this in my config.el
(use-package! dap-mode
:config
(require 'dap-node)
(dap-node-setup))
That adapter is broken, we have to fix it. I think that there was a bug about that.
Understood, thanks having a look. For now, ive manually extracted the debug program.
I'm seeing the same error when I run dap-debug. I noticed this in *Messages* after running (dap-node-setup 1):
[/var/folders/4x/k0952rkx6ys6lyn62d_xrc240000ks/T/extiEAkFa.zip]
End-of-central-directory signature not found. Either this file is not
a zipfile, or it constitutes one disk of a multi-part archive. In the
latter case the central directory and zipfile comment will be found on
the last disk(s) of this archive.
unzip: cannot find zipfile directory in one of /var/folders/4x/k0952rkx6ys6lyn62d_xrc240000ks/T/extiEAkFa.zip or
/var/folders/4x/k0952rkx6ys6lyn62d_xrc240000ks/T/extiEAkFa.zip.zip, and cannot find /var/folders/4x/k0952rkx6ys6lyn62d_xrc240000ks/T/extiEAkFa.zip.ZIP, period.
On further inspection, I found the "zip" is not a zip at all, but JSON indicating (at face value) some kind of rate limit failure:
$ cat /var/folders/4x/k0952rkx6ys6lyn62d_xrc240000ks/T/extiEAkFa.zip
{"$id":"1","innerException":null,"message":"Request was blocked due to exceeding usage of resource 'Count' in namespace 'AnonymousId'. For more information on why your request was blocked, see the topic \"Rate limits\" on the Microsoft Web site (https://go.microsoft.com/fwlink/?LinkId=823950).","typeName":"Microsoft.TeamFoundation.Framework.Server.RequestBlockedException, Microsoft.TeamFoundation.Framework.Server","typeKey":"RequestBlockedException","errorCode":0,"eventId":3000}
pretty printed:
{
"eventId": 3000,
"errorCode": 0,
"typeKey": "RequestBlockedException",
"typeName": "Microsoft.TeamFoundation.Framework.Server.RequestBlockedException, Microsoft.TeamFoundation.Framework.Server",
"message": "Request was blocked due to exceeding usage of resource 'Count' in namespace 'AnonymousId'. For more information on why your request was blocked, see the topic \"Rate limits\" on the Microsoft Web site (https://go.microsoft.com/fwlink/?LinkId=823950).",
"innerException": null,
"$id": "1"
}
Well it seems we are not the only one with this issue, please refer to this issue message for a workaround. It worked for me.
https://github.com/emacs-lsp/dap-mode/issues/554#issuecomment-1171256089
Thanks for linking @texaco. @sparkcanon @yyoncho I suggest this be closed as a dupe