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

x/website: wrong package synopses on stdlib packages containing programs #45042

Closed
zephyrtronium opened this issue Mar 15, 2021 · 5 comments
Closed
Labels
FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done.
Milestone

Comments

@zephyrtronium
Copy link
Contributor

https://golang.org/pkg/ currently shows the wrong package synopses on stdlib packages containing ignore-constrained programs intended for go run. E.g., the synopsis on package runtime is mkduff generates duff_*.s., on package os/exec is This is a test program that verifies that it can read from descriptor 3 and that no other descriptors are open., &c.

@gopherbot gopherbot added this to the Unreleased milestone Mar 15, 2021
@zephyrtronium
Copy link
Contributor Author

Probably related, the same page now shows pages for src/cmd, which I believe it did not do previously.

@prattmic
Copy link
Member

prattmic commented Mar 15, 2021

cc @rsc

Perhaps http://golang.org/cl/296378 or one of the other CLs in the stack?

The March 10 snapshot of this page at https://web.archive.org/web/*/https://golang.org/pkg/ has the correct descriptions, so it seems recent.

@cherrymui cherrymui added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Mar 16, 2021
@kortschak
Copy link
Contributor

In all the cases that this is happening, the package documentation synopsis is obtained from a file that has a // +build tag (from memory all are ignore, though that's not likely relevant).

@gopherbot
Copy link

Change https://golang.org/cl/311089 mentions this issue: internal/pkgdoc: fix synopsis pkg name == dir name matching

@dmitshur dmitshur added NeedsFix The path to resolution is known, but the work has not been done. and removed NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. labels Apr 21, 2021
@zephyrtronium
Copy link
Contributor Author

https://golang.org/pkg/ is still showing packages under src/cmd. This issue is not entirely resolved.

@golang golang locked and limited conversation to collaborators Apr 26, 2022
passionSeven added a commit to passionSeven/website that referenced this issue Oct 18, 2022
file.Name.Name should match the directory name not the filename.

In CL 296378, newDirTree's name parameter was removed and synopsis
matched against the filename of the source code, e.g. "*.go".

Fixes golang/go#45042
Fixes golang/go#45614

Change-Id: Ifa4c8a70429e277efb1f9f726de9249509cbcee0
Reviewed-on: https://go-review.googlesource.com/c/website/+/311089
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Trust: Cherry Zhang <cherryyz@google.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done.
Projects
None yet
Development

No branches or pull requests

6 participants