-
-
Notifications
You must be signed in to change notification settings - Fork 223
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Typescript pack debugger ECONNREFUSED #477
Comments
The dap support added in typescript pack is for JS, per the commit message. |
@Uzaaft |
I'm going ahead and closing this. |
Just a heads up, for anyone landing here from search. I came across this issue and was able to solve it by overwriting pwa-node adapter with {
"mfussenegger/nvim-dap",
opts = function()
local dap = require("dap")
require("dap").adapters["pwa-node"] = {
type = "server",
host = "127.0.0.1",
port = "${port}",
executable = {
command = "node",
args = {
require("mason-registry").get_package("js-debug-adapter"):get_install_path()
.. "/js-debug/src/dapDebugServer.js",
"${port}",
},
},
}
for _, language in ipairs({ "typescript", "javascript" }) do
if not dap.configurations[language] then
dap.configurations[language] = {
{
type = "pwa-node",
request = "launch",
name = "Launch file",
program = "${file}",
cwd = "${workspaceFolder}",
},
{
type = "pwa-node",
request = "attach",
name = "Attach",
processId = require("dap.utils").pick_process,
cwd = "${workspaceFolder}",
},
}
end
end
end,
} its weird macOS thing where its ipv6 localhost loop somehow denies ipv4 loop. you can either change address in configuration to 127.0.0.1 or you can remove ipv6 loop from your /etc/hosts |
I’m also on Mac. How does your default /etc/hosts look? |
|
Same as me. So it caused an issue for you, but not for me? That's strange |
I agree thats weird, but im sure its not just a single /etc/hosts file. If you really want to dig, then you should compare macOS versions, firewall rules etc etc. |
Typescript pack got updated with DAP support, but i cant get it working.
Opening debugger UI and trying to launch a debugger with F5 gives me this message
[debug-adapter stdout] Debug server listening at 127.0.0.1:58449
shortly after i get a popup saying that
DAP: Couldn't connect to localhost:${port}: ECONNREFUSED
my config
https://github.com/FiNEk/astro_nvim
The text was updated successfully, but these errors were encountered: