@cadenza.io/core 3.0.19 → 3.0.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -651,7 +651,7 @@ declare class GraphRunner extends SignalEmitter {
651
651
  setVerbose(value: boolean): void;
652
652
  destroy(): void;
653
653
  setStrategy(strategy: GraphRunStrategy): void;
654
- startRun(context: AnyObject): boolean;
654
+ startRun(context: AnyObject, emit: (signal: string, ctx: AnyObject) => void): boolean;
655
655
  }
656
656
 
657
657
  declare class SignalBroker {
package/dist/index.d.ts CHANGED
@@ -651,7 +651,7 @@ declare class GraphRunner extends SignalEmitter {
651
651
  setVerbose(value: boolean): void;
652
652
  destroy(): void;
653
653
  setStrategy(strategy: GraphRunStrategy): void;
654
- startRun(context: AnyObject): boolean;
654
+ startRun(context: AnyObject, emit: (signal: string, ctx: AnyObject) => void): boolean;
655
655
  }
656
656
 
657
657
  declare class SignalBroker {
package/dist/index.js CHANGED
@@ -2211,6 +2211,7 @@ var GraphRegistry = class _GraphRegistry {
2211
2211
  const { __name } = context;
2212
2212
  for (const task of this.tasks.values()) {
2213
2213
  if (task.name === __name) {
2214
+ console.log("TASK FOUND", task.name);
2214
2215
  return { ...context, __task: task };
2215
2216
  }
2216
2217
  }
@@ -2475,8 +2476,9 @@ var GraphRunner = class extends SignalEmitter {
2475
2476
  this.currentRun = new GraphRun(this.strategy);
2476
2477
  }
2477
2478
  }
2478
- startRun(context) {
2479
+ startRun(context, emit) {
2479
2480
  var _a, _b, _c;
2481
+ console.log("START RUN", context);
2480
2482
  if (context.__task || context.__routine) {
2481
2483
  const routine = (_a = context.__task) != null ? _a : context.__routine;
2482
2484
  delete context.__task;
@@ -2488,6 +2490,7 @@ var GraphRunner = class extends SignalEmitter {
2488
2490
  } else {
2489
2491
  context.errored = true;
2490
2492
  context.__error = "No routine or task defined.";
2493
+ emit("meta.runner.failed", context);
2491
2494
  return false;
2492
2495
  }
2493
2496
  }