go icon indicating copy to clipboard operation
go copied to clipboard

net/http: TestMaxBytesHandler failures

Open gopherbot opened this issue 2 years ago • 3 comments

#!watchflakes
post <- pkg == "net/http" && test == "TestMaxBytesHandler" && `expected echo`

Issue created automatically to collect these failures.

Example (log):

2022/12/28 09:45:59 httptest.Server blocked in Close after 5 seconds, waiting for connections:
  *net.TCPConn 0xc000014098 127.0.0.1:50424 in state active
2022/12/28 09:45:59 httptest.Server blocked in Close after 5 seconds, waiting for connections:
  *net.TCPConn 0xc00054a030 127.0.0.1:50422 in state active
--- FAIL: TestMaxBytesHandler (3.42s)
    --- FAIL: TestMaxBytesHandler/max_size_100_request_size_1000000 (2.33s)
        serve_test.go:6703: unexpected connection error: Post "http://127.0.0.1:50578": readfrom tcp 127.0.0.1:50579->127.0.0.1:50578: write tcp 127.0.0.1:50579->127.0.0.1:50578: write: connection reset by peer
        serve_test.go:6726: expected echo of size 100; got 0

watchflakes

gopherbot avatar Jan 04 '23 21:01 gopherbot

Found new dashboard test flakes for:

#!watchflakes
post <- pkg == "net/http" && test == "TestMaxBytesHandler"
2022-12-28 16:57 darwin-amd64-12_0 go@24963e5c net/http.TestMaxBytesHandler (log)
2022/12/28 09:45:59 httptest.Server blocked in Close after 5 seconds, waiting for connections:
  *net.TCPConn 0xc000014098 127.0.0.1:50424 in state active
2022/12/28 09:45:59 httptest.Server blocked in Close after 5 seconds, waiting for connections:
  *net.TCPConn 0xc00054a030 127.0.0.1:50422 in state active
--- FAIL: TestMaxBytesHandler (3.42s)
    --- FAIL: TestMaxBytesHandler/max_size_100_request_size_1000000 (2.33s)
        serve_test.go:6703: unexpected connection error: Post "http://127.0.0.1:50578": readfrom tcp 127.0.0.1:50579->127.0.0.1:50578: write tcp 127.0.0.1:50579->127.0.0.1:50578: write: connection reset by peer
        serve_test.go:6726: expected echo of size 100; got 0

watchflakes

gopherbot avatar Jan 04 '23 21:01 gopherbot

(CC @neild)

bcmills avatar Jan 06 '23 22:01 bcmills

Found new dashboard test flakes for:

#!watchflakes
post <- pkg == "net/http" && test == "TestMaxBytesHandler"
2023-02-01 19:47 linux-amd64-race go@ab0f0459 net/http.TestMaxBytesHandler (log)
--- FAIL: TestMaxBytesHandler (0.00s)
2023-02-01 21:30 darwin-amd64-race go@4b7f7eef net/http.TestMaxBytesHandler (log)
--- FAIL: TestMaxBytesHandler (0.16s)
    --- FAIL: TestMaxBytesHandler/max_size_100_request_size_100 (0.02s)
    --- FAIL: TestMaxBytesHandler/max_size_1000_request_size_1000 (0.00s)
    --- FAIL: TestMaxBytesHandler/max_size_1000000_request_size_1000000 (0.00s)
    --- FAIL: TestMaxBytesHandler/max_size_1000000_request_size_1000 (0.00s)
    --- FAIL: TestMaxBytesHandler/max_size_1000_request_size_1000000 (0.01s)
    --- FAIL: TestMaxBytesHandler/max_size_100_request_size_1000000 (0.00s)
    --- FAIL: TestMaxBytesHandler/max_size_1000_request_size_100 (0.00s)
    --- FAIL: TestMaxBytesHandler/max_size_100_request_size_1000 (0.01s)
    --- FAIL: TestMaxBytesHandler/max_size_1000000_request_size_100 (0.01s)

watchflakes

gopherbot avatar Feb 02 '23 19:02 gopherbot

Found new dashboard test flakes for:

#!watchflakes
post <- pkg == "net/http" && ((test == "TestMaxBytesHandler" && `expected echo`) || (log ~ `panic: test timed out` && log ~ `TestMaxBytesHandler \(\d+m\d+s\)`))
2023-04-11 17:02 darwin-amd64-10_15 go@6e8eec73 net/http (log)
panic: test timed out after 3m0s
running tests:
	TestMaxBytesHandler (2m59s)
	TestMaxBytesHandler/max_size_1000000_request_size_100 (2m57s)
	TestMaxBytesHandler/max_size_1000000_request_size_100/h1 (2m50s)
	TestMaxBytesHandler/max_size_1000000_request_size_1000 (2m57s)
	TestMaxBytesHandler/max_size_1000000_request_size_1000/h1 (2m50s)
	TestMaxBytesHandler/max_size_1000000_request_size_1000000 (2m57s)
	TestMaxBytesHandler/max_size_1000000_request_size_1000000/h2 (2m50s)

goroutine 21286 [running]:
panic({0x1428280?, 0xc0001c60a0?})
	/tmp/buildlet/go/src/runtime/panic.go:1016 +0x3ac fp=0xc00036ff10 sp=0xc00036fe60 pc=0x1034a8c
testing.(*M).startAlarm.func1()
	/tmp/buildlet/go/src/testing/testing.go:2260 +0x3b9 fp=0xc00036ffe0 sp=0xc00036ff10 pc=0x10f8339
runtime.goexit()
	/tmp/buildlet/go/src/runtime/asm_amd64.s:1650 +0x1 fp=0xc00036ffe8 sp=0xc00036ffe0 pc=0x1069da1
created by time.goFunc
	/tmp/buildlet/go/src/time/sleep.go:176 +0x2d

watchflakes

gopherbot avatar Apr 12 '23 03:04 gopherbot

Change https://go.dev/cl/483895 mentions this issue: net/http: avoid leaking writer goroutines in tests

gopherbot avatar Apr 12 '23 14:04 gopherbot

Found new dashboard test flakes for:

#!watchflakes
post <- pkg == "net/http" && ((test == "TestMaxBytesHandler" && `expected echo`) || (log ~ `panic: test timed out` && log ~ `TestMaxBytesHandler \(\d+m\d+s\)`))
2024-04-03 15:35 android-386-emu go@d8392e69 net/http (log)
panic: test timed out after 3m0s
running tests:
	Test304Responses (2m58s)
	TestBadResponseAfterReadingBody (2m58s)
	TestBidiStreamReverseProxy (2m58s)
	TestCancelRequestMidBody (2m58s)
	TestCancelRequestWhenSharingConnection (2m59s)
	TestCancelRequestWithChannel (2m59s)
	TestCancelRequestWithChannelBeforeDo_Cancel (2m59s)
	TestCancelRequestWithChannelBeforeDo_Context (2m59s)
...
	TestWriteHeader0 (2m58s)
	TestWriteHeaderNoCodeCheck (2m58s)
	TestWriteHeaderSwitchingProtocols (2m59s)
	TestZeroLengthPostAndResponse (2m59s)

goroutine 24228 [running]:
testing.(*M).startAlarm.func1()
	/workdir/go/src/testing/testing.go:2259 +0x3e1
created by time.goFunc
	/workdir/go/src/time/sleep.go:176 +0x35
2024-04-03 18:01 android-386-emu go@74501172 net/http (log)
panic: test timed out after 3m0s
running tests:
	Test304Responses (2m58s)
	TestBadResponseAfterReadingBody (2m58s)
	TestBidiStreamReverseProxy (2m58s)
	TestCancelRequestMidBody (2m58s)
	TestChunkedResponseHeaders (2m58s)
	TestClient (2m58s)
	TestClientAltersCookiesOnRedirect (2m58s)
	TestClientCallsCloseOnlyOnce (2m58s)
...
	TestWriteDeadlineExtendedOnNewRequest (2m58s)
	TestWriteHeader0 (2m58s)
	TestWriteHeaderNoCodeCheck (2m58s)
	TestZeroLengthPostAndResponse (2m58s)

goroutine 31241 [running]:
testing.(*M).startAlarm.func1()
	/workdir/go/src/testing/testing.go:2259 +0x3e1
created by time.goFunc
	/workdir/go/src/time/sleep.go:176 +0x35

watchflakes

gopherbot avatar Apr 12 '24 22:04 gopherbot