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

Function main

Android/android.py:1012–1048  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1010
1011
1012def main():
1013 install_signal_handler()
1014
1015 # Under the buildbot, stdout is not a TTY, but we must still flush after
1016 # every line to make sure our output appears in the correct order relative
1017 # to the output of our subprocesses.
1018 for stream in [sys.stdout, sys.stderr]:
1019 stream.reconfigure(line_buffering=True)
1020
1021 context = parse_args()
1022
1023 # Set the CROSS_BUILD_DIR if an argument was provided
1024 if context.cross_build_dir:
1025 global CROSS_BUILD_DIR
1026 CROSS_BUILD_DIR = context.cross_build_dir.resolve()
1027
1028 dispatch = {
1029 "configure-build": configure_build_python,
1030 "make-build": make_build_python,
1031 "configure-host": configure_host_python,
1032 "make-host": make_host_python,
1033 "build": build_targets,
1034 "clean": clean_targets,
1035 "build-testbed": build_testbed,
1036 "test": run_testbed,
1037 "package": package,
1038 "ci": ci,
1039 "env": env,
1040 }
1041
1042 try:
1043 result = dispatch[context.subcommand](context)
1044 if asyncio.iscoroutine(result):
1045 asyncio.run(result)
1046 except CalledProcessError as e:
1047 print_called_process_error(e)
1048 sys.exit(1)
1049
1050
1051def print_called_process_error(e):

Callers 1

android.pyFile · 0.70

Calls 7

install_signal_handlerFunction · 0.85
parse_argsFunction · 0.70
reconfigureMethod · 0.45
resolveMethod · 0.45
runMethod · 0.45
exitMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…