@fluidgrids/workflows 2026.1028.1 → 2026.1029.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.
Files changed (122) hide show
  1. package/README.md +72 -10
  2. package/dist/{activation-DnhG7SmF.d.ts → activation-BnVQMv9y.d.ts} +1 -1
  3. package/dist/{activation-BBh1p82z.d.cts → activation-CESehfYi.d.cts} +1 -1
  4. package/dist/{chunk-XB53G2DK.js → chunk-25BKWR2O.js} +1 -1
  5. package/dist/{chunk-CBL5JSCC.cjs → chunk-2B37XAFQ.cjs} +44 -8
  6. package/dist/{chunk-DJYMDLV5.js → chunk-2DDULZFM.js} +93 -1
  7. package/dist/{chunk-623FVQSN.cjs → chunk-3FIDHONL.cjs} +104 -0
  8. package/dist/chunk-6QPOJZT6.cjs +1180 -0
  9. package/dist/chunk-7ILGCUI6.js +154 -0
  10. package/dist/chunk-A2OHX3UQ.js +1156 -0
  11. package/dist/{chunk-VOKMAAJP.js → chunk-A36CCOWS.js} +188 -19
  12. package/dist/{chunk-FMSW2HDF.cjs → chunk-ELL2RBML.cjs} +0 -14
  13. package/dist/{chunk-JD2VQIDZ.cjs → chunk-EWYADREB.cjs} +2 -2
  14. package/dist/{chunk-5HDSBTBX.js → chunk-FQSJI5NV.js} +1 -1
  15. package/dist/{chunk-ABFZWYHT.js → chunk-FWBRQWRX.js} +156 -48
  16. package/dist/{chunk-PZCVF76Q.cjs → chunk-I47EENR4.cjs} +209 -40
  17. package/dist/chunk-J3PYFGKA.cjs +166 -0
  18. package/dist/{chunk-C5OLWZ42.js → chunk-KXJDRQ6G.js} +1 -13
  19. package/dist/chunk-M272AHEX.js +25 -0
  20. package/dist/{chunk-3FOTFQ3J.js → chunk-MJ5TGYVG.js} +333 -65
  21. package/dist/{chunk-57MSZ24T.cjs → chunk-NXFBVDOI.cjs} +3 -3
  22. package/dist/{chunk-PDHLTDZB.js → chunk-OIX4O6UR.js} +38 -2
  23. package/dist/{chunk-HR3BN4C4.cjs → chunk-OKX3FYIM.cjs} +3 -3
  24. package/dist/{chunk-CSNWNFKU.cjs → chunk-OMY3CKUZ.cjs} +404 -136
  25. package/dist/chunk-PWIUEWC3.js +81 -0
  26. package/dist/chunk-Q4MWQNJK.cjs +28 -0
  27. package/dist/{chunk-P6TA5EZT.cjs → chunk-RUQIMTN5.cjs} +171 -57
  28. package/dist/{chunk-IISBRUWJ.js → chunk-WXXNCHUY.js} +1 -1
  29. package/dist/chunk-YHBVMOMK.cjs +87 -0
  30. package/dist/codegen/index.d.cts +2 -2
  31. package/dist/codegen/index.d.ts +2 -2
  32. package/dist/collect-BTHjQaSp.d.ts +86 -0
  33. package/dist/collect-CSyOg5XC.d.cts +86 -0
  34. package/dist/{file-yuPCFU5b.d.ts → file-cgL9l9l8.d.cts} +765 -14
  35. package/dist/{file-BOoHZgoQ.d.cts → file-olQudcx5.d.ts} +765 -14
  36. package/dist/history/index.cjs +198 -86
  37. package/dist/history/index.d.cts +49 -10
  38. package/dist/history/index.d.ts +49 -10
  39. package/dist/history/index.js +49 -4
  40. package/dist/index.cjs +64 -51
  41. package/dist/index.d.cts +9 -53
  42. package/dist/index.d.ts +9 -53
  43. package/dist/index.js +5 -4
  44. package/dist/ir/index.cjs +24 -3
  45. package/dist/ir/index.d.cts +43 -4
  46. package/dist/ir/index.d.ts +43 -4
  47. package/dist/ir/index.js +24 -3
  48. package/dist/{lower-BuSvAFqi.d.cts → lower-3S6PsqjJ.d.cts} +41 -7
  49. package/dist/{lower-C_Qv_34S.d.ts → lower-DmZpQ8hJ.d.ts} +41 -7
  50. package/dist/lower-types-DQNBfWQn.d.cts +37 -0
  51. package/dist/lower-types-DQNBfWQn.d.ts +37 -0
  52. package/dist/{manifest-C8N6HDYl.d.ts → manifest-BJjrQt77.d.ts} +1 -1
  53. package/dist/{manifest-0OLw0i7k.d.cts → manifest-gRI2Q5Fj.d.cts} +1 -1
  54. package/dist/node-evaluator-SOADN23V.js +14 -0
  55. package/dist/node-evaluator-YGDEXK4U.cjs +24 -0
  56. package/dist/quickjs/index.cjs +25 -24
  57. package/dist/quickjs/index.d.cts +7 -7
  58. package/dist/quickjs/index.d.ts +7 -7
  59. package/dist/quickjs/index.js +8 -7
  60. package/dist/roundtrip/index.cjs +245 -43
  61. package/dist/roundtrip/index.d.cts +88 -11
  62. package/dist/roundtrip/index.d.ts +88 -11
  63. package/dist/roundtrip/index.js +172 -8
  64. package/dist/runtime/index.cjs +21 -20
  65. package/dist/runtime/index.d.cts +49 -7
  66. package/dist/runtime/index.d.ts +49 -7
  67. package/dist/runtime/index.js +8 -7
  68. package/dist/testing/index.cjs +514 -74
  69. package/dist/testing/index.d.cts +128 -11
  70. package/dist/testing/index.d.ts +128 -11
  71. package/dist/testing/index.js +480 -42
  72. package/dist/{types-BGoPzgcl.d.ts → types-Bb2wRnJ5.d.cts} +20 -1
  73. package/dist/{types-BGoPzgcl.d.cts → types-Bb2wRnJ5.d.ts} +20 -1
  74. package/dist/{types-DV-HX_Gt.d.ts → types-CQKOhPTa.d.cts} +122 -14
  75. package/dist/{types-CpBBjaGX.d.cts → types-CnIOinoz.d.ts} +122 -14
  76. package/dist/{workflow-Bpr3vnA_.d.ts → workflow-8uRU9rhL.d.ts} +2 -2
  77. package/dist/{workflow-FXUkpIBc.d.cts → workflow-CZOXUlQ5.d.cts} +2 -2
  78. package/dist/{workflow-J-yYixny.d.cts → workflow-DWTPHFbt.d.ts} +124 -12
  79. package/dist/{workflow-C2a05WUJ.d.ts → workflow-O6e64ZcG.d.cts} +124 -12
  80. package/fixtures/histories/auto-upgrade-patched.history.json +276 -0
  81. package/fixtures/histories/benign-failure.history.json +146 -0
  82. package/fixtures/histories/cancel-activity-try-cancel.history.json +150 -0
  83. package/fixtures/histories/child-cancel-wait-requested.history.json +217 -0
  84. package/fixtures/histories/child-options-roundtrip.history.json +192 -0
  85. package/fixtures/histories/continue-as-new-last-result.history.json +86 -0
  86. package/fixtures/histories/continue-as-new-options.history.json +99 -0
  87. package/fixtures/histories/continue-as-new-r1-long-task-queue.history.json +78 -0
  88. package/fixtures/histories/continue-as-new-r1-retry-options.history.json +83 -0
  89. package/fixtures/histories/execution-timeout-chain.history.json +98 -0
  90. package/fixtures/histories/external-cancel-resolved.history.json +123 -0
  91. package/fixtures/histories/external-cancel-unknown-target.history.json +127 -0
  92. package/fixtures/histories/failure-error-types-fails-run.history.json +144 -0
  93. package/fixtures/histories/handler-drain-warn.history.json +222 -0
  94. package/fixtures/histories/heartbeat-details-on-retry.history.json +145 -0
  95. package/fixtures/histories/local-activity-abandoned-at-completion.history.json +73 -0
  96. package/fixtures/histories/local-activity-cancelled-in-scope.history.json +118 -0
  97. package/fixtures/histories/local-activity-completed.history.json +157 -0
  98. package/fixtures/histories/local-activity-failed.history.json +93 -0
  99. package/fixtures/histories/local-activity-retry-in-task.history.json +88 -0
  100. package/fixtures/histories/run-retry-last-failure.history.json +90 -0
  101. package/fixtures/histories/run-timeout.history.json +159 -0
  102. package/fixtures/histories/schedule-to-start-timeout.history.json +132 -0
  103. package/fixtures/histories/start-delay-signal-ends-delay.history.json +155 -0
  104. package/fixtures/histories/typeerror-task-retry-100.history.json +137 -0
  105. package/package.json +1 -1
  106. package/schema/history-file.schema.json +283 -2
  107. package/schema/ir-v2.schema.json +45 -0
  108. package/schema/run-event.schema.json +264 -2
  109. package/schema/workflow-command.schema.json +178 -1
  110. package/schema/workflow-task.schema.json +392 -4
  111. package/dist/assemble-BLqQ8lSu.d.cts +0 -39
  112. package/dist/assemble-DWgaXHd-.d.ts +0 -39
  113. package/dist/chunk-2DP2Y6EU.cjs +0 -832
  114. package/dist/chunk-2J6TF7YI.cjs +0 -86
  115. package/dist/chunk-7NQ37GZU.js +0 -73
  116. package/dist/chunk-BO6OVILK.js +0 -79
  117. package/dist/chunk-FQIHX7YI.cjs +0 -80
  118. package/dist/chunk-H7KEVW2M.js +0 -816
  119. package/dist/lower-types-nofRXw9c.d.cts +0 -15
  120. package/dist/lower-types-nofRXw9c.d.ts +0 -15
  121. package/dist/node-evaluator-CJNP4GHX.js +0 -12
  122. package/dist/node-evaluator-DMKPKUWA.cjs +0 -22
@@ -1,9 +1,9 @@
1
1
  'use strict';
2
2
 
3
- var chunk2DP2Y6EU_cjs = require('../chunk-2DP2Y6EU.cjs');
4
- require('../chunk-CBL5JSCC.cjs');
5
- var chunkJD2VQIDZ_cjs = require('../chunk-JD2VQIDZ.cjs');
6
- require('../chunk-57MSZ24T.cjs');
3
+ var chunk6QPOJZT6_cjs = require('../chunk-6QPOJZT6.cjs');
4
+ require('../chunk-2B37XAFQ.cjs');
5
+ var chunkEWYADREB_cjs = require('../chunk-EWYADREB.cjs');
6
+ require('../chunk-NXFBVDOI.cjs');
7
7
  var chunkGBQ33SIZ_cjs = require('../chunk-GBQ33SIZ.cjs');
8
8
  require('../chunk-G4UEPUGO.cjs');
9
9
  require('../chunk-GVTZMA5C.cjs');
@@ -11,9 +11,10 @@ require('../chunk-QKZL3ONM.cjs');
11
11
  require('../chunk-TBDXTV22.cjs');
12
12
  var chunkSAENRNBJ_cjs = require('../chunk-SAENRNBJ.cjs');
13
13
  require('../chunk-L24YIZY7.cjs');
14
- require('../chunk-FQIHX7YI.cjs');
15
- require('../chunk-623FVQSN.cjs');
16
- require('../chunk-2J6TF7YI.cjs');
14
+ require('../chunk-J3PYFGKA.cjs');
15
+ require('../chunk-FR7KYWRO.cjs');
16
+ require('../chunk-3FIDHONL.cjs');
17
+ require('../chunk-YHBVMOMK.cjs');
17
18
  var chunkZ2Y65YOY_cjs = require('../chunk-Z2Y65YOY.cjs');
18
19
  var module$1 = require('module');
19
20
  var url = require('url');
@@ -33,7 +34,7 @@ function quickjsModuleUrl() {
33
34
  }
34
35
  function parseResult(outcome) {
35
36
  if (!chunkSAENRNBJ_cjs.isRecord(outcome))
36
- return chunkJD2VQIDZ_cjs.failedTaskResult("INTERNAL", "The task worker returned no outcome");
37
+ return chunkEWYADREB_cjs.failedTaskResult("INTERNAL", "The task worker returned no outcome");
37
38
  const typed = outcome;
38
39
  if (typed.ok === true && typeof typed.resultJson === "string") {
39
40
  try {
@@ -42,11 +43,11 @@ function parseResult(outcome) {
42
43
  return parsed;
43
44
  } catch {
44
45
  }
45
- return chunkJD2VQIDZ_cjs.failedTaskResult("INTERNAL", "The runtime returned an invalid result");
46
+ return chunkEWYADREB_cjs.failedTaskResult("INTERNAL", "The runtime returned an invalid result");
46
47
  }
47
48
  if (typed.ok === false && typeof typed.cause === "string")
48
- return chunkJD2VQIDZ_cjs.failedTaskResult(typed.cause, String(typed.message));
49
- return chunkJD2VQIDZ_cjs.failedTaskResult("INTERNAL", "The task worker returned an invalid outcome");
49
+ return chunkEWYADREB_cjs.failedTaskResult(typed.cause, String(typed.message));
50
+ return chunkEWYADREB_cjs.failedTaskResult("INTERNAL", "The task worker returned an invalid outcome");
50
51
  }
51
52
  function createWorkflowTaskRunner(options = {}) {
52
53
  const poolSize = Math.max(1, Math.floor(options.poolSize ?? 4));
@@ -89,7 +90,7 @@ function createWorkflowTaskRunner(options = {}) {
89
90
  if (slots.some((entry) => entry.ready)) return;
90
91
  for (const job of queue.splice(0))
91
92
  job.resolve(
92
- chunkJD2VQIDZ_cjs.failedTaskResult("INTERNAL", `The workflow task threads could not start: ${reason}`)
93
+ chunkEWYADREB_cjs.failedTaskResult("INTERNAL", `The workflow task threads could not start: ${reason}`)
93
94
  );
94
95
  };
95
96
  const spawn = () => {
@@ -121,7 +122,7 @@ function createWorkflowTaskRunner(options = {}) {
121
122
  startFailed(slot, String(message["message"]));
122
123
  return;
123
124
  }
124
- if (slot.job) finish(slot, chunkJD2VQIDZ_cjs.failedTaskResult("INTERNAL", String(message["message"])));
125
+ if (slot.job) finish(slot, chunkEWYADREB_cjs.failedTaskResult("INTERNAL", String(message["message"])));
125
126
  replace(slot);
126
127
  }
127
128
  });
@@ -131,7 +132,7 @@ function createWorkflowTaskRunner(options = {}) {
131
132
  if (slot.job)
132
133
  finish(
133
134
  slot,
134
- chunkJD2VQIDZ_cjs.failedTaskResult(
135
+ chunkEWYADREB_cjs.failedTaskResult(
135
136
  outOfMemory ? "ISOLATE_MEMORY" : "INTERNAL",
136
137
  outOfMemory ? "The workflow task ran out of memory" : `The task thread failed: ${error.message}`
137
138
  )
@@ -144,7 +145,7 @@ function createWorkflowTaskRunner(options = {}) {
144
145
  startFailed(slot, "the thread exited while starting");
145
146
  return;
146
147
  }
147
- if (slot.job) finish(slot, chunkJD2VQIDZ_cjs.failedTaskResult("INTERNAL", "The task thread exited"));
148
+ if (slot.job) finish(slot, chunkEWYADREB_cjs.failedTaskResult("INTERNAL", "The task thread exited"));
148
149
  replace(slot);
149
150
  });
150
151
  };
@@ -159,7 +160,7 @@ function createWorkflowTaskRunner(options = {}) {
159
160
  slot.timer = setTimeout(() => {
160
161
  finish(
161
162
  slot,
162
- chunkJD2VQIDZ_cjs.failedTaskResult(
163
+ chunkEWYADREB_cjs.failedTaskResult(
163
164
  "TASK_TIMEOUT",
164
165
  `The workflow task ran past its ${job.timeoutMs} ms budget`
165
166
  )
@@ -194,19 +195,19 @@ function createWorkflowTaskRunner(options = {}) {
194
195
  };
195
196
  return {
196
197
  run(bundle, request, runOptions = {}) {
197
- if (closed) return Promise.resolve(chunkJD2VQIDZ_cjs.failedTaskResult("INTERNAL", "The task runner is closed"));
198
+ if (closed) return Promise.resolve(chunkEWYADREB_cjs.failedTaskResult("INTERNAL", "The task runner is closed"));
198
199
  const code = typeof bundle === "string" ? bundle : bundle.code;
199
200
  const buildId = typeof bundle === "string" ? void 0 : bundle.buildId;
200
201
  if (buildId !== void 0 && !verify(code, buildId))
201
202
  return Promise.resolve(
202
- chunkJD2VQIDZ_cjs.failedTaskResult("BUNDLE_INTEGRITY", `The bundle does not hash to ${buildId}`)
203
+ chunkEWYADREB_cjs.failedTaskResult("BUNDLE_INTEGRITY", `The bundle does not hash to ${buildId}`)
203
204
  );
204
205
  let requestJson;
205
206
  try {
206
207
  requestJson = JSON.stringify(request);
207
208
  } catch (error) {
208
209
  return Promise.resolve(
209
- chunkJD2VQIDZ_cjs.failedTaskResult(
210
+ chunkEWYADREB_cjs.failedTaskResult(
210
211
  "INVALID_REQUEST",
211
212
  error instanceof Error ? error.message : String(error)
212
213
  )
@@ -226,10 +227,10 @@ function createWorkflowTaskRunner(options = {}) {
226
227
  async close() {
227
228
  closed = true;
228
229
  for (const job of queue.splice(0))
229
- job.resolve(chunkJD2VQIDZ_cjs.failedTaskResult("INTERNAL", "The task runner is closed"));
230
+ job.resolve(chunkEWYADREB_cjs.failedTaskResult("INTERNAL", "The task runner is closed"));
230
231
  const all = slots.splice(0);
231
232
  for (const slot of all)
232
- if (slot.job) finish(slot, chunkJD2VQIDZ_cjs.failedTaskResult("INTERNAL", "The task runner is closed"));
233
+ if (slot.job) finish(slot, chunkEWYADREB_cjs.failedTaskResult("INTERNAL", "The task runner is closed"));
233
234
  await Promise.all(all.map((slot) => slot.worker.terminate()));
234
235
  }
235
236
  };
@@ -240,7 +241,7 @@ function quickjsModuleUrl2() {
240
241
  try {
241
242
  return url.pathToFileURL(module$1.createRequire(chunkZ2Y65YOY_cjs.importMetaUrl).resolve("quickjs-emscripten")).href;
242
243
  } catch (error) {
243
- throw new chunk2DP2Y6EU_cjs.LowerError(
244
+ throw new chunk6QPOJZT6_cjs.LowerError(
244
245
  `quickjs-emscripten cannot be resolved: ${error instanceof Error ? error.message : String(error)}`,
245
246
  "crashed"
246
247
  );
@@ -255,12 +256,12 @@ function createQuickJSEvaluator(options = {}) {
255
256
  return {
256
257
  format: "esm",
257
258
  async evaluate(code) {
258
- const outcome = await chunk2DP2Y6EU_cjs.runIsolateWorker({
259
+ const outcome = await chunk6QPOJZT6_cjs.runIsolateWorker({
259
260
  source: QUICKJS_WORKER_SOURCE,
260
261
  workerData: { code, limits, moduleUrl: quickjsModuleUrl2() },
261
262
  timeoutMs: limits.timeoutMs
262
263
  });
263
- return chunk2DP2Y6EU_cjs.outcomeToCollection(outcome);
264
+ return chunk6QPOJZT6_cjs.outcomeToCollection(outcome);
264
265
  }
265
266
  };
266
267
  }
@@ -1,11 +1,11 @@
1
- import { E as Evaluator } from '../lower-BuSvAFqi.cjs';
2
- import { a7 as WorkflowTaskRequest, a8 as WorkflowTaskResult } from '../types-CpBBjaGX.cjs';
1
+ import { E as Evaluator } from '../lower-3S6PsqjJ.cjs';
2
+ import { aj as WorkflowTaskRequest, ak as WorkflowTaskResult } from '../types-CQKOhPTa.cjs';
3
3
  import '../hash-CZkTXPCX.cjs';
4
- import '../types-BGoPzgcl.cjs';
5
- import '../assemble-BLqQ8lSu.cjs';
6
- import '../workflow-FXUkpIBc.cjs';
7
- import '../workflow-J-yYixny.cjs';
8
- import '../lower-types-nofRXw9c.cjs';
4
+ import '../types-Bb2wRnJ5.cjs';
5
+ import '../collect-CSyOg5XC.cjs';
6
+ import '../workflow-CZOXUlQ5.cjs';
7
+ import '../workflow-O6e64ZcG.cjs';
8
+ import '../lower-types-DQNBfWQn.cjs';
9
9
  import 'esbuild';
10
10
 
11
11
  interface WorkflowTaskRunnerOptions {
@@ -1,11 +1,11 @@
1
- import { E as Evaluator } from '../lower-C_Qv_34S.js';
2
- import { a7 as WorkflowTaskRequest, a8 as WorkflowTaskResult } from '../types-DV-HX_Gt.js';
1
+ import { E as Evaluator } from '../lower-DmZpQ8hJ.js';
2
+ import { aj as WorkflowTaskRequest, ak as WorkflowTaskResult } from '../types-CnIOinoz.js';
3
3
  import '../hash-CZkTXPCX.js';
4
- import '../types-BGoPzgcl.js';
5
- import '../assemble-DWgaXHd-.js';
6
- import '../workflow-Bpr3vnA_.js';
7
- import '../workflow-C2a05WUJ.js';
8
- import '../lower-types-nofRXw9c.js';
4
+ import '../types-Bb2wRnJ5.js';
5
+ import '../collect-BTHjQaSp.js';
6
+ import '../workflow-8uRU9rhL.js';
7
+ import '../workflow-DWTPHFbt.js';
8
+ import '../lower-types-DQNBfWQn.js';
9
9
  import 'esbuild';
10
10
 
11
11
  interface WorkflowTaskRunnerOptions {
@@ -1,7 +1,7 @@
1
- import { runIsolateWorker, outcomeToCollection, LowerError } from '../chunk-H7KEVW2M.js';
2
- import '../chunk-PDHLTDZB.js';
3
- import { failedTaskResult } from '../chunk-IISBRUWJ.js';
4
- import '../chunk-5HDSBTBX.js';
1
+ import { runIsolateWorker, outcomeToCollection, LowerError } from '../chunk-A2OHX3UQ.js';
2
+ import '../chunk-OIX4O6UR.js';
3
+ import { failedTaskResult } from '../chunk-WXXNCHUY.js';
4
+ import '../chunk-FQSJI5NV.js';
5
5
  import { buildIdOf } from '../chunk-BD7ZPG53.js';
6
6
  import '../chunk-5LUIDMF4.js';
7
7
  import '../chunk-JZ4TOOLN.js';
@@ -9,9 +9,10 @@ import '../chunk-E2VK7J2C.js';
9
9
  import '../chunk-7AAZGVKD.js';
10
10
  import { isRecord } from '../chunk-PMCM2OH4.js';
11
11
  import '../chunk-4LYSEANA.js';
12
- import '../chunk-7NQ37GZU.js';
13
- import '../chunk-DJYMDLV5.js';
14
- import '../chunk-BO6OVILK.js';
12
+ import '../chunk-7ILGCUI6.js';
13
+ import '../chunk-LNUQE6D6.js';
14
+ import '../chunk-2DDULZFM.js';
15
+ import '../chunk-PWIUEWC3.js';
15
16
  import { createRequire } from 'module';
16
17
  import { pathToFileURL } from 'url';
17
18
  import { Worker } from 'worker_threads';