Skip to content

e2e: test_issue_810_timeout asserts a zero-slack 100ms wall-clock budget and flakes on CI runners #1376

Closed

Description

@FlorentinDUBOIS

Summary

tests::tests::test_issue_810_timeout asserts a 100 ms wall-clock budget with zero slack, repeated
up to 100 times, where a single breach fails the whole test. It fails intermittently on
GitHub-hosted runners and gated two merges on 2026-09-20.

The assertion

e2e/src/tests/tests.rs:

repeat_until_error_or(100, "issue 810: shutdown struggles until session timeout\n(fixed)",
                      try_issue_810_timeout)

and inside, on worker.wait_for_server_stop():

} else if duration > Duration::from_millis(100) {

One iteration exceeding 100 ms out of 100 fails the test. Every observed failure proxied correctly
(client sent: 1, received: 1); it is the shutdown duration alone that trips.

Measurements, with their conditions

where condition result
GitHub runner, crypto-openssl full suite FAILED
GitHub runner, beta full suite FAILED
GitHub runner, one PR's 9 cells full suite 9/9 pass
developer box isolated, 50 runs 50/50 pass (5 000 iterations, 0 breaches)
developer box full suite, contended 4/5 fail

Both runner failures were labels=ubuntu-latest, runner=GitHub Actions.

The 9/9 sweep bounds the per-cell rate only loosely — at a 5 % rate a clean nine-cell run is the most
likely single outcome, and the rule of three puts the 95 % upper bound at ~33 %. With a nine-cell
matrix, 1-(1-p)^9 gives 17 % / 37 % / 61 % of PRs red at p = 2 % / 5 % / 10 %. Bounding p ≤ 1 % would
need roughly 300 clean cells.

So: a genuine low-rate CI flake, amplified by host contention, on an assertion with no margin.

Why it is worth fixing rather than re-running

A zero-slack wall-clock assertion on a 4-vCPU shared runner cannot distinguish a shutdown regression
from scheduler noise. Today it costs a re-run per occurrence; the real cost is that a genuine
regression in wait_for_server_stop would look identical and be re-run away.

Either widen the budget to something defensible on a contended 4-core host, or replace the wall-clock
bound with what the test actually cares about — that shutdown does not wait for the session timeout —
e.g. asserting it completes well inside the session timeout rather than inside a fixed 100 ms.

Related

The same suite carries a separate and more serious problem, #1373, which is a deterministic datapath
defect rather than a timing assertion. They should not be conflated.

Activity

  1. added a commit that references this issue on Sep 21, 2026
    b96d946
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions