You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Flaky: ServiceInfoProbeTests redirect test saw 6 requests where 1 was expected (dev-01, net10) #329
ServiceInfoProbeTests.ProbeAsync_Should_Report_A_Redirect_With_A_Modern_Body_As_Waiting_Without_Following_It failed once on dev-01 (Linux), net10.0. The run was the full gate of test/bench-defects-185 at fc8254a4, on top of master d516d94e; that branch changes only the performance project. The test took 164 ms. server.RequestPaths held 6 requests where the test expects exactly ["/api/info"]. net11.0 passed in the same run.
Logs: dev-01 ~/.tools/gate-logs/bench-185-20261015T165941Z/. The exact failure block, with the six paths, follows in a comment.
it starts a LoopbackHttpServer that answers every request with 302 Found, a ready daemon's info body and Location: /elsewhere;
it probes it once;
it asserts the state is Waiting and that the server saw only /api/info, which also proves the probe did not follow the redirect.
Hypotheses (root cause first; nothing is retried or widened)
Another process hit the test server's ephemeral loopback port. dev-01 was busy at the time: the quality review's calibration run with its private opencode serve instances, and T3 Code's periodic opencode serve. If any of them probes localhost ports, or if a reused port received traffic meant for an earlier listener, the server records requests the probe never sent. The six paths settle this: a foreign client sends other paths, or another User-Agent.
The probe sent more than one request, for example by following the redirect, retrying, or re-probing. Then the paths would be /api/info or /elsewhere, repeated.
If (1) holds, the defect is in the test: RequestPaths counts every client on the port, so the assertion's oracle is not "what the probe sent". The fix is to attribute requests to the probe (for example by a header the probe sets, or by the connection), not to tolerate extra requests.
Evidence from dev-01, from the Linux lane's read-only check:
The failure. TRX OpenCode.Sdk.Tests_net10.0_x64.trx, test started 2026-10-15T17:05:25.992Z and took 165 ms: AssertionException: Expected to be equivalent to [/api/info] but collection has 6 items but expected 1 at ServiceInfoProbeTests.cs:94. net11.0 passed the same test.
The six paths are not recorded anywhere. TUnit's equivalence message reports only the count, and the console, the TRX and the tunit-report.json all carry the same message. Distinguishing the hypotheses will need the test to report what it saw (see below).
Other processes: none probes random localhost ports.
The other opencode processes on the host were the T3 service (opencode serve --service, since 10:05Z) and the calibration run's opencode serve --stdio --port 0.
Their log mentions only 127.0.0.1:3773, four times today.
In the window 17:05:24–28Z, a calibration session was booting and its MCP clients were connecting to fixed endpoints. Nothing walked ephemeral ports.
So hypothesis 1 (a foreign process) has no support.
Remaining hypotheses:
(a) The probe, or its HttpClient, sent the request more than once: 6 = 1 + 5.
(b) Another test in the same net10 host kept a client aimed at an earlier LoopbackHttpServer whose freed ephemeral port this test's server then reused, for example a background poll that outlived its test.
The first step either way: the assertion should report the paths it saw, and the server should record each request's connection and User-Agent, so the next occurrence names its source. After that comes the fix, whichever hypothesis the evidence supports. Logs: dev-01 ~/.tools/gate-logs/bench-185-20261015T165941Z/; its tests/server-diagnostics/ has not been examined yet.
Activity
Blind-Striker commentedon Oct 15, 2026
Evidence from dev-01, from the Linux lane's read-only check:
OpenCode.Sdk.Tests_net10.0_x64.trx, test started 2026-10-15T17:05:25.992Z and took 165 ms:AssertionException: Expected to be equivalent to [/api/info] but collection has 6 items but expected 1atServiceInfoProbeTests.cs:94. net11.0 passed the same test.opencodeprocesses on the host were the T3 service (opencode serve --service, since 10:05Z) and the calibration run'sopencode serve --stdio --port 0.127.0.0.1:3773, four times today.Remaining hypotheses:
HttpClient, sent the request more than once: 6 = 1 + 5.LoopbackHttpServerwhose freed ephemeral port this test's server then reused, for example a background poll that outlived its test.The first step either way: the assertion should report the paths it saw, and the server should record each request's connection and
User-Agent, so the next occurrence names its source. After that comes the fix, whichever hypothesis the evidence supports. Logs: dev-01~/.tools/gate-logs/bench-185-20261015T165941Z/; itstests/server-diagnostics/has not been examined yet.