MCPcopy
hub / github.com/coder/mux / parse

Method parse

src/node/services/bashMonitorWakeStore.ts:353–366  ·  view source on GitHub ↗
(raw: string)

Source from the content-addressed store, hash-verified

351 }
352
353 private parse(raw: string): BashMonitorWakeRecord | null {
354 let json: unknown;
355 try {
356 json = JSON.parse(raw);
357 } catch {
358 return null;
359 }
360 const parsed = BashMonitorWakeRecordSchema.safeParse(json);
361 if (!parsed.success) {
362 log.debug("Skipping malformed bash monitor wake", { error: parsed.error });
363 return null;
364 }
365 return parsed.data;
366 }
367}

Callers 15

getMethod · 0.95
listPendingMethod · 0.95
readHistoryFromOffsetMethod · 0.45
readMessagesFromFileMethod · 0.45
iterateForwardMethod · 0.45
iterateBackwardMethod · 0.45

Calls 1

debugMethod · 0.80

Tested by 9

executeFunction · 0.36
readStoreFileFunction · 0.36
parseSentBodyFunction · 0.36
readJsonlFileFunction · 0.36
runFunction · 0.36
getJsonBodyFunction · 0.36
countStaleStepUpdatesFunction · 0.36