Repository navigation
tests: Fix a race in test_tracking.py - #1106
Merged
Merged
Conversation
kiri11
approved these changes
Nov 25, 2026
In `test_thread_allocations_multiple_threads`, it was possible for one thread to make its allocation and exit before the second thread makes its allocation. When a thread dies it frees its pthread state, which can be quite large, which might mean that by the time the second thread allocates its allocation will no longer be part of the high water mark. Prevent this by ensuring that neither thread can exit until both threads have made their allocation. Signed-off-by: Matt Wozniski <mwozniski@bloomberg.net>
godlygeek
force-pushed
the
fix_race_in_tests
branch
from
November 25, 2026 19:16
c504d42 to
90e56a6
Compare
godlygeek
enabled auto-merge (rebase)
November 25, 2026 19:17
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1106 +/- ##
==========================================
- Coverage 92.40% 92.38% -0.02%
==========================================
Files 103 103
Lines 13453 13467 +14
Branches 480 480
==========================================
+ Hits 12431 12442 +11
- Misses 1022 1025 +3
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:
|
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.
In
test_thread_allocations_multiple_threads, it was possible for one thread to make its allocation and exit before the second thread makes its allocation. When a thread dies it frees its pthread state, which can be quite large, which might mean that by the time the second thread allocates its allocation will no longer be part of the high water mark.Prevent this by ensuring that neither thread can exit until both threads have made their allocation.