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

Investigate what it would take for the debugger to be aware of GOPATH from settings #840

Closed
ramya-rao-a opened this issue Mar 5, 2017 · 4 comments
Assignees

Comments

@ramya-rao-a
Copy link
Contributor

ramya-rao-a commented Mar 5, 2017

The debug adapter cannot read the settings. Therefore if go path is set using go.gopath or go.inferGopath settings then the debug adapter is never aware of the gopath thus set.

It needs user to set the GOPATH again via the debug configurations in the launch.json

@ramya-rao-a ramya-rao-a self-assigned this Mar 5, 2017
@ramya-rao-a ramya-rao-a changed the title Investigate what it would take for the debugger to be aware of User/Workspace settings Investigate what it would take for the debugger to be aware of GOPATH from settings Jul 24, 2017
@ramya-rao-a
Copy link
Contributor Author

The debug adapter runs in a different process altogether than the extension host and so the usual ways of accessing settings in the extension cannot be used by the debug adapter.

One way to solve the current GOPATH resolving issue when debugging is for the debug adapter to infer the GOPATH based on the path of the file/package it is asked to debug. This is being tracked by the PR #1150

@ramya-rao-a
Copy link
Contributor Author

The GOPATH issue is solved by the debugger figuring out the GOPATH from the path provided in the program attribute of the debug configuration. This feature is now out in the latest update to the Go extension 0.6.64

Closing this issue

@selfmodify
Copy link

It looks like GOPATH is broken with the latest release (0.6.64). I get the following error message.

go: GOPATH entry is relative; must be absolute path: "undefined".
For more details see: 'go help gopath'
exit status 2
Process exiting with code: 1

Is there a way to use the earlier version of this plugin (0.6.63)?

@ramya-rao-a
Copy link
Contributor Author

For anyone else landing here, @karamana and I are tracking the broken GOPATH issue in #1194

@vscodebot vscodebot bot locked and limited conversation to collaborators Jan 24, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants