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

Method create_python_cmd

Lib/test/libregrtest/runtests.py:148–163  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

146 )
147
148 def create_python_cmd(self) -> list[str]:
149 python_opts = support.args_from_interpreter_flags()
150 if self.python_cmd is not None:
151 executable = self.python_cmd
152 # Remove -E option, since --python=COMMAND can set PYTHON
153 # environment variables, such as PYTHONPATH, in the worker
154 # process.
155 python_opts = [opt for opt in python_opts if opt != "-E"]
156 else:
157 executable = (sys.executable,)
158 cmd = [*executable, *python_opts]
159 if '-u' not in python_opts:
160 cmd.append('-u') # Unbuffered stdout and stderr
161 if self.coverage:
162 cmd.append("-Xpresite=test.cov")
163 return cmd
164
165 def bisect_cmd_args(self) -> list[str]:
166 args = []

Callers 2

_run_bisectMethod · 0.80
create_worker_processFunction · 0.80

Calls 1

appendMethod · 0.45

Tested by

no test coverage detected