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/pkgsite: hyperlink does not inherit version for standard library packages. #68755

Open
alexbozhenko opened this issue Aug 7, 2024 · 5 comments · May be fixed by golang/pkgsite#94
Open

x/pkgsite: hyperlink does not inherit version for standard library packages. #68755

alexbozhenko opened this issue Aug 7, 2024 · 5 comments · May be fixed by golang/pkgsite#94
Assignees
Labels
help wanted NeedsFix The path to resolution is known, but the work has not been done. pkgsite

Comments

@alexbozhenko
Copy link
Contributor

alexbozhenko commented Aug 7, 2024

What is the URL of the page with the issue?

https://pkg.go.dev/[email protected]#hdr-Standard_Library_Usage

What is your user agent?

Mozilla/5.0 (X11; Linux x86_64; rv:128.0) Gecko/20100101 Firefox/128.0

Screenshot

Working link to the same package, includes version:
image

Broken link to a different package, does not include version:
image

What did you do?

  1. Open https://pkg.go.dev/[email protected]#hdr-Standard_Library_Usage
  2. Click on the link in For example, [maps.Keys](https://pkg.go.dev/maps#Keys) returns an iterator over the keys of a map

What did you see happen?

Observe that the link points to the latest(go1.22.6), which does not contain maps.Keys function. The anchor link is broken.
Note: 1.23rc2 does contain that function.

What did you expect to see?

I expected that if I explicitly chose to browse version 1.23rc2, all links would be pointing to that version.

@gopherbot gopherbot added this to the Unreleased milestone Aug 7, 2024
@gabyhelp
Copy link

gabyhelp commented Aug 7, 2024

Related Issues and Documentation

(Emoji vote if this was helpful or unhelpful; more detailed feedback welcome in this discussion.)

@alexbozhenko
Copy link
Contributor Author

@julieqiu, @jba
Hi!
Seems like last time this logic was modified in:
https://go-review.googlesource.com/c/pkgsite/+/241818

If you agree that this should be fixed, I would like to work on the fix.

@hyangah hyangah added the NeedsFix The path to resolution is known, but the work has not been done. label Aug 8, 2024
@hyangah hyangah modified the milestones: Unreleased, pkgsite/backlog Aug 8, 2024
@hyangah
Copy link
Contributor

hyangah commented Aug 8, 2024

I agree that it is a bug. (@jba please confirm so @alexbozhenko can start to work on it)

@jba
Copy link
Contributor

jba commented Aug 8, 2024

Yes it's a bug. I wonder why https://go.dev/cl/241818 didn't fix it?
Thanks for offering to work on it!

@gopherbot
Copy link
Contributor

Change https://go.dev/cl/606395 mentions this issue: internal/fetch: add versioning for links to std packages

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted NeedsFix The path to resolution is known, but the work has not been done. pkgsite
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants