sysprom 1.25.0 → 1.25.1

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.
@@ -118,12 +118,18 @@ export const validateOp = defineOperation({
118
118
  issues.push(`${n.id} (${n.name}): affects domain nodes but has no must_preserve relationship`);
119
119
  }
120
120
  }
121
- // INV13: Decisions must have options and selected
121
+ // INV13: Decisions must have options and selected (if decided)
122
122
  for (const n of input.doc.nodes.filter((n) => n.type === "decision")) {
123
123
  if (!n.options || n.options.length === 0) {
124
124
  issues.push(`${n.id} (${n.name}): decision has no options`);
125
125
  }
126
- if (!n.selected) {
126
+ // Only require selected option if the decision is in a "decided" state
127
+ // Decided states: accepted, implemented, adopted
128
+ // Undecided states allowed: proposed, experimental, deferred
129
+ const isDecided = hasLifecycleState(n, "accepted") ||
130
+ hasLifecycleState(n, "implemented") ||
131
+ hasLifecycleState(n, "adopted");
132
+ if (isDecided && !n.selected) {
127
133
  issues.push(`${n.id} (${n.name}): decision has no selected option`);
128
134
  }
129
135
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sysprom",
3
- "version": "1.25.0",
3
+ "version": "1.25.1",
4
4
  "description": "SysProM — System Provenance Model CLI and library",
5
5
  "author": "ExaDev",
6
6
  "homepage": "https://exadev.github.io/SysProM",