This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: test_unittest: TestAsyncCase.test_debug_cleanup_same_loop() hangs with gc.set_threshold(500)
Type: Stage: resolved
Components: asyncio, Tests Versions: Python 3.11
process
Status: closed Resolution: out of date
Dependencies: Superseder:
Assigned To: asvetlov Nosy List: asvetlov, vstinner, yselivanov
Priority: normal Keywords:

Created on 2022-01-21 15:21 by vstinner, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Messages (2)
msg411136 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2022-01-21 15:21
The following command hangs:

./python -u -m test -v test_unittest -m test_debug_cleanup_same_loop -v 2>/dev/null

if the following patch is applied on Python:

diff --git a/Lib/unittest/test/test_async_case.py b/Lib/unittest/test/test_async_case.py
index 3717486b265..c6759a13494 100644
--- a/Lib/unittest/test/test_async_case.py
+++ b/Lib/unittest/test/test_async_case.py
@@ -2,6 +2,7 @@
 import unittest
 from test import support
 
+import gc; gc.set_threshold(500)
 
 class MyException(Exception):
     pass
msg415298 - (view) Author: Andrew Svetlov (asvetlov) * (Python committer) Date: 2022-03-15 20:58
#46994 fixed this problem
History
Date User Action Args
2022-04-11 14:59:55adminsetgithub: 90615
2022-03-15 20:58:47asvetlovsetstatus: open -> closed
resolution: out of date
messages: + msg415298

stage: resolved
2022-01-23 21:19:08asvetlovsetassignee: asvetlov
2022-01-21 15:21:28vstinnercreate