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
test(node): a_closing_pool_is_unfunded_to_its_lane_and_not_found_to_anyone_else flakes on its pool_closing counter #2682
crates/node/tests/client_loopback.rs — a_closing_pool_is_unfunded_to_its_lane_and_not_found_to_anyone_else failed once locally (full cargo nextest run --workspace) and passed on retry.
The failing assertion is the last one:
anyhow::ensure!(
metric_line_present(&encoded,"decdn_serve_stream_rejected_pool_closing_total 2"),"both refusals must count as pool_closing:\n{encoded}");
Both requests drew their signed ok: false refusal, so the behavior under test held; only the counter read was short.
Likely cause: the test encodes the metrics as soon as the client has read the second refusal, but the server records the pool_closing reset reason when its serve_stream task ends, after the response is on the wire. On a loaded runner the client can win that race and see 1.
Suggested fix: poll the encoded metrics until the line shows 2 (bounded, e.g. 2 s), or await the server's handler completion before reading — the same pattern other loopback tests use for post-response counters.
Activity
test(node): settle the inbound-stream counters before one-shot metric…