Commits
Click on a commit to change the comparison rangefix: Make memory stream test more robust for CI environments
The test_queue_for_streaming_via_sync_call test was failing in CI due to
timing variability when testing cross-thread async communication.
Root Cause:
- The test was checking individual item delta times with a 20ms tolerance
- In CI environments, thread scheduling and event loop coordination can add
significant overhead (observed: 110ms delays)
- The strict per-item timing assertion was too brittle for CI
Solution:
Instead of checking precise timing for each item, the test now verifies:
1. All 3 items are received (correctness)
2. The last item arrives within 1 second (parallel execution proof)
3. The producer ran for the expected duration (>0.5s for 3 items)
This approach:
- Tests the same invariant (parallel streaming works)
- Is resilient to thread scheduling variance
- Provides clear failure messages
- Works reliably in both local and CI environments
The test still validates that items stream in parallel (not sequentially),
which is the core functionality being tested. style: Remove trailing whitespace from test_memory_stream.py
Fix linting errors:
- Line 106: Removed trailing whitespace after comment
- Line 115: Removed whitespace from blank line
- Line 121: Removed whitespace from blank line
All ruff checks now pass. Merge branch 'master' into feature/my-contribution