From: Kumar Aditya Date: Mon, 21 Apr 2025 17:26:56 +0000 (+0530) Subject: gh-127945: add `test_ctypes` to free-threading TSAN CI (#132727) X-Git-Tag: v3.14.0b1~379 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=8516343d3aeb12e5871ecd1701649fd1fcf46fc0;p=thirdparty%2FPython%2Fcpython.git gh-127945: add `test_ctypes` to free-threading TSAN CI (#132727) --- diff --git a/Lib/test/libregrtest/tsan.py b/Lib/test/libregrtest/tsan.py index 9cc6b5406af4..d984a735bdf9 100644 --- a/Lib/test/libregrtest/tsan.py +++ b/Lib/test/libregrtest/tsan.py @@ -7,6 +7,7 @@ TSAN_TESTS = [ 'test_capi.test_mem', 'test_capi.test_pyatomic', 'test_code', + 'test_ctypes', # 'test_concurrent_futures', # gh-130605: too many data races 'test_enum', 'test_functools', diff --git a/Lib/test/test_ctypes/test_as_parameter.py b/Lib/test/test_ctypes/test_as_parameter.py index c5e1840b0eb7..2da1acfcf298 100644 --- a/Lib/test/test_ctypes/test_as_parameter.py +++ b/Lib/test/test_ctypes/test_as_parameter.py @@ -5,7 +5,7 @@ from ctypes import (Structure, CDLL, CFUNCTYPE, c_short, c_int, c_long, c_longlong, c_byte, c_wchar, c_float, c_double, ArgumentError) -from test.support import import_helper +from test.support import import_helper, skip_if_sanitizer _ctypes_test = import_helper.import_module("_ctypes_test") @@ -192,6 +192,7 @@ class BasicWrapTestCase(unittest.TestCase): self.assertEqual((s8i.a, s8i.b, s8i.c, s8i.d, s8i.e, s8i.f, s8i.g, s8i.h), (9*2, 8*3, 7*4, 6*5, 5*6, 4*7, 3*8, 2*9)) + @skip_if_sanitizer('requires deep stack', thread=True) def test_recursive_as_param(self): class A: pass