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/doc: no error for invalid one-letter package path #24462
Comments
@willfaught does |
Seems to be exculsive to |
Ah, this is because of how However, this has a funny result; the Go tree has many one-letter packages. For example, the one that OP was finding was likely Seems like the easy fix here is to teach |
It doesn't work for
That appears to be correct. y, w, x, v, a, b, c, d all work for me, but e does not:
The output doesn't indicate the absolute import path, so I have no idea where these one-letter packages are. Perhaps go doc should print the import path to disambiguate a partial match. I didn't know about the pattern matching. If that's indeed correct behavior, then I guess this isn't a bug. Thanks for looking into it! |
@mvdan I didn't see you assigned it to yourself until I closed it. Re-opening, sorry. |
Maybe. I simply added a debug print myself. That seems like a discussion/feature for another issue, though. The fix is simple, but the tests rely on a package in the testdata directory, so keeping the tests working is being non-trivial. Will send a CL soon-ish. |
Are you planning to disable the suffix matching?
…On Wed, Mar 21, 2018 at 3:45 AM Daniel Martí ***@***.***> wrote:
Perhaps go doc should print the import path to disambiguate a partial
match.
Maybe. I simply added a debug print myself. That seems like a
discussion/feature for another issue, though.
The fix is simple, but the tests rely on a package in the testdata
directory, so keeping the tests working is being non-trivial. Will send a
CL soon-ish.
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub
<#24462 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAD5Vhuv7ABpT39wLYL6yIn6z7jYYo4hks5tgi9WgaJpZM4SyhPQ>
.
|
Completely removing the suffix matching is unlikely what we want, as that's a useful feature. The point is fixing this in a way that will keep the tests working. |
Change https://golang.org/cl/106935 mentions this issue: |
@willfaught @jimmyfrasche I finally found a way to keep the tests working that I'm happy with. Reviews welcome. |
Thanks!
…On Sat, Apr 14, 2018 at 3:01 PM GopherBot ***@***.***> wrote:
Closed #24462 <#24462> via 49e3e43
<49e3e43>
.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#24462 (comment)>, or mute the
thread
<https://github.com/notifications/unsubscribe-auth/AAD5VlYyadYyxN2AD-dC0sIM3k7SrJ2Pks5tonGygaJpZM4SyhPQ>
.
|
Reverted, because I botched the test code and broke some builders. Will try again next week. |
Change https://golang.org/cl/109216 mentions this issue: |
This felt vaguely familiar, like maybe I'd reported it before, but searched and couldn't find anything, so apologies if it's a dupe.
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes.
What operating system and processor architecture are you using (
go env
)?What did you do?
What did you expect to see?
What did you see instead?
It seems to be related to the package path being one letter:
The text was updated successfully, but these errors were encountered: