Delve(dlv)Golang调试器未在VS Code中的断点处停止,但使用了dlv connect

时间:2019-01-22 10:39:59

标签: go visual-studio-code vscode-debugger delve

本地和远程DLV版本:1.1.0
go版本远程:go版本go1.11.2 linux / amd64
go版本localhost:go版本go1.11.2 darwin / amd64

dlv调试:从docker container(docker run -p 2345:2345)...中的GOPATH:dlv debug app --headless --log --listen=:2345

dlv connect :以下操作可从本地主机(macos)GOPATH进行:dlv connect localhost:2345

但是 Vs代码不起作用,它可以连接但不会在断点处停止吗?

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Remote",
            "type": "go",
            "request": "launch",
            "mode": "remote",
            "remotePath": "${workspaceRoot}",
            "port": 2345,
            "host": "localhost",
            "program": "${workspaceRoot}",
            "env": {}
        }
    ]
}

0 个答案:

没有答案