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

Method from_subinterp

Lib/test/test_import/__init__.py:310–319  ·  view source on GitHub ↗
(cls, name, interpid=None, *, pipe=None, **script_kwds)

Source from the content-addressed store, hash-verified

308
309 @classmethod
310 def from_subinterp(cls, name, interpid=None, *, pipe=None, **script_kwds):
311 if pipe is not None:
312 return cls._from_subinterp(name, interpid, pipe, script_kwds)
313 pipe = os.pipe()
314 try:
315 return cls._from_subinterp(name, interpid, pipe, script_kwds)
316 finally:
317 r, w = pipe
318 os.close(r)
319 os.close(w)
320
321 @classmethod
322 def _from_subinterp(cls, name, interpid, pipe, script_kwargs):

Callers 1

import_in_subinterpMethod · 0.80

Calls 3

_from_subinterpMethod · 0.80
pipeMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected