MCPcopy Index your code
hub / github.com/geekcomputers/Python / load_json_list

Function load_json_list

JARVIS/memory.py:6–13  ·  view source on GitHub ↗
(path)

Source from the content-addressed store, hash-verified

4
5
6def load_json_list(path):
7 if not path.exists():
8 return []
9 try:
10 data = json.loads(path.read_text(encoding="utf-8"))
11 except (OSError, json.JSONDecodeError):
12 return []
13 return data if isinstance(data, list) else []
14
15
16def load_memory():

Callers 2

load_memoryFunction · 0.85
load_application_indexFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected