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

Method __setitem__

Lib/mailbox.py:678–682  ·  view source on GitHub ↗

Replace the keyed message; raise KeyError if it doesn't exist.

(self, key, message)

Source from the content-addressed store, hash-verified

676 self._pending = True
677
678 def __setitem__(self, key, message):
679 """Replace the keyed message; raise KeyError if it doesn't exist."""
680 self._lookup(key)
681 self._toc[key] = self._append_message(message)
682 self._pending = True
683
684 def iterkeys(self):
685 """Return an iterator over keys."""

Callers

nothing calls this directly

Calls 2

_lookupMethod · 0.95
_append_messageMethod · 0.95

Tested by

no test coverage detected