Skip to content

Commit bc28bd7

Browse files
committed
add comments on newly-added test
1 parent 2681cfa commit bc28bd7

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Lib/test/test_weakref.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2254,7 +2254,9 @@ def test_names(self):
22542254
self.assertEqual(obj.__qualname__, name)
22552255

22562256
@threading_helper.requires_working_threading()
2257+
@unittest.skipUnless(support.Py_GIL_DISABLED, 'only used under free-threaded build')
22572258
def test_module_weakref(self):
2259+
# gh-135607: Avoid potential races on module weaklist under free-threaded build
22582260
mod = types.ModuleType("temp_mod")
22592261
common_ref = weakref.ref(mod)
22602262
threads = []

0 commit comments

Comments
 (0)