MCPcopy Index your code
hub / github.com/python/cpython / restore__testsinglephase

Function restore__testsinglephase

Lib/test/test_import/__init__.py:159–166  ·  view source on GitHub ↗
(*, _orig=_testsinglephase)

Source from the content-addressed store, hash-verified

157
158if _testsinglephase is not None:
159 def restore__testsinglephase(*, _orig=_testsinglephase):
160 # We started with the module imported and want to restore
161 # it to its nominal state.
162 sys.modules.pop('_testsinglephase', None)
163 _orig._clear_globals()
164 origin = _orig.__spec__.origin
165 _testinternalcapi.clear_extension('_testsinglephase', origin)
166 import _testsinglephase
167
168
169def requires_singlephase_init(meth):

Callers 1

methFunction · 0.85

Calls 1

popMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…