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: Github username (in Capital Case variant) causes package not found on pkg.go.dev #62188

Closed
sven-seyfert opened this issue Aug 21, 2023 · 4 comments

Comments

@sven-seyfert
Copy link

What is the URL of the page with the issue?

What is your user agent?

  • Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/116.0
  • Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/115.0.0.0 Safari/537.36

Screenshot

grafik

grafik

What did you do?

  • I created my own (first tryout) go package and published it on GitHub.
  • I added git tags (v0.4.0) and used git push origin --tags (which shows up on my GitHub page too).
  • I have a license (MIT) in the repository.
  • I used the proxy command GOPROXY=proxy.golang.org go list -m github.com/sven-seyfert/gomisc@v0.4.0 to address my package for pkg.go.dev.
  • I wait more then a day for my package to be visible on pkg.go.dev.

What did you expect to see?

My package singleinstance of github.com/sven-seyfert/gomisc should be available on pkg.go.dev.

What did you see instead?

Like in the screenshot: "... could not be found."

What did I recognized?

My GitHub username is Sven-Seyfert as Capital Case. When I tried the different URLs in pkg.go.dev and on proxy.golang.org (https://proxy.golang.org/github.com/sven-seyfert/gomisc/@v/v0.4.0.info) I see no issue when I use the lower case variant of sven-seyfert. But when I use the Capital Case variant for the same request I get "bad request: invalid escaped module path "github.com/Sven-Seyfert/gomisc"".

Can this be the reason for my problem?


Thanks for your help and support, I really appreciate it 🤝 .

@gopherbot gopherbot added this to the Unreleased milestone Aug 21, 2023
@bcmills
Copy link
Contributor

bcmills commented Aug 21, 2023

when I use the Capital Case variant for the same request I get "bad request: invalid escaped module path "github.com/Sven-Seyfert/gomisc"".

No, you just have to use an escaped URL:

The proxy definitely has data for the lower-case version as well:

So this looks like some kind of bug in pkgsite itself.

@findleyr
Copy link
Contributor

findleyr commented Aug 22, 2023

I'm pretty sure this is #62031. I'll confirm after the fix is deployed.

@findleyr
Copy link
Contributor

Ok, I've figured it all out...

  • x/pkgsite: packages with go 1.21.0 in go line can't be fetch by pkg.go.dev #62031 was originally preventing any fetching from working, but even after fixing that I was having trouble fetching this module manually, because...
  • v0.1.0 lacks any go files
  • v0.2.0 was named github.com/Sven-Seyfert/gomisc in the go.mod file (and so must be fetched as such, with the exact casing)
  • v0.3.0 was also named github.com/Sven-Seyfert/gomisc, according to the proxy, but the tag in github says github.com/sven-seyfert/gomisc in the go.mod file -- did you change the tag?
  • v0.4.0 is named github.com/sven-seyfert/gomisc

So I've fetch the three valid versions (v0.2.0-v0.4.0). v0.2.0 and v0.3.0 are available with capital 'S': https://pkg.go.dev/github.com/Sven-Seyfert/gomisc?tab=versions. v0.4.0 is available with lower-case 's': https://pkg.go.dev/github.com/sven-seyfert/gomisc?tab=versions

@findleyr findleyr self-assigned this Aug 22, 2023
@findleyr findleyr modified the milestones: Unreleased, pkgsite/later Aug 22, 2023
@sven-seyfert
Copy link
Author

Thank you very much @findleyr for your investigation and your effort, I appreciate it 🤝 .
You're right with all your findings. I changed the tag v0.3.0. I really just need v0.4.0 and the future upcoming versions.
Since it's my first step into own packages and working with GO, it's not a big deal. Anyway, I really grateful.

One question @findleyr : How can I get rid of the versions v0.2.0 and v0.3.0? I really don't need them.

Best regards
Sven

@golang golang locked and limited conversation to collaborators Aug 21, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants