sebdah / vim-delve

Neovim / Vim integration for Delve
MIT License
502 stars 24 forks source link

Setting breakpoints/tracepoints in editor doesn't work #29

Open simonrycroft opened 6 years ago

simonrycroft commented 6 years ago

If I set a breakpoint in the Delve window then code execution halts as expected. However, if I set the same breakpoint using :DlvAddBreakpoint it doesn't.

Looking at my application logs I can see the debug server is creating the breakpoint when using the Delve window e.g. created breakpoint: &api.Breakpoint{ID:1...} but not when setting it in the editor. So I assume the command is not sent when using the editor.

This is when connecting to a debug server running in a Docker container using :DlvConnect localhost:2345 apiVersion=2.

This is using:

Mac OS 10.12.6 NVIM v0.3.1 Delve 1.0.0-rc.2

sebdah commented 6 years ago

This is certainly an issue. The commands should be sent using the Delve connection instead of being issued directly. I won't have time to look into this right now. Any PRs for this are most welcome.

simonrycroft commented 6 years ago

Thanks for the reply. I may have some time to take a look later in the week.

esviai commented 3 years ago

I don't know if it's fixed or not, new vim-delve user here, but I encounter the same problem, when I add the breakpoint from editor, it didn't stop at the newly assigned breakpoint. I need close the terminal buffer and reconnect delve for it to works. So perhaps for anyone encountering it, it might be a workaround for you 😁

niltooth commented 2 years ago

having the same issue