Skip to content

Commit 60c6767

Browse files
colesburysrinivasreddy
authored andcommitted
pythongh-117657: Skip tests that may cause stack overflows under TSan (python#129751)
These tests crash under TSan due to stack overflows. Just skip them if TSan is enabled.
1 parent 9411590 commit 60c6767

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

Lib/test/test_call.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import unittest
22
from test.support import (cpython_only, is_wasi, requires_limited_api, Py_DEBUG,
3-
set_recursion_limit, skip_on_s390x, skip_emscripten_stack_overflow, import_helper)
3+
set_recursion_limit, skip_on_s390x, skip_emscripten_stack_overflow,
4+
skip_if_sanitizer, import_helper)
45
try:
56
import _testcapi
67
except ImportError:
@@ -1036,6 +1037,7 @@ class TestRecursion(unittest.TestCase):
10361037

10371038
@skip_on_s390x
10381039
@unittest.skipIf(is_wasi and Py_DEBUG, "requires deep stack")
1040+
@skip_if_sanitizer("requires deep stack", thread=True)
10391041
@unittest.skipIf(_testcapi is None, "requires _testcapi")
10401042
@skip_emscripten_stack_overflow()
10411043
def test_super_deep(self):

Lib/test/test_functools.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2067,6 +2067,7 @@ def orig(a, /, b, c=True): ...
20672067

20682068
@support.skip_on_s390x
20692069
@unittest.skipIf(support.is_wasi, "WASI has limited C stack")
2070+
@support.skip_if_sanitizer("requires deep stack", thread=True)
20702071
@support.skip_emscripten_stack_overflow()
20712072
def test_lru_recursion(self):
20722073

0 commit comments

Comments
 (0)