go: cmd/go: Windows 10 causes "GOPATH entry is relative" error due to extraneous semicolon

Please answer these questions before submitting your issue. Thanks!

What version of Go are you using (go version)?

1.9

Does this issue reproduce with the latest release?

yes, freshly downloaded windows installer

What operating system and processor architecture are you using (go env)?

Windows 10 64 bit

What did you do?

C:\Users\Oliver>go env
go: GOPATH entry is relative; must be absolute path: "".
For more details see: 'go help gopath'

C:\Users\Oliver>echo %GOPATH%
C:\gopath;D:\work;D:\temp;

What did you expect to see?

normal go env output

What did you see instead?

an error

The issue seems to be the trailing semicolon. However that is what the env variable dialog in win 10 produces and I think go should deal with it.

image

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 15 (11 by maintainers)

Commits related to this issue

Most upvoted comments

" " is a mistake. For the record I consider “” as mistake, but the chances of windows 10 fixing their buggy tool are close to zero, so I guess we have to live with it.

On 20 Sep 2017, at 11:23, Alex Brainman notifications@github.com wrote:

@davecheney I do not see how path elements like " " are different from “”. What do you propose to do with path elements like " "?

Alex

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.