Skip to content
This repository was archived by the owner on Jul 15, 2023. It is now read-only.
This repository was archived by the owner on Jul 15, 2023. It is now read-only.

Remote debugging has unverified breakpoints and fails to set breakpoint if local GOPATH partially matches remote GOPATH #1009

Description

VS Code Version 1.12.2 (1.12.2)
vscode-go v0.6.61

Local GOPATH:
/Users/mgrigaitis/go
Project:
/Users/mgrigaitis/go/src/github.com/org/repo

Remote GOPATH:
/go
Project:
/go/src/github.com/org/repo

workspaceRoot = /Users/mgrigaitis/go/src/github.com/org/repo
in launch.json:

"program": "${workspaceRoot}",
"remotePath":  "/go/src/github.com/org/repo"

In such case remotePath gets set to empty string '' in https://github.com/Microsoft/vscode-go/blob/4beecf1db2aaa18b336be2ee64476b56202fc959/src/debugAdapter/goDebug.ts#L435

After it gets set to empty string, paths mismatches and breakpoints does not get set. It passes this if: https://github.com/Microsoft/vscode-go/blob/4beecf1db2aaa18b336be2ee64476b56202fc959/src/debugAdapter/goDebug.ts#L517

Error on CreateBreakpoint gets thrown.

One known workaround that I found to "overcome" this issue is add trailing "/" to remotePath. Then remotePath does not match local path and remotePath remains intact, trailing / gets removed.

Might be related to #941 #360

Looks like introduced by #742

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions