<feed xmlns='http://www.w3.org/2005/Atom'>
<title>go/src/net/http/clientserver_test.go, branch main</title>
<subtitle>Fork of Go programming language with my patches.</subtitle>
<id>http://git.kilabit.info/go/atom?h=main</id>
<link rel='self' href='http://git.kilabit.info/go/atom?h=main'/>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/'/>
<updated>2026-04-14T01:39:04Z</updated>
<entry>
<title>net/http: temporarily disable HTTP/3 tests</title>
<updated>2026-04-14T01:39:04Z</updated>
<author>
<name>Nicholas S. Husin</name>
<email>nsh@golang.org</email>
</author>
<published>2026-04-14T00:58:19Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=f35e6df70bf3cbb748657a58f9b5bb9a9a491b69'/>
<id>urn:sha1:f35e6df70bf3cbb748657a58f9b5bb9a9a491b69</id>
<content type='text'>
Tests for HTTP/3 are unfortunately still flaky. The flakes seem to come
mostly from two sources:

1. QUIC connections are not shutdown fast enough, causing them to be
   detected as goroutine leaks.
2. x/net/quic has a race condition where its output buffer are written
   to without locks (synchronously and intentionally, for optimization),
   but may be asynchronously written when the QUIC stream receives a
   STOP_SENDING frame.

Therefore, skip http3Mode for now until the above flakes are fixed.

For #70914
Fixes #78701

Change-Id: If0c857c0933b977fb10a4481124680726a6a6964
Reviewed-on: https://go-review.googlesource.com/c/go/+/766740
Reviewed-by: Nicholas Husin &lt;husin@google.com&gt;
Auto-Submit: Nicholas Husin &lt;husin@google.com&gt;
LUCI-TryBot-Result: golang-scoped@luci-project-accounts.iam.gserviceaccount.com &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Reviewed-by: Carlos Amedee &lt;carlos@golang.org&gt;
</content>
</entry>
<entry>
<title>net/http: fix wrong context being used when shutting down HTTP/3 server</title>
<updated>2026-04-13T19:51:05Z</updated>
<author>
<name>Nicholas S. Husin</name>
<email>nsh@golang.org</email>
</author>
<published>2026-04-13T17:30:33Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=81e9cc392e5787493094f1687341a626936ffdb3'/>
<id>urn:sha1:81e9cc392e5787493094f1687341a626936ffdb3</id>
<content type='text'>
t.Context was accidentally used within a t.Cleanup. This is a mistake
since t.Context will always have been cancelled by the time t.Cleanup
runs.

This is likely the reason for flakiness in some builders: our HTTP/3
finishes before QUIC connections can finish closing asynchronously,
which are then detected as goroutine leaks. To account for this, also
make the shutdown context timeout more generous.

For #70914

Change-Id: I0e5f06a47ef25c5df535543fc1e602f16a6a6964
Reviewed-on: https://go-review.googlesource.com/c/go/+/766620
LUCI-TryBot-Result: golang-scoped@luci-project-accounts.iam.gserviceaccount.com &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Reviewed-by: Nicholas Husin &lt;husin@google.com&gt;
Reviewed-by: Damien Neil &lt;dneil@google.com&gt;
</content>
</entry>
<entry>
<title>net/http: run tests for HTTP/3 where it can already pass</title>
<updated>2026-04-10T21:18:34Z</updated>
<author>
<name>Nicholas S. Husin</name>
<email>nsh@golang.org</email>
</author>
<published>2026-03-30T23:17:03Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=ccf4ba99a90f6f1366daef776ae90187c9f3c6b1'/>
<id>urn:sha1:ccf4ba99a90f6f1366daef776ae90187c9f3c6b1</id>
<content type='text'>
By default, our test harnesses (run and runSynctest) now use http3Mode,
in addition to http1Mode and http2Mode, when no []testMode were
explicitly defined for a given test.

Tests that cannot currently pass for HTTP/3 have been modified to use
http3SkippedMode, which serves as a convenient alias for the old default
of []testMode{http1Mode, http2Mode}.

We changed the default mode and defined http3SkippedMode so we have a
clear list of TODOs in terms of how much changes are still needed before
our HTTP/3 implementation reaches basic feature parity with HTTP/1 and
HTTP/2.

For #70914

Change-Id: I719d5d66399a51f7c3d96180ebed9b606a6a6964
Reviewed-on: https://go-review.googlesource.com/c/go/+/765320
Reviewed-by: Damien Neil &lt;dneil@google.com&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Reviewed-by: Nicholas Husin &lt;husin@google.com&gt;
</content>
</entry>
<entry>
<title>net/http: add support for running HTTP tests against HTTP/3</title>
<updated>2026-04-10T15:24:28Z</updated>
<author>
<name>Nicholas S. Husin</name>
<email>nsh@golang.org</email>
</author>
<published>2026-03-30T23:17:03Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=2f3c778b232dd53c41e1b623d25cd9f4ab28aaa5'/>
<id>urn:sha1:2f3c778b232dd53c41e1b623d25cd9f4ab28aaa5</id>
<content type='text'>
Add support within clientserver_test.go to bring up a test HTTP/3 server
and client when http3Mode testMode option is passed.

To be able to reuse net/http/httptest, net/http/httptest.Server.StartTLS
(and Start) have been modified so they can be called with a nil
Listener. In such cases, both methods will behave identically as usual,
but will not actually make its server serve or set its transport dialer,
both of which requires having a listener. This should be a no-op for
regular users of the package, whose entrypoint via functions such as
NewServer will automatically set a local listener.

Actually enabling HTTP/3 for our tests will be done in a separate CL.

For #70914

Change-Id: Ibc5fc83287b6a04b46e668a54924761a92b620a4
Reviewed-on: https://go-review.googlesource.com/c/go/+/740122
Reviewed-by: Damien Neil &lt;dneil@google.com&gt;
Reviewed-by: Nicholas Husin &lt;husin@google.com&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
</content>
</entry>
<entry>
<title>net/http: use net/http/internal/http2 rather than h2_bundle.go</title>
<updated>2026-03-12T15:13:20Z</updated>
<author>
<name>Damien Neil</name>
<email>dneil@google.com</email>
</author>
<published>2026-03-03T16:12:25Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=080aa8e9647e5211650f34f3a93fb493afbe396d'/>
<id>urn:sha1:080aa8e9647e5211650f34f3a93fb493afbe396d</id>
<content type='text'>
Rework net/http/internal/http2 to use internally-defined types
rather than net/http types (to avoid an import cycle).

Remove h2_bundle.go, and replace it with calls into
net/http/internal/http2 instead.

For #67810

Change-Id: I56a1b28dbd0e302ab15a30f819dd46256a6a6964
Reviewed-on: https://go-review.googlesource.com/c/go/+/751304
Reviewed-by: Nicholas Husin &lt;nsh@golang.org&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Auto-Submit: Damien Neil &lt;dneil@google.com&gt;
Reviewed-by: Nicholas Husin &lt;husin@google.com&gt;
</content>
</entry>
<entry>
<title>net/http: add Transport.NewClientConn</title>
<updated>2025-11-25T01:26:36Z</updated>
<author>
<name>Damien Neil</name>
<email>dneil@google.com</email>
</author>
<published>2025-11-18T22:15:05Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=0921e1db83d3e67032999b5a2f54f5ede8ba39b5'/>
<id>urn:sha1:0921e1db83d3e67032999b5a2f54f5ede8ba39b5</id>
<content type='text'>
For #75772

Change-Id: Iad7607b40636bab1faf8653455e92e9700309003
Reviewed-on: https://go-review.googlesource.com/c/go/+/722223
Reviewed-by: Nicholas Husin &lt;nsh@golang.org&gt;
Reviewed-by: Nicholas Husin &lt;husin@google.com&gt;
Auto-Submit: Damien Neil &lt;dneil@google.com&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
</content>
</entry>
<entry>
<title>net/http: add more tests of transport connection pool</title>
<updated>2025-09-26T22:06:09Z</updated>
<author>
<name>Damien Neil</name>
<email>dneil@google.com</email>
</author>
<published>2024-09-25T18:48:17Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=16be34df02ba073456e5f31203549165585f3e6c'/>
<id>urn:sha1:16be34df02ba073456e5f31203549165585f3e6c</id>
<content type='text'>
Add a variety of addtional tests exercising client connection pooling,
in particular HTTP/2 connection behavior.

Change-Id: I7609d36db5865f1b95c903cfadb0c3233e046c09
Reviewed-on: https://go-review.googlesource.com/c/go/+/615896
Reviewed-by: Nicholas Husin &lt;husin@google.com&gt;
Reviewed-by: Nicholas Husin &lt;nsh@golang.org&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Auto-Submit: Damien Neil &lt;dneil@google.com&gt;
</content>
</entry>
<entry>
<title>net/http: use synctest.Test rather than Run</title>
<updated>2025-05-21T23:06:11Z</updated>
<author>
<name>Damien Neil</name>
<email>dneil@google.com</email>
</author>
<published>2025-05-21T20:24:49Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=a473a0dbc48e9c2f08408e1736d40b6f660eb34b'/>
<id>urn:sha1:a473a0dbc48e9c2f08408e1736d40b6f660eb34b</id>
<content type='text'>
Use the non-experimental Test function.
As a bonus, this lets us drop the hacks we were doing to support
t.Cleanup inside bubbles.

Change-Id: I070624e1384494e9d5fcfee594cfbb7680c1beda
Reviewed-on: https://go-review.googlesource.com/c/go/+/675315
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Auto-Submit: Damien Neil &lt;dneil@google.com&gt;
Reviewed-by: Jonathan Amsterdam &lt;jba@google.com&gt;
</content>
</entry>
<entry>
<title>net/http: use runtime.AddCleanup instead of runtime.SetFinalizer</title>
<updated>2025-02-14T17:59:55Z</updated>
<author>
<name>Carlos Amedee</name>
<email>carlos@golang.org</email>
</author>
<published>2025-02-11T20:50:55Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=45447b4bfff4227a8945951dd7d37f2873992e1b'/>
<id>urn:sha1:45447b4bfff4227a8945951dd7d37f2873992e1b</id>
<content type='text'>
Replace the usage of runtime.SetFinalizer with runtime.AddCleanup in
tests.

Updates #70907

Change-Id: Idd3f1c07f6a7709352ca09948fbcb4a0ad9418bb
Reviewed-on: https://go-review.googlesource.com/c/go/+/648655
Auto-Submit: Carlos Amedee &lt;carlos@golang.org&gt;
Reviewed-by: Damien Neil &lt;dneil@google.com&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
</content>
</entry>
<entry>
<title>net/http: test for racing idle conn closure and new requests</title>
<updated>2024-11-26T18:05:09Z</updated>
<author>
<name>Damien Neil</name>
<email>dneil@google.com</email>
</author>
<published>2024-11-25T19:27:33Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=04879acdebbb08bdca00356f043d769c4b4375ce'/>
<id>urn:sha1:04879acdebbb08bdca00356f043d769c4b4375ce</id>
<content type='text'>
TestTransportRemovesH2ConnsAfterIdle is experiencing flaky
failures due to a bug in idle connection handling.
Upon inspection, TestTransportRemovesH2ConnsAfterIdle
is slow and (I think) not currently testing the condition
that it was added to test.

Using the new synctest package, this CL:

- Adds a test for the failure causing flakes in this test.
- Rewrites the existing test to use synctest to avoid sleeps.
- Adds a new test that covers the condition the test was
  intended to examine.

The new TestTransportIdleConnRacesRequest exercises the
scenario where a never-used connection is closed by the
idle-conn timer at the same time as a new request attempts
to use it. In this race, the new request should either
successfully use the old connection (superseding the
idle timer) or should use a new connection; it should not
use the closing connection and fail.

TestTransportRemovesConnsAfterIdle verifies that
a connection is reused before the idle timer expires,
and not reused after.

TestTransportRemovesConnsAfterBroken verifies
that a connection is not reused after it encounters
an error. This exercises the bug fixed in CL 196665,
which introduced TestTransportRemovesH2ConnsAfterIdle.

For #70515

Change-Id: Id23026d2903fb15ef9a831b2df71177ea177b096
Reviewed-on: https://go-review.googlesource.com/c/go/+/631795
Reviewed-by: Jonathan Amsterdam &lt;jba@google.com&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Auto-Submit: Damien Neil &lt;dneil@google.com&gt;
</content>
</entry>
</feed>
