Skip to content

Commit 3c19ee0

Browse files
authored
GH-111801: set a lower recursion limit for test_infintely_many_bases() in test_isinstance (#113997)
1 parent a47353d commit 3c19ee0

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

Lib/test/test_isinstance.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -344,7 +344,7 @@ class B:
344344
pass
345345
A.__getattr__ = B.__getattr__ = X.__getattr__
346346
return (A(), B())
347-
with support.infinite_recursion():
347+
with support.infinite_recursion(25):
348348
self.assertRaises(RecursionError, issubclass, X(), int)
349349

350350

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Lower the recursion limit in ``test_isinstance`` for
2+
``test_infinitely_many_bases()``. This prevents a stack overflow on a
3+
pydebug build of WASI.

0 commit comments

Comments
 (0)