Skip to content
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

net/http: TestCancelRequestWithChannelBeforeDo_Cancel failure on Windows long test #35122

Closed
zx2c4 opened this issue Oct 23, 2019 · 7 comments
Closed

Comments

@zx2c4
Copy link
Contributor

@zx2c4 zx2c4 commented Oct 23, 2019

--- FAIL: TestCancelRequestWithChannelBeforeDo_Cancel (1.01s)
    main_test.go:140: Test appears to have leaked a timing out dial:
        internal/poll.runtime_pollWait(0x1018c28, 0x77, 0xa240e0)
                C:/workdir/go/src/runtime/netpoll.go:196 +0x5c
        internal/poll.(*pollDesc).wait(0xc0000f4bc8, 0x77, 0xc00027a000, 0x0, 0x0)
                C:/workdir/go/src/internal/poll/fd_poll_runtime.go:87 +0x4c
        internal/poll.(*ioSrv).ExecIO(0xd57418, 0xc0000f4af0, 0x98c9b8, 0x20, 0xc000417800, 0x5dbc13)
                C:/workdir/go/src/internal/poll/fd_windows.go:228 +0x121
        internal/poll.(*FD).ConnectEx(0xc0000f4a00, 0xa233a0, 0xc00014e120, 0xc0000181b8, 0xc0000f4a00)
                C:/workdir/go/src/internal/poll/fd_windows.go:886 +0x76
        net.(*netFD).connect(0xc0000f4a00, 0xa2d880, 0xc0000181b8, 0x0, 0x0, 0xa233a0, 0xc00014e120, 0x0, 0x0, 0x0, ...)
                C:/workdir/go/src/net/fd_windows.go:117 +0x1fe
        net.(*netFD).dial(0xc0000f4a00, 0xa2d880, 0xc0000181b8, 0xa30860, 0x0, 0xa30860, 0xc0003f0180, 0x0, 0xc00027a001, 0xc0002d53c8)
                C:/workdir/go/src/net/sock_posix.go:149 +0x109
        net.socket(0xa2d880, 0xc0000181b8, 0x958dcb, 0x3, 0x2, 0x1, 0x0, 0x0, 0xa30860, 0x0, ...)
                C:/workdir/go/src/net/sock_posix.go:70 +0x1d9
        net.internetSocket(0xa2d880, 0xc0000181b8, 0x958dcb, 0x3, 0xa30860, 0x0, 0xa30860, 0xc0003f0180, 0x1, 0x0, ...)
                C:/workdir/go/src/net/ipsock_posix.go:141 +0x178
        net.(*sysDialer).doDialTCP(0xc0000ec080, 0xa2d880, 0xc0000181b8, 0x0, 0xc0003f0180, 0x1, 0xc000489680, 0x9)
                C:/workdir/go/src/net/tcpsock_posix.go:65 +0xc9
        net.(*sysDialer).dialTCP(0xc0000ec080, 0xa2d880, 0xc0000181b8, 0x0, 0xc0003f0180, 0xc00015a370, 0x10, 0x10)
                C:/workdir/go/src/net/tcpsock_posix.go:61 +0xde
        net.(*sysDialer).dialSingle(0xc0000ec080, 0xa2d880, 0xc0000181b8, 0xa25840, 0xc0003f0180, 0x0, 0x0, 0x0, 0x0)
                C:/workdir/go/src/net/dial.go:580 +0x509
        net.(*sysDialer).dialSerial(0xc0000ec080, 0xa2d880, 0xc0000181b8, 0xc00015a370, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0)
                C:/workdir/go/src/net/dial.go:548 +0x22b
        net.(*Dialer).DialContext(0xd59b40, 0xa2d880, 0xc0000181b8, 0x958dcb, 0x3, 0xc0001f40f0, 0xf, 0x0, 0x0, 0x0, ...)
                C:/workdir/go/src/net/dial.go:426 +0x5df
        net/http.(*Transport).dial(0xc000068140, 0xa2d880, 0xc0000181b8, 0x958dcb, 0x3, 0xc0001f40f0, 0xf, 0x0, 0xd68440, 0xd68450, ...)
                C:/workdir/go/src/net/http/transport.go:1041 +0x16c
        net/http.(*Transport).dialConn(0xc000068140, 0xa2d880, 0xc0000181b8, 0x0, 0xc00014a220, 0x4, 0xc0001f40f0, 0xf, 0x0, 0xc000006068, ...)
                C:/workdir/go/src/net/http/transport.go:1457 +0x1874
        net/http.(*Transport).dialConnFor(0xc000068140, 0xc00015c210)
                C:/workdir/go/src/net/http/transport.go:1300 +0xe3
        created by net/http.(*Transport).queueForDial
                C:/workdir/go/src/net/http/transport.go:1269 +0x424
        
        net.(*netFD).connect.func2(0xa2d880, 0xc0000181b8, 0xc0000f4a00, 0xc000188360)
                C:/workdir/go/src/net/fd_windows.go:106 +0xbe
        created by net.(*netFD).connect
                C:/workdir/go/src/net/fd_windows.go:105 +0x1d3
        
        testing.(*T).Parallel(0xc0000e3100)
                C:/workdir/go/src/testing/testing.go:821 +0x1dc
        net/http.TestCmdGoNoHTTPServer(0xc0000e3100)
                C:/workdir/go/src/net/http/http_test.go:86 +0x4a
        testing.tRunner(0xc0000e3100, 0x98ce08)
                C:/workdir/go/src/testing/testing.go:916 +0xd0
        created by testing.(*T).Run
                C:/workdir/go/src/testing/testing.go:967 +0x358
        
        testing.(*T).Parallel(0xc0001b2700)
                C:/workdir/go/src/testing/testing.go:821 +0x1dc
        net/http_test.TestConsumingBodyOnNextConn(0xc0001b2700)
                C:/workdir/go/src/net/http/serve_test.go:167 +0x4a
        testing.tRunner(0xc0001b2700, 0x98d5b0)
                C:/workdir/go/src/testing/testing.go:916 +0xd0
        created by testing.(*T).Run
                C:/workdir/go/src/testing/testing.go:967 +0x358
        
        testing.(*T).Parallel(0xc0001b2b00)
                C:/workdir/go/src/testing/testing.go:821 +0x1dc
        net/http.TestRequestWriteTransport(0xc0001b2b00)
                C:/workdir/go/src/net/http/requestwrite_test.go:648 +0x4a
        testing.tRunner(0xc0001b2b00, 0x98cf08)
                C:/workdir/go/src/testing/testing.go:916 +0xd0
        created by testing.(*T).Run
                C:/workdir/go/src/testing/testing.go:967 +0x358
        
        testing.(*T).Parallel(0xc0001b3200)
                C:/workdir/go/src/testing/testing.go:821 +0x1dc
        net/http.TestReadResponseCloseInMiddle(0xc0001b3200)
                C:/workdir/go/src/net/http/response_test.go:648 +0x4a
        testing.tRunner(0xc0001b3200, 0x98ceb0)
                C:/workdir/go/src/testing/testing.go:916 +0xd0
        created by testing.(*T).Run
                C:/workdir/go/src/testing/testing.go:967 +0x358
        
        testing.(*T).Run(0xc0000ea000, 0x978010, 0x2b, 0x98d358, 0x4cab01)
                C:/workdir/go/src/testing/testing.go:968 +0x37f
        testing.runTests.func1(0xc0000cf600)
                C:/workdir/go/src/testing/testing.go:1209 +0x7f
        testing.tRunner(0xc0000cf600, 0xc00008bd98)
                C:/workdir/go/src/testing/testing.go:916 +0xd0
        testing.runTests(0xc000004840, 0xd542e0, 0x200, 0x200, 0x0)
                C:/workdir/go/src/testing/testing.go:1207 +0x2ae
        testing.(*M).Run(0xc000094700, 0x0)
                C:/workdir/go/src/testing/testing.go:1124 +0x17d
        net/http_test.TestMain(0xc000094700)
                C:/workdir/go/src/net/http/main_test.go:23 +0x32
        main.main()
                _testmain.go:1132 +0x13c
FAIL
FAIL    net/http        46.571s

cc @bradfitz @alexbrainman

@gopherbot
Copy link

@gopherbot gopherbot commented Oct 24, 2019

Change https://golang.org/cl/203079 mentions this issue: net/http: remove t.Parallel from a test that counts goroutines

@gopherbot
Copy link

@gopherbot gopherbot commented Oct 25, 2019

Change https://golang.org/cl/203500 mentions this issue: net/http: skip failing test on windows-amd64-longtest builder

gopherbot pushed a commit that referenced this issue Oct 25, 2019
bradfitz is actively thinking about a proper fix.
In the meantime, skip the test to suss out any other failures in the builder.

Updates #35122

Change-Id: I9bf0640222e3d385c1a3e2be5ab52b80d3e8c21a
Reviewed-on: https://go-review.googlesource.com/c/go/+/203500
Run-TryBot: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
@iWdGo
Copy link
Contributor

@iWdGo iWdGo commented Nov 1, 2019

When using the deprecated CloseNotifier interface, goroutines clean up takes longer. Simplest seems to add another second of sleep time.

@gopherbot
Copy link

@gopherbot gopherbot commented Nov 1, 2019

Change https://golang.org/cl/204661 mentions this issue: http/net: add sleep time to allow goroutines clean up

@gopherbot gopherbot closed this in 1e4a358 Nov 2, 2019
@gopherbot
Copy link

@gopherbot gopherbot commented Mar 16, 2020

Change https://golang.org/cl/223699 mentions this issue: [release-branch.go1.13] net/http: deflake TestCancelRequestWithChannelBeforeDo_Cancel

@dmitshur
Copy link
Member

@dmitshur dmitshur commented Mar 16, 2020

@gopherbot, please backport to Go 1.13. This is a test fix. It is needed to fix resolve a failure in the net/http package on windows-amd64-longtest builder, which could be masking other problems and making releasing Go 1.13.x more difficult.

@gopherbot
Copy link

@gopherbot gopherbot commented Mar 16, 2020

Backport issue(s) opened: #37892 (for 1.13).

Remember to create the cherry-pick CL(s) as soon as the patch is submitted to master, according to https://golang.org/wiki/MinorReleases.

gopherbot pushed a commit that referenced this issue Mar 31, 2020
…lBeforeDo_Cancel

Goroutines clean up takes longer when using deprecated CloseNotifier.

For #35122.
Fixes #37892.

Change-Id: Id820a3012b5c781ddfb294b38ee3b009624e398c
Reviewed-on: https://go-review.googlesource.com/c/go/+/204661
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
(cherry picked from commit 1e4a358)
Reviewed-on: https://go-review.googlesource.com/c/go/+/223699
Run-TryBot: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants