@rotorsoft/act 1.37.2 → 1.37.3

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.
@@ -1,26 +1,13 @@
1
1
  /**
2
- * The sensitive-data marker: the registry `sensitive(zodType)` writes to,
3
- * and the lookups that read it. The public `sensitive()` and the two
4
- * sentinels live in `types/schemas.ts`, which re-exports `pii_fields` from
5
- * here. The transforms that apply the marker at commit, load and dispatch
6
- * live in `internal/pii.ts`.
2
+ * The sensitive-data marker: the symbol `sensitive(zodType)` stamps on a
3
+ * schema's definition, and the lookups that read it. The public
4
+ * `sensitive()` and the two sentinels live in `types/schemas.ts`, which
5
+ * re-exports `pii_fields` from here. The transforms that apply the marker at
6
+ * commit, load and dispatch live in `internal/pii.ts`.
7
7
  */
8
- import { z } from "zod";
8
+ import type { z } from "zod";
9
9
  /**
10
- * Process-global registry holding every Zod schema marked sensitive. Backed
11
- * by a `WeakMap`, so wrapper-created instances (`.optional()`, `.nullable()`,
12
- * `.default()`) that chain off a marked schema produce *new* schema instances
13
- * the registry doesn't track; the field walker handles those via unwrap.
14
- *
15
- * Exported so the public `sensitive(zodType)` wrapper can call `_registry.add`.
16
- * Underscore prefix marks "framework-private, don't touch from user code."
17
- */
18
- export declare const _registry: z.core.$ZodRegistry<{
19
- sensitive: true;
20
- }, z.core.$ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
21
- /**
22
- * Stamp the def-level marker. Called by the public `sensitive()` alongside
23
- * `_registry.add`.
10
+ * Stamp the def-level marker. Called by the public `sensitive()`.
24
11
  */
25
12
  export declare function _mark_sensitive(schema: z.ZodType): void;
26
13
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"sensitive.d.ts","sourceRoot":"","sources":["../../src/sensitive.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;GAQG;AACH,eAAO,MAAM,SAAS;eAA2B,IAAI;iFAAK,CAAC;AAe3D;;;GAGG;AACH,wBAAgB,eAAe,CAAC,MAAM,EAAE,CAAC,CAAC,OAAO,GAAG,IAAI,CAOvD;AAkCD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,CAAC,CAAC,OAAO,GAAG,MAAM,CAAC,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,CAmBxE;AAED;;;;;GAKG;AACH,wBAAgB,UAAU,CAAC,MAAM,EAAE,CAAC,CAAC,OAAO,GAAG,SAAS,MAAM,EAAE,CAE/D"}
1
+ {"version":3,"file":"sensitive.d.ts","sourceRoot":"","sources":["../../src/sensitive.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAY7B;;GAEG;AACH,wBAAgB,eAAe,CAAC,MAAM,EAAE,CAAC,CAAC,OAAO,GAAG,IAAI,CAOvD;AA+BD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,CAAC,CAAC,OAAO,GAAG,MAAM,CAAC,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,CAmBxE;AAED;;;;;GAKG;AACH,wBAAgB,UAAU,CAAC,MAAM,EAAE,CAAC,CAAC,OAAO,GAAG,SAAS,MAAM,EAAE,CAE/D"}
@@ -25,8 +25,9 @@ export declare const REDACTED: "[REDACTED]";
25
25
  export declare const SHREDDED: "[SHREDDED]";
26
26
  /**
27
27
  * Mark a Zod schema as sensitive. Returns the same schema instance — the
28
- * marker is registered out-of-band so the static type is preserved and the
29
- * call site reads as a pure annotation.
28
+ * marker is stamped on the schema's definition, so the static type is
29
+ * preserved, the call site reads as a pure annotation, and the marker
30
+ * survives any refinement chained after the call.
30
31
  *
31
32
  * Idempotent: re-wrapping an already-sensitive schema is a no-op.
32
33
  *
@@ -1 +1 @@
1
- {"version":3,"file":"schemas.d.ts","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C"}
@@ -6,7 +6,7 @@
6
6
 
7
7
 
8
8
 
9
- var _chunkJ6G7UKZAcjs = require('./chunk-J6G7UKZA.cjs');
9
+ var _chunkTCADE3WYcjs = require('./chunk-TCADE3WY.cjs');
10
10
 
11
11
  // src/adapters/console-logger.ts
12
12
  var LEVEL_VALUES = {
@@ -350,9 +350,9 @@ var validate = (target, payload, schema) => {
350
350
  return schema ? schema.parse(payload) : payload;
351
351
  } catch (error) {
352
352
  if (error instanceof _zod.ZodError) {
353
- throw new (0, _chunkJ6G7UKZAcjs.ValidationError)(target, payload, _zod.prettifyError.call(void 0, error));
353
+ throw new (0, _chunkTCADE3WYcjs.ValidationError)(target, payload, _zod.prettifyError.call(void 0, error));
354
354
  }
355
- throw new (0, _chunkJ6G7UKZAcjs.ValidationError)(target, payload, error);
355
+ throw new (0, _chunkTCADE3WYcjs.ValidationError)(target, payload, error);
356
356
  }
357
357
  };
358
358
  var extend = (source, schema, target) => {
@@ -385,7 +385,7 @@ var InMemoryStream = (_class2 = class {
385
385
  __init8() {this._deferred_at = void 0}
386
386
  // Work mark; `undefined` = never correlated, so `claim` skips it.
387
387
  __init9() {this._correlated_at = void 0}
388
- constructor(stream, source, priority = 0, lane = _chunkJ6G7UKZAcjs.DEFAULT_LANE) {;_class2.prototype.__init2.call(this);_class2.prototype.__init3.call(this);_class2.prototype.__init4.call(this);_class2.prototype.__init5.call(this);_class2.prototype.__init6.call(this);_class2.prototype.__init7.call(this);_class2.prototype.__init8.call(this);_class2.prototype.__init9.call(this);
388
+ constructor(stream, source, priority = 0, lane = _chunkTCADE3WYcjs.DEFAULT_LANE) {;_class2.prototype.__init2.call(this);_class2.prototype.__init3.call(this);_class2.prototype.__init4.call(this);_class2.prototype.__init5.call(this);_class2.prototype.__init6.call(this);_class2.prototype.__init7.call(this);_class2.prototype.__init8.call(this);_class2.prototype.__init9.call(this);
389
389
  this.stream = stream;
390
390
  this.source = source;
391
391
  this._priority = priority;
@@ -582,7 +582,7 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
582
582
  if (query.names && !query.names.includes(e.name)) return false;
583
583
  if (query.correlation && _optionalChain([e, 'access', _8 => _8.meta, 'optionalAccess', _9 => _9.correlation]) !== query.correlation)
584
584
  return false;
585
- if (e.name === _chunkJ6G7UKZAcjs.SNAP_EVENT && !query.with_snaps) return false;
585
+ if (e.name === _chunkTCADE3WYcjs.SNAP_EVENT && !query.with_snaps) return false;
586
586
  if (query.created_after && e.created <= query.created_after) return false;
587
587
  if (query.created_before && e.created >= query.created_before)
588
588
  return false;
@@ -595,7 +595,7 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
595
595
  return -1;
596
596
  for (let j = this._events.length - 1; j >= 0; j--) {
597
597
  const e = this._events[j];
598
- if (e.stream === query.stream && e.name === _chunkJ6G7UKZAcjs.SNAP_EVENT) return j;
598
+ if (e.stream === query.stream && e.name === _chunkTCADE3WYcjs.SNAP_EVENT) return j;
599
599
  }
600
600
  return -1;
601
601
  }
@@ -622,7 +622,7 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
622
622
  await sleep();
623
623
  const current_version = _nullishCoalesce(this._stream_versions.get(stream), () => ( -1));
624
624
  if (typeof expectedVersion === "number" && current_version !== expectedVersion) {
625
- throw new (0, _chunkJ6G7UKZAcjs.ConcurrencyError)(
625
+ throw new (0, _chunkTCADE3WYcjs.ConcurrencyError)(
626
626
  stream,
627
627
  current_version,
628
628
  msgs,
@@ -713,7 +713,7 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
713
713
  stream,
714
714
  source,
715
715
  priority = 0,
716
- lane = _chunkJ6G7UKZAcjs.DEFAULT_LANE,
716
+ lane = _chunkTCADE3WYcjs.DEFAULT_LANE,
717
717
  correlated_at: correlated_at2
718
718
  } of streams) {
719
719
  const existing = this._streams.get(stream);
@@ -897,7 +897,7 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
897
897
  for (const { stream, before, max_id } of windowed) {
898
898
  let boundary;
899
899
  for (const e of this._events) {
900
- if (e.stream === stream && e.name === _chunkJ6G7UKZAcjs.SNAP_EVENT && e.created < before && (max_id === void 0 || e.id <= max_id) && (!boundary || e.id > boundary.id))
900
+ if (e.stream === stream && e.name === _chunkTCADE3WYcjs.SNAP_EVENT && e.created < before && (max_id === void 0 || e.id <= max_id) && (!boundary || e.id > boundary.id))
901
901
  boundary = e;
902
902
  }
903
903
  if (!boundary) continue;
@@ -926,7 +926,7 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
926
926
  stream,
927
927
  version: 0,
928
928
  created: /* @__PURE__ */ new Date(),
929
- name: snapshot !== void 0 ? _chunkJ6G7UKZAcjs.SNAP_EVENT : _chunkJ6G7UKZAcjs.TOMBSTONE_EVENT,
929
+ name: snapshot !== void 0 ? _chunkTCADE3WYcjs.SNAP_EVENT : _chunkTCADE3WYcjs.TOMBSTONE_EVENT,
930
930
  data: _nullishCoalesce(snapshot, () => ( {})),
931
931
  meta: _nullishCoalesce(meta, () => ( { correlation: "", causation: {} }))
932
932
  };
@@ -1131,8 +1131,8 @@ var get_package = () => {
1131
1131
  };
1132
1132
  var pkg_load_error;
1133
1133
  var BaseSchema = PackageSchema.extend({
1134
- env: _zod.z.enum(_chunkJ6G7UKZAcjs.Environments),
1135
- logLevel: _zod.z.enum(_chunkJ6G7UKZAcjs.LogLevels),
1134
+ env: _zod.z.enum(_chunkTCADE3WYcjs.Environments),
1135
+ logLevel: _zod.z.enum(_chunkTCADE3WYcjs.LogLevels),
1136
1136
  logSingleLine: _zod.z.boolean(),
1137
1137
  sleepMs: _zod.z.number().int().min(0).max(5e3)
1138
1138
  });
@@ -1206,4 +1206,4 @@ function resolveAutocloseConfig2(options) {
1206
1206
 
1207
1207
 
1208
1208
  exports.ConsoleLogger = ConsoleLogger; exports.LruMap = LruMap; exports.InMemoryCache = InMemoryCache; exports.DEFAULT_BACKOFF = DEFAULT_BACKOFF; exports.DEFAULT_MAX_RETRIES = DEFAULT_MAX_RETRIES; exports.DEFAULT_BLOCK_ON_ERROR = DEFAULT_BLOCK_ON_ERROR; exports.resolveReactionConfig = resolveReactionConfig; exports.resolveActionConfig = resolveActionConfig; exports.resolveLaneConfig = resolveLaneConfig; exports.DEFAULT_STREAM_LIMIT = DEFAULT_STREAM_LIMIT; exports.DEFAULT_EVENT_LIMIT = DEFAULT_EVENT_LIMIT; exports.DEFAULT_LEASE_MILLIS = DEFAULT_LEASE_MILLIS; exports.resolveDrainConfig = resolveDrainConfig; exports.resolveSettleConfig = resolveSettleConfig; exports.MAX_SHUTDOWN_GRACE_MS = MAX_SHUTDOWN_GRACE_MS; exports.resolveShutdownConfig = resolveShutdownConfig; exports.resolveActConfig = resolveActConfig; exports.resolveAutocloseConfig = resolveAutocloseConfig; exports.resolveCircuitBreakerConfig = resolveCircuitBreakerConfig; exports.resolveFoldConfig = resolveFoldConfig; exports.PackageSchema = PackageSchema; exports.config = config; exports.resolveAutocloseConfig2 = resolveAutocloseConfig2; exports.validate = validate; exports.extend = extend; exports.sleep = sleep; exports.is_literal_source = is_literal_source; exports.dateReviver = dateReviver; exports.InMemoryStore = InMemoryStore; exports.register_weak_disposer = register_weak_disposer; exports.make_run_scoped = make_run_scoped; exports.current_autoclose_window = current_autoclose_window; exports.current_reacting = current_reacting; exports.make_reaction_scope = make_reaction_scope; exports.port = port; exports.log = log; exports.store = store2; exports.cache = cache2; exports.default_scope = default_scope; exports.disposeAndExit = disposeAndExit; exports.dispose = dispose;
1209
- //# sourceMappingURL=chunk-5OU5CTJZ.cjs.map
1209
+ //# sourceMappingURL=chunk-BYTYS2LB.cjs.map