Skip to content

Commit 5e7f75b

Browse files
hawkinspcharleshofer
authored andcommitted
Disable profiler tests under Python 3.14 if multithreaded.
These are currently thread-unsafe due to python/cpython#132817
1 parent 82389d9 commit 5e7f75b

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

‎tests/profiler_test.py‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,12 @@ class ProfilerTest(unittest.TestCase):
6161
# check functional correctness.
6262

6363
def setUp(self):
64+
if sys.version_info >= (3, 14) and jtu.TEST_NUM_THREADS.value > 1:
65+
# TODO(phawkins): try reenabling these after
66+
# https://github.com/python/cpython/issues/132817 is fixed. Simply
67+
# installing the profiler hook is unsafe if there are multiple threads.
68+
self.skipTest("Profiler tests are not thread-safe under Python 3.14")
69+
6470
super().setUp()
6571
self.worker_start = threading.Event()
6672
self.profile_done = False

0 commit comments

Comments
 (0)