Skip to content

Commit ae8b776

Browse files
committed
fix global counter test again
1 parent aaf0b25 commit ae8b776

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

tests/isolated/multidict_global_counter.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@
44
import sysconfig
55

66
FREETHREADED = bool(sysconfig.get_config_var("Py_GIL_DISABLED"))
7-
if not FREETHREADED:
8-
raise SystemExit(0)
7+
98

109
md: MultiDict[int] = MultiDict()
1110
N, M = 3, 100
@@ -17,7 +16,7 @@ def worker(tid: int) -> None:
1716
md[f"k{tid}_{i}"] = i
1817

1918

20-
if __name__ == "__main__":
19+
if (__name__ == "__main__") and FREETHREADED:
2120
threads = [threading.Thread(target=worker, args=(tid,)) for tid in range(N)]
2221
for t in threads:
2322
t.start()

0 commit comments

Comments
 (0)