-
Notifications
You must be signed in to change notification settings - Fork 17.9k
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/all: no obvious way to download source code #62645
Comments
In my opinion these outdated instructions should just be removed. How to add a module as a dependency to a project is something a Go developer learns once at the beginning of their journey and it doesn't need to be repeated in every README. How to get the source code of a repository depends on where it's hosted. It shouldn't be in the README either, because the same repository can be hosted on various hosting platforms. It's the responsibility of the hosting platform to provide the user with a cloneable path or a download link. |
To be clear I'm not trying to discuss dependencies or adding of them at all. I'm talking about downloading source code, and as you said the hosting platform does not seem to provide the necessary info. The READMEs attempt to provide instructions but these instructions have been broken by the tooling changes. |
But that was the purpose of the instructions in the READMEs. It was not to tell how to get the source code, but how to make it usable as a dependency. The fact that "go get" used to download the source code into GOPATH was a side effect. In the module world you still use "go get" to make it usable as a dependency, but you need to be in a folder with a "go.mod" file. |
In this case the right thing is to fix the hosting platform, not to copy some instructions into every README, which will be wrong as soon as the repository is hosted somewhere else. |
|
maybe we need to add the same notice as the main repo?
|
As a usability case-study, if I want to do a VCS checkout of, say x/crypto, my process is:
|
Same issue. This is extremely frustrating |
Indeed. Just wanted to update my local copy of x/crypto and ran into the same issue, then remembered i had it before a few years ago. This is ridiculous. Its apparently an open source software hosting site, yet it provides no information how to actually clone the repositories. Obvious methods don't work. Well thanks to @aslatter for the github link. |
Change https://go.dev/cl/624115 mentions this issue: |
Change https://go.dev/cl/624155 mentions this issue: |
Change https://go.dev/cl/624175 mentions this issue: |
Change https://go.dev/cl/624195 mentions this issue: |
Change https://go.dev/cl/624215 mentions this issue: |
Change https://go.dev/cl/623820 mentions this issue: |
Change https://go.dev/cl/624078 mentions this issue: |
Change https://go.dev/cl/624216 mentions this issue: |
Change https://go.dev/cl/624235 mentions this issue: |
Change https://go.dev/cl/624217 mentions this issue: |
These days people will just import the packages and the go tool will do the right thing. We don't need to explain it. Add a pointer to the git repo, though. For golang/go#62645 Change-Id: Icbe33e05f96e1b32f6fcc99fb5fb0b2ecb213a08 Reviewed-on: https://go-review.googlesource.com/c/sync/+/623820 Commit-Queue: Ian Lance Taylor <[email protected]> Auto-Submit: Ian Lance Taylor <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: Alan Donovan <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]>
These days people will just import the packages and the go tool will do the right thing. We don't need to explain it. Add a pointer to the git repo, though. For golang/go#62645 Change-Id: Ia5a16d8d66395e3feee2029ea1c3140b4d3939e7 Reviewed-on: https://go-review.googlesource.com/c/net/+/624175 Auto-Submit: Ian Lance Taylor <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: Damien Neil <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]>
These days people will just import the packages and the go tool will do the right thing. We don't need to explain it. Add a pointer to the git repo, though. For golang/go#62645 Change-Id: Ib6a6fb8989df8071b20d50de446d05b270c1f1ae Reviewed-on: https://go-review.googlesource.com/c/oauth2/+/624195 Commit-Queue: Ian Lance Taylor <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: Cody Oss <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> Auto-Submit: Ian Lance Taylor <[email protected]>
Change https://go.dev/cl/624296 mentions this issue: |
These days people will just import the packages and the go tool will do the right thing. We don't need to explain it. Add a pointer to the git repo, though. For golang/go#62645 Change-Id: I0a1721eb456645c1422580497e3dcc9906a41223 Reviewed-on: https://go-review.googlesource.com/c/text/+/624296 Auto-Submit: Ian Lance Taylor <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> Commit-Queue: Ian Lance Taylor <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]>
Add a pointer to the git repo. For golang/go#62645 Change-Id: Ie28be88c7ed4ff3f0f758a7cf8f1c5bf64e5a1f3 Reviewed-on: https://go-review.googlesource.com/c/review/+/624215 Commit-Queue: Ian Lance Taylor <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> Auto-Submit: Ian Lance Taylor <[email protected]>
These days people will just import the packages and the go tool will do the right thing. We don't need to explain it. Add a pointer to the git repo, though. For golang/go#62645 Change-Id: I87fbf5d50e75120052f56ed6d4ac9977056cde9f Reviewed-on: https://go-review.googlesource.com/c/time/+/624235 LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> Commit-Queue: Ian Lance Taylor <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> Auto-Submit: Ian Lance Taylor <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]>
These days people will just import the packages and the go tool will do the right thing. We don't need to explain it. Add a pointer to the git repo, though. For golang/go#62645 Change-Id: I641439c4fa02391fb77b05d639d6815094724a3a Reviewed-on: https://go-review.googlesource.com/c/term/+/624216 Reviewed-by: Dmitri Shuralyov <[email protected]> Auto-Submit: Ian Lance Taylor <[email protected]> Commit-Queue: Ian Lance Taylor <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]>
These days people will just import the packages and the go tool will do the right thing. We don't need to explain it. Add a pointer to the git repo, though. For golang/go#62645 Change-Id: I94cd9c588a68d92c61d00be05740248509a2ae6e Reviewed-on: https://go-review.googlesource.com/c/sys/+/624078 Auto-Submit: Ian Lance Taylor <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Commit-Queue: Ian Lance Taylor <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]>
Remove reference cloning repo into GOPATH. For golang/go#62645 Change-Id: Id1b483f63e7a1c82529df5d991179c07acd51245 Reviewed-on: https://go-review.googlesource.com/c/vgo/+/624217 Reviewed-by: Ian Lance Taylor <[email protected]> Auto-Submit: Ian Lance Taylor <[email protected]> Commit-Queue: Ian Lance Taylor <[email protected]> TryBot-Bypass: Dmitri Shuralyov <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> Commit-Queue: Ian Lance Taylor <[email protected]>
These days people will just import the packages and the go tool will do the right thing. We don't need to explain it. Add a pointer to the git repo, though. For golang/go#62645 Change-Id: I8b1e4a877bd83fe6891688a44d27a6c7902c8979 Reviewed-on: https://go-review.googlesource.com/c/crypto/+/624155 LUCI-TryBot-Result: Go LUCI <[email protected]> Commit-Queue: Ian Lance Taylor <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> Auto-Submit: Ian Lance Taylor <[email protected]> Reviewed-by: Roland Shoemaker <[email protected]>
* x/term: set missing VIRTUAL_TERMINAL_INPUT flag on Windows With this change the arrow keys work with Windows 11 Terminal After verifying https://github.com/containerd/console did work fine, unlike x/term, it's because they have: https://github.com/containerd/console/blob/v1.0.4/console_windows.go#L194 using the same flag fixed x/term for my program Small e2e test reproducing the issue and showing it being fixed can be ran using go run fortio.org/terminal/[email protected] # has the fix (or @latest) go run fortio.org/terminal/[email protected] -history .history # does not have working arrow keys/this fix Fixes golang/go#68830 Change-Id: If20addd054c76b889a52f933695467812be72306 GitHub-Last-Rev: 68e3ca0 GitHub-Pull-Request: golang#17 Reviewed-on: https://go-review.googlesource.com/c/term/+/603960 LUCI-TryBot-Result: Go LUCI <[email protected]> Auto-Submit: Ian Lance Taylor <[email protected]> Reviewed-by: Cherry Mui <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> Commit-Queue: Ian Lance Taylor <[email protected]> Reviewed-by: Alex Brainman <[email protected]> * go.mod: update golang.org/x dependencies Update golang.org/x dependencies to their latest tagged versions. Change-Id: Ia875ad082f993ce02f2cf97d6d3b318091360433 Reviewed-on: https://go-review.googlesource.com/c/term/+/610637 LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: Michael Pratt <[email protected]> Auto-Submit: Gopher Robot <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> * go.mod: update golang.org/x dependencies Update golang.org/x dependencies to their latest tagged versions. Change-Id: I1fc21941bdc8066f3a8d24afdf16e6e10bceaf55 Reviewed-on: https://go-review.googlesource.com/c/term/+/617955 Reviewed-by: Dmitri Shuralyov <[email protected]> Reviewed-by: David Chase <[email protected]> Auto-Submit: Gopher Robot <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> * README: don't recommend go get These days people will just import the packages and the go tool will do the right thing. We don't need to explain it. Add a pointer to the git repo, though. For golang/go#62645 Change-Id: I641439c4fa02391fb77b05d639d6815094724a3a Reviewed-on: https://go-review.googlesource.com/c/term/+/624216 Reviewed-by: Dmitri Shuralyov <[email protected]> Auto-Submit: Ian Lance Taylor <[email protected]> Commit-Queue: Ian Lance Taylor <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> * go.mod: update golang.org/x dependencies Update golang.org/x dependencies to their latest tagged versions. Change-Id: I4ba440821ddd8ce48c2658e67836ff4fbcdd258d Reviewed-on: https://go-review.googlesource.com/c/term/+/626355 Reviewed-by: Dmitri Shuralyov <[email protected]> Auto-Submit: Gopher Robot <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: David Chase <[email protected]> * go.mod: update golang.org/x dependencies Update golang.org/x dependencies to their latest tagged versions. Change-Id: I8348c05748f22f6b6701a197b29e8b6dba837d0d Reviewed-on: https://go-review.googlesource.com/c/term/+/633476 Auto-Submit: Gopher Robot <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: David Chase <[email protected]> * go.mod: update golang.org/x dependencies Update golang.org/x dependencies to their latest tagged versions. Change-Id: Ib4be7af15f194517725e80dde8b52ce59dce04c9 Reviewed-on: https://go-review.googlesource.com/c/term/+/640357 Reviewed-by: Dmitri Shuralyov <[email protected]> Auto-Submit: Gopher Robot <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: David Chase <[email protected]> * Expose History() AddToHistory() and NewHistory() so users of the library can save and restore the history * prep for release under fortio.org/term (#2) * Don't add adjacent duplicates to history (#3) * Add AutoHistory(false) option (default remains true) to not automatically add to the History (#4) * Add AutoHistory(false) option (default remains true) to not automatically add to the History and let the caller of ReadLine() decide, for instance to only add validated commands * Add ReplaceLatest() to mutate top of history. Add comments. Expose DefaultHistoryEntries as const (#5) * Add ReplaceLatest() to mutate top of history. Add comments. Expose DefaultHistoryEntries as const * Correct godoc for ReplaceLatest * Change history default to 99 from 100 so history printed with %02d looks good (#7) --------- Co-authored-by: Gopher Robot <[email protected]> Co-authored-by: Ian Lance Taylor <[email protected]>
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
)?go env
OutputWhat did you do?
I tried to download the source for the golang.org/x/image module.
Following the instructions in the README:
Neither the README, nor the git hosting website that golang.org/x/image redirects to provide a cloneable URL. If one tries to guess using the website URL:
Note that while I use
x/image
as an example, the majority of these modules provide non-working instructions for retrieving the source code.This lack of a canonical way to download source code has apparently been an issue since module-aware
go get
was introduced, with tracking issues coming and going with no new solution provided other than "use the typical VCS clone command". Which is OK (though a worse experience), but seemingly the Go ecosystem never adapted by providing alternate instructions. This is not typically an issue on git hosts like github, where the clone URL is prominent, but I searched for a few minutes and found no mention of a repository clone URL for any of the golang.org/x modules.What did you expect to see?
Ideally, a useable
go
command which downloads the source code, as we were all accustomed to in the pre-module days. Otherwise, simple (working) instructions for cloning these repositories, or at minimum a visible URL which can be used withgit clone
.What did you see instead?
The errors shown above.
The text was updated successfully, but these errors were encountered: