fix: lag ratio guards only engage when churn latency is actually slow#80
Merged
Conversation
The p95/avg ratio caps fired repeatedly today on runs whose absolute latency was excellent (churn p95 of 13-17ms against a 35ms cap) because a fast baseline (~6-8ms) makes the ratio hypersensitive to a few ms of runner jitter. Six unrelated PRs burned manual re-runs on this. Ratio enforcement now additionally requires the churn result itself to be slow (p95 >= 20ms, avg >= 14ms by default, env-tunable). Real regressions on fast baselines remain caught by the untouched delta caps (+20ms p95 / +12ms avg) and absolute cap (35ms p95): a genuine 3x regression from a 7ms baseline blows the delta cap regardless.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this does
Stops the
tests-build-and-lagjob failing on runs whose typing latency is objectively excellent. Six unrelated PRs today failed on ratio blowups where churn p95 was 13–28ms against a 35ms cap — fast baselines make the ratio explode on a few ms of runner jitter.Summary
PROGRAMA_LAG_MIN_CHURN_*_MS_FOR_RATIO)Test Plan