@riddledc/riddle-proof 0.7.153 → 0.7.155

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.
@@ -480,6 +480,8 @@ function profileSetupWindowCallReceipts(results) {
480
480
  };
481
481
  if (result.returned !== void 0) receipt.returned = result.returned;
482
482
  if (result.expected_return !== void 0) receipt.expected_return = result.expected_return;
483
+ const returnSummary = profileSetupReturnSummary(result);
484
+ if (returnSummary.length) receipt.return_summary = returnSummary;
483
485
  return receipt;
484
486
  });
485
487
  }
@@ -495,6 +497,40 @@ function profileSetupWindowEvalReceipts(results) {
495
497
  };
496
498
  if (result.returned !== void 0) receipt.returned = result.returned;
497
499
  if (result.expected_return !== void 0) receipt.expected_return = result.expected_return;
500
+ const returnSummary = profileSetupReturnSummary(result);
501
+ if (returnSummary.length) receipt.return_summary = returnSummary;
502
+ return receipt;
503
+ });
504
+ }
505
+ function profileSetupReturnSummaryFields(result) {
506
+ const input = result.return_summary_fields;
507
+ if (!Array.isArray(input)) return [];
508
+ const fields = [];
509
+ for (const item of input) {
510
+ if (typeof item === "string") {
511
+ const path2 = item.trim();
512
+ if (path2) fields.push({ path: path2 });
513
+ continue;
514
+ }
515
+ if (!isRecord(item)) continue;
516
+ const path = stringValue(item.path) ?? stringValue(item.key) ?? stringValue(item.json_path) ?? stringValue(item.jsonPath);
517
+ if (!path) continue;
518
+ const label = stringValue(item.label) ?? stringValue(item.name) ?? stringValue(item.title);
519
+ fields.push(label ? { path, label } : { path });
520
+ }
521
+ return fields;
522
+ }
523
+ function profileSetupReturnSummary(result) {
524
+ if (result.returned === void 0) return [];
525
+ return profileSetupReturnSummaryFields(result).map((field) => {
526
+ const resolved = resolveJsonPath(result.returned, field.path);
527
+ const receipt = {
528
+ label: field.label || field.path,
529
+ path: field.path,
530
+ exists: resolved.exists
531
+ };
532
+ if (resolved.exists) receipt.value = toJsonValue(resolved.value);
533
+ if (resolved.error) receipt.reason = resolved.error;
498
534
  return receipt;
499
535
  });
500
536
  }
@@ -683,6 +719,37 @@ function normalizeSetupActionArgs(input, index) {
683
719
  }
684
720
  return argsInput.map(toJsonValue);
685
721
  }
722
+ function normalizeReturnSummaryFields(input, index) {
723
+ const fieldsInput = valueFromOwn(
724
+ input,
725
+ "return_summary_fields",
726
+ "returnSummaryFields",
727
+ "summary_fields",
728
+ "summaryFields",
729
+ "receipt_fields",
730
+ "receiptFields",
731
+ "return_receipt_fields",
732
+ "returnReceiptFields"
733
+ );
734
+ if (fieldsInput === void 0) return void 0;
735
+ if (!Array.isArray(fieldsInput)) {
736
+ throw new Error(`target.setup_actions[${index}].return_summary_fields must be an array.`);
737
+ }
738
+ return fieldsInput.map((field, fieldIndex) => {
739
+ if (typeof field === "string") {
740
+ const path2 = field.trim();
741
+ if (!path2) throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] requires path.`);
742
+ return { path: path2 };
743
+ }
744
+ if (!isRecord(field)) {
745
+ throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] must be a string path or object.`);
746
+ }
747
+ const path = stringFromOwn(field, "path", "key", "json_path", "jsonPath");
748
+ if (!path) throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] requires path.`);
749
+ const label = stringFromOwn(field, "label", "name", "title");
750
+ return label ? { path, label } : { path };
751
+ });
752
+ }
686
753
  function normalizeSetupActionRepeat(input, index) {
687
754
  const repeat = numberValue(valueFromOwn(input, "repeat", "repeat_count", "repeatCount", "times"));
688
755
  if (repeat === void 0) return void 0;
@@ -904,6 +971,7 @@ function normalizeSetupAction(input, index) {
904
971
  expect_return: hasExpectedReturn ? toJsonValue(valueFromOwn(input, "expect_return", "expectReturn", "expected_return", "expectedReturn")) : void 0,
905
972
  store_return_to: storeReturnTo,
906
973
  capture_return: captureReturn,
974
+ return_summary_fields: normalizeReturnSummaryFields(input, index),
907
975
  until_path: untilPath,
908
976
  until_expected_value: hasUntilExpectedValue ? toJsonValue(valueFromOwn(input, "until_expected_value", "untilExpectedValue", "until_expected", "untilExpected", "until_value", "untilValue", "expected_value", "expectedValue", "expected")) : void 0,
909
977
  max_calls: maxCalls,
@@ -3942,6 +4010,8 @@ function profileSetupWindowCallReceipts(results) {
3942
4010
  };
3943
4011
  if (result.returned !== undefined) receipt.returned = result.returned;
3944
4012
  if (result.expected_return !== undefined) receipt.expected_return = result.expected_return;
4013
+ const returnSummary = profileSetupReturnSummary(result);
4014
+ if (returnSummary.length) receipt.return_summary = returnSummary;
3945
4015
  return receipt;
3946
4016
  });
3947
4017
  }
@@ -3959,9 +4029,43 @@ function profileSetupWindowEvalReceipts(results) {
3959
4029
  };
3960
4030
  if (result.returned !== undefined) receipt.returned = result.returned;
3961
4031
  if (result.expected_return !== undefined) receipt.expected_return = result.expected_return;
4032
+ const returnSummary = profileSetupReturnSummary(result);
4033
+ if (returnSummary.length) receipt.return_summary = returnSummary;
3962
4034
  return receipt;
3963
4035
  });
3964
4036
  }
4037
+ function profileSetupReturnSummaryFields(result) {
4038
+ const input = result && result.return_summary_fields;
4039
+ if (!Array.isArray(input)) return [];
4040
+ const fields = [];
4041
+ for (const item of input) {
4042
+ if (typeof item === "string") {
4043
+ const path = item.trim();
4044
+ if (path) fields.push({ path });
4045
+ continue;
4046
+ }
4047
+ if (!item || typeof item !== "object" || Array.isArray(item)) continue;
4048
+ const path = String(item.path || item.key || item.json_path || item.jsonPath || "").trim();
4049
+ if (!path) continue;
4050
+ const label = String(item.label || item.name || item.title || "").trim();
4051
+ fields.push(label ? { path, label } : { path });
4052
+ }
4053
+ return fields;
4054
+ }
4055
+ function profileSetupReturnSummary(result) {
4056
+ if (!result || result.returned === undefined) return [];
4057
+ return profileSetupReturnSummaryFields(result).map((field) => {
4058
+ const resolved = resolveJsonProbePath(result.returned, field.path);
4059
+ const receipt = {
4060
+ label: field.label || field.path,
4061
+ path: field.path,
4062
+ exists: Boolean(resolved.exists),
4063
+ };
4064
+ if (resolved.exists) receipt.value = setupJsonValue(resolved.value);
4065
+ if (resolved.error) receipt.reason = resolved.error;
4066
+ return receipt;
4067
+ });
4068
+ }
3965
4069
  function profileSetupRangeValueReceipts(results) {
3966
4070
  return (results || [])
3967
4071
  .filter((result) => result && profileSetupResultAction(result) === "set_range_value")
@@ -5696,6 +5800,7 @@ async function executeSetupAction(action, ordinal, viewport) {
5696
5800
  const script = String(action.script || action.code || action.source || action.body || "");
5697
5801
  const args = Array.isArray(action.args) ? action.args : [];
5698
5802
  const storeReturnTo = String(action.store_return_to || action.storeReturnTo || action.save_return_to || action.saveReturnTo || action.assign_return_to || action.assignReturnTo || action.return_state_path || action.returnStatePath || "").trim();
5803
+ const returnSummaryFields = Array.isArray(action.return_summary_fields) ? action.return_summary_fields : [];
5699
5804
  if (!script.trim()) return { ...base, reason: "missing_script" };
5700
5805
  const scope = await setupActionScope(action, timeout);
5701
5806
  if (!scope.ok) return setupScopeFailure(base, scope);
@@ -5725,6 +5830,7 @@ async function executeSetupAction(action, ordinal, viewport) {
5725
5830
  return_captured: captureReturn,
5726
5831
  expected_return: hasExpectation ? setupJsonValue(expected) : undefined,
5727
5832
  return_stored_to: result.return_stored_to || storeReturnTo || undefined,
5833
+ return_summary_fields: returnSummaryFields.length ? setupJsonValue(returnSummaryFields) : undefined,
5728
5834
  reason: result.ok ? (expectationMet ? undefined : "unexpected_return_value") : result.reason,
5729
5835
  store_reason: result.store_reason || undefined,
5730
5836
  error: result.error || undefined,
@@ -5734,6 +5840,7 @@ async function executeSetupAction(action, ordinal, viewport) {
5734
5840
  const path = String(action.path || action.function_path || action.functionPath || "");
5735
5841
  const args = Array.isArray(action.args) ? action.args : [];
5736
5842
  const storeReturnTo = String(action.store_return_to || action.storeReturnTo || action.save_return_to || action.saveReturnTo || action.assign_return_to || action.assignReturnTo || action.return_state_path || action.returnStatePath || "").trim();
5843
+ const returnSummaryFields = Array.isArray(action.return_summary_fields) ? action.return_summary_fields : [];
5737
5844
  if (!path) return { ...base, path, reason: "missing_path" };
5738
5845
  const scope = await setupActionScope(action, timeout);
5739
5846
  if (!scope.ok) return setupScopeFailure(base, scope);
@@ -5763,6 +5870,7 @@ async function executeSetupAction(action, ordinal, viewport) {
5763
5870
  return_captured: captureReturn,
5764
5871
  expected_return: hasExpectation ? setupJsonValue(expected) : undefined,
5765
5872
  return_stored_to: result.return_stored_to || storeReturnTo || undefined,
5873
+ return_summary_fields: returnSummaryFields.length ? setupJsonValue(returnSummaryFields) : undefined,
5766
5874
  reason: result.ok ? (expectationMet ? undefined : "unexpected_return_value") : result.reason,
5767
5875
  store_reason: result.store_reason || undefined,
5768
5876
  error: result.error || undefined,
package/dist/cli.cjs CHANGED
@@ -7437,6 +7437,8 @@ function profileSetupWindowCallReceipts(results) {
7437
7437
  };
7438
7438
  if (result.returned !== void 0) receipt.returned = result.returned;
7439
7439
  if (result.expected_return !== void 0) receipt.expected_return = result.expected_return;
7440
+ const returnSummary = profileSetupReturnSummary(result);
7441
+ if (returnSummary.length) receipt.return_summary = returnSummary;
7440
7442
  return receipt;
7441
7443
  });
7442
7444
  }
@@ -7452,6 +7454,40 @@ function profileSetupWindowEvalReceipts(results) {
7452
7454
  };
7453
7455
  if (result.returned !== void 0) receipt.returned = result.returned;
7454
7456
  if (result.expected_return !== void 0) receipt.expected_return = result.expected_return;
7457
+ const returnSummary = profileSetupReturnSummary(result);
7458
+ if (returnSummary.length) receipt.return_summary = returnSummary;
7459
+ return receipt;
7460
+ });
7461
+ }
7462
+ function profileSetupReturnSummaryFields(result) {
7463
+ const input = result.return_summary_fields;
7464
+ if (!Array.isArray(input)) return [];
7465
+ const fields = [];
7466
+ for (const item of input) {
7467
+ if (typeof item === "string") {
7468
+ const path8 = item.trim();
7469
+ if (path8) fields.push({ path: path8 });
7470
+ continue;
7471
+ }
7472
+ if (!isRecord(item)) continue;
7473
+ const path7 = stringValue2(item.path) ?? stringValue2(item.key) ?? stringValue2(item.json_path) ?? stringValue2(item.jsonPath);
7474
+ if (!path7) continue;
7475
+ const label = stringValue2(item.label) ?? stringValue2(item.name) ?? stringValue2(item.title);
7476
+ fields.push(label ? { path: path7, label } : { path: path7 });
7477
+ }
7478
+ return fields;
7479
+ }
7480
+ function profileSetupReturnSummary(result) {
7481
+ if (result.returned === void 0) return [];
7482
+ return profileSetupReturnSummaryFields(result).map((field) => {
7483
+ const resolved = resolveJsonPath(result.returned, field.path);
7484
+ const receipt = {
7485
+ label: field.label || field.path,
7486
+ path: field.path,
7487
+ exists: resolved.exists
7488
+ };
7489
+ if (resolved.exists) receipt.value = toJsonValue(resolved.value);
7490
+ if (resolved.error) receipt.reason = resolved.error;
7455
7491
  return receipt;
7456
7492
  });
7457
7493
  }
@@ -7640,6 +7676,37 @@ function normalizeSetupActionArgs(input, index) {
7640
7676
  }
7641
7677
  return argsInput.map(toJsonValue);
7642
7678
  }
7679
+ function normalizeReturnSummaryFields(input, index) {
7680
+ const fieldsInput = valueFromOwn(
7681
+ input,
7682
+ "return_summary_fields",
7683
+ "returnSummaryFields",
7684
+ "summary_fields",
7685
+ "summaryFields",
7686
+ "receipt_fields",
7687
+ "receiptFields",
7688
+ "return_receipt_fields",
7689
+ "returnReceiptFields"
7690
+ );
7691
+ if (fieldsInput === void 0) return void 0;
7692
+ if (!Array.isArray(fieldsInput)) {
7693
+ throw new Error(`target.setup_actions[${index}].return_summary_fields must be an array.`);
7694
+ }
7695
+ return fieldsInput.map((field, fieldIndex) => {
7696
+ if (typeof field === "string") {
7697
+ const path8 = field.trim();
7698
+ if (!path8) throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] requires path.`);
7699
+ return { path: path8 };
7700
+ }
7701
+ if (!isRecord(field)) {
7702
+ throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] must be a string path or object.`);
7703
+ }
7704
+ const path7 = stringFromOwn(field, "path", "key", "json_path", "jsonPath");
7705
+ if (!path7) throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] requires path.`);
7706
+ const label = stringFromOwn(field, "label", "name", "title");
7707
+ return label ? { path: path7, label } : { path: path7 };
7708
+ });
7709
+ }
7643
7710
  function normalizeSetupActionRepeat(input, index) {
7644
7711
  const repeat = numberValue(valueFromOwn(input, "repeat", "repeat_count", "repeatCount", "times"));
7645
7712
  if (repeat === void 0) return void 0;
@@ -7861,6 +7928,7 @@ function normalizeSetupAction(input, index) {
7861
7928
  expect_return: hasExpectedReturn ? toJsonValue(valueFromOwn(input, "expect_return", "expectReturn", "expected_return", "expectedReturn")) : void 0,
7862
7929
  store_return_to: storeReturnTo,
7863
7930
  capture_return: captureReturn,
7931
+ return_summary_fields: normalizeReturnSummaryFields(input, index),
7864
7932
  until_path: untilPath,
7865
7933
  until_expected_value: hasUntilExpectedValue ? toJsonValue(valueFromOwn(input, "until_expected_value", "untilExpectedValue", "until_expected", "untilExpected", "until_value", "untilValue", "expected_value", "expectedValue", "expected")) : void 0,
7866
7934
  max_calls: maxCalls,
@@ -10883,6 +10951,8 @@ function profileSetupWindowCallReceipts(results) {
10883
10951
  };
10884
10952
  if (result.returned !== undefined) receipt.returned = result.returned;
10885
10953
  if (result.expected_return !== undefined) receipt.expected_return = result.expected_return;
10954
+ const returnSummary = profileSetupReturnSummary(result);
10955
+ if (returnSummary.length) receipt.return_summary = returnSummary;
10886
10956
  return receipt;
10887
10957
  });
10888
10958
  }
@@ -10900,9 +10970,43 @@ function profileSetupWindowEvalReceipts(results) {
10900
10970
  };
10901
10971
  if (result.returned !== undefined) receipt.returned = result.returned;
10902
10972
  if (result.expected_return !== undefined) receipt.expected_return = result.expected_return;
10973
+ const returnSummary = profileSetupReturnSummary(result);
10974
+ if (returnSummary.length) receipt.return_summary = returnSummary;
10903
10975
  return receipt;
10904
10976
  });
10905
10977
  }
10978
+ function profileSetupReturnSummaryFields(result) {
10979
+ const input = result && result.return_summary_fields;
10980
+ if (!Array.isArray(input)) return [];
10981
+ const fields = [];
10982
+ for (const item of input) {
10983
+ if (typeof item === "string") {
10984
+ const path = item.trim();
10985
+ if (path) fields.push({ path });
10986
+ continue;
10987
+ }
10988
+ if (!item || typeof item !== "object" || Array.isArray(item)) continue;
10989
+ const path = String(item.path || item.key || item.json_path || item.jsonPath || "").trim();
10990
+ if (!path) continue;
10991
+ const label = String(item.label || item.name || item.title || "").trim();
10992
+ fields.push(label ? { path, label } : { path });
10993
+ }
10994
+ return fields;
10995
+ }
10996
+ function profileSetupReturnSummary(result) {
10997
+ if (!result || result.returned === undefined) return [];
10998
+ return profileSetupReturnSummaryFields(result).map((field) => {
10999
+ const resolved = resolveJsonProbePath(result.returned, field.path);
11000
+ const receipt = {
11001
+ label: field.label || field.path,
11002
+ path: field.path,
11003
+ exists: Boolean(resolved.exists),
11004
+ };
11005
+ if (resolved.exists) receipt.value = setupJsonValue(resolved.value);
11006
+ if (resolved.error) receipt.reason = resolved.error;
11007
+ return receipt;
11008
+ });
11009
+ }
10906
11010
  function profileSetupRangeValueReceipts(results) {
10907
11011
  return (results || [])
10908
11012
  .filter((result) => result && profileSetupResultAction(result) === "set_range_value")
@@ -12637,6 +12741,7 @@ async function executeSetupAction(action, ordinal, viewport) {
12637
12741
  const script = String(action.script || action.code || action.source || action.body || "");
12638
12742
  const args = Array.isArray(action.args) ? action.args : [];
12639
12743
  const storeReturnTo = String(action.store_return_to || action.storeReturnTo || action.save_return_to || action.saveReturnTo || action.assign_return_to || action.assignReturnTo || action.return_state_path || action.returnStatePath || "").trim();
12744
+ const returnSummaryFields = Array.isArray(action.return_summary_fields) ? action.return_summary_fields : [];
12640
12745
  if (!script.trim()) return { ...base, reason: "missing_script" };
12641
12746
  const scope = await setupActionScope(action, timeout);
12642
12747
  if (!scope.ok) return setupScopeFailure(base, scope);
@@ -12666,6 +12771,7 @@ async function executeSetupAction(action, ordinal, viewport) {
12666
12771
  return_captured: captureReturn,
12667
12772
  expected_return: hasExpectation ? setupJsonValue(expected) : undefined,
12668
12773
  return_stored_to: result.return_stored_to || storeReturnTo || undefined,
12774
+ return_summary_fields: returnSummaryFields.length ? setupJsonValue(returnSummaryFields) : undefined,
12669
12775
  reason: result.ok ? (expectationMet ? undefined : "unexpected_return_value") : result.reason,
12670
12776
  store_reason: result.store_reason || undefined,
12671
12777
  error: result.error || undefined,
@@ -12675,6 +12781,7 @@ async function executeSetupAction(action, ordinal, viewport) {
12675
12781
  const path = String(action.path || action.function_path || action.functionPath || "");
12676
12782
  const args = Array.isArray(action.args) ? action.args : [];
12677
12783
  const storeReturnTo = String(action.store_return_to || action.storeReturnTo || action.save_return_to || action.saveReturnTo || action.assign_return_to || action.assignReturnTo || action.return_state_path || action.returnStatePath || "").trim();
12784
+ const returnSummaryFields = Array.isArray(action.return_summary_fields) ? action.return_summary_fields : [];
12678
12785
  if (!path) return { ...base, path, reason: "missing_path" };
12679
12786
  const scope = await setupActionScope(action, timeout);
12680
12787
  if (!scope.ok) return setupScopeFailure(base, scope);
@@ -12704,6 +12811,7 @@ async function executeSetupAction(action, ordinal, viewport) {
12704
12811
  return_captured: captureReturn,
12705
12812
  expected_return: hasExpectation ? setupJsonValue(expected) : undefined,
12706
12813
  return_stored_to: result.return_stored_to || storeReturnTo || undefined,
12814
+ return_summary_fields: returnSummaryFields.length ? setupJsonValue(returnSummaryFields) : undefined,
12707
12815
  reason: result.ok ? (expectationMet ? undefined : "unexpected_return_value") : result.reason,
12708
12816
  store_reason: result.store_reason || undefined,
12709
12817
  error: result.error || undefined,
@@ -15276,6 +15384,42 @@ function cliValueLabel(value) {
15276
15384
  return String(value);
15277
15385
  }
15278
15386
  }
15387
+ function cliReturnSummaryLabel(value) {
15388
+ if (!Array.isArray(value)) return void 0;
15389
+ const parts = value.map(cliRecord).filter((item) => Boolean(item)).map((item) => {
15390
+ const label = cliString(item.label) || cliString(item.path) || "value";
15391
+ const observed = item.exists === false ? "missing" : cliValueLabel(item.value);
15392
+ return `${label}=${observed ?? "null"}`;
15393
+ }).filter(Boolean);
15394
+ return parts.length ? parts.join(", ") : void 0;
15395
+ }
15396
+ function balancedSetupReceiptDetails(groups, limit) {
15397
+ if (limit <= 0) return [];
15398
+ const total = groups.reduce((sum, group) => sum + group.length, 0);
15399
+ if (total <= limit) return groups.flat();
15400
+ const selected = [];
15401
+ const indexes = new Array(groups.length).fill(0);
15402
+ const nonEmptyIndexes = groups.map((group, index) => group.length ? index : -1).filter((index) => index >= 0);
15403
+ for (const index of nonEmptyIndexes) {
15404
+ if (selected.length >= limit) return selected;
15405
+ selected.push(groups[index][0]);
15406
+ indexes[index] = 1;
15407
+ }
15408
+ while (selected.length < limit) {
15409
+ let progressed = false;
15410
+ for (const index of nonEmptyIndexes) {
15411
+ const nextIndex = indexes[index];
15412
+ const next = groups[index][nextIndex];
15413
+ if (!next) continue;
15414
+ selected.push(next);
15415
+ indexes[index] = nextIndex + 1;
15416
+ progressed = true;
15417
+ if (selected.length >= limit) break;
15418
+ }
15419
+ if (!progressed) break;
15420
+ }
15421
+ return selected;
15422
+ }
15279
15423
  function cliStringArray(value) {
15280
15424
  return Array.isArray(value) ? value.filter((entry) => typeof entry === "string" && Boolean(entry.trim())) : [];
15281
15425
  }
@@ -15421,12 +15565,14 @@ function profileSetupSummaryMarkdown(result) {
15421
15565
  const observedPath = cliString(viewport.observed_path);
15422
15566
  lines.push(`- ${name}: ${ok}, ${resultCount} result(s), ${screenshotCount} setup screenshot(s), ${clicked} click(s)${clickCountActions ? `, ${clickCountActions} click_count action(s)` : ""}${rangeValueActions ? `, ${rangeValueActions} set_range_value action(s)` : ""}${windowCallActions ? `, ${windowCallActions} window_call action(s), ${windowCallStored} stored return(s), ${windowCallCaptured} captured return(s)` : ""}${windowEvalActions ? `, ${windowEvalActions} window_eval action(s), ${windowEvalStored} stored return(s), ${windowEvalCaptured} captured return(s)` : ""}${windowCallUntilActions ? `, ${windowCallUntilActions} window_call_until action(s), ${windowCallUntilCalls} call(s)` : ""}${observedPath ? `, path ${observedPath}` : ""}`);
15423
15567
  }
15424
- const rangeValueDetails = viewports.flatMap((viewport) => {
15568
+ const rangeValueGroups = viewports.map((viewport) => {
15425
15569
  const name = cliString(viewport.name) || "viewport";
15426
15570
  const receipts = Array.isArray(viewport.set_range_value) ? viewport.set_range_value.map(cliRecord).filter((item) => Boolean(item)) : [];
15427
15571
  return receipts.map((receipt) => ({ name, receipt }));
15428
15572
  });
15429
- for (const { name, receipt } of rangeValueDetails.slice(0, 12)) {
15573
+ const rangeValueDetails = rangeValueGroups.flat();
15574
+ const sampledRangeValueDetails = balancedSetupReceiptDetails(rangeValueGroups, 12);
15575
+ for (const { name, receipt } of sampledRangeValueDetails) {
15430
15576
  const selector = cliString(receipt.selector) || "input[type=range]";
15431
15577
  const requested = cliValueLabel(receipt.requested_value);
15432
15578
  const actual = cliValueLabel(receipt.actual_value);
@@ -15439,45 +15585,53 @@ function profileSetupSummaryMarkdown(result) {
15439
15585
  const reason = cliString(receipt.reason);
15440
15586
  lines.push(`- ${name} set_range_value: ${ok}, ${markdownInlineCode(selector)}${requested === void 0 ? "" : ` requested ${markdownInlineCode(requested, 80)}`}${actual === void 0 ? "" : ` -> ${markdownInlineCode(actual, 80)}`}${before === void 0 ? "" : `, before ${markdownInlineCode(before, 80)}`}${valueAsNumber === void 0 ? "" : `, number ${valueAsNumber}`}${min === void 0 && max === void 0 ? "" : `, range ${min === void 0 ? "?" : markdownInlineCode(min, 40)}..${max === void 0 ? "?" : markdownInlineCode(max, 40)}`}${step === void 0 ? "" : ` step ${markdownInlineCode(step, 40)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
15441
15587
  }
15442
- if (rangeValueDetails.length > 12) lines.push(`- ${rangeValueDetails.length - 12} additional set_range_value receipt(s) omitted.`);
15443
- const windowCallDetails = viewports.flatMap((viewport) => {
15588
+ if (rangeValueDetails.length > sampledRangeValueDetails.length) lines.push(`- ${rangeValueDetails.length - sampledRangeValueDetails.length} additional set_range_value receipt(s) omitted.`);
15589
+ const windowCallGroups = viewports.map((viewport) => {
15444
15590
  const name = cliString(viewport.name) || "viewport";
15445
15591
  const receipts = Array.isArray(viewport.window_call) ? viewport.window_call.map(cliRecord).filter((item) => Boolean(item)) : [];
15446
15592
  return receipts.map((receipt) => ({ name, receipt }));
15447
15593
  });
15448
- for (const { name, receipt } of windowCallDetails.slice(0, 12)) {
15594
+ const windowCallDetails = windowCallGroups.flat();
15595
+ const sampledWindowCallDetails = balancedSetupReceiptDetails(windowCallGroups, 12);
15596
+ for (const { name, receipt } of sampledWindowCallDetails) {
15449
15597
  const path7 = cliString(receipt.path) || "window_function";
15450
15598
  const storedTo = cliString(receipt.return_stored_to);
15451
15599
  const returned = cliValueLabel(receipt.returned);
15452
15600
  const expected = cliValueLabel(receipt.expected_return);
15601
+ const returnSummary = cliReturnSummaryLabel(receipt.return_summary);
15453
15602
  const captured = receipt.return_captured === true ? "captured" : receipt.return_captured === false ? "not captured" : "capture unknown";
15454
15603
  const ok = receipt.ok === false ? "failed" : "ok";
15455
15604
  const reason = cliString(receipt.reason);
15456
- lines.push(`- ${name} window_call: ${ok}, ${markdownInlineCode(path7)}${storedTo ? `, stored ${markdownInlineCode(storedTo)}` : ""}, return ${captured}${expected === void 0 ? "" : `, expected ${markdownInlineCode(expected, 80)}`}${returned === void 0 ? "" : `, returned ${markdownInlineCode(returned, 80)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
15605
+ lines.push(`- ${name} window_call: ${ok}, ${markdownInlineCode(path7)}${storedTo ? `, stored ${markdownInlineCode(storedTo)}` : ""}, return ${captured}${expected === void 0 ? "" : `, expected ${markdownInlineCode(expected, 80)}`}${returnSummary ? `, summary ${markdownInlineCode(returnSummary, 140)}` : ""}${returned === void 0 ? "" : `, returned ${markdownInlineCode(returned, 80)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
15457
15606
  }
15458
- if (windowCallDetails.length > 12) lines.push(`- ${windowCallDetails.length - 12} additional window_call receipt(s) omitted.`);
15459
- const windowEvalDetails = viewports.flatMap((viewport) => {
15607
+ if (windowCallDetails.length > sampledWindowCallDetails.length) lines.push(`- ${windowCallDetails.length - sampledWindowCallDetails.length} additional window_call receipt(s) omitted.`);
15608
+ const windowEvalGroups = viewports.map((viewport) => {
15460
15609
  const name = cliString(viewport.name) || "viewport";
15461
15610
  const receipts = Array.isArray(viewport.window_eval) ? viewport.window_eval.map(cliRecord).filter((item) => Boolean(item)) : [];
15462
15611
  return receipts.map((receipt) => ({ name, receipt }));
15463
15612
  });
15464
- for (const { name, receipt } of windowEvalDetails.slice(0, 12)) {
15613
+ const windowEvalDetails = windowEvalGroups.flat();
15614
+ const sampledWindowEvalDetails = balancedSetupReceiptDetails(windowEvalGroups, 12);
15615
+ for (const { name, receipt } of sampledWindowEvalDetails) {
15465
15616
  const scriptLength = cliFiniteNumber(receipt.script_length);
15466
15617
  const storedTo = cliString(receipt.return_stored_to);
15467
15618
  const returned = cliValueLabel(receipt.returned);
15468
15619
  const expected = cliValueLabel(receipt.expected_return);
15620
+ const returnSummary = cliReturnSummaryLabel(receipt.return_summary);
15469
15621
  const captured = receipt.return_captured === true ? "captured" : receipt.return_captured === false ? "not captured" : "capture unknown";
15470
15622
  const ok = receipt.ok === false ? "failed" : "ok";
15471
15623
  const reason = cliString(receipt.reason);
15472
- lines.push(`- ${name} window_eval: ${ok}${scriptLength === void 0 ? "" : `, script ${scriptLength} chars`}${storedTo ? `, stored ${markdownInlineCode(storedTo)}` : ""}, return ${captured}${expected === void 0 ? "" : `, expected ${markdownInlineCode(expected, 80)}`}${returned === void 0 ? "" : `, returned ${markdownInlineCode(returned, 80)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
15624
+ lines.push(`- ${name} window_eval: ${ok}${scriptLength === void 0 ? "" : `, script ${scriptLength} chars`}${storedTo ? `, stored ${markdownInlineCode(storedTo)}` : ""}, return ${captured}${expected === void 0 ? "" : `, expected ${markdownInlineCode(expected, 80)}`}${returnSummary ? `, summary ${markdownInlineCode(returnSummary, 140)}` : ""}${returned === void 0 ? "" : `, returned ${markdownInlineCode(returned, 80)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
15473
15625
  }
15474
- if (windowEvalDetails.length > 12) lines.push(`- ${windowEvalDetails.length - 12} additional window_eval receipt(s) omitted.`);
15475
- const windowCallUntilDetails = viewports.flatMap((viewport) => {
15626
+ if (windowEvalDetails.length > sampledWindowEvalDetails.length) lines.push(`- ${windowEvalDetails.length - sampledWindowEvalDetails.length} additional window_eval receipt(s) omitted.`);
15627
+ const windowCallUntilGroups = viewports.map((viewport) => {
15476
15628
  const name = cliString(viewport.name) || "viewport";
15477
15629
  const receipts = Array.isArray(viewport.window_call_until) ? viewport.window_call_until.map(cliRecord).filter((item) => Boolean(item)) : [];
15478
15630
  return receipts.map((receipt) => ({ name, receipt }));
15479
15631
  });
15480
- for (const { name, receipt } of windowCallUntilDetails.slice(0, 12)) {
15632
+ const windowCallUntilDetails = windowCallUntilGroups.flat();
15633
+ const sampledWindowCallUntilDetails = balancedSetupReceiptDetails(windowCallUntilGroups, 12);
15634
+ for (const { name, receipt } of sampledWindowCallUntilDetails) {
15481
15635
  const path7 = cliString(receipt.path) || "window_function";
15482
15636
  const untilPath = cliString(receipt.until_path) || "until_path";
15483
15637
  const expected = cliValueLabel(receipt.until_expected_value);
@@ -15489,7 +15643,7 @@ function profileSetupSummaryMarkdown(result) {
15489
15643
  const callText = callCount === void 0 ? "" : ` in ${callCount}${maxCalls === void 0 ? "" : `/${maxCalls}`} call(s)`;
15490
15644
  lines.push(`- ${name} window_call_until: ${ok}, ${markdownInlineCode(path7)} until ${markdownInlineCode(untilPath)}${expected === void 0 ? "" : ` == ${markdownInlineCode(expected, 80)}`}${callText}${actual === void 0 ? "" : `, observed ${markdownInlineCode(actual, 80)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
15491
15645
  }
15492
- if (windowCallUntilDetails.length > 12) lines.push(`- ${windowCallUntilDetails.length - 12} additional window_call_until receipt(s) omitted.`);
15646
+ if (windowCallUntilDetails.length > sampledWindowCallUntilDetails.length) lines.push(`- ${windowCallUntilDetails.length - sampledWindowCallUntilDetails.length} additional window_call_until receipt(s) omitted.`);
15493
15647
  const failedDetails = viewports.flatMap((viewport) => {
15494
15648
  const name = cliString(viewport.name) || "viewport";
15495
15649
  const failed = Array.isArray(viewport.failed) ? viewport.failed.map(cliRecord).filter((item) => Boolean(item)) : [];
package/dist/cli.js CHANGED
@@ -13,7 +13,7 @@ import {
13
13
  profileStatusExitCode,
14
14
  resolveRiddleProofProfileTargetUrl,
15
15
  resolveRiddleProofProfileTimeoutSec
16
- } from "./chunk-QJJ3ISMK.js";
16
+ } from "./chunk-YB3LNLZB.js";
17
17
  import {
18
18
  createRiddleApiClient,
19
19
  isTerminalRiddleJobStatus,
@@ -635,6 +635,42 @@ function cliValueLabel(value) {
635
635
  return String(value);
636
636
  }
637
637
  }
638
+ function cliReturnSummaryLabel(value) {
639
+ if (!Array.isArray(value)) return void 0;
640
+ const parts = value.map(cliRecord).filter((item) => Boolean(item)).map((item) => {
641
+ const label = cliString(item.label) || cliString(item.path) || "value";
642
+ const observed = item.exists === false ? "missing" : cliValueLabel(item.value);
643
+ return `${label}=${observed ?? "null"}`;
644
+ }).filter(Boolean);
645
+ return parts.length ? parts.join(", ") : void 0;
646
+ }
647
+ function balancedSetupReceiptDetails(groups, limit) {
648
+ if (limit <= 0) return [];
649
+ const total = groups.reduce((sum, group) => sum + group.length, 0);
650
+ if (total <= limit) return groups.flat();
651
+ const selected = [];
652
+ const indexes = new Array(groups.length).fill(0);
653
+ const nonEmptyIndexes = groups.map((group, index) => group.length ? index : -1).filter((index) => index >= 0);
654
+ for (const index of nonEmptyIndexes) {
655
+ if (selected.length >= limit) return selected;
656
+ selected.push(groups[index][0]);
657
+ indexes[index] = 1;
658
+ }
659
+ while (selected.length < limit) {
660
+ let progressed = false;
661
+ for (const index of nonEmptyIndexes) {
662
+ const nextIndex = indexes[index];
663
+ const next = groups[index][nextIndex];
664
+ if (!next) continue;
665
+ selected.push(next);
666
+ indexes[index] = nextIndex + 1;
667
+ progressed = true;
668
+ if (selected.length >= limit) break;
669
+ }
670
+ if (!progressed) break;
671
+ }
672
+ return selected;
673
+ }
638
674
  function cliStringArray(value) {
639
675
  return Array.isArray(value) ? value.filter((entry) => typeof entry === "string" && Boolean(entry.trim())) : [];
640
676
  }
@@ -780,12 +816,14 @@ function profileSetupSummaryMarkdown(result) {
780
816
  const observedPath = cliString(viewport.observed_path);
781
817
  lines.push(`- ${name}: ${ok}, ${resultCount} result(s), ${screenshotCount} setup screenshot(s), ${clicked} click(s)${clickCountActions ? `, ${clickCountActions} click_count action(s)` : ""}${rangeValueActions ? `, ${rangeValueActions} set_range_value action(s)` : ""}${windowCallActions ? `, ${windowCallActions} window_call action(s), ${windowCallStored} stored return(s), ${windowCallCaptured} captured return(s)` : ""}${windowEvalActions ? `, ${windowEvalActions} window_eval action(s), ${windowEvalStored} stored return(s), ${windowEvalCaptured} captured return(s)` : ""}${windowCallUntilActions ? `, ${windowCallUntilActions} window_call_until action(s), ${windowCallUntilCalls} call(s)` : ""}${observedPath ? `, path ${observedPath}` : ""}`);
782
818
  }
783
- const rangeValueDetails = viewports.flatMap((viewport) => {
819
+ const rangeValueGroups = viewports.map((viewport) => {
784
820
  const name = cliString(viewport.name) || "viewport";
785
821
  const receipts = Array.isArray(viewport.set_range_value) ? viewport.set_range_value.map(cliRecord).filter((item) => Boolean(item)) : [];
786
822
  return receipts.map((receipt) => ({ name, receipt }));
787
823
  });
788
- for (const { name, receipt } of rangeValueDetails.slice(0, 12)) {
824
+ const rangeValueDetails = rangeValueGroups.flat();
825
+ const sampledRangeValueDetails = balancedSetupReceiptDetails(rangeValueGroups, 12);
826
+ for (const { name, receipt } of sampledRangeValueDetails) {
789
827
  const selector = cliString(receipt.selector) || "input[type=range]";
790
828
  const requested = cliValueLabel(receipt.requested_value);
791
829
  const actual = cliValueLabel(receipt.actual_value);
@@ -798,45 +836,53 @@ function profileSetupSummaryMarkdown(result) {
798
836
  const reason = cliString(receipt.reason);
799
837
  lines.push(`- ${name} set_range_value: ${ok}, ${markdownInlineCode(selector)}${requested === void 0 ? "" : ` requested ${markdownInlineCode(requested, 80)}`}${actual === void 0 ? "" : ` -> ${markdownInlineCode(actual, 80)}`}${before === void 0 ? "" : `, before ${markdownInlineCode(before, 80)}`}${valueAsNumber === void 0 ? "" : `, number ${valueAsNumber}`}${min === void 0 && max === void 0 ? "" : `, range ${min === void 0 ? "?" : markdownInlineCode(min, 40)}..${max === void 0 ? "?" : markdownInlineCode(max, 40)}`}${step === void 0 ? "" : ` step ${markdownInlineCode(step, 40)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
800
838
  }
801
- if (rangeValueDetails.length > 12) lines.push(`- ${rangeValueDetails.length - 12} additional set_range_value receipt(s) omitted.`);
802
- const windowCallDetails = viewports.flatMap((viewport) => {
839
+ if (rangeValueDetails.length > sampledRangeValueDetails.length) lines.push(`- ${rangeValueDetails.length - sampledRangeValueDetails.length} additional set_range_value receipt(s) omitted.`);
840
+ const windowCallGroups = viewports.map((viewport) => {
803
841
  const name = cliString(viewport.name) || "viewport";
804
842
  const receipts = Array.isArray(viewport.window_call) ? viewport.window_call.map(cliRecord).filter((item) => Boolean(item)) : [];
805
843
  return receipts.map((receipt) => ({ name, receipt }));
806
844
  });
807
- for (const { name, receipt } of windowCallDetails.slice(0, 12)) {
845
+ const windowCallDetails = windowCallGroups.flat();
846
+ const sampledWindowCallDetails = balancedSetupReceiptDetails(windowCallGroups, 12);
847
+ for (const { name, receipt } of sampledWindowCallDetails) {
808
848
  const path2 = cliString(receipt.path) || "window_function";
809
849
  const storedTo = cliString(receipt.return_stored_to);
810
850
  const returned = cliValueLabel(receipt.returned);
811
851
  const expected = cliValueLabel(receipt.expected_return);
852
+ const returnSummary = cliReturnSummaryLabel(receipt.return_summary);
812
853
  const captured = receipt.return_captured === true ? "captured" : receipt.return_captured === false ? "not captured" : "capture unknown";
813
854
  const ok = receipt.ok === false ? "failed" : "ok";
814
855
  const reason = cliString(receipt.reason);
815
- lines.push(`- ${name} window_call: ${ok}, ${markdownInlineCode(path2)}${storedTo ? `, stored ${markdownInlineCode(storedTo)}` : ""}, return ${captured}${expected === void 0 ? "" : `, expected ${markdownInlineCode(expected, 80)}`}${returned === void 0 ? "" : `, returned ${markdownInlineCode(returned, 80)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
856
+ lines.push(`- ${name} window_call: ${ok}, ${markdownInlineCode(path2)}${storedTo ? `, stored ${markdownInlineCode(storedTo)}` : ""}, return ${captured}${expected === void 0 ? "" : `, expected ${markdownInlineCode(expected, 80)}`}${returnSummary ? `, summary ${markdownInlineCode(returnSummary, 140)}` : ""}${returned === void 0 ? "" : `, returned ${markdownInlineCode(returned, 80)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
816
857
  }
817
- if (windowCallDetails.length > 12) lines.push(`- ${windowCallDetails.length - 12} additional window_call receipt(s) omitted.`);
818
- const windowEvalDetails = viewports.flatMap((viewport) => {
858
+ if (windowCallDetails.length > sampledWindowCallDetails.length) lines.push(`- ${windowCallDetails.length - sampledWindowCallDetails.length} additional window_call receipt(s) omitted.`);
859
+ const windowEvalGroups = viewports.map((viewport) => {
819
860
  const name = cliString(viewport.name) || "viewport";
820
861
  const receipts = Array.isArray(viewport.window_eval) ? viewport.window_eval.map(cliRecord).filter((item) => Boolean(item)) : [];
821
862
  return receipts.map((receipt) => ({ name, receipt }));
822
863
  });
823
- for (const { name, receipt } of windowEvalDetails.slice(0, 12)) {
864
+ const windowEvalDetails = windowEvalGroups.flat();
865
+ const sampledWindowEvalDetails = balancedSetupReceiptDetails(windowEvalGroups, 12);
866
+ for (const { name, receipt } of sampledWindowEvalDetails) {
824
867
  const scriptLength = cliFiniteNumber(receipt.script_length);
825
868
  const storedTo = cliString(receipt.return_stored_to);
826
869
  const returned = cliValueLabel(receipt.returned);
827
870
  const expected = cliValueLabel(receipt.expected_return);
871
+ const returnSummary = cliReturnSummaryLabel(receipt.return_summary);
828
872
  const captured = receipt.return_captured === true ? "captured" : receipt.return_captured === false ? "not captured" : "capture unknown";
829
873
  const ok = receipt.ok === false ? "failed" : "ok";
830
874
  const reason = cliString(receipt.reason);
831
- lines.push(`- ${name} window_eval: ${ok}${scriptLength === void 0 ? "" : `, script ${scriptLength} chars`}${storedTo ? `, stored ${markdownInlineCode(storedTo)}` : ""}, return ${captured}${expected === void 0 ? "" : `, expected ${markdownInlineCode(expected, 80)}`}${returned === void 0 ? "" : `, returned ${markdownInlineCode(returned, 80)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
875
+ lines.push(`- ${name} window_eval: ${ok}${scriptLength === void 0 ? "" : `, script ${scriptLength} chars`}${storedTo ? `, stored ${markdownInlineCode(storedTo)}` : ""}, return ${captured}${expected === void 0 ? "" : `, expected ${markdownInlineCode(expected, 80)}`}${returnSummary ? `, summary ${markdownInlineCode(returnSummary, 140)}` : ""}${returned === void 0 ? "" : `, returned ${markdownInlineCode(returned, 80)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
832
876
  }
833
- if (windowEvalDetails.length > 12) lines.push(`- ${windowEvalDetails.length - 12} additional window_eval receipt(s) omitted.`);
834
- const windowCallUntilDetails = viewports.flatMap((viewport) => {
877
+ if (windowEvalDetails.length > sampledWindowEvalDetails.length) lines.push(`- ${windowEvalDetails.length - sampledWindowEvalDetails.length} additional window_eval receipt(s) omitted.`);
878
+ const windowCallUntilGroups = viewports.map((viewport) => {
835
879
  const name = cliString(viewport.name) || "viewport";
836
880
  const receipts = Array.isArray(viewport.window_call_until) ? viewport.window_call_until.map(cliRecord).filter((item) => Boolean(item)) : [];
837
881
  return receipts.map((receipt) => ({ name, receipt }));
838
882
  });
839
- for (const { name, receipt } of windowCallUntilDetails.slice(0, 12)) {
883
+ const windowCallUntilDetails = windowCallUntilGroups.flat();
884
+ const sampledWindowCallUntilDetails = balancedSetupReceiptDetails(windowCallUntilGroups, 12);
885
+ for (const { name, receipt } of sampledWindowCallUntilDetails) {
840
886
  const path2 = cliString(receipt.path) || "window_function";
841
887
  const untilPath = cliString(receipt.until_path) || "until_path";
842
888
  const expected = cliValueLabel(receipt.until_expected_value);
@@ -848,7 +894,7 @@ function profileSetupSummaryMarkdown(result) {
848
894
  const callText = callCount === void 0 ? "" : ` in ${callCount}${maxCalls === void 0 ? "" : `/${maxCalls}`} call(s)`;
849
895
  lines.push(`- ${name} window_call_until: ${ok}, ${markdownInlineCode(path2)} until ${markdownInlineCode(untilPath)}${expected === void 0 ? "" : ` == ${markdownInlineCode(expected, 80)}`}${callText}${actual === void 0 ? "" : `, observed ${markdownInlineCode(actual, 80)}`}${reason ? `, reason ${markdownInlineCode(reason, 100)}` : ""}`);
850
896
  }
851
- if (windowCallUntilDetails.length > 12) lines.push(`- ${windowCallUntilDetails.length - 12} additional window_call_until receipt(s) omitted.`);
897
+ if (windowCallUntilDetails.length > sampledWindowCallUntilDetails.length) lines.push(`- ${windowCallUntilDetails.length - sampledWindowCallUntilDetails.length} additional window_call_until receipt(s) omitted.`);
852
898
  const failedDetails = viewports.flatMap((viewport) => {
853
899
  const name = cliString(viewport.name) || "viewport";
854
900
  const failed = Array.isArray(viewport.failed) ? viewport.failed.map(cliRecord).filter((item) => Boolean(item)) : [];
package/dist/index.cjs CHANGED
@@ -9213,6 +9213,8 @@ function profileSetupWindowCallReceipts(results) {
9213
9213
  };
9214
9214
  if (result.returned !== void 0) receipt.returned = result.returned;
9215
9215
  if (result.expected_return !== void 0) receipt.expected_return = result.expected_return;
9216
+ const returnSummary = profileSetupReturnSummary(result);
9217
+ if (returnSummary.length) receipt.return_summary = returnSummary;
9216
9218
  return receipt;
9217
9219
  });
9218
9220
  }
@@ -9228,6 +9230,40 @@ function profileSetupWindowEvalReceipts(results) {
9228
9230
  };
9229
9231
  if (result.returned !== void 0) receipt.returned = result.returned;
9230
9232
  if (result.expected_return !== void 0) receipt.expected_return = result.expected_return;
9233
+ const returnSummary = profileSetupReturnSummary(result);
9234
+ if (returnSummary.length) receipt.return_summary = returnSummary;
9235
+ return receipt;
9236
+ });
9237
+ }
9238
+ function profileSetupReturnSummaryFields(result) {
9239
+ const input = result.return_summary_fields;
9240
+ if (!Array.isArray(input)) return [];
9241
+ const fields = [];
9242
+ for (const item of input) {
9243
+ if (typeof item === "string") {
9244
+ const path7 = item.trim();
9245
+ if (path7) fields.push({ path: path7 });
9246
+ continue;
9247
+ }
9248
+ if (!isRecord2(item)) continue;
9249
+ const path6 = stringValue5(item.path) ?? stringValue5(item.key) ?? stringValue5(item.json_path) ?? stringValue5(item.jsonPath);
9250
+ if (!path6) continue;
9251
+ const label = stringValue5(item.label) ?? stringValue5(item.name) ?? stringValue5(item.title);
9252
+ fields.push(label ? { path: path6, label } : { path: path6 });
9253
+ }
9254
+ return fields;
9255
+ }
9256
+ function profileSetupReturnSummary(result) {
9257
+ if (result.returned === void 0) return [];
9258
+ return profileSetupReturnSummaryFields(result).map((field) => {
9259
+ const resolved = resolveJsonPath(result.returned, field.path);
9260
+ const receipt = {
9261
+ label: field.label || field.path,
9262
+ path: field.path,
9263
+ exists: resolved.exists
9264
+ };
9265
+ if (resolved.exists) receipt.value = toJsonValue(resolved.value);
9266
+ if (resolved.error) receipt.reason = resolved.error;
9231
9267
  return receipt;
9232
9268
  });
9233
9269
  }
@@ -9416,6 +9452,37 @@ function normalizeSetupActionArgs(input, index) {
9416
9452
  }
9417
9453
  return argsInput.map(toJsonValue);
9418
9454
  }
9455
+ function normalizeReturnSummaryFields(input, index) {
9456
+ const fieldsInput = valueFromOwn(
9457
+ input,
9458
+ "return_summary_fields",
9459
+ "returnSummaryFields",
9460
+ "summary_fields",
9461
+ "summaryFields",
9462
+ "receipt_fields",
9463
+ "receiptFields",
9464
+ "return_receipt_fields",
9465
+ "returnReceiptFields"
9466
+ );
9467
+ if (fieldsInput === void 0) return void 0;
9468
+ if (!Array.isArray(fieldsInput)) {
9469
+ throw new Error(`target.setup_actions[${index}].return_summary_fields must be an array.`);
9470
+ }
9471
+ return fieldsInput.map((field, fieldIndex) => {
9472
+ if (typeof field === "string") {
9473
+ const path7 = field.trim();
9474
+ if (!path7) throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] requires path.`);
9475
+ return { path: path7 };
9476
+ }
9477
+ if (!isRecord2(field)) {
9478
+ throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] must be a string path or object.`);
9479
+ }
9480
+ const path6 = stringFromOwn(field, "path", "key", "json_path", "jsonPath");
9481
+ if (!path6) throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] requires path.`);
9482
+ const label = stringFromOwn(field, "label", "name", "title");
9483
+ return label ? { path: path6, label } : { path: path6 };
9484
+ });
9485
+ }
9419
9486
  function normalizeSetupActionRepeat(input, index) {
9420
9487
  const repeat = numberValue3(valueFromOwn(input, "repeat", "repeat_count", "repeatCount", "times"));
9421
9488
  if (repeat === void 0) return void 0;
@@ -9637,6 +9704,7 @@ function normalizeSetupAction(input, index) {
9637
9704
  expect_return: hasExpectedReturn ? toJsonValue(valueFromOwn(input, "expect_return", "expectReturn", "expected_return", "expectedReturn")) : void 0,
9638
9705
  store_return_to: storeReturnTo,
9639
9706
  capture_return: captureReturn,
9707
+ return_summary_fields: normalizeReturnSummaryFields(input, index),
9640
9708
  until_path: untilPath,
9641
9709
  until_expected_value: hasUntilExpectedValue ? toJsonValue(valueFromOwn(input, "until_expected_value", "untilExpectedValue", "until_expected", "untilExpected", "until_value", "untilValue", "expected_value", "expectedValue", "expected")) : void 0,
9642
9710
  max_calls: maxCalls,
@@ -12675,6 +12743,8 @@ function profileSetupWindowCallReceipts(results) {
12675
12743
  };
12676
12744
  if (result.returned !== undefined) receipt.returned = result.returned;
12677
12745
  if (result.expected_return !== undefined) receipt.expected_return = result.expected_return;
12746
+ const returnSummary = profileSetupReturnSummary(result);
12747
+ if (returnSummary.length) receipt.return_summary = returnSummary;
12678
12748
  return receipt;
12679
12749
  });
12680
12750
  }
@@ -12692,9 +12762,43 @@ function profileSetupWindowEvalReceipts(results) {
12692
12762
  };
12693
12763
  if (result.returned !== undefined) receipt.returned = result.returned;
12694
12764
  if (result.expected_return !== undefined) receipt.expected_return = result.expected_return;
12765
+ const returnSummary = profileSetupReturnSummary(result);
12766
+ if (returnSummary.length) receipt.return_summary = returnSummary;
12695
12767
  return receipt;
12696
12768
  });
12697
12769
  }
12770
+ function profileSetupReturnSummaryFields(result) {
12771
+ const input = result && result.return_summary_fields;
12772
+ if (!Array.isArray(input)) return [];
12773
+ const fields = [];
12774
+ for (const item of input) {
12775
+ if (typeof item === "string") {
12776
+ const path = item.trim();
12777
+ if (path) fields.push({ path });
12778
+ continue;
12779
+ }
12780
+ if (!item || typeof item !== "object" || Array.isArray(item)) continue;
12781
+ const path = String(item.path || item.key || item.json_path || item.jsonPath || "").trim();
12782
+ if (!path) continue;
12783
+ const label = String(item.label || item.name || item.title || "").trim();
12784
+ fields.push(label ? { path, label } : { path });
12785
+ }
12786
+ return fields;
12787
+ }
12788
+ function profileSetupReturnSummary(result) {
12789
+ if (!result || result.returned === undefined) return [];
12790
+ return profileSetupReturnSummaryFields(result).map((field) => {
12791
+ const resolved = resolveJsonProbePath(result.returned, field.path);
12792
+ const receipt = {
12793
+ label: field.label || field.path,
12794
+ path: field.path,
12795
+ exists: Boolean(resolved.exists),
12796
+ };
12797
+ if (resolved.exists) receipt.value = setupJsonValue(resolved.value);
12798
+ if (resolved.error) receipt.reason = resolved.error;
12799
+ return receipt;
12800
+ });
12801
+ }
12698
12802
  function profileSetupRangeValueReceipts(results) {
12699
12803
  return (results || [])
12700
12804
  .filter((result) => result && profileSetupResultAction(result) === "set_range_value")
@@ -14429,6 +14533,7 @@ async function executeSetupAction(action, ordinal, viewport) {
14429
14533
  const script = String(action.script || action.code || action.source || action.body || "");
14430
14534
  const args = Array.isArray(action.args) ? action.args : [];
14431
14535
  const storeReturnTo = String(action.store_return_to || action.storeReturnTo || action.save_return_to || action.saveReturnTo || action.assign_return_to || action.assignReturnTo || action.return_state_path || action.returnStatePath || "").trim();
14536
+ const returnSummaryFields = Array.isArray(action.return_summary_fields) ? action.return_summary_fields : [];
14432
14537
  if (!script.trim()) return { ...base, reason: "missing_script" };
14433
14538
  const scope = await setupActionScope(action, timeout);
14434
14539
  if (!scope.ok) return setupScopeFailure(base, scope);
@@ -14458,6 +14563,7 @@ async function executeSetupAction(action, ordinal, viewport) {
14458
14563
  return_captured: captureReturn,
14459
14564
  expected_return: hasExpectation ? setupJsonValue(expected) : undefined,
14460
14565
  return_stored_to: result.return_stored_to || storeReturnTo || undefined,
14566
+ return_summary_fields: returnSummaryFields.length ? setupJsonValue(returnSummaryFields) : undefined,
14461
14567
  reason: result.ok ? (expectationMet ? undefined : "unexpected_return_value") : result.reason,
14462
14568
  store_reason: result.store_reason || undefined,
14463
14569
  error: result.error || undefined,
@@ -14467,6 +14573,7 @@ async function executeSetupAction(action, ordinal, viewport) {
14467
14573
  const path = String(action.path || action.function_path || action.functionPath || "");
14468
14574
  const args = Array.isArray(action.args) ? action.args : [];
14469
14575
  const storeReturnTo = String(action.store_return_to || action.storeReturnTo || action.save_return_to || action.saveReturnTo || action.assign_return_to || action.assignReturnTo || action.return_state_path || action.returnStatePath || "").trim();
14576
+ const returnSummaryFields = Array.isArray(action.return_summary_fields) ? action.return_summary_fields : [];
14470
14577
  if (!path) return { ...base, path, reason: "missing_path" };
14471
14578
  const scope = await setupActionScope(action, timeout);
14472
14579
  if (!scope.ok) return setupScopeFailure(base, scope);
@@ -14496,6 +14603,7 @@ async function executeSetupAction(action, ordinal, viewport) {
14496
14603
  return_captured: captureReturn,
14497
14604
  expected_return: hasExpectation ? setupJsonValue(expected) : undefined,
14498
14605
  return_stored_to: result.return_stored_to || storeReturnTo || undefined,
14606
+ return_summary_fields: returnSummaryFields.length ? setupJsonValue(returnSummaryFields) : undefined,
14499
14607
  reason: result.ok ? (expectationMet ? undefined : "unexpected_return_value") : result.reason,
14500
14608
  store_reason: result.store_reason || undefined,
14501
14609
  error: result.error || undefined,
package/dist/index.d.cts CHANGED
@@ -10,5 +10,5 @@ export { CreateCaptureDiagnosticInput, DEFAULT_DIAGNOSTIC_ARRAY_LIMIT, DEFAULT_D
10
10
  export { BuildVisualProofSessionInput, RIDDLE_PROOF_VISUAL_SESSION_FINGERPRINT_VERSION, RIDDLE_PROOF_VISUAL_SESSION_VERSION, VisualProofSessionMismatch, buildVisualProofSession, compareVisualProofSessionFingerprint, parseVisualProofSession, visualSessionFingerprint, visualSessionFingerprintBasis } from './proof-session.cjs';
11
11
  export { AssessPlayabilityOptions, RIDDLE_PROOF_PLAYABILITY_ASSESSMENT_VERSION, RIDDLE_PROOF_PLAYABILITY_VERSION, RiddleProofPlayabilityAssessment, RiddleProofPlayabilityEvidence, assessPlayabilityEvidence, extractPlayabilityEvidence, isRiddleProofPlayabilityMode } from './playability.cjs';
12
12
  export { AssessBasicGameplayOptions, AttachBasicGameplayArtifactOptions, BASIC_GAMEPLAY_ACTION_TYPES, BASIC_GAMEPLAY_PROGRESS_CHECK_TYPES, BasicGameplayActionResult, BasicGameplayActionType, BasicGameplayArtifactResolution, BasicGameplayAssessmentSummary, BasicGameplayBoundsOffender, BasicGameplayCanvasState, BasicGameplayCatchRecord, BasicGameplayChangeSummary, BasicGameplayFailureCode, BasicGameplayFixReference, BasicGameplayMetric, BasicGameplayMobileEvidence, BasicGameplayProgressCheckType, BasicGameplayProgressionCheck, BasicGameplayProofArtifact, BasicGameplayResponsiveViewportEvidence, BasicGameplayRouteReference, BasicGameplaySnapshot, BasicGameplaySuiteFailure, BasicGameplayWarningCode, CreateBasicGameplayCatchSummaryInput, RIDDLE_PROOF_BASIC_GAMEPLAY_ASSESSMENT_VERSION, RIDDLE_PROOF_BASIC_GAMEPLAY_CATCH_VERSION, RIDDLE_PROOF_BASIC_GAMEPLAY_VERSION, RiddleProofBasicGameplayAssessment, RiddleProofBasicGameplayCatchSummary, RiddleProofBasicGameplayEvidence, RiddleProofBasicGameplayRouteAssessment, RiddleProofBasicGameplayRouteEvidence, assessBasicGameplayEvidence, assessBasicGameplayProgressionCheck, assessBasicGameplayProgressionChecks, assessBasicGameplayRoute, attachBasicGameplayArtifactScreenshotHashes, augmentBasicGameplayAssessmentWithProgressionChecks, compactBasicGameplayText, createBasicGameplayCatchRecords, createBasicGameplayCatchSummary, extractBasicGameplayEvidence, resolveBasicGameplayProgressionCheckWithArtifactScreenshots, sanitizeBasicGameplayJsonString } from './basic-gameplay.cjs';
13
- export { NormalizeRiddleProofProfileOptions, RIDDLE_PROOF_PROFILE_CHECK_TYPES, RIDDLE_PROOF_PROFILE_EVIDENCE_VERSION, RIDDLE_PROOF_PROFILE_NETWORK_ABORT_ERROR_CODES, RIDDLE_PROOF_PROFILE_RESULT_VERSION, RIDDLE_PROOF_PROFILE_SETUP_ACTION_TYPES, RIDDLE_PROOF_PROFILE_STATUSES, RIDDLE_PROOF_PROFILE_VERSION, RiddleProofArtifactBodyAssertionInput, RiddleProofArtifactBodyAssertionResult, RiddleProofProfile, RiddleProofProfileArtifactRef, RiddleProofProfileBaselinePolicy, RiddleProofProfileBoundsOffender, RiddleProofProfileCheck, RiddleProofProfileCheckResult, RiddleProofProfileCheckType, RiddleProofProfileEvidence, RiddleProofProfileFailureAction, RiddleProofProfileHttpStatusBodyJsonAssertion, RiddleProofProfileHttpStatusBodyJsonAssertionResult, RiddleProofProfileHttpStatusPreflightCheckResult, RiddleProofProfileHttpStatusPreflightFetch, RiddleProofProfileHttpStatusPreflightFetchResponse, RiddleProofProfileHttpStatusPreflightOptions, RiddleProofProfileHttpStatusPreflightResult, RiddleProofProfileJsonValueType, RiddleProofProfileNetworkAbortErrorCode, RiddleProofProfileNetworkMock, RiddleProofProfileNetworkMockResponse, RiddleProofProfileResult, RiddleProofProfileRouteEvidence, RiddleProofProfileRouteInventoryRoute, RiddleProofProfileRunner, RiddleProofProfileSetupAction, RiddleProofProfileSetupActionType, RiddleProofProfileStatus, RiddleProofProfileTarget, RiddleProofProfileViewport, RiddleProofProfileViewportEvidence, assessRiddleProofProfileEvidence, buildRiddleProofProfileScript, collectRiddleProfileArtifactRefs, collectRiddleProofProfileWarnings, createRiddleProofProfileConfigurationError, createRiddleProofProfileEnvironmentBlockedResult, createRiddleProofProfileInsufficientResult, deriveRiddleProofArtifactBodyAssertions, extractRiddleProofProfileResult, normalizeRiddleProofProfile, preflightRiddleProofProfileHttpStatusChecks, profileStatusExitCode, resolveRiddleProofProfileRouteUrl, resolveRiddleProofProfileTargetUrl, resolveRiddleProofProfileTimeoutSec, slugifyRiddleProofProfileName, summarizeRiddleProofProfileResult } from './profile.cjs';
13
+ export { NormalizeRiddleProofProfileOptions, RIDDLE_PROOF_PROFILE_CHECK_TYPES, RIDDLE_PROOF_PROFILE_EVIDENCE_VERSION, RIDDLE_PROOF_PROFILE_NETWORK_ABORT_ERROR_CODES, RIDDLE_PROOF_PROFILE_RESULT_VERSION, RIDDLE_PROOF_PROFILE_SETUP_ACTION_TYPES, RIDDLE_PROOF_PROFILE_STATUSES, RIDDLE_PROOF_PROFILE_VERSION, RiddleProofArtifactBodyAssertionInput, RiddleProofArtifactBodyAssertionResult, RiddleProofProfile, RiddleProofProfileArtifactRef, RiddleProofProfileBaselinePolicy, RiddleProofProfileBoundsOffender, RiddleProofProfileCheck, RiddleProofProfileCheckResult, RiddleProofProfileCheckType, RiddleProofProfileEvidence, RiddleProofProfileFailureAction, RiddleProofProfileHttpStatusBodyJsonAssertion, RiddleProofProfileHttpStatusBodyJsonAssertionResult, RiddleProofProfileHttpStatusPreflightCheckResult, RiddleProofProfileHttpStatusPreflightFetch, RiddleProofProfileHttpStatusPreflightFetchResponse, RiddleProofProfileHttpStatusPreflightOptions, RiddleProofProfileHttpStatusPreflightResult, RiddleProofProfileJsonValueType, RiddleProofProfileNetworkAbortErrorCode, RiddleProofProfileNetworkMock, RiddleProofProfileNetworkMockResponse, RiddleProofProfileResult, RiddleProofProfileReturnSummaryField, RiddleProofProfileRouteEvidence, RiddleProofProfileRouteInventoryRoute, RiddleProofProfileRunner, RiddleProofProfileSetupAction, RiddleProofProfileSetupActionType, RiddleProofProfileStatus, RiddleProofProfileTarget, RiddleProofProfileViewport, RiddleProofProfileViewportEvidence, assessRiddleProofProfileEvidence, buildRiddleProofProfileScript, collectRiddleProfileArtifactRefs, collectRiddleProofProfileWarnings, createRiddleProofProfileConfigurationError, createRiddleProofProfileEnvironmentBlockedResult, createRiddleProofProfileInsufficientResult, deriveRiddleProofArtifactBodyAssertions, extractRiddleProofProfileResult, normalizeRiddleProofProfile, preflightRiddleProofProfileHttpStatusChecks, profileStatusExitCode, resolveRiddleProofProfileRouteUrl, resolveRiddleProofProfileTargetUrl, resolveRiddleProofProfileTimeoutSec, slugifyRiddleProofProfileName, summarizeRiddleProofProfileResult } from './profile.cjs';
14
14
  export { DEFAULT_RIDDLE_API_BASE_URL, DEFAULT_RIDDLE_API_KEY_FILE, RiddleApiError, RiddleClientConfig, RiddleFetch, RiddlePollJobOptions, RiddlePollJobResult, RiddlePollProgressSnapshot, RiddlePollSummary, RiddlePreviewDeployResult, RiddlePreviewFramework, RiddleRunScriptInput, RiddleServerPreviewInput, RiddleServerPreviewResult, createRiddleApiClient, deployRiddlePreview, deployRiddleStaticPreview, isTerminalRiddleJobStatus, parseRiddleViewport, pollRiddleJob, resolveRiddleApiKey, riddleRequestJson, runRiddleScript, runRiddleServerPreview } from './riddle-client.cjs';
package/dist/index.d.ts CHANGED
@@ -10,5 +10,5 @@ export { CreateCaptureDiagnosticInput, DEFAULT_DIAGNOSTIC_ARRAY_LIMIT, DEFAULT_D
10
10
  export { BuildVisualProofSessionInput, RIDDLE_PROOF_VISUAL_SESSION_FINGERPRINT_VERSION, RIDDLE_PROOF_VISUAL_SESSION_VERSION, VisualProofSessionMismatch, buildVisualProofSession, compareVisualProofSessionFingerprint, parseVisualProofSession, visualSessionFingerprint, visualSessionFingerprintBasis } from './proof-session.js';
11
11
  export { AssessPlayabilityOptions, RIDDLE_PROOF_PLAYABILITY_ASSESSMENT_VERSION, RIDDLE_PROOF_PLAYABILITY_VERSION, RiddleProofPlayabilityAssessment, RiddleProofPlayabilityEvidence, assessPlayabilityEvidence, extractPlayabilityEvidence, isRiddleProofPlayabilityMode } from './playability.js';
12
12
  export { AssessBasicGameplayOptions, AttachBasicGameplayArtifactOptions, BASIC_GAMEPLAY_ACTION_TYPES, BASIC_GAMEPLAY_PROGRESS_CHECK_TYPES, BasicGameplayActionResult, BasicGameplayActionType, BasicGameplayArtifactResolution, BasicGameplayAssessmentSummary, BasicGameplayBoundsOffender, BasicGameplayCanvasState, BasicGameplayCatchRecord, BasicGameplayChangeSummary, BasicGameplayFailureCode, BasicGameplayFixReference, BasicGameplayMetric, BasicGameplayMobileEvidence, BasicGameplayProgressCheckType, BasicGameplayProgressionCheck, BasicGameplayProofArtifact, BasicGameplayResponsiveViewportEvidence, BasicGameplayRouteReference, BasicGameplaySnapshot, BasicGameplaySuiteFailure, BasicGameplayWarningCode, CreateBasicGameplayCatchSummaryInput, RIDDLE_PROOF_BASIC_GAMEPLAY_ASSESSMENT_VERSION, RIDDLE_PROOF_BASIC_GAMEPLAY_CATCH_VERSION, RIDDLE_PROOF_BASIC_GAMEPLAY_VERSION, RiddleProofBasicGameplayAssessment, RiddleProofBasicGameplayCatchSummary, RiddleProofBasicGameplayEvidence, RiddleProofBasicGameplayRouteAssessment, RiddleProofBasicGameplayRouteEvidence, assessBasicGameplayEvidence, assessBasicGameplayProgressionCheck, assessBasicGameplayProgressionChecks, assessBasicGameplayRoute, attachBasicGameplayArtifactScreenshotHashes, augmentBasicGameplayAssessmentWithProgressionChecks, compactBasicGameplayText, createBasicGameplayCatchRecords, createBasicGameplayCatchSummary, extractBasicGameplayEvidence, resolveBasicGameplayProgressionCheckWithArtifactScreenshots, sanitizeBasicGameplayJsonString } from './basic-gameplay.js';
13
- export { NormalizeRiddleProofProfileOptions, RIDDLE_PROOF_PROFILE_CHECK_TYPES, RIDDLE_PROOF_PROFILE_EVIDENCE_VERSION, RIDDLE_PROOF_PROFILE_NETWORK_ABORT_ERROR_CODES, RIDDLE_PROOF_PROFILE_RESULT_VERSION, RIDDLE_PROOF_PROFILE_SETUP_ACTION_TYPES, RIDDLE_PROOF_PROFILE_STATUSES, RIDDLE_PROOF_PROFILE_VERSION, RiddleProofArtifactBodyAssertionInput, RiddleProofArtifactBodyAssertionResult, RiddleProofProfile, RiddleProofProfileArtifactRef, RiddleProofProfileBaselinePolicy, RiddleProofProfileBoundsOffender, RiddleProofProfileCheck, RiddleProofProfileCheckResult, RiddleProofProfileCheckType, RiddleProofProfileEvidence, RiddleProofProfileFailureAction, RiddleProofProfileHttpStatusBodyJsonAssertion, RiddleProofProfileHttpStatusBodyJsonAssertionResult, RiddleProofProfileHttpStatusPreflightCheckResult, RiddleProofProfileHttpStatusPreflightFetch, RiddleProofProfileHttpStatusPreflightFetchResponse, RiddleProofProfileHttpStatusPreflightOptions, RiddleProofProfileHttpStatusPreflightResult, RiddleProofProfileJsonValueType, RiddleProofProfileNetworkAbortErrorCode, RiddleProofProfileNetworkMock, RiddleProofProfileNetworkMockResponse, RiddleProofProfileResult, RiddleProofProfileRouteEvidence, RiddleProofProfileRouteInventoryRoute, RiddleProofProfileRunner, RiddleProofProfileSetupAction, RiddleProofProfileSetupActionType, RiddleProofProfileStatus, RiddleProofProfileTarget, RiddleProofProfileViewport, RiddleProofProfileViewportEvidence, assessRiddleProofProfileEvidence, buildRiddleProofProfileScript, collectRiddleProfileArtifactRefs, collectRiddleProofProfileWarnings, createRiddleProofProfileConfigurationError, createRiddleProofProfileEnvironmentBlockedResult, createRiddleProofProfileInsufficientResult, deriveRiddleProofArtifactBodyAssertions, extractRiddleProofProfileResult, normalizeRiddleProofProfile, preflightRiddleProofProfileHttpStatusChecks, profileStatusExitCode, resolveRiddleProofProfileRouteUrl, resolveRiddleProofProfileTargetUrl, resolveRiddleProofProfileTimeoutSec, slugifyRiddleProofProfileName, summarizeRiddleProofProfileResult } from './profile.js';
13
+ export { NormalizeRiddleProofProfileOptions, RIDDLE_PROOF_PROFILE_CHECK_TYPES, RIDDLE_PROOF_PROFILE_EVIDENCE_VERSION, RIDDLE_PROOF_PROFILE_NETWORK_ABORT_ERROR_CODES, RIDDLE_PROOF_PROFILE_RESULT_VERSION, RIDDLE_PROOF_PROFILE_SETUP_ACTION_TYPES, RIDDLE_PROOF_PROFILE_STATUSES, RIDDLE_PROOF_PROFILE_VERSION, RiddleProofArtifactBodyAssertionInput, RiddleProofArtifactBodyAssertionResult, RiddleProofProfile, RiddleProofProfileArtifactRef, RiddleProofProfileBaselinePolicy, RiddleProofProfileBoundsOffender, RiddleProofProfileCheck, RiddleProofProfileCheckResult, RiddleProofProfileCheckType, RiddleProofProfileEvidence, RiddleProofProfileFailureAction, RiddleProofProfileHttpStatusBodyJsonAssertion, RiddleProofProfileHttpStatusBodyJsonAssertionResult, RiddleProofProfileHttpStatusPreflightCheckResult, RiddleProofProfileHttpStatusPreflightFetch, RiddleProofProfileHttpStatusPreflightFetchResponse, RiddleProofProfileHttpStatusPreflightOptions, RiddleProofProfileHttpStatusPreflightResult, RiddleProofProfileJsonValueType, RiddleProofProfileNetworkAbortErrorCode, RiddleProofProfileNetworkMock, RiddleProofProfileNetworkMockResponse, RiddleProofProfileResult, RiddleProofProfileReturnSummaryField, RiddleProofProfileRouteEvidence, RiddleProofProfileRouteInventoryRoute, RiddleProofProfileRunner, RiddleProofProfileSetupAction, RiddleProofProfileSetupActionType, RiddleProofProfileStatus, RiddleProofProfileTarget, RiddleProofProfileViewport, RiddleProofProfileViewportEvidence, assessRiddleProofProfileEvidence, buildRiddleProofProfileScript, collectRiddleProfileArtifactRefs, collectRiddleProofProfileWarnings, createRiddleProofProfileConfigurationError, createRiddleProofProfileEnvironmentBlockedResult, createRiddleProofProfileInsufficientResult, deriveRiddleProofArtifactBodyAssertions, extractRiddleProofProfileResult, normalizeRiddleProofProfile, preflightRiddleProofProfileHttpStatusChecks, profileStatusExitCode, resolveRiddleProofProfileRouteUrl, resolveRiddleProofProfileTargetUrl, resolveRiddleProofProfileTimeoutSec, slugifyRiddleProofProfileName, summarizeRiddleProofProfileResult } from './profile.js';
14
14
  export { DEFAULT_RIDDLE_API_BASE_URL, DEFAULT_RIDDLE_API_KEY_FILE, RiddleApiError, RiddleClientConfig, RiddleFetch, RiddlePollJobOptions, RiddlePollJobResult, RiddlePollProgressSnapshot, RiddlePollSummary, RiddlePreviewDeployResult, RiddlePreviewFramework, RiddleRunScriptInput, RiddleServerPreviewInput, RiddleServerPreviewResult, createRiddleApiClient, deployRiddlePreview, deployRiddleStaticPreview, isTerminalRiddleJobStatus, parseRiddleViewport, pollRiddleJob, resolveRiddleApiKey, riddleRequestJson, runRiddleScript, runRiddleServerPreview } from './riddle-client.js';
package/dist/index.js CHANGED
@@ -62,7 +62,7 @@ import {
62
62
  resolveRiddleProofProfileTimeoutSec,
63
63
  slugifyRiddleProofProfileName,
64
64
  summarizeRiddleProofProfileResult
65
- } from "./chunk-QJJ3ISMK.js";
65
+ } from "./chunk-YB3LNLZB.js";
66
66
  import {
67
67
  DEFAULT_RIDDLE_API_BASE_URL,
68
68
  DEFAULT_RIDDLE_API_KEY_FILE,
package/dist/profile.cjs CHANGED
@@ -527,6 +527,8 @@ function profileSetupWindowCallReceipts(results) {
527
527
  };
528
528
  if (result.returned !== void 0) receipt.returned = result.returned;
529
529
  if (result.expected_return !== void 0) receipt.expected_return = result.expected_return;
530
+ const returnSummary = profileSetupReturnSummary(result);
531
+ if (returnSummary.length) receipt.return_summary = returnSummary;
530
532
  return receipt;
531
533
  });
532
534
  }
@@ -542,6 +544,40 @@ function profileSetupWindowEvalReceipts(results) {
542
544
  };
543
545
  if (result.returned !== void 0) receipt.returned = result.returned;
544
546
  if (result.expected_return !== void 0) receipt.expected_return = result.expected_return;
547
+ const returnSummary = profileSetupReturnSummary(result);
548
+ if (returnSummary.length) receipt.return_summary = returnSummary;
549
+ return receipt;
550
+ });
551
+ }
552
+ function profileSetupReturnSummaryFields(result) {
553
+ const input = result.return_summary_fields;
554
+ if (!Array.isArray(input)) return [];
555
+ const fields = [];
556
+ for (const item of input) {
557
+ if (typeof item === "string") {
558
+ const path2 = item.trim();
559
+ if (path2) fields.push({ path: path2 });
560
+ continue;
561
+ }
562
+ if (!isRecord(item)) continue;
563
+ const path = stringValue(item.path) ?? stringValue(item.key) ?? stringValue(item.json_path) ?? stringValue(item.jsonPath);
564
+ if (!path) continue;
565
+ const label = stringValue(item.label) ?? stringValue(item.name) ?? stringValue(item.title);
566
+ fields.push(label ? { path, label } : { path });
567
+ }
568
+ return fields;
569
+ }
570
+ function profileSetupReturnSummary(result) {
571
+ if (result.returned === void 0) return [];
572
+ return profileSetupReturnSummaryFields(result).map((field) => {
573
+ const resolved = resolveJsonPath(result.returned, field.path);
574
+ const receipt = {
575
+ label: field.label || field.path,
576
+ path: field.path,
577
+ exists: resolved.exists
578
+ };
579
+ if (resolved.exists) receipt.value = toJsonValue(resolved.value);
580
+ if (resolved.error) receipt.reason = resolved.error;
545
581
  return receipt;
546
582
  });
547
583
  }
@@ -730,6 +766,37 @@ function normalizeSetupActionArgs(input, index) {
730
766
  }
731
767
  return argsInput.map(toJsonValue);
732
768
  }
769
+ function normalizeReturnSummaryFields(input, index) {
770
+ const fieldsInput = valueFromOwn(
771
+ input,
772
+ "return_summary_fields",
773
+ "returnSummaryFields",
774
+ "summary_fields",
775
+ "summaryFields",
776
+ "receipt_fields",
777
+ "receiptFields",
778
+ "return_receipt_fields",
779
+ "returnReceiptFields"
780
+ );
781
+ if (fieldsInput === void 0) return void 0;
782
+ if (!Array.isArray(fieldsInput)) {
783
+ throw new Error(`target.setup_actions[${index}].return_summary_fields must be an array.`);
784
+ }
785
+ return fieldsInput.map((field, fieldIndex) => {
786
+ if (typeof field === "string") {
787
+ const path2 = field.trim();
788
+ if (!path2) throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] requires path.`);
789
+ return { path: path2 };
790
+ }
791
+ if (!isRecord(field)) {
792
+ throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] must be a string path or object.`);
793
+ }
794
+ const path = stringFromOwn(field, "path", "key", "json_path", "jsonPath");
795
+ if (!path) throw new Error(`target.setup_actions[${index}].return_summary_fields[${fieldIndex}] requires path.`);
796
+ const label = stringFromOwn(field, "label", "name", "title");
797
+ return label ? { path, label } : { path };
798
+ });
799
+ }
733
800
  function normalizeSetupActionRepeat(input, index) {
734
801
  const repeat = numberValue(valueFromOwn(input, "repeat", "repeat_count", "repeatCount", "times"));
735
802
  if (repeat === void 0) return void 0;
@@ -951,6 +1018,7 @@ function normalizeSetupAction(input, index) {
951
1018
  expect_return: hasExpectedReturn ? toJsonValue(valueFromOwn(input, "expect_return", "expectReturn", "expected_return", "expectedReturn")) : void 0,
952
1019
  store_return_to: storeReturnTo,
953
1020
  capture_return: captureReturn,
1021
+ return_summary_fields: normalizeReturnSummaryFields(input, index),
954
1022
  until_path: untilPath,
955
1023
  until_expected_value: hasUntilExpectedValue ? toJsonValue(valueFromOwn(input, "until_expected_value", "untilExpectedValue", "until_expected", "untilExpected", "until_value", "untilValue", "expected_value", "expectedValue", "expected")) : void 0,
956
1024
  max_calls: maxCalls,
@@ -3989,6 +4057,8 @@ function profileSetupWindowCallReceipts(results) {
3989
4057
  };
3990
4058
  if (result.returned !== undefined) receipt.returned = result.returned;
3991
4059
  if (result.expected_return !== undefined) receipt.expected_return = result.expected_return;
4060
+ const returnSummary = profileSetupReturnSummary(result);
4061
+ if (returnSummary.length) receipt.return_summary = returnSummary;
3992
4062
  return receipt;
3993
4063
  });
3994
4064
  }
@@ -4006,9 +4076,43 @@ function profileSetupWindowEvalReceipts(results) {
4006
4076
  };
4007
4077
  if (result.returned !== undefined) receipt.returned = result.returned;
4008
4078
  if (result.expected_return !== undefined) receipt.expected_return = result.expected_return;
4079
+ const returnSummary = profileSetupReturnSummary(result);
4080
+ if (returnSummary.length) receipt.return_summary = returnSummary;
4009
4081
  return receipt;
4010
4082
  });
4011
4083
  }
4084
+ function profileSetupReturnSummaryFields(result) {
4085
+ const input = result && result.return_summary_fields;
4086
+ if (!Array.isArray(input)) return [];
4087
+ const fields = [];
4088
+ for (const item of input) {
4089
+ if (typeof item === "string") {
4090
+ const path = item.trim();
4091
+ if (path) fields.push({ path });
4092
+ continue;
4093
+ }
4094
+ if (!item || typeof item !== "object" || Array.isArray(item)) continue;
4095
+ const path = String(item.path || item.key || item.json_path || item.jsonPath || "").trim();
4096
+ if (!path) continue;
4097
+ const label = String(item.label || item.name || item.title || "").trim();
4098
+ fields.push(label ? { path, label } : { path });
4099
+ }
4100
+ return fields;
4101
+ }
4102
+ function profileSetupReturnSummary(result) {
4103
+ if (!result || result.returned === undefined) return [];
4104
+ return profileSetupReturnSummaryFields(result).map((field) => {
4105
+ const resolved = resolveJsonProbePath(result.returned, field.path);
4106
+ const receipt = {
4107
+ label: field.label || field.path,
4108
+ path: field.path,
4109
+ exists: Boolean(resolved.exists),
4110
+ };
4111
+ if (resolved.exists) receipt.value = setupJsonValue(resolved.value);
4112
+ if (resolved.error) receipt.reason = resolved.error;
4113
+ return receipt;
4114
+ });
4115
+ }
4012
4116
  function profileSetupRangeValueReceipts(results) {
4013
4117
  return (results || [])
4014
4118
  .filter((result) => result && profileSetupResultAction(result) === "set_range_value")
@@ -5743,6 +5847,7 @@ async function executeSetupAction(action, ordinal, viewport) {
5743
5847
  const script = String(action.script || action.code || action.source || action.body || "");
5744
5848
  const args = Array.isArray(action.args) ? action.args : [];
5745
5849
  const storeReturnTo = String(action.store_return_to || action.storeReturnTo || action.save_return_to || action.saveReturnTo || action.assign_return_to || action.assignReturnTo || action.return_state_path || action.returnStatePath || "").trim();
5850
+ const returnSummaryFields = Array.isArray(action.return_summary_fields) ? action.return_summary_fields : [];
5746
5851
  if (!script.trim()) return { ...base, reason: "missing_script" };
5747
5852
  const scope = await setupActionScope(action, timeout);
5748
5853
  if (!scope.ok) return setupScopeFailure(base, scope);
@@ -5772,6 +5877,7 @@ async function executeSetupAction(action, ordinal, viewport) {
5772
5877
  return_captured: captureReturn,
5773
5878
  expected_return: hasExpectation ? setupJsonValue(expected) : undefined,
5774
5879
  return_stored_to: result.return_stored_to || storeReturnTo || undefined,
5880
+ return_summary_fields: returnSummaryFields.length ? setupJsonValue(returnSummaryFields) : undefined,
5775
5881
  reason: result.ok ? (expectationMet ? undefined : "unexpected_return_value") : result.reason,
5776
5882
  store_reason: result.store_reason || undefined,
5777
5883
  error: result.error || undefined,
@@ -5781,6 +5887,7 @@ async function executeSetupAction(action, ordinal, viewport) {
5781
5887
  const path = String(action.path || action.function_path || action.functionPath || "");
5782
5888
  const args = Array.isArray(action.args) ? action.args : [];
5783
5889
  const storeReturnTo = String(action.store_return_to || action.storeReturnTo || action.save_return_to || action.saveReturnTo || action.assign_return_to || action.assignReturnTo || action.return_state_path || action.returnStatePath || "").trim();
5890
+ const returnSummaryFields = Array.isArray(action.return_summary_fields) ? action.return_summary_fields : [];
5784
5891
  if (!path) return { ...base, path, reason: "missing_path" };
5785
5892
  const scope = await setupActionScope(action, timeout);
5786
5893
  if (!scope.ok) return setupScopeFailure(base, scope);
@@ -5810,6 +5917,7 @@ async function executeSetupAction(action, ordinal, viewport) {
5810
5917
  return_captured: captureReturn,
5811
5918
  expected_return: hasExpectation ? setupJsonValue(expected) : undefined,
5812
5919
  return_stored_to: result.return_stored_to || storeReturnTo || undefined,
5920
+ return_summary_fields: returnSummaryFields.length ? setupJsonValue(returnSummaryFields) : undefined,
5813
5921
  reason: result.ok ? (expectationMet ? undefined : "unexpected_return_value") : result.reason,
5814
5922
  store_reason: result.store_reason || undefined,
5815
5923
  error: result.error || undefined,
@@ -133,6 +133,7 @@ interface RiddleProofProfileSetupAction {
133
133
  expect_return?: JsonValue;
134
134
  store_return_to?: string;
135
135
  capture_return?: boolean;
136
+ return_summary_fields?: RiddleProofProfileReturnSummaryField[];
136
137
  until_path?: string;
137
138
  until_expected_value?: JsonValue;
138
139
  max_calls?: number;
@@ -159,6 +160,10 @@ interface RiddleProofProfileSetupAction {
159
160
  optional?: boolean;
160
161
  continue_on_failure?: boolean;
161
162
  }
163
+ interface RiddleProofProfileReturnSummaryField {
164
+ path: string;
165
+ label?: string;
166
+ }
162
167
  interface RiddleProofProfileNetworkMockResponse {
163
168
  label?: string;
164
169
  status: number;
@@ -464,4 +469,4 @@ declare function buildRiddleProofProfileScript(profile: RiddleProofProfile): str
464
469
  declare function collectRiddleProfileArtifactRefs(input: unknown): RiddleProofProfileArtifactRef[];
465
470
  declare function extractRiddleProofProfileResult(input: unknown): RiddleProofProfileResult | undefined;
466
471
 
467
- export { type NormalizeRiddleProofProfileOptions, RIDDLE_PROOF_PROFILE_CHECK_TYPES, RIDDLE_PROOF_PROFILE_EVIDENCE_VERSION, RIDDLE_PROOF_PROFILE_NETWORK_ABORT_ERROR_CODES, RIDDLE_PROOF_PROFILE_RESULT_VERSION, RIDDLE_PROOF_PROFILE_SETUP_ACTION_TYPES, RIDDLE_PROOF_PROFILE_STATUSES, RIDDLE_PROOF_PROFILE_VERSION, type RiddleProofArtifactBodyAssertionInput, type RiddleProofArtifactBodyAssertionResult, type RiddleProofProfile, type RiddleProofProfileArtifactRef, type RiddleProofProfileBaselinePolicy, type RiddleProofProfileBoundsOffender, type RiddleProofProfileCheck, type RiddleProofProfileCheckResult, type RiddleProofProfileCheckType, type RiddleProofProfileEvidence, type RiddleProofProfileFailureAction, type RiddleProofProfileHttpStatusBodyJsonAssertion, type RiddleProofProfileHttpStatusBodyJsonAssertionResult, type RiddleProofProfileHttpStatusPreflightCheckResult, type RiddleProofProfileHttpStatusPreflightFetch, type RiddleProofProfileHttpStatusPreflightFetchResponse, type RiddleProofProfileHttpStatusPreflightOptions, type RiddleProofProfileHttpStatusPreflightResult, type RiddleProofProfileJsonValueType, type RiddleProofProfileNetworkAbortErrorCode, type RiddleProofProfileNetworkMock, type RiddleProofProfileNetworkMockResponse, type RiddleProofProfileResult, type RiddleProofProfileRouteEvidence, type RiddleProofProfileRouteInventoryRoute, type RiddleProofProfileRunner, type RiddleProofProfileSetupAction, type RiddleProofProfileSetupActionType, type RiddleProofProfileStatus, type RiddleProofProfileTarget, type RiddleProofProfileViewport, type RiddleProofProfileViewportEvidence, assessRiddleProofProfileEvidence, buildRiddleProofProfileScript, collectRiddleProfileArtifactRefs, collectRiddleProofProfileWarnings, createRiddleProofProfileConfigurationError, createRiddleProofProfileEnvironmentBlockedResult, createRiddleProofProfileInsufficientResult, deriveRiddleProofArtifactBodyAssertions, extractRiddleProofProfileResult, normalizeRiddleProofProfile, preflightRiddleProofProfileHttpStatusChecks, profileStatusExitCode, resolveRiddleProofProfileRouteUrl, resolveRiddleProofProfileTargetUrl, resolveRiddleProofProfileTimeoutSec, slugifyRiddleProofProfileName, summarizeRiddleProofProfileResult };
472
+ export { type NormalizeRiddleProofProfileOptions, RIDDLE_PROOF_PROFILE_CHECK_TYPES, RIDDLE_PROOF_PROFILE_EVIDENCE_VERSION, RIDDLE_PROOF_PROFILE_NETWORK_ABORT_ERROR_CODES, RIDDLE_PROOF_PROFILE_RESULT_VERSION, RIDDLE_PROOF_PROFILE_SETUP_ACTION_TYPES, RIDDLE_PROOF_PROFILE_STATUSES, RIDDLE_PROOF_PROFILE_VERSION, type RiddleProofArtifactBodyAssertionInput, type RiddleProofArtifactBodyAssertionResult, type RiddleProofProfile, type RiddleProofProfileArtifactRef, type RiddleProofProfileBaselinePolicy, type RiddleProofProfileBoundsOffender, type RiddleProofProfileCheck, type RiddleProofProfileCheckResult, type RiddleProofProfileCheckType, type RiddleProofProfileEvidence, type RiddleProofProfileFailureAction, type RiddleProofProfileHttpStatusBodyJsonAssertion, type RiddleProofProfileHttpStatusBodyJsonAssertionResult, type RiddleProofProfileHttpStatusPreflightCheckResult, type RiddleProofProfileHttpStatusPreflightFetch, type RiddleProofProfileHttpStatusPreflightFetchResponse, type RiddleProofProfileHttpStatusPreflightOptions, type RiddleProofProfileHttpStatusPreflightResult, type RiddleProofProfileJsonValueType, type RiddleProofProfileNetworkAbortErrorCode, type RiddleProofProfileNetworkMock, type RiddleProofProfileNetworkMockResponse, type RiddleProofProfileResult, type RiddleProofProfileReturnSummaryField, type RiddleProofProfileRouteEvidence, type RiddleProofProfileRouteInventoryRoute, type RiddleProofProfileRunner, type RiddleProofProfileSetupAction, type RiddleProofProfileSetupActionType, type RiddleProofProfileStatus, type RiddleProofProfileTarget, type RiddleProofProfileViewport, type RiddleProofProfileViewportEvidence, assessRiddleProofProfileEvidence, buildRiddleProofProfileScript, collectRiddleProfileArtifactRefs, collectRiddleProofProfileWarnings, createRiddleProofProfileConfigurationError, createRiddleProofProfileEnvironmentBlockedResult, createRiddleProofProfileInsufficientResult, deriveRiddleProofArtifactBodyAssertions, extractRiddleProofProfileResult, normalizeRiddleProofProfile, preflightRiddleProofProfileHttpStatusChecks, profileStatusExitCode, resolveRiddleProofProfileRouteUrl, resolveRiddleProofProfileTargetUrl, resolveRiddleProofProfileTimeoutSec, slugifyRiddleProofProfileName, summarizeRiddleProofProfileResult };
package/dist/profile.d.ts CHANGED
@@ -133,6 +133,7 @@ interface RiddleProofProfileSetupAction {
133
133
  expect_return?: JsonValue;
134
134
  store_return_to?: string;
135
135
  capture_return?: boolean;
136
+ return_summary_fields?: RiddleProofProfileReturnSummaryField[];
136
137
  until_path?: string;
137
138
  until_expected_value?: JsonValue;
138
139
  max_calls?: number;
@@ -159,6 +160,10 @@ interface RiddleProofProfileSetupAction {
159
160
  optional?: boolean;
160
161
  continue_on_failure?: boolean;
161
162
  }
163
+ interface RiddleProofProfileReturnSummaryField {
164
+ path: string;
165
+ label?: string;
166
+ }
162
167
  interface RiddleProofProfileNetworkMockResponse {
163
168
  label?: string;
164
169
  status: number;
@@ -464,4 +469,4 @@ declare function buildRiddleProofProfileScript(profile: RiddleProofProfile): str
464
469
  declare function collectRiddleProfileArtifactRefs(input: unknown): RiddleProofProfileArtifactRef[];
465
470
  declare function extractRiddleProofProfileResult(input: unknown): RiddleProofProfileResult | undefined;
466
471
 
467
- export { type NormalizeRiddleProofProfileOptions, RIDDLE_PROOF_PROFILE_CHECK_TYPES, RIDDLE_PROOF_PROFILE_EVIDENCE_VERSION, RIDDLE_PROOF_PROFILE_NETWORK_ABORT_ERROR_CODES, RIDDLE_PROOF_PROFILE_RESULT_VERSION, RIDDLE_PROOF_PROFILE_SETUP_ACTION_TYPES, RIDDLE_PROOF_PROFILE_STATUSES, RIDDLE_PROOF_PROFILE_VERSION, type RiddleProofArtifactBodyAssertionInput, type RiddleProofArtifactBodyAssertionResult, type RiddleProofProfile, type RiddleProofProfileArtifactRef, type RiddleProofProfileBaselinePolicy, type RiddleProofProfileBoundsOffender, type RiddleProofProfileCheck, type RiddleProofProfileCheckResult, type RiddleProofProfileCheckType, type RiddleProofProfileEvidence, type RiddleProofProfileFailureAction, type RiddleProofProfileHttpStatusBodyJsonAssertion, type RiddleProofProfileHttpStatusBodyJsonAssertionResult, type RiddleProofProfileHttpStatusPreflightCheckResult, type RiddleProofProfileHttpStatusPreflightFetch, type RiddleProofProfileHttpStatusPreflightFetchResponse, type RiddleProofProfileHttpStatusPreflightOptions, type RiddleProofProfileHttpStatusPreflightResult, type RiddleProofProfileJsonValueType, type RiddleProofProfileNetworkAbortErrorCode, type RiddleProofProfileNetworkMock, type RiddleProofProfileNetworkMockResponse, type RiddleProofProfileResult, type RiddleProofProfileRouteEvidence, type RiddleProofProfileRouteInventoryRoute, type RiddleProofProfileRunner, type RiddleProofProfileSetupAction, type RiddleProofProfileSetupActionType, type RiddleProofProfileStatus, type RiddleProofProfileTarget, type RiddleProofProfileViewport, type RiddleProofProfileViewportEvidence, assessRiddleProofProfileEvidence, buildRiddleProofProfileScript, collectRiddleProfileArtifactRefs, collectRiddleProofProfileWarnings, createRiddleProofProfileConfigurationError, createRiddleProofProfileEnvironmentBlockedResult, createRiddleProofProfileInsufficientResult, deriveRiddleProofArtifactBodyAssertions, extractRiddleProofProfileResult, normalizeRiddleProofProfile, preflightRiddleProofProfileHttpStatusChecks, profileStatusExitCode, resolveRiddleProofProfileRouteUrl, resolveRiddleProofProfileTargetUrl, resolveRiddleProofProfileTimeoutSec, slugifyRiddleProofProfileName, summarizeRiddleProofProfileResult };
472
+ export { type NormalizeRiddleProofProfileOptions, RIDDLE_PROOF_PROFILE_CHECK_TYPES, RIDDLE_PROOF_PROFILE_EVIDENCE_VERSION, RIDDLE_PROOF_PROFILE_NETWORK_ABORT_ERROR_CODES, RIDDLE_PROOF_PROFILE_RESULT_VERSION, RIDDLE_PROOF_PROFILE_SETUP_ACTION_TYPES, RIDDLE_PROOF_PROFILE_STATUSES, RIDDLE_PROOF_PROFILE_VERSION, type RiddleProofArtifactBodyAssertionInput, type RiddleProofArtifactBodyAssertionResult, type RiddleProofProfile, type RiddleProofProfileArtifactRef, type RiddleProofProfileBaselinePolicy, type RiddleProofProfileBoundsOffender, type RiddleProofProfileCheck, type RiddleProofProfileCheckResult, type RiddleProofProfileCheckType, type RiddleProofProfileEvidence, type RiddleProofProfileFailureAction, type RiddleProofProfileHttpStatusBodyJsonAssertion, type RiddleProofProfileHttpStatusBodyJsonAssertionResult, type RiddleProofProfileHttpStatusPreflightCheckResult, type RiddleProofProfileHttpStatusPreflightFetch, type RiddleProofProfileHttpStatusPreflightFetchResponse, type RiddleProofProfileHttpStatusPreflightOptions, type RiddleProofProfileHttpStatusPreflightResult, type RiddleProofProfileJsonValueType, type RiddleProofProfileNetworkAbortErrorCode, type RiddleProofProfileNetworkMock, type RiddleProofProfileNetworkMockResponse, type RiddleProofProfileResult, type RiddleProofProfileReturnSummaryField, type RiddleProofProfileRouteEvidence, type RiddleProofProfileRouteInventoryRoute, type RiddleProofProfileRunner, type RiddleProofProfileSetupAction, type RiddleProofProfileSetupActionType, type RiddleProofProfileStatus, type RiddleProofProfileTarget, type RiddleProofProfileViewport, type RiddleProofProfileViewportEvidence, assessRiddleProofProfileEvidence, buildRiddleProofProfileScript, collectRiddleProfileArtifactRefs, collectRiddleProofProfileWarnings, createRiddleProofProfileConfigurationError, createRiddleProofProfileEnvironmentBlockedResult, createRiddleProofProfileInsufficientResult, deriveRiddleProofArtifactBodyAssertions, extractRiddleProofProfileResult, normalizeRiddleProofProfile, preflightRiddleProofProfileHttpStatusChecks, profileStatusExitCode, resolveRiddleProofProfileRouteUrl, resolveRiddleProofProfileTargetUrl, resolveRiddleProofProfileTimeoutSec, slugifyRiddleProofProfileName, summarizeRiddleProofProfileResult };
package/dist/profile.js CHANGED
@@ -23,7 +23,7 @@ import {
23
23
  resolveRiddleProofProfileTimeoutSec,
24
24
  slugifyRiddleProofProfileName,
25
25
  summarizeRiddleProofProfileResult
26
- } from "./chunk-QJJ3ISMK.js";
26
+ } from "./chunk-YB3LNLZB.js";
27
27
  export {
28
28
  RIDDLE_PROOF_PROFILE_CHECK_TYPES,
29
29
  RIDDLE_PROOF_PROFILE_EVIDENCE_VERSION,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riddledc/riddle-proof",
3
- "version": "0.7.153",
3
+ "version": "0.7.155",
4
4
  "description": "Reusable Riddle Proof contracts and helpers for evidence-backed agent changes.",
5
5
  "license": "MIT",
6
6
  "author": "RiddleDC",