-
Notifications
You must be signed in to change notification settings - Fork 17.8k
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/tools/cmd/cover: isolate, tag, and delete package #56783
Comments
I wonder - is this trick a general solution to deleting code from stable modules? I guess it technically is a breaking change, but we're OK with that given that x/tools is a v0, and the workaround is easy - use the new module instead. |
Change https://go.dev/cl/451595 mentions this issue: |
Change https://go.dev/cl/451596 mentions this issue: |
No change in consensus, so accepted. 🎉 |
Since cmd/cover imports x/tools/cover (which is not itself deprecated), its go.mod file needs to require a version of x/tools that includes cover but not cmd/cover. Arbitrarily choose x/tools v0.4.0 as the likely next x/tools release tag and slot it in using a 'replace' directive. For golang/go#56783. Change-Id: I26a5829d0421724ab14437955a8cec4acbfd62b0 Reviewed-on: https://go-review.googlesource.com/c/tools/+/451595 Run-TryBot: Bryan Mills <bcmills@google.com> gopls-CI: kokoro <noreply+kokoro@google.com> Auto-Submit: Bryan Mills <bcmills@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Than McIntosh <thanm@google.com>
Change https://go.dev/cl/461656 mentions this issue: |
Change https://go.dev/cl/461655 mentions this issue: |
Since cmd/cover imports x/tools/cover (which is not itself deprecated), its go.mod file needs to require a version of x/tools that includes cover but not cmd/cover. Arbitrarily choose x/tools v0.6.0 as the likely next x/tools release tag and slot it in using a 'replace' directive. In a followup commit, I will remove the replace directive and update the x/tools dependency to the pseudo-version of the exact commit of this CL. For golang/go#56783. Change-Id: Ia70206cb8c4e6128b90a048aad4e2607db19740b Reviewed-on: https://go-review.googlesource.com/c/tools/+/461655 gopls-CI: kokoro <noreply+kokoro@google.com> Reviewed-by: Robert Findley <rfindley@google.com> Run-TryBot: Bryan Mills <bcmills@google.com> Auto-Submit: Bryan Mills <bcmills@google.com> TryBot-Result: Gopher Robot <gobot@golang.org>
This makes it so that 'go install golang.org/x/tools/cmd/cover@latest' will continue to work. ('go install pkg@version' does not allow replace directives.) For golang/go#56783. Change-Id: I9f899eee36ab4118367b0a3118f701b7b9a5cceb Reviewed-on: https://go-review.googlesource.com/c/tools/+/461656 gopls-CI: kokoro <noreply+kokoro@google.com> Run-TryBot: Bryan Mills <bcmills@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com> Auto-Submit: Bryan Mills <bcmills@google.com>
The documentation for
x/tools/cmd/cover
says:I count 11 CLs updating the package since that notice was first added in CL 9539.
Keeping the code around clearly isn't doing anyone any good — at the very least, it adds noise in
git grep
results (which is how I came to notice it in the first place).I propose that we give it the same treatment as
x/exp/winfsnotify
: carve it out into a nested module, tag that modulecmd/cover/v0.1.0-deprecated
, and then delete it from thex/tools
repo at HEAD.The text was updated successfully, but these errors were encountered: