@riddledc/riddle-proof 0.7.143 → 0.7.144
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/dist/{chunk-66RDQVFI.js → chunk-LFFTWXLB.js} +40 -2
- package/dist/cli.cjs +67 -2
- package/dist/cli.js +28 -1
- package/dist/index.cjs +40 -2
- package/dist/index.js +1 -1
- package/dist/profile.cjs +40 -2
- package/dist/profile.js +1 -1
- package/dist/proof-run-engine.d.cts +3 -3
- package/dist/proof-run-engine.d.ts +3 -3
- package/package.json +1 -1
|
@@ -2044,6 +2044,20 @@ function summarizeRouteInventory(viewport, inventory) {
|
|
|
2044
2044
|
failure_count: failures.length
|
|
2045
2045
|
};
|
|
2046
2046
|
}
|
|
2047
|
+
function routeInventoryExpectedRouteSummaries(value, fallback) {
|
|
2048
|
+
const rawRoutes = Array.isArray(value) ? value : Array.isArray(fallback) ? fallback : [];
|
|
2049
|
+
return rawRoutes.map((route) => {
|
|
2050
|
+
if (typeof route === "string") {
|
|
2051
|
+
const path2 = route.trim();
|
|
2052
|
+
return path2 ? { path: path2 } : void 0;
|
|
2053
|
+
}
|
|
2054
|
+
if (!isRecord(route)) return void 0;
|
|
2055
|
+
const path = stringValue(route.path);
|
|
2056
|
+
if (!path) return void 0;
|
|
2057
|
+
const name = stringValue(route.name);
|
|
2058
|
+
return name ? { name, path } : { path };
|
|
2059
|
+
}).filter((route) => Boolean(route));
|
|
2060
|
+
}
|
|
2047
2061
|
function matchText(sample, check) {
|
|
2048
2062
|
if (check.pattern) {
|
|
2049
2063
|
try {
|
|
@@ -2645,7 +2659,10 @@ function assessCheckFromEvidence(check, evidence) {
|
|
|
2645
2659
|
type: check.type,
|
|
2646
2660
|
label: checkLabel(check),
|
|
2647
2661
|
status: "failed",
|
|
2648
|
-
evidence: {
|
|
2662
|
+
evidence: {
|
|
2663
|
+
expected_count: check.expected_routes?.length || 0,
|
|
2664
|
+
expected_routes: routeInventoryExpectedRouteSummaries(void 0, check.expected_routes)
|
|
2665
|
+
},
|
|
2649
2666
|
message: "No route inventory evidence was captured."
|
|
2650
2667
|
};
|
|
2651
2668
|
}
|
|
@@ -2658,12 +2675,14 @@ function assessCheckFromEvidence(check, evidence) {
|
|
|
2658
2675
|
const sourceUniqueLinkCount = numberValue(first?.source_unique_link_count) ?? numberValue(first?.home_unique_game_link_count) ?? null;
|
|
2659
2676
|
const duplicateSourceLinks = Array.isArray(first?.duplicate_source_link_paths) ? first.duplicate_source_link_paths.map((path) => String(path)) : [];
|
|
2660
2677
|
const duplicateSourceLinkCount = numberValue(first?.duplicate_source_link_count) ?? (sourceLinkCount !== null && sourceUniqueLinkCount !== null ? Math.max(0, sourceLinkCount - sourceUniqueLinkCount) : null);
|
|
2678
|
+
const expectedRoutes = routeInventoryExpectedRouteSummaries(first?.expected_routes, check.expected_routes);
|
|
2661
2679
|
return {
|
|
2662
2680
|
type: check.type,
|
|
2663
2681
|
label: checkLabel(check),
|
|
2664
2682
|
status: failures.length ? "failed" : "passed",
|
|
2665
2683
|
evidence: {
|
|
2666
2684
|
expected_count: check.expected_routes?.length || 0,
|
|
2685
|
+
expected_routes: expectedRoutes,
|
|
2667
2686
|
source_link_count: sourceLinkCount,
|
|
2668
2687
|
source_unique_link_count: sourceUniqueLinkCount,
|
|
2669
2688
|
duplicate_source_link_count: duplicateSourceLinkCount,
|
|
@@ -3670,6 +3689,20 @@ function summarizeRouteInventory(viewport, inventory) {
|
|
|
3670
3689
|
failure_count: failures.length,
|
|
3671
3690
|
};
|
|
3672
3691
|
}
|
|
3692
|
+
function routeInventoryExpectedRouteSummaries(value, fallback) {
|
|
3693
|
+
const rawRoutes = Array.isArray(value) ? value : Array.isArray(fallback) ? fallback : [];
|
|
3694
|
+
return rawRoutes.map((route) => {
|
|
3695
|
+
if (typeof route === "string") {
|
|
3696
|
+
const path = route.trim();
|
|
3697
|
+
return path ? { path } : null;
|
|
3698
|
+
}
|
|
3699
|
+
if (!route || typeof route !== "object" || Array.isArray(route)) return null;
|
|
3700
|
+
const path = typeof route.path === "string" && route.path.trim() ? route.path.trim() : "";
|
|
3701
|
+
if (!path) return null;
|
|
3702
|
+
const name = typeof route.name === "string" && route.name.trim() ? route.name.trim() : "";
|
|
3703
|
+
return name ? { name, path } : { path };
|
|
3704
|
+
}).filter(Boolean);
|
|
3705
|
+
}
|
|
3673
3706
|
function numberValue(value) {
|
|
3674
3707
|
return typeof value === "number" && Number.isFinite(value) ? value : undefined;
|
|
3675
3708
|
}
|
|
@@ -4497,7 +4530,10 @@ function assessProfile(profile, evidence) {
|
|
|
4497
4530
|
type: check.type,
|
|
4498
4531
|
label: check.label || check.type,
|
|
4499
4532
|
status: "failed",
|
|
4500
|
-
evidence: {
|
|
4533
|
+
evidence: {
|
|
4534
|
+
expected_count: (check.expected_routes || []).length,
|
|
4535
|
+
expected_routes: routeInventoryExpectedRouteSummaries(undefined, check.expected_routes),
|
|
4536
|
+
},
|
|
4501
4537
|
message: "No route inventory evidence was captured.",
|
|
4502
4538
|
});
|
|
4503
4539
|
continue;
|
|
@@ -4516,12 +4552,14 @@ function assessProfile(profile, evidence) {
|
|
|
4516
4552
|
const sourceUniqueLinkCount = typeof first.source_unique_link_count === "number" ? first.source_unique_link_count : typeof first.home_unique_game_link_count === "number" ? first.home_unique_game_link_count : null;
|
|
4517
4553
|
const duplicateSourceLinks = Array.isArray(first.duplicate_source_link_paths) ? first.duplicate_source_link_paths.map((path) => String(path)) : [];
|
|
4518
4554
|
const duplicateSourceLinkCount = typeof first.duplicate_source_link_count === "number" ? first.duplicate_source_link_count : sourceLinkCount !== null && sourceUniqueLinkCount !== null ? Math.max(0, sourceLinkCount - sourceUniqueLinkCount) : null;
|
|
4555
|
+
const expectedRoutes = routeInventoryExpectedRouteSummaries(first.expected_routes, check.expected_routes);
|
|
4519
4556
|
checks.push({
|
|
4520
4557
|
type: check.type,
|
|
4521
4558
|
label: check.label || check.type,
|
|
4522
4559
|
status: failures.length ? "failed" : "passed",
|
|
4523
4560
|
evidence: {
|
|
4524
4561
|
expected_count: (check.expected_routes || []).length,
|
|
4562
|
+
expected_routes: expectedRoutes,
|
|
4525
4563
|
source_link_count: sourceLinkCount,
|
|
4526
4564
|
source_unique_link_count: sourceUniqueLinkCount,
|
|
4527
4565
|
duplicate_source_link_count: duplicateSourceLinkCount,
|
package/dist/cli.cjs
CHANGED
|
@@ -8981,6 +8981,20 @@ function summarizeRouteInventory(viewport, inventory) {
|
|
|
8981
8981
|
failure_count: failures.length
|
|
8982
8982
|
};
|
|
8983
8983
|
}
|
|
8984
|
+
function routeInventoryExpectedRouteSummaries(value, fallback) {
|
|
8985
|
+
const rawRoutes = Array.isArray(value) ? value : Array.isArray(fallback) ? fallback : [];
|
|
8986
|
+
return rawRoutes.map((route) => {
|
|
8987
|
+
if (typeof route === "string") {
|
|
8988
|
+
const path8 = route.trim();
|
|
8989
|
+
return path8 ? { path: path8 } : void 0;
|
|
8990
|
+
}
|
|
8991
|
+
if (!isRecord(route)) return void 0;
|
|
8992
|
+
const path7 = stringValue2(route.path);
|
|
8993
|
+
if (!path7) return void 0;
|
|
8994
|
+
const name = stringValue2(route.name);
|
|
8995
|
+
return name ? { name, path: path7 } : { path: path7 };
|
|
8996
|
+
}).filter((route) => Boolean(route));
|
|
8997
|
+
}
|
|
8984
8998
|
function matchText(sample, check) {
|
|
8985
8999
|
if (check.pattern) {
|
|
8986
9000
|
try {
|
|
@@ -9582,7 +9596,10 @@ function assessCheckFromEvidence(check, evidence) {
|
|
|
9582
9596
|
type: check.type,
|
|
9583
9597
|
label: checkLabel(check),
|
|
9584
9598
|
status: "failed",
|
|
9585
|
-
evidence: {
|
|
9599
|
+
evidence: {
|
|
9600
|
+
expected_count: check.expected_routes?.length || 0,
|
|
9601
|
+
expected_routes: routeInventoryExpectedRouteSummaries(void 0, check.expected_routes)
|
|
9602
|
+
},
|
|
9586
9603
|
message: "No route inventory evidence was captured."
|
|
9587
9604
|
};
|
|
9588
9605
|
}
|
|
@@ -9595,12 +9612,14 @@ function assessCheckFromEvidence(check, evidence) {
|
|
|
9595
9612
|
const sourceUniqueLinkCount = numberValue(first?.source_unique_link_count) ?? numberValue(first?.home_unique_game_link_count) ?? null;
|
|
9596
9613
|
const duplicateSourceLinks = Array.isArray(first?.duplicate_source_link_paths) ? first.duplicate_source_link_paths.map((path7) => String(path7)) : [];
|
|
9597
9614
|
const duplicateSourceLinkCount = numberValue(first?.duplicate_source_link_count) ?? (sourceLinkCount !== null && sourceUniqueLinkCount !== null ? Math.max(0, sourceLinkCount - sourceUniqueLinkCount) : null);
|
|
9615
|
+
const expectedRoutes = routeInventoryExpectedRouteSummaries(first?.expected_routes, check.expected_routes);
|
|
9598
9616
|
return {
|
|
9599
9617
|
type: check.type,
|
|
9600
9618
|
label: checkLabel(check),
|
|
9601
9619
|
status: failures.length ? "failed" : "passed",
|
|
9602
9620
|
evidence: {
|
|
9603
9621
|
expected_count: check.expected_routes?.length || 0,
|
|
9622
|
+
expected_routes: expectedRoutes,
|
|
9604
9623
|
source_link_count: sourceLinkCount,
|
|
9605
9624
|
source_unique_link_count: sourceUniqueLinkCount,
|
|
9606
9625
|
duplicate_source_link_count: duplicateSourceLinkCount,
|
|
@@ -10591,6 +10610,20 @@ function summarizeRouteInventory(viewport, inventory) {
|
|
|
10591
10610
|
failure_count: failures.length,
|
|
10592
10611
|
};
|
|
10593
10612
|
}
|
|
10613
|
+
function routeInventoryExpectedRouteSummaries(value, fallback) {
|
|
10614
|
+
const rawRoutes = Array.isArray(value) ? value : Array.isArray(fallback) ? fallback : [];
|
|
10615
|
+
return rawRoutes.map((route) => {
|
|
10616
|
+
if (typeof route === "string") {
|
|
10617
|
+
const path = route.trim();
|
|
10618
|
+
return path ? { path } : null;
|
|
10619
|
+
}
|
|
10620
|
+
if (!route || typeof route !== "object" || Array.isArray(route)) return null;
|
|
10621
|
+
const path = typeof route.path === "string" && route.path.trim() ? route.path.trim() : "";
|
|
10622
|
+
if (!path) return null;
|
|
10623
|
+
const name = typeof route.name === "string" && route.name.trim() ? route.name.trim() : "";
|
|
10624
|
+
return name ? { name, path } : { path };
|
|
10625
|
+
}).filter(Boolean);
|
|
10626
|
+
}
|
|
10594
10627
|
function numberValue(value) {
|
|
10595
10628
|
return typeof value === "number" && Number.isFinite(value) ? value : undefined;
|
|
10596
10629
|
}
|
|
@@ -11418,7 +11451,10 @@ function assessProfile(profile, evidence) {
|
|
|
11418
11451
|
type: check.type,
|
|
11419
11452
|
label: check.label || check.type,
|
|
11420
11453
|
status: "failed",
|
|
11421
|
-
evidence: {
|
|
11454
|
+
evidence: {
|
|
11455
|
+
expected_count: (check.expected_routes || []).length,
|
|
11456
|
+
expected_routes: routeInventoryExpectedRouteSummaries(undefined, check.expected_routes),
|
|
11457
|
+
},
|
|
11422
11458
|
message: "No route inventory evidence was captured.",
|
|
11423
11459
|
});
|
|
11424
11460
|
continue;
|
|
@@ -11437,12 +11473,14 @@ function assessProfile(profile, evidence) {
|
|
|
11437
11473
|
const sourceUniqueLinkCount = typeof first.source_unique_link_count === "number" ? first.source_unique_link_count : typeof first.home_unique_game_link_count === "number" ? first.home_unique_game_link_count : null;
|
|
11438
11474
|
const duplicateSourceLinks = Array.isArray(first.duplicate_source_link_paths) ? first.duplicate_source_link_paths.map((path) => String(path)) : [];
|
|
11439
11475
|
const duplicateSourceLinkCount = typeof first.duplicate_source_link_count === "number" ? first.duplicate_source_link_count : sourceLinkCount !== null && sourceUniqueLinkCount !== null ? Math.max(0, sourceLinkCount - sourceUniqueLinkCount) : null;
|
|
11476
|
+
const expectedRoutes = routeInventoryExpectedRouteSummaries(first.expected_routes, check.expected_routes);
|
|
11440
11477
|
checks.push({
|
|
11441
11478
|
type: check.type,
|
|
11442
11479
|
label: check.label || check.type,
|
|
11443
11480
|
status: failures.length ? "failed" : "passed",
|
|
11444
11481
|
evidence: {
|
|
11445
11482
|
expected_count: (check.expected_routes || []).length,
|
|
11483
|
+
expected_routes: expectedRoutes,
|
|
11446
11484
|
source_link_count: sourceLinkCount,
|
|
11447
11485
|
source_unique_link_count: sourceUniqueLinkCount,
|
|
11448
11486
|
duplicate_source_link_count: duplicateSourceLinkCount,
|
|
@@ -14820,6 +14858,29 @@ function cliValueLabel(value) {
|
|
|
14820
14858
|
function cliStringArray(value) {
|
|
14821
14859
|
return Array.isArray(value) ? value.filter((entry) => typeof entry === "string" && Boolean(entry.trim())) : [];
|
|
14822
14860
|
}
|
|
14861
|
+
function cliRouteInventoryRoutes(value) {
|
|
14862
|
+
if (!Array.isArray(value)) return [];
|
|
14863
|
+
return value.map((entry) => {
|
|
14864
|
+
if (typeof entry === "string") {
|
|
14865
|
+
const pathValue2 = entry.trim();
|
|
14866
|
+
return pathValue2 ? { path: pathValue2 } : void 0;
|
|
14867
|
+
}
|
|
14868
|
+
const route = cliRecord(entry);
|
|
14869
|
+
if (!route) return void 0;
|
|
14870
|
+
const pathValue = cliString(route.path);
|
|
14871
|
+
if (!pathValue) return void 0;
|
|
14872
|
+
const nameValue = cliString(route.name);
|
|
14873
|
+
return nameValue ? { name: nameValue, path: pathValue } : { path: pathValue };
|
|
14874
|
+
}).filter((route) => Boolean(route));
|
|
14875
|
+
}
|
|
14876
|
+
function cliRouteInventoryRouteLabel(route) {
|
|
14877
|
+
return route.name && route.name !== route.path ? `${route.name} (${route.path})` : route.path;
|
|
14878
|
+
}
|
|
14879
|
+
function cliRouteInventoryRouteList(routes) {
|
|
14880
|
+
const visible = routes.slice(0, 12).map(cliRouteInventoryRouteLabel);
|
|
14881
|
+
const omitted = routes.length > 12 ? `; ${routes.length - 12} more` : "";
|
|
14882
|
+
return `${visible.join("; ")}${omitted}`;
|
|
14883
|
+
}
|
|
14823
14884
|
function profileEnvironmentBlockerMarkdown(result) {
|
|
14824
14885
|
const blocker = cliRecord(result.environment_blocker);
|
|
14825
14886
|
if (!blocker) return [];
|
|
@@ -15063,6 +15124,10 @@ function profileRouteInventorySummaryMarkdown(result) {
|
|
|
15063
15124
|
const duplicateText = duplicateLinks.length ? `: ${duplicateLinks.slice(0, 8).join(", ")}${duplicateLinks.length > 8 ? `, ${duplicateLinks.length - 8} more` : ""}` : "";
|
|
15064
15125
|
lines.push(`- ${label} duplicate source links: ${duplicateCount}${evidence.duplicates_allowed === true ? " allowed" : ""}${duplicateText}`);
|
|
15065
15126
|
}
|
|
15127
|
+
const expectedRoutes = cliRouteInventoryRoutes(evidence.expected_routes);
|
|
15128
|
+
if (expectedRoutes.length) {
|
|
15129
|
+
lines.push(`- ${label} expected routes: ${cliRouteInventoryRouteList(expectedRoutes)}`);
|
|
15130
|
+
}
|
|
15066
15131
|
for (const viewport of viewports.slice(0, 8)) {
|
|
15067
15132
|
const viewportName = cliString(viewport.viewport) || cliString(viewport.name) || "viewport";
|
|
15068
15133
|
const viewportSourceLinkCount = cliFiniteNumber(viewport.source_link_count);
|
package/dist/cli.js
CHANGED
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
profileStatusExitCode,
|
|
13
13
|
resolveRiddleProofProfileTargetUrl,
|
|
14
14
|
resolveRiddleProofProfileTimeoutSec
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-LFFTWXLB.js";
|
|
16
16
|
import {
|
|
17
17
|
createRiddleApiClient,
|
|
18
18
|
parseRiddleViewport
|
|
@@ -567,6 +567,29 @@ function cliValueLabel(value) {
|
|
|
567
567
|
function cliStringArray(value) {
|
|
568
568
|
return Array.isArray(value) ? value.filter((entry) => typeof entry === "string" && Boolean(entry.trim())) : [];
|
|
569
569
|
}
|
|
570
|
+
function cliRouteInventoryRoutes(value) {
|
|
571
|
+
if (!Array.isArray(value)) return [];
|
|
572
|
+
return value.map((entry) => {
|
|
573
|
+
if (typeof entry === "string") {
|
|
574
|
+
const pathValue2 = entry.trim();
|
|
575
|
+
return pathValue2 ? { path: pathValue2 } : void 0;
|
|
576
|
+
}
|
|
577
|
+
const route = cliRecord(entry);
|
|
578
|
+
if (!route) return void 0;
|
|
579
|
+
const pathValue = cliString(route.path);
|
|
580
|
+
if (!pathValue) return void 0;
|
|
581
|
+
const nameValue = cliString(route.name);
|
|
582
|
+
return nameValue ? { name: nameValue, path: pathValue } : { path: pathValue };
|
|
583
|
+
}).filter((route) => Boolean(route));
|
|
584
|
+
}
|
|
585
|
+
function cliRouteInventoryRouteLabel(route) {
|
|
586
|
+
return route.name && route.name !== route.path ? `${route.name} (${route.path})` : route.path;
|
|
587
|
+
}
|
|
588
|
+
function cliRouteInventoryRouteList(routes) {
|
|
589
|
+
const visible = routes.slice(0, 12).map(cliRouteInventoryRouteLabel);
|
|
590
|
+
const omitted = routes.length > 12 ? `; ${routes.length - 12} more` : "";
|
|
591
|
+
return `${visible.join("; ")}${omitted}`;
|
|
592
|
+
}
|
|
570
593
|
function profileEnvironmentBlockerMarkdown(result) {
|
|
571
594
|
const blocker = cliRecord(result.environment_blocker);
|
|
572
595
|
if (!blocker) return [];
|
|
@@ -810,6 +833,10 @@ function profileRouteInventorySummaryMarkdown(result) {
|
|
|
810
833
|
const duplicateText = duplicateLinks.length ? `: ${duplicateLinks.slice(0, 8).join(", ")}${duplicateLinks.length > 8 ? `, ${duplicateLinks.length - 8} more` : ""}` : "";
|
|
811
834
|
lines.push(`- ${label} duplicate source links: ${duplicateCount}${evidence.duplicates_allowed === true ? " allowed" : ""}${duplicateText}`);
|
|
812
835
|
}
|
|
836
|
+
const expectedRoutes = cliRouteInventoryRoutes(evidence.expected_routes);
|
|
837
|
+
if (expectedRoutes.length) {
|
|
838
|
+
lines.push(`- ${label} expected routes: ${cliRouteInventoryRouteList(expectedRoutes)}`);
|
|
839
|
+
}
|
|
813
840
|
for (const viewport of viewports.slice(0, 8)) {
|
|
814
841
|
const viewportName = cliString(viewport.viewport) || cliString(viewport.name) || "viewport";
|
|
815
842
|
const viewportSourceLinkCount = cliFiniteNumber(viewport.source_link_count);
|
package/dist/index.cjs
CHANGED
|
@@ -10777,6 +10777,20 @@ function summarizeRouteInventory(viewport, inventory) {
|
|
|
10777
10777
|
failure_count: failures.length
|
|
10778
10778
|
};
|
|
10779
10779
|
}
|
|
10780
|
+
function routeInventoryExpectedRouteSummaries(value, fallback) {
|
|
10781
|
+
const rawRoutes = Array.isArray(value) ? value : Array.isArray(fallback) ? fallback : [];
|
|
10782
|
+
return rawRoutes.map((route) => {
|
|
10783
|
+
if (typeof route === "string") {
|
|
10784
|
+
const path7 = route.trim();
|
|
10785
|
+
return path7 ? { path: path7 } : void 0;
|
|
10786
|
+
}
|
|
10787
|
+
if (!isRecord2(route)) return void 0;
|
|
10788
|
+
const path6 = stringValue5(route.path);
|
|
10789
|
+
if (!path6) return void 0;
|
|
10790
|
+
const name = stringValue5(route.name);
|
|
10791
|
+
return name ? { name, path: path6 } : { path: path6 };
|
|
10792
|
+
}).filter((route) => Boolean(route));
|
|
10793
|
+
}
|
|
10780
10794
|
function matchText(sample, check) {
|
|
10781
10795
|
if (check.pattern) {
|
|
10782
10796
|
try {
|
|
@@ -11378,7 +11392,10 @@ function assessCheckFromEvidence(check, evidence) {
|
|
|
11378
11392
|
type: check.type,
|
|
11379
11393
|
label: checkLabel(check),
|
|
11380
11394
|
status: "failed",
|
|
11381
|
-
evidence: {
|
|
11395
|
+
evidence: {
|
|
11396
|
+
expected_count: check.expected_routes?.length || 0,
|
|
11397
|
+
expected_routes: routeInventoryExpectedRouteSummaries(void 0, check.expected_routes)
|
|
11398
|
+
},
|
|
11382
11399
|
message: "No route inventory evidence was captured."
|
|
11383
11400
|
};
|
|
11384
11401
|
}
|
|
@@ -11391,12 +11408,14 @@ function assessCheckFromEvidence(check, evidence) {
|
|
|
11391
11408
|
const sourceUniqueLinkCount = numberValue3(first?.source_unique_link_count) ?? numberValue3(first?.home_unique_game_link_count) ?? null;
|
|
11392
11409
|
const duplicateSourceLinks = Array.isArray(first?.duplicate_source_link_paths) ? first.duplicate_source_link_paths.map((path6) => String(path6)) : [];
|
|
11393
11410
|
const duplicateSourceLinkCount = numberValue3(first?.duplicate_source_link_count) ?? (sourceLinkCount !== null && sourceUniqueLinkCount !== null ? Math.max(0, sourceLinkCount - sourceUniqueLinkCount) : null);
|
|
11411
|
+
const expectedRoutes = routeInventoryExpectedRouteSummaries(first?.expected_routes, check.expected_routes);
|
|
11394
11412
|
return {
|
|
11395
11413
|
type: check.type,
|
|
11396
11414
|
label: checkLabel(check),
|
|
11397
11415
|
status: failures.length ? "failed" : "passed",
|
|
11398
11416
|
evidence: {
|
|
11399
11417
|
expected_count: check.expected_routes?.length || 0,
|
|
11418
|
+
expected_routes: expectedRoutes,
|
|
11400
11419
|
source_link_count: sourceLinkCount,
|
|
11401
11420
|
source_unique_link_count: sourceUniqueLinkCount,
|
|
11402
11421
|
duplicate_source_link_count: duplicateSourceLinkCount,
|
|
@@ -12403,6 +12422,20 @@ function summarizeRouteInventory(viewport, inventory) {
|
|
|
12403
12422
|
failure_count: failures.length,
|
|
12404
12423
|
};
|
|
12405
12424
|
}
|
|
12425
|
+
function routeInventoryExpectedRouteSummaries(value, fallback) {
|
|
12426
|
+
const rawRoutes = Array.isArray(value) ? value : Array.isArray(fallback) ? fallback : [];
|
|
12427
|
+
return rawRoutes.map((route) => {
|
|
12428
|
+
if (typeof route === "string") {
|
|
12429
|
+
const path = route.trim();
|
|
12430
|
+
return path ? { path } : null;
|
|
12431
|
+
}
|
|
12432
|
+
if (!route || typeof route !== "object" || Array.isArray(route)) return null;
|
|
12433
|
+
const path = typeof route.path === "string" && route.path.trim() ? route.path.trim() : "";
|
|
12434
|
+
if (!path) return null;
|
|
12435
|
+
const name = typeof route.name === "string" && route.name.trim() ? route.name.trim() : "";
|
|
12436
|
+
return name ? { name, path } : { path };
|
|
12437
|
+
}).filter(Boolean);
|
|
12438
|
+
}
|
|
12406
12439
|
function numberValue(value) {
|
|
12407
12440
|
return typeof value === "number" && Number.isFinite(value) ? value : undefined;
|
|
12408
12441
|
}
|
|
@@ -13230,7 +13263,10 @@ function assessProfile(profile, evidence) {
|
|
|
13230
13263
|
type: check.type,
|
|
13231
13264
|
label: check.label || check.type,
|
|
13232
13265
|
status: "failed",
|
|
13233
|
-
evidence: {
|
|
13266
|
+
evidence: {
|
|
13267
|
+
expected_count: (check.expected_routes || []).length,
|
|
13268
|
+
expected_routes: routeInventoryExpectedRouteSummaries(undefined, check.expected_routes),
|
|
13269
|
+
},
|
|
13234
13270
|
message: "No route inventory evidence was captured.",
|
|
13235
13271
|
});
|
|
13236
13272
|
continue;
|
|
@@ -13249,12 +13285,14 @@ function assessProfile(profile, evidence) {
|
|
|
13249
13285
|
const sourceUniqueLinkCount = typeof first.source_unique_link_count === "number" ? first.source_unique_link_count : typeof first.home_unique_game_link_count === "number" ? first.home_unique_game_link_count : null;
|
|
13250
13286
|
const duplicateSourceLinks = Array.isArray(first.duplicate_source_link_paths) ? first.duplicate_source_link_paths.map((path) => String(path)) : [];
|
|
13251
13287
|
const duplicateSourceLinkCount = typeof first.duplicate_source_link_count === "number" ? first.duplicate_source_link_count : sourceLinkCount !== null && sourceUniqueLinkCount !== null ? Math.max(0, sourceLinkCount - sourceUniqueLinkCount) : null;
|
|
13288
|
+
const expectedRoutes = routeInventoryExpectedRouteSummaries(first.expected_routes, check.expected_routes);
|
|
13252
13289
|
checks.push({
|
|
13253
13290
|
type: check.type,
|
|
13254
13291
|
label: check.label || check.type,
|
|
13255
13292
|
status: failures.length ? "failed" : "passed",
|
|
13256
13293
|
evidence: {
|
|
13257
13294
|
expected_count: (check.expected_routes || []).length,
|
|
13295
|
+
expected_routes: expectedRoutes,
|
|
13258
13296
|
source_link_count: sourceLinkCount,
|
|
13259
13297
|
source_unique_link_count: sourceUniqueLinkCount,
|
|
13260
13298
|
duplicate_source_link_count: duplicateSourceLinkCount,
|
package/dist/index.js
CHANGED
|
@@ -62,7 +62,7 @@ import {
|
|
|
62
62
|
resolveRiddleProofProfileTimeoutSec,
|
|
63
63
|
slugifyRiddleProofProfileName,
|
|
64
64
|
summarizeRiddleProofProfileResult
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-LFFTWXLB.js";
|
|
66
66
|
import {
|
|
67
67
|
DEFAULT_RIDDLE_API_BASE_URL,
|
|
68
68
|
DEFAULT_RIDDLE_API_KEY_FILE,
|
package/dist/profile.cjs
CHANGED
|
@@ -2091,6 +2091,20 @@ function summarizeRouteInventory(viewport, inventory) {
|
|
|
2091
2091
|
failure_count: failures.length
|
|
2092
2092
|
};
|
|
2093
2093
|
}
|
|
2094
|
+
function routeInventoryExpectedRouteSummaries(value, fallback) {
|
|
2095
|
+
const rawRoutes = Array.isArray(value) ? value : Array.isArray(fallback) ? fallback : [];
|
|
2096
|
+
return rawRoutes.map((route) => {
|
|
2097
|
+
if (typeof route === "string") {
|
|
2098
|
+
const path2 = route.trim();
|
|
2099
|
+
return path2 ? { path: path2 } : void 0;
|
|
2100
|
+
}
|
|
2101
|
+
if (!isRecord(route)) return void 0;
|
|
2102
|
+
const path = stringValue(route.path);
|
|
2103
|
+
if (!path) return void 0;
|
|
2104
|
+
const name = stringValue(route.name);
|
|
2105
|
+
return name ? { name, path } : { path };
|
|
2106
|
+
}).filter((route) => Boolean(route));
|
|
2107
|
+
}
|
|
2094
2108
|
function matchText(sample, check) {
|
|
2095
2109
|
if (check.pattern) {
|
|
2096
2110
|
try {
|
|
@@ -2692,7 +2706,10 @@ function assessCheckFromEvidence(check, evidence) {
|
|
|
2692
2706
|
type: check.type,
|
|
2693
2707
|
label: checkLabel(check),
|
|
2694
2708
|
status: "failed",
|
|
2695
|
-
evidence: {
|
|
2709
|
+
evidence: {
|
|
2710
|
+
expected_count: check.expected_routes?.length || 0,
|
|
2711
|
+
expected_routes: routeInventoryExpectedRouteSummaries(void 0, check.expected_routes)
|
|
2712
|
+
},
|
|
2696
2713
|
message: "No route inventory evidence was captured."
|
|
2697
2714
|
};
|
|
2698
2715
|
}
|
|
@@ -2705,12 +2722,14 @@ function assessCheckFromEvidence(check, evidence) {
|
|
|
2705
2722
|
const sourceUniqueLinkCount = numberValue(first?.source_unique_link_count) ?? numberValue(first?.home_unique_game_link_count) ?? null;
|
|
2706
2723
|
const duplicateSourceLinks = Array.isArray(first?.duplicate_source_link_paths) ? first.duplicate_source_link_paths.map((path) => String(path)) : [];
|
|
2707
2724
|
const duplicateSourceLinkCount = numberValue(first?.duplicate_source_link_count) ?? (sourceLinkCount !== null && sourceUniqueLinkCount !== null ? Math.max(0, sourceLinkCount - sourceUniqueLinkCount) : null);
|
|
2725
|
+
const expectedRoutes = routeInventoryExpectedRouteSummaries(first?.expected_routes, check.expected_routes);
|
|
2708
2726
|
return {
|
|
2709
2727
|
type: check.type,
|
|
2710
2728
|
label: checkLabel(check),
|
|
2711
2729
|
status: failures.length ? "failed" : "passed",
|
|
2712
2730
|
evidence: {
|
|
2713
2731
|
expected_count: check.expected_routes?.length || 0,
|
|
2732
|
+
expected_routes: expectedRoutes,
|
|
2714
2733
|
source_link_count: sourceLinkCount,
|
|
2715
2734
|
source_unique_link_count: sourceUniqueLinkCount,
|
|
2716
2735
|
duplicate_source_link_count: duplicateSourceLinkCount,
|
|
@@ -3717,6 +3736,20 @@ function summarizeRouteInventory(viewport, inventory) {
|
|
|
3717
3736
|
failure_count: failures.length,
|
|
3718
3737
|
};
|
|
3719
3738
|
}
|
|
3739
|
+
function routeInventoryExpectedRouteSummaries(value, fallback) {
|
|
3740
|
+
const rawRoutes = Array.isArray(value) ? value : Array.isArray(fallback) ? fallback : [];
|
|
3741
|
+
return rawRoutes.map((route) => {
|
|
3742
|
+
if (typeof route === "string") {
|
|
3743
|
+
const path = route.trim();
|
|
3744
|
+
return path ? { path } : null;
|
|
3745
|
+
}
|
|
3746
|
+
if (!route || typeof route !== "object" || Array.isArray(route)) return null;
|
|
3747
|
+
const path = typeof route.path === "string" && route.path.trim() ? route.path.trim() : "";
|
|
3748
|
+
if (!path) return null;
|
|
3749
|
+
const name = typeof route.name === "string" && route.name.trim() ? route.name.trim() : "";
|
|
3750
|
+
return name ? { name, path } : { path };
|
|
3751
|
+
}).filter(Boolean);
|
|
3752
|
+
}
|
|
3720
3753
|
function numberValue(value) {
|
|
3721
3754
|
return typeof value === "number" && Number.isFinite(value) ? value : undefined;
|
|
3722
3755
|
}
|
|
@@ -4544,7 +4577,10 @@ function assessProfile(profile, evidence) {
|
|
|
4544
4577
|
type: check.type,
|
|
4545
4578
|
label: check.label || check.type,
|
|
4546
4579
|
status: "failed",
|
|
4547
|
-
evidence: {
|
|
4580
|
+
evidence: {
|
|
4581
|
+
expected_count: (check.expected_routes || []).length,
|
|
4582
|
+
expected_routes: routeInventoryExpectedRouteSummaries(undefined, check.expected_routes),
|
|
4583
|
+
},
|
|
4548
4584
|
message: "No route inventory evidence was captured.",
|
|
4549
4585
|
});
|
|
4550
4586
|
continue;
|
|
@@ -4563,12 +4599,14 @@ function assessProfile(profile, evidence) {
|
|
|
4563
4599
|
const sourceUniqueLinkCount = typeof first.source_unique_link_count === "number" ? first.source_unique_link_count : typeof first.home_unique_game_link_count === "number" ? first.home_unique_game_link_count : null;
|
|
4564
4600
|
const duplicateSourceLinks = Array.isArray(first.duplicate_source_link_paths) ? first.duplicate_source_link_paths.map((path) => String(path)) : [];
|
|
4565
4601
|
const duplicateSourceLinkCount = typeof first.duplicate_source_link_count === "number" ? first.duplicate_source_link_count : sourceLinkCount !== null && sourceUniqueLinkCount !== null ? Math.max(0, sourceLinkCount - sourceUniqueLinkCount) : null;
|
|
4602
|
+
const expectedRoutes = routeInventoryExpectedRouteSummaries(first.expected_routes, check.expected_routes);
|
|
4566
4603
|
checks.push({
|
|
4567
4604
|
type: check.type,
|
|
4568
4605
|
label: check.label || check.type,
|
|
4569
4606
|
status: failures.length ? "failed" : "passed",
|
|
4570
4607
|
evidence: {
|
|
4571
4608
|
expected_count: (check.expected_routes || []).length,
|
|
4609
|
+
expected_routes: expectedRoutes,
|
|
4572
4610
|
source_link_count: sourceLinkCount,
|
|
4573
4611
|
source_unique_link_count: sourceUniqueLinkCount,
|
|
4574
4612
|
duplicate_source_link_count: duplicateSourceLinkCount,
|
package/dist/profile.js
CHANGED
|
@@ -23,7 +23,7 @@ import {
|
|
|
23
23
|
resolveRiddleProofProfileTimeoutSec,
|
|
24
24
|
slugifyRiddleProofProfileName,
|
|
25
25
|
summarizeRiddleProofProfileResult
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-LFFTWXLB.js";
|
|
27
27
|
export {
|
|
28
28
|
RIDDLE_PROOF_PROFILE_CHECK_TYPES,
|
|
29
29
|
RIDDLE_PROOF_PROFILE_EVIDENCE_VERSION,
|
|
@@ -292,7 +292,7 @@ declare function executeWorkflow(params: WorkflowParams, pluginConfig: any, reso
|
|
|
292
292
|
blocking?: boolean;
|
|
293
293
|
details?: Record<string, unknown>;
|
|
294
294
|
ok: boolean;
|
|
295
|
-
action: "
|
|
295
|
+
action: "author" | "recon" | "ship" | "implement" | "verify" | "setup" | "run";
|
|
296
296
|
state_path: string;
|
|
297
297
|
stage: any;
|
|
298
298
|
summary: string;
|
|
@@ -382,7 +382,7 @@ declare function executeWorkflow(params: WorkflowParams, pluginConfig: any, reso
|
|
|
382
382
|
continueWithStage?: WorkflowStage | null;
|
|
383
383
|
blocking?: boolean;
|
|
384
384
|
details?: Record<string, unknown>;
|
|
385
|
-
action: "
|
|
385
|
+
action: "author" | "recon" | "ship" | "implement" | "verify" | "setup" | "run";
|
|
386
386
|
state_path: string;
|
|
387
387
|
stage: any;
|
|
388
388
|
checkpoint: string;
|
|
@@ -659,7 +659,7 @@ declare function executeWorkflow(params: WorkflowParams, pluginConfig: any, reso
|
|
|
659
659
|
error?: undefined;
|
|
660
660
|
} | {
|
|
661
661
|
ok: boolean;
|
|
662
|
-
action: "
|
|
662
|
+
action: "author" | "recon" | "ship" | "implement" | "verify" | "setup" | "run";
|
|
663
663
|
state_path: string;
|
|
664
664
|
stage: any;
|
|
665
665
|
summary: string;
|
|
@@ -292,7 +292,7 @@ declare function executeWorkflow(params: WorkflowParams, pluginConfig: any, reso
|
|
|
292
292
|
blocking?: boolean;
|
|
293
293
|
details?: Record<string, unknown>;
|
|
294
294
|
ok: boolean;
|
|
295
|
-
action: "
|
|
295
|
+
action: "author" | "recon" | "ship" | "implement" | "verify" | "setup" | "run";
|
|
296
296
|
state_path: string;
|
|
297
297
|
stage: any;
|
|
298
298
|
summary: string;
|
|
@@ -382,7 +382,7 @@ declare function executeWorkflow(params: WorkflowParams, pluginConfig: any, reso
|
|
|
382
382
|
continueWithStage?: WorkflowStage | null;
|
|
383
383
|
blocking?: boolean;
|
|
384
384
|
details?: Record<string, unknown>;
|
|
385
|
-
action: "
|
|
385
|
+
action: "author" | "recon" | "ship" | "implement" | "verify" | "setup" | "run";
|
|
386
386
|
state_path: string;
|
|
387
387
|
stage: any;
|
|
388
388
|
checkpoint: string;
|
|
@@ -659,7 +659,7 @@ declare function executeWorkflow(params: WorkflowParams, pluginConfig: any, reso
|
|
|
659
659
|
error?: undefined;
|
|
660
660
|
} | {
|
|
661
661
|
ok: boolean;
|
|
662
|
-
action: "
|
|
662
|
+
action: "author" | "recon" | "ship" | "implement" | "verify" | "setup" | "run";
|
|
663
663
|
state_path: string;
|
|
664
664
|
stage: any;
|
|
665
665
|
summary: string;
|