Skip to content

CI flake test_no_delay (recurrence after #9231) #9329

Description

@ksedgwic

test_no_delay failed on an unrelated PR (#9328), including its rerun:
https://github.com/ElementsProject/lightning/actions/runs/29611273082/job/87988254786

The test's own statistics line from the failing run:

Nagle: mean trip 242.8ms with vs 198.2ms without; saving 44.6ms, 3-sigma margin 45.3ms (totals 24.3s vs 19.8s)

So the measured saving (44.6ms) missed the required 3-sigma margin (45.3ms) by 0.7ms. Two observations:

  1. The docstring assumes the Linux Nagle stall is ~200ms, but the measured penalty (~40ms) matches the Linux delayed-ACK minimum: the Nagle stall lasts until the peer's delayed ACK fires, and that quantum is 40ms on Linux (the ~200ms figure is other platforms). So on Linux runners the entire true effect is only ~40ms.

  2. On a loaded runner (4 xdist workers) the margin can exceed that effect: a 45.3ms 3-sigma margin over N=100 implies a per-trip standard deviation of ~107ms against a ~200ms mean, i.e. the distribution is heavy-tailed and a few multi-hundred-ms outliers inflate both the mean and the margin. When margin > effect, the assertion can fail even though the effect is cleanly present.

A median comparison would be much more stable here: the delayed-ACK stall shifts the whole distribution by a quantum, so the median difference captures it while ignoring the scheduler-noise tail.

Part of #9222.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions