@inerrata-corporation/errata 2.0.23-dev.4821 → 2.0.23-dev.4826

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.
@@ -20616,7 +20616,8 @@ function generalize(text, opts = {}) {
20616
20616
  init_src();
20617
20617
 
20618
20618
  // src/instance-receipts.ts
20619
- var INSTANCE_SEMANTIC_EDGE_TYPES = ["CAUSED_BY", "SOLVED_BY"];
20619
+ var INSTANCE_SEMANTIC_EDGE_TYPES = ["CAUSED_BY", "SOLVED_BY", "SUPERSEDES", "BUILDS_ON", "ALTERNATIVE_TO"];
20620
+ var INSTANCE_STRUCTURE_EDGE_TYPES = /* @__PURE__ */ new Set(["SUPERSEDES", "BUILDS_ON", "ALTERNATIVE_TO"]);
20620
20621
  var INSTANCE_ANCHOR_EDGE_TYPES = ["OCCURS_IN", "DEPENDS_ON", "PERTAIN_TO", "CONCERNS"];
20621
20622
  function instanceCloudWithdrawal(n, destination, getMeta) {
20622
20623
  const id = n.attrs["source"] === "cloud" ? n.attrs["cloudNodeId"] ?? n.id : instanceReceipt(n, destination)["cloudNodeId"];
@@ -22041,6 +22042,11 @@ function buildInstanceIngest(store, profile, daemonVersion, ignorePatterns = [],
22041
22042
  }
22042
22043
  const edges = [];
22043
22044
  const semanticEdgeDigests = {};
22045
+ const pulledStructureTarget = (e) => {
22046
+ if (!INSTANCE_STRUCTURE_EDGE_TYPES.has(e.type)) return void 0;
22047
+ const target = store.getNode(e.to) ?? opts.sharedStore?.getNode(e.to);
22048
+ return target?.label === "Solution" && target.attrs["source"] === "cloud" ? e.to : void 0;
22049
+ };
22044
22050
  for (const [sourceId, wireFrom] of semanticEndpoints) {
22045
22051
  const rawOuts = [
22046
22052
  ...store.outEdges(sourceId, [...INSTANCE_EDGES]),
@@ -22048,7 +22054,7 @@ function buildInstanceIngest(store, profile, daemonVersion, ignorePatterns = [],
22048
22054
  ];
22049
22055
  const dedup = /* @__PURE__ */ new Map();
22050
22056
  for (const e of rawOuts) dedup.set(`${e.type}>${e.to}`, e);
22051
- const outs = [...dedup.values()].map((e) => ({ e, wireTo: semanticEndpoints.get(e.to) })).filter((x) => {
22057
+ const outs = [...dedup.values()].map((e) => ({ e, wireTo: semanticEndpoints.get(e.to) ?? pulledStructureTarget(e) })).filter((x) => {
22052
22058
  if (x.wireTo === wireFrom) {
22053
22059
  composition.collapsedEdges++;
22054
22060
  return false;