@boboddy/sdk 0.5.0 → 0.5.2

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.
@@ -338,16 +338,16 @@ async function loadPushDefaults(opts) {
338
338
  return { baseUrl, projectId, accessToken };
339
339
  }
340
340
  export {
341
- setTelemetryDisabled,
342
- saveAuthProfile,
343
- resolveBoboddyBaseUrl,
344
- loadPushDefaults,
345
- loadProjectConfig,
346
- loadAuthProfile,
347
- loadAuthFile,
348
- isTelemetryDisabled,
349
- getOrCreateAnonymousId,
350
- getAuthFilePath,
341
+ PROJECT_CONFIG_RELATIVE_PATH,
351
342
  deleteAuthProfile,
352
- PROJECT_CONFIG_RELATIVE_PATH
343
+ getAuthFilePath,
344
+ getOrCreateAnonymousId,
345
+ isTelemetryDisabled,
346
+ loadAuthFile,
347
+ loadAuthProfile,
348
+ loadProjectConfig,
349
+ loadPushDefaults,
350
+ resolveBoboddyBaseUrl,
351
+ saveAuthProfile,
352
+ setTelemetryDisabled
353
353
  };
@@ -488,16 +488,16 @@ function makeAdvanceAllCtx() {
488
488
  };
489
489
  }
490
490
  export {
491
- serializeCondition,
492
- serializeCohortAdvancementPolicy,
493
- serializeAdvancementPolicy,
494
- makeAdvanceEachCtx,
495
- makeAdvanceCtx,
496
- makeAdvanceAllCtx,
497
- extractInlineStepSignalsListDefinitions,
498
- extractInlineComputedSignals,
499
- cohortAdvancementEventTypeValues,
500
- branchOutcomeValues,
491
+ Computed,
501
492
  Rule,
502
- Computed
493
+ branchOutcomeValues,
494
+ cohortAdvancementEventTypeValues,
495
+ extractInlineComputedSignals,
496
+ extractInlineStepSignalsListDefinitions,
497
+ makeAdvanceAllCtx,
498
+ makeAdvanceCtx,
499
+ makeAdvanceEachCtx,
500
+ serializeAdvancementPolicy,
501
+ serializeCohortAdvancementPolicy,
502
+ serializeCondition
503
503
  };
@@ -18,3 +18,32 @@ export declare function tryComputeTopoRanks(nodeDefinitions: readonly Pick<NodeD
18
18
  * `tryComputeTopoRanks` does.
19
19
  */
20
20
  export declare function tryOrderNodeDefinitionsByTopoRank(nodeDefinitions: readonly NodeDefinitionSpec[], dependencyEdges: readonly DependencyEdgeSpec[]): NodeDefinitionSpec[] | null;
21
+ /**
22
+ * For every node reachable from `entryNodeKey`, the set of nodes that
23
+ * *dominate* it — every node that appears on *every* path from the entry to
24
+ * it, including the node itself (`dom(n)` always contains `n`). Standard
25
+ * iterative dataflow (Cooper/Harvey/Kennedy-style):
26
+ * `dom(entry) = {entry}`; `dom(n) = {n} ∪ ⋂ dom(p)` for each predecessor `p`
27
+ * of `n`, iterated to a fixed point.
28
+ *
29
+ * Unlike `tryComputeTopoRanks` above — which deliberately treats *every*
30
+ * in-degree-zero node as its own rank-0 root, so a graph with several
31
+ * disconnected entry points still ranks (see lines 51-56) — a dominator
32
+ * relation is only meaningful relative to a single root: "runs on every
33
+ * path from the entry" has no answer if there could be more than one
34
+ * entry. Callers must supply that root explicitly as `entryNodeKey`
35
+ * (`PipelineDefinitionSpec.entryNodeKey`, the node `config.startAt` names)
36
+ * rather than have it inferred from in-degree.
37
+ *
38
+ * Returns `null` (does not throw), same as `tryComputeTopoRanks`, when
39
+ * `entryNodeKey` does not name a node in `nodeDefinitions`, when
40
+ * `dependencyEdges` references a node key outside `nodeDefinitions`, or
41
+ * when the graph contains a cycle — every caller here is a diagnostic
42
+ * tool, not a build-time assertion (see `tryComputeTopoRanks`'s own doc
43
+ * comment), so it degrades gracefully rather than crashing validation.
44
+ *
45
+ * Nodes unreachable from `entryNodeKey` are simply absent from the
46
+ * returned map — an unreachable node can never appear on a path from the
47
+ * entry, so it neither dominates nor is dominated by anything reachable.
48
+ */
49
+ export declare function tryComputeDominators(nodeDefinitions: readonly Pick<NodeDefinitionSpec, "nodeKey">[], dependencyEdges: readonly DependencyEdgeSpec[], entryNodeKey: string): Map<string, ReadonlySet<string>> | null;
@@ -17,11 +17,3 @@ export declare function compileFanOutState(stateKey: string, state: FanOutState,
17
17
  export declare function compileParallelState(stateKey: string, state: ParallelState, ctx: CompileContext): CompiledState;
18
18
  export declare function compileLoopState(stateKey: string, state: LoopState, ctx: CompileContext): CompiledState;
19
19
  export declare function compileTerminalState(stateKey: string, kind: "succeed" | "fail"): CompiledState;
20
- /**
21
- * The SDK-side mirror of §6's domain invariant: a node may have more than
22
- * one incoming edge only when every source is a `choice`/`loop` state
23
- * (never an unconditional `step`/`fanOut`/`parallel`/`cohortGate`
24
- * successor) — gives authors a fast local error instead of a round-trip to
25
- * the server.
26
- */
27
- export declare function assertNoIllegalConvergentEdges(pipelineKey: string, nodeKindByKey: ReadonlyMap<string, NodeDefinitionSpec["kind"]>, edges: readonly DependencyEdgeSpec[]): void;
@@ -117,6 +117,8 @@ export type PipelineDefinitionSpec = {
117
117
  version: number;
118
118
  status: "draft" | "active" | "archived";
119
119
  inputSchemaJson?: Record<string, unknown> | null;
120
+ /** The node the pipeline begins execution at — mirrors `config.startAt`. */
121
+ entryNodeKey: string;
120
122
  nodeDefinitions: NodeDefinitionSpec[];
121
123
  dependencyEdges: DependencyEdgeSpec[];
122
124
  /** Step specs referenced by this pipeline. Used by the push command to auto-push steps that aren't explicitly exported. */