Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/go: `go get` fails when repository ends with `.go` [1.13 backport] #34243

Closed
gopherbot opened this issue Sep 11, 2019 · 4 comments
Closed

cmd/go: `go get` fails when repository ends with `.go` [1.13 backport] #34243

gopherbot opened this issue Sep 11, 2019 · 4 comments

Comments

@gopherbot
Copy link

@gopherbot gopherbot commented Sep 11, 2019

@jayconrod requested issue #32483 to be considered for backport to the next 1.13 minor release.

@gopherbot please backport to 1.13, this was a regression

@gopherbot

This comment has been minimized.

Copy link
Author

@gopherbot gopherbot commented Sep 11, 2019

Change https://golang.org/cl/194687 mentions this issue: [release-branch.go1.13] cmd/go: strip trailing slash from versioned arguments

@jayconrod

This comment has been minimized.

Copy link
Contributor

@jayconrod jayconrod commented Sep 11, 2019

This was a regression in 1.13. A workaround is possible, but it's subtle and difficult to discover, and the fix is small.

@gopherbot

This comment has been minimized.

Copy link
Author

@gopherbot gopherbot commented Sep 11, 2019

Closed by merging f0c6230 to release-branch.go1.13.

@gopherbot gopherbot closed this Sep 11, 2019
gopherbot pushed a commit that referenced this issue Sep 11, 2019
…rguments

'go get' accepts arguments of the form path@version, and it passes
them through search.CleanPatterns before querying proxies. With this
change, CleanPatterns preserves text after '@' and will strip trailing
slashes from the patn.

Previously, we did not strip trailing slashes when a version was
present, which caused proxy base URL validation to fail. Module paths
that end with ".go" (for example, github.com/nats-io/nats.go) use
trailing slashes to prevent 'go build' and other commands from
interpreting packages as source file names, so this caused unnecessary
problems for them.

Fixes #34243

Change-Id: Id3730c52089e52f1cac446617c20132a3021a808
Reviewed-on: https://go-review.googlesource.com/c/go/+/194600
Run-TryBot: Jay Conrod <jayconrod@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
(cherry picked from commit 8875fb9)
Reviewed-on: https://go-review.googlesource.com/c/go/+/194687
@bcmills bcmills modified the milestones: Go1.13.1, Go1.13.2 Sep 25, 2019
@katiehockman katiehockman modified the milestones: Go1.13.2, Go1.13.3 Oct 17, 2019
@derekcollison

This comment has been minimized.

Copy link

@derekcollison derekcollison commented Oct 18, 2019

Thank you! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants
You can’t perform that action at this time.