@rotorsoft/act 0.42.0 → 0.43.0

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.
@@ -3831,7 +3831,7 @@ function manageArtifactAttachment(attachment) {
3831
3831
  }
3832
3832
  }
3833
3833
 
3834
- // ../../node_modules/.pnpm/vite@7.3.3_@types+node@25.7.0_jiti@2.6.1_lightningcss@1.32.0_terser@5.46.1_tsx@4.21.0_yaml@2.9.0/node_modules/vite/dist/node/module-runner.js
3834
+ // ../../node_modules/.pnpm/vite@7.3.3_@types+node@25.7.0_jiti@2.6.1_lightningcss@1.32.0_terser@5.46.1_tsx@4.22.0_yaml@2.9.0/node_modules/vite/dist/node/module-runner.js
3835
3835
  var SOURCEMAPPING_URL = "sourceMa";
3836
3836
  SOURCEMAPPING_URL += "ppingURL";
3837
3837
  var isWindows = typeof process < "u" && process.platform === "win32";
@@ -3876,7 +3876,7 @@ var envProxy = new Proxy({}, { get(_, p) {
3876
3876
  throw Error(`[module runner] Dynamic access of "import.meta.env" is not supported. Please, use "import.meta.env.${String(p)}" instead.`);
3877
3877
  } });
3878
3878
 
3879
- // ../../node_modules/.pnpm/vitest@4.1.6_@opentelemetry+api@1.9.0_@types+node@25.7.0_@vitest+coverage-v8@4.1.6_vite_582ee6038b40d7e1fe3c73876076a024/node_modules/vitest/dist/index.js
3879
+ // ../../node_modules/.pnpm/vitest@4.1.6_@opentelemetry+api@1.9.0_@types+node@25.7.0_@vitest+coverage-v8@4.1.6_vite_e55bbfcaf248f5e226d3dcf8ee1c3ee4/node_modules/vitest/dist/index.js
3880
3880
  var import_expect_type = __toESM(require_dist(), 1);
3881
3881
 
3882
3882
  // src/internal/lru-map.ts
@@ -4076,7 +4076,8 @@ var Errors = {
4076
4076
  ValidationError: "ERR_VALIDATION",
4077
4077
  InvariantError: "ERR_INVARIANT",
4078
4078
  ConcurrencyError: "ERR_CONCURRENCY",
4079
- StreamClosedError: "ERR_STREAM_CLOSED"
4079
+ StreamClosedError: "ERR_STREAM_CLOSED",
4080
+ NonRetryableError: "ERR_NON_RETRYABLE"
4080
4081
  };
4081
4082
  var ValidationError = class extends Error {
4082
4083
  constructor(target, payload, details) {
@@ -4392,6 +4393,20 @@ var InMemoryStream = class {
4392
4393
  this._leased_by = void 0;
4393
4394
  this._leased_until = void 0;
4394
4395
  }
4396
+ /**
4397
+ * Clear the blocked flag and lease bookkeeping without touching the
4398
+ * watermark. Returns true if the stream was actually blocked (and is
4399
+ * now flipped); false otherwise.
4400
+ */
4401
+ unblock() {
4402
+ if (!this._blocked) return false;
4403
+ this._blocked = false;
4404
+ this._retry = -1;
4405
+ this._error = "";
4406
+ this._leased_by = void 0;
4407
+ this._leased_until = void 0;
4408
+ return true;
4409
+ }
4395
4410
  };
4396
4411
  var InMemoryStore = class {
4397
4412
  // stored events
@@ -4627,19 +4642,81 @@ var InMemoryStore = class {
4627
4642
  return leases.map((l) => this._streams.get(l.stream)?.block(l, l.error)).filter((l) => !!l);
4628
4643
  }
4629
4644
  /**
4630
- * Reset watermarks for the given streams to -1, clearing retry, blocked,
4631
- * error, and lease state so they can be replayed from the beginning.
4632
- * @param streams - Stream names to reset.
4645
+ * Build a predicate from a {@link StreamFilter}. Compiled regexes are
4646
+ * cached in the closure so callers can apply it across the streams
4647
+ * map without re-compiling per iteration.
4648
+ */
4649
+ _filterPredicate(filter) {
4650
+ const streamRe = filter.stream && !filter.stream_exact ? new RegExp(filter.stream) : void 0;
4651
+ const sourceRe = filter.source && !filter.source_exact ? new RegExp(filter.source) : void 0;
4652
+ return (s) => {
4653
+ if (filter.stream !== void 0) {
4654
+ if (filter.stream_exact ? s.stream !== filter.stream : !streamRe.test(s.stream))
4655
+ return false;
4656
+ }
4657
+ if (filter.source !== void 0) {
4658
+ if (s.source === void 0) return false;
4659
+ if (filter.source_exact ? s.source !== filter.source : !sourceRe.test(s.source))
4660
+ return false;
4661
+ }
4662
+ if (filter.blocked !== void 0 && s.blocked !== filter.blocked)
4663
+ return false;
4664
+ return true;
4665
+ };
4666
+ }
4667
+ /**
4668
+ * Reset watermarks to -1, clearing retry, blocked, error, and lease
4669
+ * state so the matched streams can be replayed from the beginning.
4670
+ * Accepts either an explicit list of names or a {@link StreamFilter}.
4671
+ *
4672
+ * @param input - Stream names or a filter selecting the streams to reset.
4633
4673
  * @returns Count of streams that were actually reset.
4634
4674
  */
4635
- async reset(streams) {
4675
+ async reset(input) {
4636
4676
  await sleep();
4637
4677
  let count = 0;
4638
- for (const name of streams) {
4639
- const s = this._streams.get(name);
4640
- if (s) {
4641
- s.reset();
4642
- count++;
4678
+ if (Array.isArray(input)) {
4679
+ for (const name of input) {
4680
+ const s = this._streams.get(name);
4681
+ if (s) {
4682
+ s.reset();
4683
+ count++;
4684
+ }
4685
+ }
4686
+ } else {
4687
+ const matches = this._filterPredicate(input);
4688
+ for (const s of this._streams.values()) {
4689
+ if (matches(s)) {
4690
+ s.reset();
4691
+ count++;
4692
+ }
4693
+ }
4694
+ }
4695
+ return count;
4696
+ }
4697
+ /**
4698
+ * Clear the blocked flag (and retry / error / lease) on the matched
4699
+ * streams without touching the watermark. Streams that aren't blocked
4700
+ * at call time are silently skipped. Accepts either an explicit list
4701
+ * of names or a {@link StreamFilter}. The filter form always restricts
4702
+ * to blocked streams — passing `blocked: false` matches nothing.
4703
+ * See {@link Store.unblock}.
4704
+ *
4705
+ * @param input - Stream names or a filter selecting the streams to unblock.
4706
+ * @returns Count of streams that were actually flipped (were blocked).
4707
+ */
4708
+ async unblock(input) {
4709
+ await sleep();
4710
+ let count = 0;
4711
+ if (Array.isArray(input)) {
4712
+ for (const name of input) {
4713
+ const s = this._streams.get(name);
4714
+ if (s?.unblock()) count++;
4715
+ }
4716
+ } else {
4717
+ const matches = this._filterPredicate({ ...input, blocked: true });
4718
+ for (const s of this._streams.values()) {
4719
+ if (matches(s) && s.unblock()) count++;
4643
4720
  }
4644
4721
  }
4645
4722
  return count;
@@ -4655,21 +4732,10 @@ var InMemoryStore = class {
4655
4732
  */
4656
4733
  async prioritize(filter, priority) {
4657
4734
  await sleep();
4658
- const streamRe = filter.stream && !filter.stream_exact ? new RegExp(filter.stream) : void 0;
4659
- const sourceRe = filter.source && !filter.source_exact ? new RegExp(filter.source) : void 0;
4735
+ const matches = this._filterPredicate(filter);
4660
4736
  let count = 0;
4661
4737
  for (const s of this._streams.values()) {
4662
- if (filter.stream !== void 0) {
4663
- if (filter.stream_exact ? s.stream !== filter.stream : !streamRe.test(s.stream))
4664
- continue;
4665
- }
4666
- if (filter.source !== void 0) {
4667
- if (s.source === void 0) continue;
4668
- if (filter.source_exact ? s.source !== filter.source : !sourceRe.test(s.source))
4669
- continue;
4670
- }
4671
- if (filter.blocked !== void 0 && s.blocked !== filter.blocked)
4672
- continue;
4738
+ if (!matches(s)) continue;
4673
4739
  if (s.priority !== priority) {
4674
4740
  s.setPriority(priority);
4675
4741
  count++;