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

Method _normalized_name

Lib/importlib/metadata/__init__.py:1038–1047  ·  view source on GitHub ↗

Performance optimization: where possible, resolve the normalized name from the file system path.

(self)

Source from the content-addressed store, hash-verified

1036
1037 @property
1038 def _normalized_name(self):
1039 """
1040 Performance optimization: where possible, resolve the
1041 normalized name from the file system path.
1042 """
1043 stem = os.path.basename(str(self._path))
1044 return (
1045 pass_none(Prepared.normalize)(self._name_from_stem(stem))
1046 or super()._normalized_name
1047 )
1048
1049 @staticmethod
1050 def _name_from_stem(stem):

Callers

nothing calls this directly

Calls 5

_name_from_stemMethod · 0.95
strFunction · 0.85
pass_noneFunction · 0.85
superClass · 0.85
basenameMethod · 0.45

Tested by

no test coverage detected