MCPcopy Index your code
hub / github.com/RustPython/RustPython / get_bytes

Method get_bytes

Lib/mailbox.py:388–391  ·  view source on GitHub ↗

Return a bytes representation or raise a KeyError.

(self, key)

Source from the content-addressed store, hash-verified

386 return msg
387
388 def get_bytes(self, key):
389 """Return a bytes representation or raise a KeyError."""
390 with open(os.path.join(self._path, self._lookup(key)), 'rb') as f:
391 return f.read().replace(linesep, b'\n')
392
393 def get_file(self, key):
394 """Return a file-like representation or raise a KeyError."""

Callers

nothing calls this directly

Calls 5

_lookupMethod · 0.95
openFunction · 0.70
joinMethod · 0.45
replaceMethod · 0.45
readMethod · 0.45

Tested by

no test coverage detected