Repository navigation
fix(python): start clock before connect in template protocol delay test - #4161
Closed
EmilyRagan wants to merge 1 commit into
Closed
EmilyRagan wants to merge 1 commit into
EmilyRagan wants to merge 1 commit into
Conversation
The initial delay is measured from connect, but the test started its clock after connect returned. The write then waited slightly less than the full delay as measured, so the >= 0.02 assertion flaked on CI. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: true
Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4161 +/- ##
==========================================
+ Coverage 79.82% 80.33% +0.50%
==========================================
Files 907 911 +4
Lines 70041 70779 +738
Branches 2687 2688 +1
==========================================
+ Hits 55912 56862 +950
+ Misses 13463 13244 -219
- Partials 666 673 +7
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
Member
|
Dup of #4155 |
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.



Summary
test_waits_before_writing_during_the_initial_delay_periodflaked in CI (0.0196 not greater than or equal to 0.02, failed run).TemplateProtocol.connect()setsconnect_complete_timeto the connect time plus the initial delay, but the test started its clock afterconnect()returned. The write could therefore wait slightly less than the full delay as measured.connect()so the measurement covers the whole delay.Test-only change; no protocol behavior changes.
Test plan
uv run pytest test/interfaces/protocols/test_template_protocol.py(22 passed)🤖 Generated with Claude Code