@githolon/dsl 0.58.0 → 0.59.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.
package/src/law_check.ts CHANGED
@@ -379,6 +379,12 @@ function unreadPayloadFindings(domain: string, dir: Directive<unknown>, probe: P
379
379
  const objectFromField = (dir as { requiresRelationGate?: { objectFrom?: { idField?: string } } })
380
380
  .requiresRelationGate?.objectFrom?.idField;
381
381
  if (typeof objectFromField === "string") gateConsumed.add(objectFromField);
382
+ // A dynamic .readsFrom(fromPayload("<wsField>"), …) edge routes the foreign read by a payload field the
383
+ // ROUTING lane consumes (the plan may pass it straight to read(…, {from}) without a tracked property
384
+ // read on the sampled path) — a declared trust-edge field is never a dead field.
385
+ for (const e of (dir as { declaredForeignReads?: ForeignReadEdge[] }).declaredForeignReads ?? []) {
386
+ if ("fromPayload" in e && typeof e.fromPayload === "string") gateConsumed.add(e.fromPayload);
387
+ }
382
388
  const out: Finding[] = [];
383
389
  for (const f of requiredPayloadFields(dir.payloadSchema as z.ZodTypeAny)) {
384
390
  if (probe.readFields.has(f)) continue;
File without changes
File without changes
File without changes
File without changes
File without changes