golang / go

The Go programming language
https://go.dev
BSD 3-Clause "New" or "Revised" License
124.07k stars 17.68k forks source link

cmd/go: eliminate test dependencies on cloud.google.com/go #51051

Open bcmills opened 2 years ago

bcmills commented 2 years ago
#!watchflakes
post <- pkg == "cmd/go" && log ~ `https://cloud\.google\.com/go.*: 5\d\d\b`

CL 196961 added a test that fetched a module from cloud.google.com/go.

Unfortunately, the rate of 5XX-series errors for fetches from that repo has increased substantially since around 2021-11-04, quite possibly due to the same underlying problem as #50541.

Since the cloud.google.com server isn't controlled by the Go project proper, we should probably eliminate this test dependency. (CC @matloob)

greplogs --dashboard -md -l -e 'https://cloud\.google\.com/go.*: 5\d\d\b'

2022-02-04T23:42:58-7c9885d/linux-386-longtest 2022-01-25T00:39:08-16d6a52/linux-386-longtest 2022-01-20T19:24:26-2c2e081/linux-386-longtest 2022-01-17T09:23:25-897b3da/linux-386-longtest 2021-12-21T18:34:03-cfb0cc3/linux-amd64-longtest 2021-12-20T23:46:23-1555062/linux-amd64-longtest 2021-11-16T06:36:08-a52e4b9/linux-386-longtest 2021-11-13T02:30:25-c546052/linux-386-longtest 2021-11-04T17:07:48-5772877/linux-amd64-longtest 2021-11-04T16:59:45-6e7b82a/linux-386-longtest 2021-08-16T20:22:08-4466141/linux-386-longtest 2020-07-09T16:26:07-72735e7/linux-386-longtest

bcmills commented 2 years ago

https://build.golang.org/log/4817f8416202d679733c88b235c161ccbe8d7817 provides fairly compelling evidence that this is, in fact, related to #50541: in that log, a cloud.google.com/go fetch with a 500 error occurred in close correspondence with a go.googlesource.com fetch with a 502.

bcmills commented 2 years ago

greplogs -l -e 'https://cloud\.google\.com/go.*: 5\d\d\b' --since=2022-02-05 2022-05-04T00:51:08-8b389eb/linux-386-longtest 2022-04-25T14:52:51-6b1d9ae/linux-386-longtest 2022-03-01T19:46:03-0fcb948/linux-386-longtest 2022-02-08T23:38:05-0b7e586/linux-386-longtest 2022-02-08T22:25:54-5406328/linux-386-longtest

gopherbot commented 1 year ago

Found new dashboard test flakes for:

#!watchflakes
post <- pkg == "cmd/go" && log ~ `https://cloud\.google\.com/go.*: 5\d\d\b`
2023-03-07 20:02 linux-386-longtest go@a4cf4fde cmd/go.TestScript (log) vcs-test.golang.org rerouted to http://127.0.0.1:45969 https://vcs-test.golang.org rerouted to https://127.0.0.1:46359 go test proxy running at GOPROXY=http://127.0.0.1:35749/mod 2023/03/07 20:31:09 http: TLS handshake error from 127.0.0.1:36164: read tcp 127.0.0.1:46359->127.0.0.1:36164: read: connection reset by peer 2023/03/07 20:31:12 http: TLS handshake error from 127.0.0.1:48432: EOF 2023/03/07 20:31:22 http: TLS handshake error from 127.0.0.1:57014: EOF 2023/03/07 20:31:22 http: TLS handshake error from 127.0.0.1:57066: EOF 2023/03/07 20:31:22 http: TLS handshake error from 127.0.0.1:57074: EOF 2023/03/07 20:31:22 http: TLS handshake error from 127.0.0.1:57084: EOF 2023/03/07 20:31:22 http: TLS handshake error from 127.0.0.1:57116: EOF ... --- FAIL: TestScript (0.04s) --- FAIL: TestScript/mod_get_direct (17.59s) script_test.go:134: 2023-03-07T20:31:20Z script_test.go:136: $WORK=/workdir/tmp/cmd-go-test-1421711440/tmpdir1834007519/mod_get_direct3586836163 script_test.go:154: # Regression test for golang.org/issue/34092: with an empty module cache, # 'GOPROXY=direct go get golang.org/x/tools/gopls@master' did not correctly # resolve the pseudo-version for its dependency on golang.org/x/tools. (17.588s) > [short] skip [condition not met] ... [condition not met] > [!git] skip [condition not met] > env GO111MODULE=on > env GOPROXY=direct > env GOSUMDB=off > go list -m cloud.google.com/go@main [stderr] go: cloud.google.com/go@main: unrecognized import path "cloud.google.com/go": reading https://cloud.google.com/go?go-get=1: 500 Internal Server Error script_test.go:154: FAIL: mod_get_direct.txt:13: go list -m cloud.google.com/go@main: exit status 1

watchflakes

gopherbot commented 1 year ago

Found new dashboard test flakes for:

#!watchflakes
post <- pkg == "cmd/go" && log ~ `https://cloud\.google\.com/go.*: 5\d\d\b`
2023-05-31 15:21 darwin-amd64-longtest go@51114a3f cmd/go.TestScript (log) vcs-test.golang.org rerouted to http://127.0.0.1:64035 https://vcs-test.golang.org rerouted to https://127.0.0.1:64036 go test proxy running at GOPROXY=http://127.0.0.1:64037/mod 2023/06/01 07:23:52 http: TLS handshake error from 127.0.0.1:65412: read tcp 127.0.0.1:64036->127.0.0.1:65412: read: connection reset by peer 2023/06/01 07:23:52 http: TLS handshake error from 127.0.0.1:65410: read tcp 127.0.0.1:64036->127.0.0.1:65410: read: connection reset by peer --- FAIL: TestScript (0.73s) --- FAIL: TestScript/mod_get_direct (10.60s) script_test.go:134: 2023-06-01T11:23:25Z script_test.go:136: $WORK=/tmp/buildlet/tmp/cmd-go-test-643595429/tmpdir761922772/mod_get_direct737956522 script_test.go:158: # Regression test for golang.org/issue/34092: with an empty module cache, # 'GOPROXY=direct go get golang.org/x/tools/gopls@master' did not correctly # resolve the pseudo-version for its dependency on golang.org/x/tools. (10.595s) > [!net:cloud.google.com] skip [condition not met] > [!git] skip [condition not met] > env GO111MODULE=on > env GOPROXY=direct > env GOSUMDB=off > go list -m cloud.google.com/go@main [stderr] go: cloud.google.com/go@main: unrecognized import path "cloud.google.com/go": reading https://cloud.google.com/go?go-get=1: 500 Internal Server Error script_test.go:158: FAIL: testdata/script/mod_get_direct.txt:12: go list -m cloud.google.com/go@main: exit status 1

watchflakes

gopherbot commented 1 year ago

Found new dashboard test flakes for:

#!watchflakes
post <- pkg == "cmd/go" && log ~ `https://cloud\.google\.com/go.*: 5\d\d\b`
2023-08-01 17:36 darwin-amd64-longtest go@6fe97654 cmd/go.TestScript (log) vcs-test.golang.org rerouted to http://127.0.0.1:49575 https://vcs-test.golang.org rerouted to https://127.0.0.1:49576 go test proxy running at GOPROXY=http://127.0.0.1:49577/mod 2023/08/01 15:02:48 http: TLS handshake error from 127.0.0.1:51035: read tcp 127.0.0.1:49576->127.0.0.1:51035: read: connection reset by peer 2023/08/01 15:02:48 http: TLS handshake error from 127.0.0.1:51037: read tcp 127.0.0.1:49576->127.0.0.1:51037: read: connection reset by peer --- FAIL: TestScript (0.59s) --- FAIL: TestScript/mod_get_direct (10.43s) script_test.go:132: 2023-08-01T19:01:26Z script_test.go:134: $WORK=/tmp/buildlet/tmp/cmd-go-test-1289819161/tmpdir1692641574/mod_get_direct2118794506 script_test.go:156: # Regression test for golang.org/issue/34092: with an empty module cache, # 'GOPROXY=direct go get golang.org/x/tools/gopls@master' did not correctly # resolve the pseudo-version for its dependency on golang.org/x/tools. (10.413s) > [!net:cloud.google.com] skip [condition not met] > [!git] skip [condition not met] > env GO111MODULE=on > env GOPROXY=direct > env GOSUMDB=off > go list -m cloud.google.com/go@main [stderr] go: cloud.google.com/go@main: unrecognized import path "cloud.google.com/go": reading https://cloud.google.com/go?go-get=1: 500 Internal Server Error script_test.go:156: FAIL: testdata/script/mod_get_direct.txt:12: go list -m cloud.google.com/go@main: exit status 1

watchflakes