-
Notifications
You must be signed in to change notification settings - Fork 17.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cmd/go/internal/modfetch: show real URL in response body read errors
CL 233437 added a redactedURL field to proxyRepo, a struct that already had a field named 'url'. Neither fields were documented, so the similar names suggest the most natural interpretation that proxyRepo.redactedURL is equivalent to proxyRepo.url.Redacted() rather than something else. That's possibly why it was joined with the module version in CL 406675. It turns out the two URLs differ in more than just redaction: one is the base proxy URL with (escaped) module path joined, the other is just the base proxy URL, in redacted form. Document and rename the fields to make the distinction more clear, and include all 3 of base module proxy URL + module path + module version in the reported URL, rather than just the first and third bits as seen in the errors at https://go.dev/issue/51323#issuecomment-1735812250. For #51323. Updates #38680. Updates #52727. Change-Id: Ib4b134b548adeec826ee88fe51a2cf580fde0516 Cq-Include-Trybots: luci.golang.try:gotip-linux-amd64-longtest Reviewed-on: https://go-review.googlesource.com/c/go/+/532035 LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Bryan Mills <bcmills@google.com> Auto-Submit: Dmitri Shuralyov <dmitshur@golang.org> Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
- Loading branch information
Showing
1 changed file
with
26 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters