https://github.com/python/cpython/commit/3c92a06e0d08f482f1e368a41670404ef5d247da
commit: 3c92a06e0d08f482f1e368a41670404ef5d247da
branch: main
author: sobolevn <[email protected]>
committer: hugovk <[email protected]>
date: 2026-11-06T16:22:52+02:00
summary:
gh-161490: Fix leak in `test_any_str_deprecated` in `test_typing` (#161491)
files:
M Lib/test/test_typing.py
diff --git a/Lib/test/test_typing.py b/Lib/test/test_typing.py
index b1775ba7d81e521..3879c49c714dd9b 100644
--- a/Lib/test/test_typing.py
+++ b/Lib/test/test_typing.py
@@ -11300,6 +11300,7 @@ def test_all_exported_names(self):
def test_any_str_deprecated(self):
# gh-105578
fresh = import_helper.import_fresh_module('typing')
+ self.addCleanup(atexit.unregister, fresh._clear_caches)
with self.assertWarnsRegex(DeprecationWarning, r'typing\.AnyStr'):
fresh.AnyStr
_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]