@rivetkit/workflow-engine 3.0.6 → 3.0.7

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.
@@ -43,7 +43,7 @@
43
43
 
44
44
 
45
45
 
46
- var _chunkL4MA54VFcjs = require('./chunk-L4MA54VF.cjs');
46
+ var _chunkZ4F6P6M4cjs = require('./chunk-Z4F6P6M4.cjs');
47
47
 
48
48
 
49
49
 
@@ -89,5 +89,5 @@ var _chunkL4MA54VFcjs = require('./chunk-L4MA54VF.cjs');
89
89
 
90
90
 
91
91
 
92
- exports.CancelledError = _chunkL4MA54VFcjs.CancelledError; exports.CriticalError = _chunkL4MA54VFcjs.CriticalError; exports.DEFAULT_LOOP_HISTORY_PRUNE_INTERVAL = _chunkL4MA54VFcjs.DEFAULT_LOOP_HISTORY_PRUNE_INTERVAL; exports.DEFAULT_MAX_RETRIES = _chunkL4MA54VFcjs.DEFAULT_MAX_RETRIES; exports.DEFAULT_RETRY_BACKOFF_BASE = _chunkL4MA54VFcjs.DEFAULT_RETRY_BACKOFF_BASE; exports.DEFAULT_RETRY_BACKOFF_MAX = _chunkL4MA54VFcjs.DEFAULT_RETRY_BACKOFF_MAX; exports.DEFAULT_STEP_TIMEOUT = _chunkL4MA54VFcjs.DEFAULT_STEP_TIMEOUT; exports.EntryInProgressError = _chunkL4MA54VFcjs.EntryInProgressError; exports.EvictedError = _chunkL4MA54VFcjs.EvictedError; exports.HistoryDivergedError = _chunkL4MA54VFcjs.HistoryDivergedError; exports.JoinError = _chunkL4MA54VFcjs.JoinError; exports.Loop = _chunkL4MA54VFcjs.Loop; exports.MessageWaitError = _chunkL4MA54VFcjs.MessageWaitError; exports.RaceError = _chunkL4MA54VFcjs.RaceError; exports.RollbackCheckpointError = _chunkL4MA54VFcjs.RollbackCheckpointError; exports.RollbackError = _chunkL4MA54VFcjs.RollbackError; exports.SleepError = _chunkL4MA54VFcjs.SleepError; exports.StepExhaustedError = _chunkL4MA54VFcjs.StepExhaustedError; exports.StepFailedError = _chunkL4MA54VFcjs.StepFailedError; exports.WorkflowContextImpl = _chunkL4MA54VFcjs.WorkflowContextImpl; exports.appendLoopIteration = _chunkL4MA54VFcjs.appendLoopIteration; exports.appendName = _chunkL4MA54VFcjs.appendName; exports.createEntry = _chunkL4MA54VFcjs.createEntry; exports.createHistorySnapshot = _chunkL4MA54VFcjs.createHistorySnapshot; exports.createStorage = _chunkL4MA54VFcjs.createStorage; exports.deleteEntriesWithPrefix = _chunkL4MA54VFcjs.deleteEntriesWithPrefix; exports.emptyLocation = _chunkL4MA54VFcjs.emptyLocation; exports.extractErrorInfo = _chunkL4MA54VFcjs.extractErrorInfo; exports.flush = _chunkL4MA54VFcjs.flush; exports.generateId = _chunkL4MA54VFcjs.generateId; exports.getEntry = _chunkL4MA54VFcjs.getEntry; exports.getOrCreateMetadata = _chunkL4MA54VFcjs.getOrCreateMetadata; exports.isLocationPrefix = _chunkL4MA54VFcjs.isLocationPrefix; exports.isLoopIterationMarker = _chunkL4MA54VFcjs.isLoopIterationMarker; exports.loadMetadata = _chunkL4MA54VFcjs.loadMetadata; exports.loadStorage = _chunkL4MA54VFcjs.loadStorage; exports.locationToKey = _chunkL4MA54VFcjs.locationToKey; exports.locationsEqual = _chunkL4MA54VFcjs.locationsEqual; exports.parentLocation = _chunkL4MA54VFcjs.parentLocation; exports.registerName = _chunkL4MA54VFcjs.registerName; exports.replayWorkflowFromStep = _chunkL4MA54VFcjs.replayWorkflowFromStep; exports.resolveName = _chunkL4MA54VFcjs.resolveName; exports.runWorkflow = _chunkL4MA54VFcjs.runWorkflow; exports.setEntry = _chunkL4MA54VFcjs.setEntry;
92
+ exports.CancelledError = _chunkZ4F6P6M4cjs.CancelledError; exports.CriticalError = _chunkZ4F6P6M4cjs.CriticalError; exports.DEFAULT_LOOP_HISTORY_PRUNE_INTERVAL = _chunkZ4F6P6M4cjs.DEFAULT_LOOP_HISTORY_PRUNE_INTERVAL; exports.DEFAULT_MAX_RETRIES = _chunkZ4F6P6M4cjs.DEFAULT_MAX_RETRIES; exports.DEFAULT_RETRY_BACKOFF_BASE = _chunkZ4F6P6M4cjs.DEFAULT_RETRY_BACKOFF_BASE; exports.DEFAULT_RETRY_BACKOFF_MAX = _chunkZ4F6P6M4cjs.DEFAULT_RETRY_BACKOFF_MAX; exports.DEFAULT_STEP_TIMEOUT = _chunkZ4F6P6M4cjs.DEFAULT_STEP_TIMEOUT; exports.EntryInProgressError = _chunkZ4F6P6M4cjs.EntryInProgressError; exports.EvictedError = _chunkZ4F6P6M4cjs.EvictedError; exports.HistoryDivergedError = _chunkZ4F6P6M4cjs.HistoryDivergedError; exports.JoinError = _chunkZ4F6P6M4cjs.JoinError; exports.Loop = _chunkZ4F6P6M4cjs.Loop; exports.MessageWaitError = _chunkZ4F6P6M4cjs.MessageWaitError; exports.RaceError = _chunkZ4F6P6M4cjs.RaceError; exports.RollbackCheckpointError = _chunkZ4F6P6M4cjs.RollbackCheckpointError; exports.RollbackError = _chunkZ4F6P6M4cjs.RollbackError; exports.SleepError = _chunkZ4F6P6M4cjs.SleepError; exports.StepExhaustedError = _chunkZ4F6P6M4cjs.StepExhaustedError; exports.StepFailedError = _chunkZ4F6P6M4cjs.StepFailedError; exports.WorkflowContextImpl = _chunkZ4F6P6M4cjs.WorkflowContextImpl; exports.appendLoopIteration = _chunkZ4F6P6M4cjs.appendLoopIteration; exports.appendName = _chunkZ4F6P6M4cjs.appendName; exports.createEntry = _chunkZ4F6P6M4cjs.createEntry; exports.createHistorySnapshot = _chunkZ4F6P6M4cjs.createHistorySnapshot; exports.createStorage = _chunkZ4F6P6M4cjs.createStorage; exports.deleteEntriesWithPrefix = _chunkZ4F6P6M4cjs.deleteEntriesWithPrefix; exports.emptyLocation = _chunkZ4F6P6M4cjs.emptyLocation; exports.extractErrorInfo = _chunkZ4F6P6M4cjs.extractErrorInfo; exports.flush = _chunkZ4F6P6M4cjs.flush; exports.generateId = _chunkZ4F6P6M4cjs.generateId; exports.getEntry = _chunkZ4F6P6M4cjs.getEntry; exports.getOrCreateMetadata = _chunkZ4F6P6M4cjs.getOrCreateMetadata; exports.isLocationPrefix = _chunkZ4F6P6M4cjs.isLocationPrefix; exports.isLoopIterationMarker = _chunkZ4F6P6M4cjs.isLoopIterationMarker; exports.loadMetadata = _chunkZ4F6P6M4cjs.loadMetadata; exports.loadStorage = _chunkZ4F6P6M4cjs.loadStorage; exports.locationToKey = _chunkZ4F6P6M4cjs.locationToKey; exports.locationsEqual = _chunkZ4F6P6M4cjs.locationsEqual; exports.parentLocation = _chunkZ4F6P6M4cjs.parentLocation; exports.registerName = _chunkZ4F6P6M4cjs.registerName; exports.replayWorkflowFromStep = _chunkZ4F6P6M4cjs.replayWorkflowFromStep; exports.resolveName = _chunkZ4F6P6M4cjs.resolveName; exports.runWorkflow = _chunkZ4F6P6M4cjs.runWorkflow; exports.setEntry = _chunkZ4F6P6M4cjs.setEntry;
93
93
  //# sourceMappingURL=index.cjs.map
@@ -356,7 +356,7 @@ interface StepConfig<T> {
356
356
  retryBackoffBase?: number;
357
357
  /** Maximum delay in ms for exponential backoff (default: 30000). */
358
358
  retryBackoffMax?: number;
359
- /** Timeout in ms for step execution (default: 30000). Set to 0 to disable. */
359
+ /** Timeout in ms for step execution (default: 30000). Set to 0 or Infinity to disable. */
360
360
  timeout?: number;
361
361
  /** If true, step timeouts retry like any other error instead of failing immediately as critical. Default: false. */
362
362
  retryOnTimeout?: boolean;
@@ -696,6 +696,8 @@ declare class WorkflowContextImpl implements WorkflowContextInterface {
696
696
  private messageDriver;
697
697
  private entryInProgress;
698
698
  private abortController;
699
+ /** The run's signal. Race branches have their own, which eviction skips. */
700
+ private evictionSignal;
699
701
  private currentLocation;
700
702
  private visitedKeys;
701
703
  private runSpan?;
@@ -714,6 +716,8 @@ declare class WorkflowContextImpl implements WorkflowContextInterface {
714
716
  isEvicted(): boolean;
715
717
  private assertNotInProgress;
716
718
  private checkEvicted;
719
+ /** Whether an enclosing race picked a winner and cancelled this branch. */
720
+ private isRaceCancelled;
717
721
  private flushStorage;
718
722
  /**
719
723
  * Create a new branch context for parallel/nested execution.
@@ -772,6 +776,11 @@ declare class WorkflowContextImpl implements WorkflowContextInterface {
772
776
  * long-lived run abort signal.
773
777
  */
774
778
  private sleepOrEvict;
779
+ /**
780
+ * Wait until `deadline`, a running race branch settles, or the workflow is
781
+ * evicted. The timer and abort listener are torn down on every outcome.
782
+ */
783
+ private waitForRaceWake;
775
784
  step<T>(nameOrConfig: string | StepConfig<T>, run?: () => Promise<T>): Promise<T>;
776
785
  tryStep<T>(nameOrConfig: string | TryStepConfig<T>, run?: () => Promise<T>): Promise<TryStepResult<T>>;
777
786
  try<T>(nameOrConfig: string | TryBlockConfig<T>, run?: (ctx: WorkflowContextInterface) => Promise<T>): Promise<TryBlockResult<T>>;
@@ -1052,9 +1061,11 @@ interface PendingDeletions {
1052
1061
  }[];
1053
1062
  }
1054
1063
  /**
1055
- * Flush all dirty data to the driver. Optionally includes pending
1056
- * deletions so that history pruning happens alongside the
1057
- * state write.
1064
+ * Save workflow history in order, preserving mutations made during each write.
1065
+ *
1066
+ * A save that has not started reads storage when it starts, so it also saves
1067
+ * the changes of callers that join it. They share its result. Saves with
1068
+ * deletions do not share, so pruning runs in order with the writes around it.
1058
1069
  */
1059
1070
  declare function flush(storage: Storage, driver: EngineDriver, onHistoryUpdated?: () => void, pendingDeletions?: PendingDeletions): Promise<void>;
1060
1071
  /**
@@ -356,7 +356,7 @@ interface StepConfig<T> {
356
356
  retryBackoffBase?: number;
357
357
  /** Maximum delay in ms for exponential backoff (default: 30000). */
358
358
  retryBackoffMax?: number;
359
- /** Timeout in ms for step execution (default: 30000). Set to 0 to disable. */
359
+ /** Timeout in ms for step execution (default: 30000). Set to 0 or Infinity to disable. */
360
360
  timeout?: number;
361
361
  /** If true, step timeouts retry like any other error instead of failing immediately as critical. Default: false. */
362
362
  retryOnTimeout?: boolean;
@@ -696,6 +696,8 @@ declare class WorkflowContextImpl implements WorkflowContextInterface {
696
696
  private messageDriver;
697
697
  private entryInProgress;
698
698
  private abortController;
699
+ /** The run's signal. Race branches have their own, which eviction skips. */
700
+ private evictionSignal;
699
701
  private currentLocation;
700
702
  private visitedKeys;
701
703
  private runSpan?;
@@ -714,6 +716,8 @@ declare class WorkflowContextImpl implements WorkflowContextInterface {
714
716
  isEvicted(): boolean;
715
717
  private assertNotInProgress;
716
718
  private checkEvicted;
719
+ /** Whether an enclosing race picked a winner and cancelled this branch. */
720
+ private isRaceCancelled;
717
721
  private flushStorage;
718
722
  /**
719
723
  * Create a new branch context for parallel/nested execution.
@@ -772,6 +776,11 @@ declare class WorkflowContextImpl implements WorkflowContextInterface {
772
776
  * long-lived run abort signal.
773
777
  */
774
778
  private sleepOrEvict;
779
+ /**
780
+ * Wait until `deadline`, a running race branch settles, or the workflow is
781
+ * evicted. The timer and abort listener are torn down on every outcome.
782
+ */
783
+ private waitForRaceWake;
775
784
  step<T>(nameOrConfig: string | StepConfig<T>, run?: () => Promise<T>): Promise<T>;
776
785
  tryStep<T>(nameOrConfig: string | TryStepConfig<T>, run?: () => Promise<T>): Promise<TryStepResult<T>>;
777
786
  try<T>(nameOrConfig: string | TryBlockConfig<T>, run?: (ctx: WorkflowContextInterface) => Promise<T>): Promise<TryBlockResult<T>>;
@@ -1052,9 +1061,11 @@ interface PendingDeletions {
1052
1061
  }[];
1053
1062
  }
1054
1063
  /**
1055
- * Flush all dirty data to the driver. Optionally includes pending
1056
- * deletions so that history pruning happens alongside the
1057
- * state write.
1064
+ * Save workflow history in order, preserving mutations made during each write.
1065
+ *
1066
+ * A save that has not started reads storage when it starts, so it also saves
1067
+ * the changes of callers that join it. They share its result. Saves with
1068
+ * deletions do not share, so pruning runs in order with the writes around it.
1058
1069
  */
1059
1070
  declare function flush(storage: Storage, driver: EngineDriver, onHistoryUpdated?: () => void, pendingDeletions?: PendingDeletions): Promise<void>;
1060
1071
  /**
@@ -43,7 +43,7 @@ import {
43
43
  resolveName,
44
44
  runWorkflow,
45
45
  setEntry
46
- } from "./chunk-JMOI2OHA.js";
46
+ } from "./chunk-NIKZ2NOQ.js";
47
47
  export {
48
48
  CancelledError,
49
49
  CriticalError,
@@ -47,7 +47,7 @@
47
47
 
48
48
 
49
49
 
50
- var _chunkL4MA54VFcjs = require('./chunk-L4MA54VF.cjs');
50
+ var _chunkZ4F6P6M4cjs = require('./chunk-Z4F6P6M4.cjs');
51
51
 
52
52
  // src/testing.ts
53
53
  var InMemoryWorkflowMessageDriver = class {
@@ -97,7 +97,7 @@ var InMemoryWorkflowMessageDriver = class {
97
97
  }
98
98
  async waitForMessages(messageNames, abortSignal) {
99
99
  if (abortSignal.aborted) {
100
- throw new (0, _chunkL4MA54VFcjs.EvictedError)();
100
+ throw new (0, _chunkZ4F6P6M4cjs.EvictedError)();
101
101
  }
102
102
  const nameSet = messageNames.length > 0 ? new Set(messageNames) : void 0;
103
103
  if (this.#messages.some(
@@ -118,7 +118,7 @@ var InMemoryWorkflowMessageDriver = class {
118
118
  },
119
119
  abortSignal,
120
120
  onAbort: () => {
121
- waiter.reject(new (0, _chunkL4MA54VFcjs.EvictedError)());
121
+ waiter.reject(new (0, _chunkZ4F6P6M4cjs.EvictedError)());
122
122
  }
123
123
  };
124
124
  abortSignal.addEventListener("abort", waiter.onAbort, {
@@ -158,62 +158,62 @@ var InMemoryDriver = (_class = class {constructor() { _class.prototype.__init.ca
158
158
  __init4() {this.workerPollInterval = 100}
159
159
  __init5() {this.messageDriver = this.#inMemoryMessageDriver}
160
160
  async get(key) {
161
- await _chunkL4MA54VFcjs.sleep.call(void 0, this.latency);
162
- const entry = this.kv.get(_chunkL4MA54VFcjs.keyToHex.call(void 0, key));
161
+ await _chunkZ4F6P6M4cjs.sleep.call(void 0, this.latency);
162
+ const entry = this.kv.get(_chunkZ4F6P6M4cjs.keyToHex.call(void 0, key));
163
163
  return _nullishCoalesce((entry == null ? void 0 : entry.value), () => ( null));
164
164
  }
165
165
  async set(key, value) {
166
- await _chunkL4MA54VFcjs.sleep.call(void 0, this.latency);
167
- this.kv.set(_chunkL4MA54VFcjs.keyToHex.call(void 0, key), { key, value });
166
+ await _chunkZ4F6P6M4cjs.sleep.call(void 0, this.latency);
167
+ this.kv.set(_chunkZ4F6P6M4cjs.keyToHex.call(void 0, key), { key, value });
168
168
  }
169
169
  async delete(key) {
170
- await _chunkL4MA54VFcjs.sleep.call(void 0, this.latency);
171
- this.kv.delete(_chunkL4MA54VFcjs.keyToHex.call(void 0, key));
170
+ await _chunkZ4F6P6M4cjs.sleep.call(void 0, this.latency);
171
+ this.kv.delete(_chunkZ4F6P6M4cjs.keyToHex.call(void 0, key));
172
172
  }
173
173
  async batchDelete(keys) {
174
- await _chunkL4MA54VFcjs.sleep.call(void 0, this.latency);
174
+ await _chunkZ4F6P6M4cjs.sleep.call(void 0, this.latency);
175
175
  for (const key of keys) {
176
- this.kv.delete(_chunkL4MA54VFcjs.keyToHex.call(void 0, key));
176
+ this.kv.delete(_chunkZ4F6P6M4cjs.keyToHex.call(void 0, key));
177
177
  }
178
178
  }
179
179
  async deletePrefix(prefix) {
180
- await _chunkL4MA54VFcjs.sleep.call(void 0, this.latency);
180
+ await _chunkZ4F6P6M4cjs.sleep.call(void 0, this.latency);
181
181
  for (const [hexKey, entry] of this.kv) {
182
- if (_chunkL4MA54VFcjs.keyStartsWith.call(void 0, entry.key, prefix)) {
182
+ if (_chunkZ4F6P6M4cjs.keyStartsWith.call(void 0, entry.key, prefix)) {
183
183
  this.kv.delete(hexKey);
184
184
  }
185
185
  }
186
186
  }
187
187
  async deleteRange(start, end) {
188
- await _chunkL4MA54VFcjs.sleep.call(void 0, this.latency);
188
+ await _chunkZ4F6P6M4cjs.sleep.call(void 0, this.latency);
189
189
  for (const [hexKey, entry] of this.kv) {
190
- if (_chunkL4MA54VFcjs.compareKeys.call(void 0, entry.key, start) >= 0 && _chunkL4MA54VFcjs.compareKeys.call(void 0, entry.key, end) < 0) {
190
+ if (_chunkZ4F6P6M4cjs.compareKeys.call(void 0, entry.key, start) >= 0 && _chunkZ4F6P6M4cjs.compareKeys.call(void 0, entry.key, end) < 0) {
191
191
  this.kv.delete(hexKey);
192
192
  }
193
193
  }
194
194
  }
195
195
  async list(prefix) {
196
- await _chunkL4MA54VFcjs.sleep.call(void 0, this.latency);
196
+ await _chunkZ4F6P6M4cjs.sleep.call(void 0, this.latency);
197
197
  const results = [];
198
198
  for (const entry of this.kv.values()) {
199
- if (_chunkL4MA54VFcjs.keyStartsWith.call(void 0, entry.key, prefix)) {
199
+ if (_chunkZ4F6P6M4cjs.keyStartsWith.call(void 0, entry.key, prefix)) {
200
200
  results.push({ key: entry.key, value: entry.value });
201
201
  }
202
202
  }
203
- return results.sort((a, b) => _chunkL4MA54VFcjs.compareKeys.call(void 0, a.key, b.key));
203
+ return results.sort((a, b) => _chunkZ4F6P6M4cjs.compareKeys.call(void 0, a.key, b.key));
204
204
  }
205
205
  async batch(writes) {
206
- await _chunkL4MA54VFcjs.sleep.call(void 0, this.latency);
206
+ await _chunkZ4F6P6M4cjs.sleep.call(void 0, this.latency);
207
207
  for (const { key, value } of writes) {
208
- this.kv.set(_chunkL4MA54VFcjs.keyToHex.call(void 0, key), { key, value });
208
+ this.kv.set(_chunkZ4F6P6M4cjs.keyToHex.call(void 0, key), { key, value });
209
209
  }
210
210
  }
211
211
  async setAlarm(workflowId, wakeAt) {
212
- await _chunkL4MA54VFcjs.sleep.call(void 0, this.latency);
212
+ await _chunkZ4F6P6M4cjs.sleep.call(void 0, this.latency);
213
213
  this.alarms.set(workflowId, wakeAt);
214
214
  }
215
215
  async clearAlarm(workflowId) {
216
- await _chunkL4MA54VFcjs.sleep.call(void 0, this.latency);
216
+ await _chunkZ4F6P6M4cjs.sleep.call(void 0, this.latency);
217
217
  this.alarms.delete(workflowId);
218
218
  }
219
219
  async waitForMessages(messageNames, abortSignal) {
@@ -224,7 +224,7 @@ var InMemoryDriver = (_class = class {constructor() { _class.prototype.__init.ca
224
224
  }
225
225
  while (true) {
226
226
  if (abortSignal.aborted) {
227
- throw new (0, _chunkL4MA54VFcjs.EvictedError)();
227
+ throw new (0, _chunkZ4F6P6M4cjs.EvictedError)();
228
228
  }
229
229
  const messages = await this.messageDriver.receiveMessages({
230
230
  names: messageNames.length > 0 ? messageNames : void 0,
@@ -234,7 +234,7 @@ var InMemoryDriver = (_class = class {constructor() { _class.prototype.__init.ca
234
234
  if (messages.length > 0) {
235
235
  return;
236
236
  }
237
- await _chunkL4MA54VFcjs.sleep.call(void 0, Math.max(1, this.latency));
237
+ await _chunkZ4F6P6M4cjs.sleep.call(void 0, Math.max(1, this.latency));
238
238
  }
239
239
  }
240
240
  /**
@@ -330,5 +330,5 @@ var InMemoryDriver = (_class = class {constructor() { _class.prototype.__init.ca
330
330
 
331
331
 
332
332
 
333
- exports.CancelledError = _chunkL4MA54VFcjs.CancelledError; exports.CriticalError = _chunkL4MA54VFcjs.CriticalError; exports.DEFAULT_LOOP_HISTORY_PRUNE_INTERVAL = _chunkL4MA54VFcjs.DEFAULT_LOOP_HISTORY_PRUNE_INTERVAL; exports.DEFAULT_MAX_RETRIES = _chunkL4MA54VFcjs.DEFAULT_MAX_RETRIES; exports.DEFAULT_RETRY_BACKOFF_BASE = _chunkL4MA54VFcjs.DEFAULT_RETRY_BACKOFF_BASE; exports.DEFAULT_RETRY_BACKOFF_MAX = _chunkL4MA54VFcjs.DEFAULT_RETRY_BACKOFF_MAX; exports.DEFAULT_STEP_TIMEOUT = _chunkL4MA54VFcjs.DEFAULT_STEP_TIMEOUT; exports.EntryInProgressError = _chunkL4MA54VFcjs.EntryInProgressError; exports.EvictedError = _chunkL4MA54VFcjs.EvictedError; exports.HistoryDivergedError = _chunkL4MA54VFcjs.HistoryDivergedError; exports.InMemoryDriver = InMemoryDriver; exports.JoinError = _chunkL4MA54VFcjs.JoinError; exports.Loop = _chunkL4MA54VFcjs.Loop; exports.MessageWaitError = _chunkL4MA54VFcjs.MessageWaitError; exports.RaceError = _chunkL4MA54VFcjs.RaceError; exports.RollbackCheckpointError = _chunkL4MA54VFcjs.RollbackCheckpointError; exports.RollbackError = _chunkL4MA54VFcjs.RollbackError; exports.SleepError = _chunkL4MA54VFcjs.SleepError; exports.StepExhaustedError = _chunkL4MA54VFcjs.StepExhaustedError; exports.StepFailedError = _chunkL4MA54VFcjs.StepFailedError; exports.WorkflowContextImpl = _chunkL4MA54VFcjs.WorkflowContextImpl; exports.appendLoopIteration = _chunkL4MA54VFcjs.appendLoopIteration; exports.appendName = _chunkL4MA54VFcjs.appendName; exports.createEntry = _chunkL4MA54VFcjs.createEntry; exports.createHistorySnapshot = _chunkL4MA54VFcjs.createHistorySnapshot; exports.createStorage = _chunkL4MA54VFcjs.createStorage; exports.deleteEntriesWithPrefix = _chunkL4MA54VFcjs.deleteEntriesWithPrefix; exports.emptyLocation = _chunkL4MA54VFcjs.emptyLocation; exports.extractErrorInfo = _chunkL4MA54VFcjs.extractErrorInfo; exports.flush = _chunkL4MA54VFcjs.flush; exports.generateId = _chunkL4MA54VFcjs.generateId; exports.getEntry = _chunkL4MA54VFcjs.getEntry; exports.getOrCreateMetadata = _chunkL4MA54VFcjs.getOrCreateMetadata; exports.isLocationPrefix = _chunkL4MA54VFcjs.isLocationPrefix; exports.isLoopIterationMarker = _chunkL4MA54VFcjs.isLoopIterationMarker; exports.loadMetadata = _chunkL4MA54VFcjs.loadMetadata; exports.loadStorage = _chunkL4MA54VFcjs.loadStorage; exports.locationToKey = _chunkL4MA54VFcjs.locationToKey; exports.locationsEqual = _chunkL4MA54VFcjs.locationsEqual; exports.parentLocation = _chunkL4MA54VFcjs.parentLocation; exports.registerName = _chunkL4MA54VFcjs.registerName; exports.replayWorkflowFromStep = _chunkL4MA54VFcjs.replayWorkflowFromStep; exports.resolveName = _chunkL4MA54VFcjs.resolveName; exports.runWorkflow = _chunkL4MA54VFcjs.runWorkflow; exports.setEntry = _chunkL4MA54VFcjs.setEntry;
333
+ exports.CancelledError = _chunkZ4F6P6M4cjs.CancelledError; exports.CriticalError = _chunkZ4F6P6M4cjs.CriticalError; exports.DEFAULT_LOOP_HISTORY_PRUNE_INTERVAL = _chunkZ4F6P6M4cjs.DEFAULT_LOOP_HISTORY_PRUNE_INTERVAL; exports.DEFAULT_MAX_RETRIES = _chunkZ4F6P6M4cjs.DEFAULT_MAX_RETRIES; exports.DEFAULT_RETRY_BACKOFF_BASE = _chunkZ4F6P6M4cjs.DEFAULT_RETRY_BACKOFF_BASE; exports.DEFAULT_RETRY_BACKOFF_MAX = _chunkZ4F6P6M4cjs.DEFAULT_RETRY_BACKOFF_MAX; exports.DEFAULT_STEP_TIMEOUT = _chunkZ4F6P6M4cjs.DEFAULT_STEP_TIMEOUT; exports.EntryInProgressError = _chunkZ4F6P6M4cjs.EntryInProgressError; exports.EvictedError = _chunkZ4F6P6M4cjs.EvictedError; exports.HistoryDivergedError = _chunkZ4F6P6M4cjs.HistoryDivergedError; exports.InMemoryDriver = InMemoryDriver; exports.JoinError = _chunkZ4F6P6M4cjs.JoinError; exports.Loop = _chunkZ4F6P6M4cjs.Loop; exports.MessageWaitError = _chunkZ4F6P6M4cjs.MessageWaitError; exports.RaceError = _chunkZ4F6P6M4cjs.RaceError; exports.RollbackCheckpointError = _chunkZ4F6P6M4cjs.RollbackCheckpointError; exports.RollbackError = _chunkZ4F6P6M4cjs.RollbackError; exports.SleepError = _chunkZ4F6P6M4cjs.SleepError; exports.StepExhaustedError = _chunkZ4F6P6M4cjs.StepExhaustedError; exports.StepFailedError = _chunkZ4F6P6M4cjs.StepFailedError; exports.WorkflowContextImpl = _chunkZ4F6P6M4cjs.WorkflowContextImpl; exports.appendLoopIteration = _chunkZ4F6P6M4cjs.appendLoopIteration; exports.appendName = _chunkZ4F6P6M4cjs.appendName; exports.createEntry = _chunkZ4F6P6M4cjs.createEntry; exports.createHistorySnapshot = _chunkZ4F6P6M4cjs.createHistorySnapshot; exports.createStorage = _chunkZ4F6P6M4cjs.createStorage; exports.deleteEntriesWithPrefix = _chunkZ4F6P6M4cjs.deleteEntriesWithPrefix; exports.emptyLocation = _chunkZ4F6P6M4cjs.emptyLocation; exports.extractErrorInfo = _chunkZ4F6P6M4cjs.extractErrorInfo; exports.flush = _chunkZ4F6P6M4cjs.flush; exports.generateId = _chunkZ4F6P6M4cjs.generateId; exports.getEntry = _chunkZ4F6P6M4cjs.getEntry; exports.getOrCreateMetadata = _chunkZ4F6P6M4cjs.getOrCreateMetadata; exports.isLocationPrefix = _chunkZ4F6P6M4cjs.isLocationPrefix; exports.isLoopIterationMarker = _chunkZ4F6P6M4cjs.isLoopIterationMarker; exports.loadMetadata = _chunkZ4F6P6M4cjs.loadMetadata; exports.loadStorage = _chunkZ4F6P6M4cjs.loadStorage; exports.locationToKey = _chunkZ4F6P6M4cjs.locationToKey; exports.locationsEqual = _chunkZ4F6P6M4cjs.locationsEqual; exports.parentLocation = _chunkZ4F6P6M4cjs.parentLocation; exports.registerName = _chunkZ4F6P6M4cjs.registerName; exports.replayWorkflowFromStep = _chunkZ4F6P6M4cjs.replayWorkflowFromStep; exports.resolveName = _chunkZ4F6P6M4cjs.resolveName; exports.runWorkflow = _chunkZ4F6P6M4cjs.runWorkflow; exports.setEntry = _chunkZ4F6P6M4cjs.setEntry;
334
334
  //# sourceMappingURL=testing.cjs.map
@@ -47,7 +47,7 @@ import {
47
47
  runWorkflow,
48
48
  setEntry,
49
49
  sleep
50
- } from "./chunk-JMOI2OHA.js";
50
+ } from "./chunk-NIKZ2NOQ.js";
51
51
 
52
52
  // src/testing.ts
53
53
  var InMemoryWorkflowMessageDriver = class {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rivetkit/workflow-engine",
3
- "version": "3.0.6",
3
+ "version": "3.0.7",
4
4
  "description": "Durable workflow engine with reentrant execution",
5
5
  "license": "Apache-2.0",
6
6
  "keywords": [