Skip to content

pytest: check test_gossip_throttle's throttling in the log, not by a 3s floor - #46

Merged
kwsantiago merged 2 commits into
blake2b-unifiedfrom
gossip-throttle-tests
Oct 18, 2026
Merged

kwsantiago merged 2 commits into
blake2b-unifiedfrom
gossip-throttle-tests

Conversation

@kwsantiago

Copy link
Copy Markdown

test_gossip_throttle asserted that each throttled session to l4 took more than 3 seconds, which fails in CI at about 2.8 to 2.95 seconds. How long a throttled session takes depends on the message sizes and on the random delay before buffered gossip is flushed (up to a second), and the 3 second figure predates the proportional throttle retry delay.

The test now checks l4's log for a throttle during each slow session, and keeps a lower bound of 1 second, the minimum any throttle waits.

With the flush delay forced to its 1 ms minimum, the old test fails 12/12 (throttled sessions take 2.04 to 2.54 seconds) and the new one passes 10/10. Stock, it passes 20/20. With dev-throttle-gossip removed from l4 it fails, so the check still catches a missing throttle.

This does not address the separate set comparison flake in the same test (#17).

Changelog-None

@kwsantiago
kwsantiago merged commit 78dfd88 into blake2b-unified Oct 18, 2026
46 checks passed
@kwsantiago
kwsantiago deleted the gossip-throttle-tests branch October 18, 2026 00:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant