MCPcopy Index your code
hub / github.com/callstack/agent-device / parseBatchStepRuntime

Function parseBatchStepRuntime

src/batch-contract.ts:52–65  ·  view source on GitHub ↗
(
  value: unknown,
  stepNumber: number,
  makeError: BatchStepErrorFactory = batchInvalidArgsError,
)

Source from the content-addressed store, hash-verified

50}
51
52export function parseBatchStepRuntime(
53 value: unknown,
54 stepNumber: number,
55 makeError: BatchStepErrorFactory = batchInvalidArgsError,
56): SessionRuntimeHints | undefined {
57 if (value === undefined) return undefined;
58 try {
59 return daemonRuntimeSchema.parse(value);
60 } catch (error) {
61 throw makeError(
62 `Batch step ${stepNumber} runtime is invalid: ${error instanceof Error ? error.message : String(error)}`,
63 );
64 }
65}

Callers 5

readBatchDaemonStepFunction · 0.90
readStructuredBatchStepFunction · 0.90
readLegacyCliBatchStepFunction · 0.90

Calls 1

parseMethod · 0.45

Tested by

no test coverage detected