FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-136186: Fix more flaky tests in test_external_inspection by pablogsal · Pull Request #143235 · python/cpython · GitHub

/ cpython Public
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension .py  (1) All 1 file type selected
Viewed files
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Unified
Split
Hide whitespace
Diff view
Unified
Split
Hide whitespace
7 changes: 6 additions & 1 deletion Lib/test/test_external_inspection.py
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
Original file line number Diff line number Diff line change
Expand Up @@ -1752,7 +1752,12 @@ def main_work():
unwinder_gil = RemoteUnwinder(
p.pid, only_active_thread=True
)
gil_traces = _get_stack_trace_with_retry(unwinder_gil)
# Use condition to retry until we capture a thread holding the GIL
# (sampling may catch moments with no GIL holder on slow CI)
gil_traces = _get_stack_trace_with_retry(
unwinder_gil,
condition=lambda t: sum(len(i.threads) for i in t) >= 1,
)

# Count threads
total_threads = sum(
Expand Down
Loading

Back | FazBrowse Home | New Git URL