Closed ddxtanx closed 1 year ago
I can confirm it is the resolution of ${port} that is making the configuration fail. Manually entering the configuration like
code_lldb_port_num = 13000
return {
lldb = {
type = 'server',
executable = {
command = '/Users/{my name}/.vscode/extensions/vadimcn.vscode-lldb-1.8.1/adapter/codelldb',
args = {"--port", code_lldb_port_num}-- adjust as needed, must be absolute path
},
name = 'lldb',
host = '127.0.0.1',
port = code_lldb_port_num
}
}
makes the DAP setup work perfectly.
@ddxtanx How did you come up with that port number 13000? Is that constant? or can anyone define whatever port one wish?
@juhaku It's just a random port I chose! The only important part is that it is defined in the lua file, whereas in the rust-tools.dap file, it is defined as an unresolved "${port}".
Awesome, I update my configs as well.
I get the same issue, and resolved by manually setting the port.
Works for me with ${port}, might be an os thing? not sure. Anyways, manually set the port if it doesn't work for some reason
Does just manually setting the port actually work on Windows? I've done the manual setting and it almost works but the debugger just rejects any breakpoints
I'm currently trying to setup Rust debugging using the codelldb setup listed in the wiki. However, whenever I try to debug a file codelldb exits with status code 1 with the error being listed as "Couldn't connect to 127.0.0.1:${port}: ECONNREFUSED". Is this a problem with how rust-tools.dap is setup or are there configuration steps that I should do to get the port variable filled in? Thank you so much!