@cadenza.io/core 3.0.13 → 3.0.15

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.js CHANGED
@@ -798,7 +798,7 @@ var GraphNode = class _GraphNode extends SignalEmitter {
798
798
  uuid: this.id,
799
799
  routineExecutionId: this.routineExecId,
800
800
  executionTraceId: (_b = context.__executionTraceId) != null ? _b : (_a = context.__metadata) == null ? void 0 : _a.__executionTraceId,
801
- context: this.context.export(),
801
+ context: this.previousNodes.length === 0 ? this.context.id : this.context.export(),
802
802
  taskName: this.task.name,
803
803
  taskVersion: this.task.version,
804
804
  isMeta: this.isMeta(),
@@ -886,6 +886,7 @@ var GraphNode = class _GraphNode extends SignalEmitter {
886
886
  isRunning: false,
887
887
  isComplete: true,
888
888
  resultContext: this.context.export(),
889
+ //TODO: this needs processing
889
890
  errored: this.errored,
890
891
  failed: this.failed,
891
892
  errorMessage: context.__error,
@@ -895,6 +896,10 @@ var GraphNode = class _GraphNode extends SignalEmitter {
895
896
  filter: { uuid: this.id }
896
897
  });
897
898
  if (this.graphDone()) {
899
+ this.emitWithMetadata(
900
+ `meta.node.graph_completed:${this.routineExecId}`,
901
+ context
902
+ );
898
903
  this.emitMetricsWithMetadata(
899
904
  `meta.node.ended_routine_execution:${this.routineExecId}`,
900
905
  {
@@ -1960,7 +1965,7 @@ var Task = class extends SignalEmitter {
1960
1965
  this.observedSignals.add(signal);
1961
1966
  this.emitWithMetadata("meta.task.observed_signal", {
1962
1967
  data: {
1963
- signalName: signal,
1968
+ signalName: signal.split(":")[0],
1964
1969
  taskName: this.name,
1965
1970
  taskVersion: this.version
1966
1971
  }
@@ -1979,7 +1984,7 @@ var Task = class extends SignalEmitter {
1979
1984
  this.emitsSignals.add(signal);
1980
1985
  this.emitWithMetadata("meta.task.attached_signal", {
1981
1986
  data: {
1982
- signalName: signal,
1987
+ signalName: signal.split(":")[0],
1983
1988
  taskName: this.name,
1984
1989
  taskVersion: this.version
1985
1990
  }
@@ -2474,7 +2479,6 @@ var GraphRunner = class extends SignalEmitter {
2474
2479
  var _a;
2475
2480
  if (context.__task || context.__routine) {
2476
2481
  const routine = (_a = context.__task) != null ? _a : context.__routine;
2477
- console.log("starting routine", routine, context);
2478
2482
  this.run(routine, context);
2479
2483
  return true;
2480
2484
  } else {