@geonosis/workflows 0.2.0 → 0.3.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.
package/CHANGELOG.md ADDED
@@ -0,0 +1,43 @@
1
+ # @geonosis/workflows
2
+
3
+ ## 0.3.1
4
+
5
+ ### Patch Changes
6
+
7
+ - d15a654: **A bump names what the floors it crossed changed, and runs the tier it left behind (#268).** The
8
+ `BY HAND` block was driven by the doctor's required-option FAILs alone, so `--floors latest` across
9
+ a floor minor that changed `sessionDb`'s key printed nothing and the consumer's own tests found it.
10
+ `update` now reads each bumped floor's own `CHANGELOG.md` out of what the install unpacked, for the
11
+ versions crossed, and prints every change its author named — and says so by name when a floor ships
12
+ no changelog to read (measured: `npm pack --dry-run --json` over a floor carries `dist`,
13
+ `package.json`, `README.md` and `LICENSE`; CHANGELOG is not on npm's always-included list, so the
14
+ floors name it in `files` now). A seventh ritual step runs the tier this tree calls `fast` in
15
+ `geonosis.json` after the frozen install: a bump cannot report PASS over a tree it has just
16
+ reddened, and a repo that declares no tier is told so rather than passed over.
17
+ - Updated dependencies [d15a654]
18
+ - @geonosis/conformance@0.2.1
19
+ - @geonosis/events@1.5.2
20
+
21
+ ## 0.3.0
22
+
23
+ ### Minor Changes
24
+
25
+ - 13ca75b: **Every conformance case that can name its refusal now names it (#213).** `assertRefuses` takes the class or a phrase of the refusal, and five cases were still passing nothing: an index that refused an undeclared filter, value or ordering with any error at all passed the search exam, and a journal that refused a held idempotency key with a raw uniqueness violation passed two of the three cases about it. The search cases require `SearchRefusal` and the journal cases `IdempotencyKeyHeldError` — the classes both contracts already export for exactly this. A subject that refuses with something else now fails, naming what it threw.
26
+
27
+ ### Patch Changes
28
+
29
+ - Updated dependencies [e0da9a3]
30
+ - @geonosis/events@1.5.1
31
+
32
+ ## 0.2.0
33
+
34
+ ### Minor Changes
35
+
36
+ - 6b5b3db: **BREAKING for a durable workflow: the definition declares its execution, and each door refuses the other's (#210).** `createWorkflow` hardcoded `execution: 'inline'` and `WorkflowOptions` had no way to say otherwise, while `durable-body-reads-through-steps` read a `durable`/`execution` key off the call — a declaration a consumer could not write without an excess-property error, so the engine and its own rule disagreed about what a durable workflow looks like. `WorkflowOptions.execution` (default `'inline'`) is carried on the definition; `executeDurable` refuses a workflow declared inline and `.run()` refuses one declared durable, both by name — a body written for one request is replayed by the durable door, and that is exactly the free read the rule exists for. **REACH CHANGED:** the rule's defaults are now `durableKey: 'execution'`, `durableValue: 'durable'`, the engine's own spelling; a repo whose factory says it another way names `durableKey`/`durableValue`. A durable workflow must add `{ execution: 'durable' }`.
37
+
38
+ ### Patch Changes
39
+
40
+ - Updated dependencies [bb5e84b]
41
+ - Updated dependencies [6d14aa2]
42
+ - @geonosis/conformance@0.2.0
43
+ - @geonosis/events@1.5.0
package/dist/index.cjs CHANGED
@@ -1037,7 +1037,8 @@ var journalConformance = (createSubject) => {
1037
1037
  await openRun(journal, { idempotencyKey: "key-a" });
1038
1038
  await (0, import_conformance.assertRefuses)(
1039
1039
  () => openRun(journal, { idempotencyKey: "key-a" }),
1040
- "a key held by a running run must be refused"
1040
+ "a key held by a running run must be refused",
1041
+ IdempotencyKeyHeldError
1041
1042
  );
1042
1043
  }),
1043
1044
  // Named rather than merely thrown. Every store words a uniqueness violation differently, and an
@@ -1062,7 +1063,8 @@ var journalConformance = (createSubject) => {
1062
1063
  await closeRun(journal, runId, "completed", { done: true });
1063
1064
  await (0, import_conformance.assertRefuses)(
1064
1065
  () => openRun(journal, { idempotencyKey: "key-b" }),
1065
- "a key held by a completed run must be refused"
1066
+ "a key held by a completed run must be refused",
1067
+ IdempotencyKeyHeldError
1066
1068
  );
1067
1069
  }),
1068
1070
  ...["failed", "compensated", "cancelled"].map(
package/dist/index.js CHANGED
@@ -975,7 +975,8 @@ var journalConformance = (createSubject) => {
975
975
  await openRun(journal, { idempotencyKey: "key-a" });
976
976
  await assertRefuses(
977
977
  () => openRun(journal, { idempotencyKey: "key-a" }),
978
- "a key held by a running run must be refused"
978
+ "a key held by a running run must be refused",
979
+ IdempotencyKeyHeldError
979
980
  );
980
981
  }),
981
982
  // Named rather than merely thrown. Every store words a uniqueness violation differently, and an
@@ -1000,7 +1001,8 @@ var journalConformance = (createSubject) => {
1000
1001
  await closeRun(journal, runId, "completed", { done: true });
1001
1002
  await assertRefuses(
1002
1003
  () => openRun(journal, { idempotencyKey: "key-b" }),
1003
- "a key held by a completed run must be refused"
1004
+ "a key held by a completed run must be refused",
1005
+ IdempotencyKeyHeldError
1004
1006
  );
1005
1007
  }),
1006
1008
  ...["failed", "compensated", "cancelled"].map(
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@geonosis/workflows",
3
- "version": "0.2.0",
3
+ "version": "0.3.1",
4
4
  "types": "./dist/index.d.ts",
5
5
  "description": "A workflow engine with one door: named steps whose compensation travels with them, a body that is a real async function with real values, and a journal contract whose run lifecycle, transactional outbox and reverse-start unwinding are model-checked.",
6
6
  "keywords": [
@@ -33,11 +33,12 @@
33
33
  }
34
34
  },
35
35
  "files": [
36
+ "CHANGELOG.md",
36
37
  "dist"
37
38
  ],
38
39
  "dependencies": {
39
- "@geonosis/conformance": "^0.2.0",
40
- "@geonosis/events": "^1.5.0"
40
+ "@geonosis/conformance": "^0.2.1",
41
+ "@geonosis/events": "^1.5.2"
41
42
  },
42
43
  "engines": {
43
44
  "node": ">=22"