MCPcopy Create free account
hub / github.com/ShipSecAI/studio / handleSkip

Function handleSkip

worker/src/temporal/workflow-scheduler.ts:339–372  ·  view source on GitHub ↗
(
  ref: string,
  readyQueue: ReadyItem[],
  pending: Set<string>,
  nodeStates: Map<string, NodeState>,
  successEdges: Map<string, WorkflowEdge[]>,
  onNodeSkipped?: (ref: string) => Promise<void>,
)

Source from the content-addressed store, hash-verified

337}
338
339async function handleSkip(
340 ref: string,
341 readyQueue: ReadyItem[],
342 pending: Set<string>,
343 nodeStates: Map<string, NodeState>,
344 successEdges: Map<string, WorkflowEdge[]>,
345 onNodeSkipped?: (ref: string) => Promise<void>,
346) {
347 if (!pending.has(ref)) return;
348
349 pending.delete(ref);
350 const state = nodeStates.get(ref);
351 if (state) state.skipped = true;
352
353 if (onNodeSkipped) {
354 await onNodeSkipped(ref);
355 }
356
357 const edges = successEdges.get(ref) ?? [];
358 const children = new Set(edges.map((e) => e.targetRef));
359
360 for (const child of children) {
361 await processChild(
362 child,
363 ref,
364 'skipped',
365 readyQueue,
366 pending,
367 nodeStates,
368 successEdges,
369 onNodeSkipped,
370 );
371 }
372}
373
374async function handleFailure(
375 ref: string,

Callers 1

processChildFunction · 0.85

Calls 4

processChildFunction · 0.85
hasMethod · 0.80
getMethod · 0.65
deleteMethod · 0.45

Tested by

no test coverage detected