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

Class Mapping

Lib/test/test_string/test_string.py:223–231  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

221 pass
222
223class Mapping:
224 def __getitem__(self, name):
225 obj = self
226 for part in name.split('.'):
227 try:
228 obj = getattr(obj, part)
229 except AttributeError:
230 raise KeyError(name)
231 return obj
232
233
234class TestTemplate(unittest.TestCase):

Callers 2

test_pattern_overrideMethod · 0.70

Calls

no outgoing calls

Tested by 2

test_pattern_overrideMethod · 0.56

Used in the wild real call sites across dependent graphs

searching dependent graphs…