Commit graph

11 commits

Author SHA1 Message Date
Michael Davis
cb25d13028 Improve error handling for which::which failures
Co-authored-by: Pascal Kuthe <pascalkuthe@pm.me>
2024-01-24 15:47:49 +09:00
Filip Dutescu
e3765ac6d2
feat(dap): send Disconnect if Terminated event received (#5532)
Send a `Disconnect` DAP request if the `Terminated` event is received.
According to the specification, if the debugging session was started by
as `launch`, the debuggee should be terminated alongside the session. If
instead the session was started as `attach`, it should not be disposed of.

This default behaviour can be overriden if the `supportTerminateDebuggee`
capability is supported by the adapter, through the `Disconnect` request
`terminateDebuggee` argument, as described in
[the specification][discon-spec].

This also implies saving the starting command for a debug sessions, in
order to decide which behaviour should be used, as well as validating the
capabilities of the adapter, in order to decide what the disconnect should
do.

An additional change made is handling of the `Exited` event, showing a
message if the exit code is different than `0`, for the user to be aware
off the termination failure.

[discon-spec]: https://microsoft.github.io/debug-adapter-protocol/specification#Requests_Disconnect

Closes: #4674

Signed-off-by: Filip Dutescu <filip.dutescu@gmail.com>
2023-02-20 13:00:00 +09:00
xiaoma20082008
ce0837dbb7
DAP: Add request ID to request timeout message (#6018)
This improves error logging for dap requests. Without the ID
it's hard to know which request is the one that timed out.
2023-02-16 10:21:12 -06:00
Blaž Hrastnik
83a8167402 Invert core -> dap dependency 2021-10-17 13:58:11 +09:00
Dmitry Sharshakov
d943a51e3e
editor: add Node.js debugger 2021-09-26 21:36:06 +03:00
Blaž Hrastnik
28658836ee Add more event types, simplify event decoding 2021-08-22 16:05:12 +09:00
Blaž Hrastnik
3a9e1c305b Refactor types, add a Request trait 2021-08-20 13:43:54 +09:00
Blaž Hrastnik
2d1ae2e44b dap: Split types off into types.rs 2021-08-20 13:43:54 +09:00
Dmitry Sharshakov
b3be6b269a dap-basic: parse stop event 2021-08-20 13:43:54 +09:00
Dmitry Sharshakov
09390be6a5 dap-basic: handle output events 2021-08-20 13:43:54 +09:00
Dmitry Sharshakov
0f6e81b85b Initial debug adapter protocol implementation 2021-08-20 13:43:54 +09:00