diff options
author | Victor Stinner <vstinner@python.org> | 2020-03-13 12:07:31 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-13 12:07:31 (GMT) |
commit | 3f2f4fefca388bc62fc2a7d07cb6ef24197c84bd (patch) | |
tree | 7f4c00316acc193d3a00daf660af48dd67f6ad48 /Lib | |
parent | 224481a8c988fca12f488544edd2f01c0af2a91d (diff) | |
download | cpython-3f2f4fefca388bc62fc2a7d07cb6ef24197c84bd.zip cpython-3f2f4fefca388bc62fc2a7d07cb6ef24197c84bd.tar.gz cpython-3f2f4fefca388bc62fc2a7d07cb6ef24197c84bd.tar.bz2 |
bpo-39947: Move get_recursion_depth() to _testinternalcapi (GH-18974)
Move get_recursion_depth() function from _testcapi to
_testinternalcapi to avoid accessing PyThreadState attributes
directly in _testcapi.
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_exceptions.py | 2 | ||||
-rw-r--r-- | Lib/test/test_sys.py | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/Lib/test/test_exceptions.py b/Lib/test/test_exceptions.py index 2d3a13a..d6739f1 100644 --- a/Lib/test/test_exceptions.py +++ b/Lib/test/test_exceptions.py @@ -994,7 +994,7 @@ class ExceptionTests(unittest.TestCase): # finalization of these locals. code = """if 1: import sys - from _testcapi import get_recursion_depth + from _testinternalcapi import get_recursion_depth class MyException(Exception): pass diff --git a/Lib/test/test_sys.py b/Lib/test/test_sys.py index 027f87e..3957258 100644 --- a/Lib/test/test_sys.py +++ b/Lib/test/test_sys.py @@ -241,7 +241,7 @@ class SysModuleTest(unittest.TestCase): # mark". Otherwise, it may not be possible anymore to # reset the overflowed flag to 0. - from _testcapi import get_recursion_depth + from _testinternalcapi import get_recursion_depth def set_recursion_limit_at_depth(depth, limit): recursion_depth = get_recursion_depth() |