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

Function collect_support

Lib/test/pythoninfo.py:759–787  ·  view source on GitHub ↗
(info_add)

Source from the content-addressed store, hash-verified

757
758
759def collect_support(info_add):
760 try:
761 from test import support
762 except ImportError:
763 return
764
765 attributes = (
766 'MS_WINDOWS',
767 'has_fork_support',
768 'has_socket_support',
769 'has_strftime_extensions',
770 'has_subprocess_support',
771 'is_android',
772 'is_emscripten',
773 'is_jython',
774 'is_wasi',
775 'is_wasm32',
776 )
777 copy_attributes(info_add, support, 'support.%s', attributes)
778
779 call_func(info_add, 'support._is_gui_available', support, '_is_gui_available')
780 call_func(info_add, 'support.python_is_optimized', support, 'python_is_optimized')
781
782 info_add('support.check_sanitizer(address=True)',
783 support.check_sanitizer(address=True))
784 info_add('support.check_sanitizer(memory=True)',
785 support.check_sanitizer(memory=True))
786 info_add('support.check_sanitizer(ub=True)',
787 support.check_sanitizer(ub=True))
788
789
790def collect_support_os_helper(info_add):

Callers

nothing calls this directly

Calls 2

copy_attributesFunction · 0.85
call_funcFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…