MCPcopy Create free account
hub / github.com/libgit2/pygit2 / _get_entry

Method _get_entry

pygit2/config.py:121–128  ·  view source on GitHub ↗
(self, key: str | bytes)

Source from the content-addressed store, hash-verified

119 return err, ConfigEntry._from_c(entry[0])
120
121 def _get_entry(self, key: str | bytes) -> 'ConfigEntry':
122 err, entry = self._get(key)
123
124 if err == C.GIT_ENOTFOUND:
125 raise KeyError(key)
126
127 check_error(err)
128 return entry
129
130 def __contains__(self, key: str | bytes) -> bool:
131 err, cstr = self._get(key)

Callers 3

__getitem__Method · 0.95
get_boolMethod · 0.95
get_intMethod · 0.95

Calls 2

_getMethod · 0.95
check_errorFunction · 0.85

Tested by

no test coverage detected