-
Notifications
You must be signed in to change notification settings - Fork 18k
cmd/go: fix listing of ambiguous paths #34663
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
Conversation
This PR (HEAD: bd2d8f6) has been imported to Gerrit for code review. Please visit https://go-review.googlesource.com/c/go/+/198459 to see it. Tip: You can toggle comments from me using the |
Message from Gobot Gobot: Patch Set 1: Congratulations on opening your first change. Thank you for your contribution! Next steps: Most changes in the Go project go through a few rounds of revision. This can be During May-July and Nov-Jan the Go project is in a code freeze, during which Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Bryan C. Mills: Patch Set 1: (5 comments) Thanks for the CL! Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Jay Conrod: Patch Set 1: (2 comments) Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
This PR (HEAD: 0afdc3e) has been imported to Gerrit for code review. Please visit https://go-review.googlesource.com/c/go/+/198459 to see it. Tip: You can toggle comments from me using the |
Message from Duco van Amstel: Patch Set 1: (8 comments) I have addressed the comments. There was initially some confusion on my side (now resolved thanks to your suggestions!) about the supported use-cases for patterns passed to The new patchset is smaller and should be significantly less impactful from a performance perspective with the Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Jay Conrod: Patch Set 4: Run-TryBot+1 (1 comment) Looks good, with one very small nit to fix. Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Gobot Gobot: Patch Set 4: TryBots beginning. Status page: https://farmer.golang.org/try?commit=86b58c07 Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Bryan C. Mills: Patch Set 4: Code-Review+2 LGTM modulo Jay's comment. Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Gobot Gobot: Patch Set 4: Build is still in progress... Other builds still in progress; subsequent failure notices suppressed until final report. Consult https://build.golang.org/ to see whether they are new failures. Keep in mind that TryBots currently test exactly your git commit, without rebasing. If your commit's git parent is old, the failure might've already been fixed. Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Bryan C. Mills: Patch Set 4: Code-Review+1 TryBot failure looks legitimate. Please update mod_get_trailing_slash.txt. Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Gobot Gobot: Patch Set 4: TryBot-Result-1 6 of 19 TryBots failed: Consult https://build.golang.org/ to see whether they are new failures. Keep in mind that TryBots currently test exactly your git commit, without rebasing. If your commit's git parent is old, the failure might've already been fixed. Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
This PR (HEAD: 4a9bc42) has been imported to Gerrit for code review. Please visit https://go-review.googlesource.com/c/go/+/198459 to see it. Tip: You can toggle comments from me using the |
Message from Duco van Amstel: Patch Set 6: I have updated the comment as per the request. The test failure led me to also consider the initial fix that was made for golang.org/issue/32483 as it appears to no longer be necessary. I have updated the failing test to assert the new and fixed behaviour of Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Duco van Amstel: Patch Set 6:
Aside from the existing unit-tests I have confirmed that the removal of the previous fix is not inducing a regression via a local check on my machine With go1.13.1: -> go version With the HEAD of this CL's Patchset 6: -> /data/go/bin/go version Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Bryan C. Mills: Patch Set 6: Run-TryBot+1 Code-Review+2 (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Gobot Gobot: Patch Set 6: TryBots beginning. Status page: https://farmer.golang.org/try?commit=3bf8b3bd Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Gobot Gobot: Patch Set 6: Build is still in progress... Other builds still in progress; subsequent failure notices suppressed until final report. Consult https://build.golang.org/ to see whether they are new failures. Keep in mind that TryBots currently test exactly your git commit, without rebasing. If your commit's git parent is old, the failure might've already been fixed. Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Gobot Gobot: Patch Set 6: TryBot-Result-1 2 of 19 TryBots failed: Consult https://build.golang.org/ to see whether they are new failures. Keep in mind that TryBots currently test exactly your git commit, without rebasing. If your commit's git parent is old, the failure might've already been fixed. Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Bryan C. Mills: Patch Set 6:
Test failure looks genuine. Probably just need to make the expected outputs conditional on the operating system, or agnostic to the errno text. Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Bryan C. Mills: Patch Set 6: Code-Review+1 Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Bryan C. Mills: Patch Set 6:
Some examples of those approaches to consider: go/src/cmd/go/testdata/script/env_write.txt Lines 7 to 14 in 323212b
•
Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
This PR (HEAD: 5abc200) has been imported to Gerrit for code review. Please visit https://go-review.googlesource.com/c/go/+/198459 to see it. Tip: You can toggle comments from me using the |
Message from Duco van Amstel: Patch Set 7: Have addressed the failing test by platform-dependent error message checks. Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Bryan C. Mills: Patch Set 7: Run-TryBot+1 Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Gobot Gobot: Patch Set 7: TryBots beginning. Status page: https://farmer.golang.org/try?commit=1bfaa22f Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Gobot Gobot: Patch Set 7: TryBot-Result+1 TryBots are happy. Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Message from Duco van Amstel: Patch Set 7: FWIW: I just tested it locally and this change cherry-picks clean on top of release-branch.go1.13 in case we want to back-port this. Please don’t reply on this GitHub thread. Visit golang.org/cl/198459. |
Passing ambiguous patterns, ending in `.go`, to `go list` results in them being interpreted as Go files despite potentially being package references. This can then result in errors on other package references. The parsing logic is modified to check for a locally present file corresponding to any pattern ending in `.go`. If no such file is present the pattern is considered to be a package reference. We're also adding a variety of non-regression tests that fail with the original parsing code but passes after applying the fix. Fixes #32483 Fixes #34653 Change-Id: I073871da0dfc5641a359643f95ac14608fdca09b GitHub-Last-Rev: 5abc200 GitHub-Pull-Request: #34663 Reviewed-on: https://go-review.googlesource.com/c/go/+/198459 Run-TryBot: Bryan C. Mills <[email protected]> TryBot-Result: Gobot Gobot <[email protected]> Reviewed-by: Bryan C. Mills <[email protected]>
This PR is being closed because golang.org/cl/198459 has been merged. |
Passing ambiguous patterns, ending in `.go`, to `go list` results in them being interpreted as Go files despite potentially being package references. This can then result in errors on other package references. The parsing logic is modified to check for a locally present file corresponding to any pattern ending in `.go`. If no such file is present the pattern is considered to be a package reference. We're also adding a variety of non-regression tests that fail with the original parsing code but passes after applying the fix. Updates #34653 Fixes #34694 Change-Id: I073871da0dfc5641a359643f95ac14608fdca09b GitHub-Last-Rev: 5abc200 GitHub-Pull-Request: #34663 Reviewed-on: https://go-review.googlesource.com/c/go/+/198459 Run-TryBot: Bryan C. Mills <[email protected]> TryBot-Result: Gobot Gobot <[email protected]> Reviewed-by: Bryan C. Mills <[email protected]> (cherry picked from commit 33683f1d64df0cef2c598a84b741abb5af8abe5e) Reviewed-on: https://go-review.googlesource.com/c/go/+/198957 Reviewed-by: Jay Conrod <[email protected]>
Passing ambiguous patterns, ending in
.go
, togo list
results in thembeing interpreted as Go files despite potentially being package references.
This can then result in errors on other package references.
The parsing logic is modified to check for a locally present file
corresponding to any pattern ending in
.go
. If no such file is presentthe pattern is considered to be a package reference.
We're also adding a variety of non-regression tests that fail with the
original parsing code but passes after applying the fix.
Fixes #32483
Fixes #34653