MCPcopy Create free account
hub / github.com/Nativu5/Gemini-FastAPI / _dump_all

Function _dump_all

scripts/dump_lmdb.py:18–23  ·  view source on GitHub ↗

Return all records from the database.

(txn: lmdb.Transaction)

Source from the content-addressed store, hash-verified

16
17
18def _dump_all(txn: lmdb.Transaction) -> list[dict[str, Any]]:
19 """Return all records from the database."""
20 result: list[dict[str, Any]] = []
21 for key, value in txn.cursor():
22 result.append({"key": key.decode("utf-8"), "value": _decode_value(value)})
23 return result
24
25
26def _dump_selected(txn: lmdb.Transaction, keys: Iterable[str]) -> list[dict[str, Any]]:

Callers 1

dump_lmdbFunction · 0.85

Calls 1

_decode_valueFunction · 0.85

Tested by

no test coverage detected