MCPcopy
hub / github.com/benoitc/gunicorn / get

Method get

gunicorn/dirty/stash.py:204–219  ·  view source on GitHub ↗

Retrieve a value from a table. Args: table: Table name key: Key to retrieve default: Default value if key not found Returns: The stored value, or default if not found

(self, table, key, default=None)

Source from the content-addressed store, hash-verified

202 self._execute(STASH_OP_PUT, table, key=key, value=value)
203
204 def get(self, table, key, default=None):
205 """
206 Retrieve a value from a table.
207
208 Args:
209 table: Table name
210 key: Key to retrieve
211 default: Default value if key not found
212
213 Returns:
214 The stored value, or default if not found
215 """
216 try:
217 return self._execute(STASH_OP_GET, table, key=key)
218 except StashKeyNotFoundError:
219 return default
220
221 def delete(self, table, key):
222 """

Callers

nothing calls this directly

Calls 1

_executeMethod · 0.95

Tested by

no test coverage detected