MCPcopy Create free account
hub / github.com/Zoo-Code-Org/Zoo-Code / readJsonFile

Function readJsonFile

packages/core/src/task-history/index.ts:48–55  ·  view source on GitHub ↗
(filePath: string)

Source from the content-addressed store, hash-verified

46}
47
48async function readJsonFile(filePath: string): Promise<unknown | undefined> {
49 try {
50 const raw = await fs.readFile(filePath, "utf8")
51 return JSON.parse(raw)
52 } catch {
53 return undefined
54 }
55}
56
57export async function readTaskSessionsFromStoragePath(storageBasePath: string): Promise<TaskSessionEntry[]> {
58 const tasksDir = path.join(storageBasePath, "tasks")

Callers 1

Calls 2

parseMethod · 0.80
readFileMethod · 0.45

Tested by

no test coverage detected