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

Function _make_relax_case

Lib/importlib/_bootstrap_external.py:60–74  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

58
59
60def _make_relax_case():
61 if sys.platform.startswith(_CASE_INSENSITIVE_PLATFORMS):
62 if sys.platform.startswith(_CASE_INSENSITIVE_PLATFORMS_STR_KEY):
63 key = 'PYTHONCASEOK'
64 else:
65 key = b'PYTHONCASEOK'
66
67 def _relax_case():
68 """True if filenames must be checked case-insensitively and ignore environment flags are not set."""
69 return not sys.flags.ignore_environment and key in _os.environ
70 else:
71 def _relax_case():
72 """True if filenames must be checked case-insensitively."""
73 return False
74 return _relax_case
75
76_relax_case = _make_relax_case()
77

Callers 1

Calls 1

startswithMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…