@almadar/core 11.0.1 → 11.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{builders-BdgbY7Th.d.ts → builders-C4TIhiks.d.ts} +292 -292
- package/dist/builders.d.ts +5 -5
- package/dist/builders.js +3 -3
- package/dist/{bus-C0hFDNFR.d.ts → bus-do1P9luP.d.ts} +4 -4
- package/dist/{chunk-ENOCKYGA.js → chunk-2NKK2X53.js} +3 -3
- package/dist/{chunk-ENOCKYGA.js.map → chunk-2NKK2X53.js.map} +1 -1
- package/dist/{chunk-TDNQT3M3.js → chunk-3DZOFI53.js} +4 -4
- package/dist/{chunk-TDNQT3M3.js.map → chunk-3DZOFI53.js.map} +1 -1
- package/dist/{chunk-5YTPYMPZ.js → chunk-6H3UIZR2.js} +3 -3
- package/dist/{chunk-5YTPYMPZ.js.map → chunk-6H3UIZR2.js.map} +1 -1
- package/dist/{chunk-FGT5OS2Y.js → chunk-7B4JRMRL.js} +15 -3
- package/dist/chunk-7B4JRMRL.js.map +1 -0
- package/dist/{chunk-5WQ3U7NJ.js → chunk-IE6WCCJP.js} +14 -2
- package/dist/chunk-IE6WCCJP.js.map +1 -0
- package/dist/{chunk-PNGFWLHD.js → chunk-LPJ7GKRM.js} +18 -8
- package/dist/chunk-LPJ7GKRM.js.map +1 -0
- package/dist/{chunk-SNZYN7UA.js → chunk-N3CK4AYW.js} +106 -16
- package/dist/{chunk-SNZYN7UA.js.map → chunk-N3CK4AYW.js.map} +1 -1
- package/dist/{chunk-E4T2MQAV.js → chunk-PYYHDYTD.js} +3 -3
- package/dist/{chunk-E4T2MQAV.js.map → chunk-PYYHDYTD.js.map} +1 -1
- package/dist/{chunk-Z7BI7DE7.js → chunk-VIHQKKTZ.js} +45 -15
- package/dist/chunk-VIHQKKTZ.js.map +1 -0
- package/dist/{chunk-GF7KCLNR.js → chunk-VOFHP52Z.js} +29 -4
- package/dist/chunk-VOFHP52Z.js.map +1 -0
- package/dist/{chunk-66Q5VX2F.js → chunk-ZDIHVDTW.js} +6 -6
- package/dist/chunk-ZDIHVDTW.js.map +1 -0
- package/dist/{effect-DZaXwSAz.d.ts → effect-Dr--GXRe.d.ts} +59 -51
- package/dist/{effect-result-1HpXgeBc.d.ts → effect-result-geymPT9w.d.ts} +39 -5
- package/dist/factory/index.d.ts +2 -2
- package/dist/factory/index.js +4 -4
- package/dist/factory-runtime/index.d.ts +3 -3
- package/dist/factory-runtime/index.js +10 -10
- package/dist/fixtures.d.ts +3 -3
- package/dist/fixtures.js +2 -2
- package/dist/i18n/index.js +1 -1
- package/dist/{index-D7SxwNdv.d.ts → index-C8mF8btS.d.ts} +39 -28
- package/dist/index.d.ts +14 -14
- package/dist/index.js +15 -15
- package/dist/kernel-wire.d.ts +2 -2
- package/dist/kernel-wire.js +1 -1
- package/dist/language/validation-codes.json +25 -0
- package/dist/language/vocabulary.json +2 -0
- package/dist/language-data.js +1 -1
- package/dist/patterns/component-mapping.json +1 -1
- package/dist/patterns/definitions.d.ts +1 -1
- package/dist/patterns/definitions.js +1 -1
- package/dist/patterns/event-contracts.json +1 -1
- package/dist/patterns/index.d.ts +2 -2
- package/dist/patterns/index.js +2 -2
- package/dist/patterns/patterns-registry.json +104 -14
- package/dist/patterns/registry.json +104 -14
- package/dist/{trait-sRjIivFq.d.ts → trait-D9MjuwGC.d.ts} +86 -86
- package/dist/types/index.d.ts +8 -8
- package/dist/types/index.js +7 -7
- package/dist/{types-C6_yPMpn.d.ts → types-Bi-KSa0a.d.ts} +2 -2
- package/package.json +4 -4
- package/dist/chunk-5WQ3U7NJ.js.map +0 -1
- package/dist/chunk-66Q5VX2F.js.map +0 -1
- package/dist/chunk-FGT5OS2Y.js.map +0 -1
- package/dist/chunk-GF7KCLNR.js.map +0 -1
- package/dist/chunk-PNGFWLHD.js.map +0 -1
- package/dist/chunk-Z7BI7DE7.js.map +0 -1
- package/dist/{domain-Cpmja5ak.d.ts → domain-JuWUUeJ3.d.ts} +51 -51
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { isInlineTrait } from './chunk-
|
|
1
|
+
import { isInlineTrait } from './chunk-LPJ7GKRM.js';
|
|
2
2
|
|
|
3
3
|
// src/data-bearing.ts
|
|
4
4
|
function touchesRecord(effect, name) {
|
|
@@ -20,5 +20,5 @@ function orbitalTouchesOwnRecord(orbital) {
|
|
|
20
20
|
}
|
|
21
21
|
|
|
22
22
|
export { orbitalTouchesOwnRecord };
|
|
23
|
-
//# sourceMappingURL=chunk-
|
|
24
|
-
//# sourceMappingURL=chunk-
|
|
23
|
+
//# sourceMappingURL=chunk-PYYHDYTD.js.map
|
|
24
|
+
//# sourceMappingURL=chunk-PYYHDYTD.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/data-bearing.ts"],"names":[],"mappings":";;;AAKA,SAAS,aAAA,CAAc,QAA6B,IAAA,EAAuB;AACzE,EAAA,IAAI,CAAC,KAAA,CAAM,OAAA,CAAQ,MAAM,GAAG,OAAO,KAAA;AACnC,EAAA,IAAI,MAAA,CAAO,CAAC,CAAA,KAAM,OAAA,IAAW,OAAO,CAAC,CAAA,KAAM,MAAM,OAAO,IAAA;AACxD,EAAA,IAAI,MAAA,CAAO,CAAC,CAAA,KAAM,SAAA,IAAa,OAAO,CAAC,CAAA,KAAM,MAAM,OAAO,IAAA;AAC1D,EAAA,KAAA,MAAW,QAAQ,MAAA,EAAQ;AACzB,IAAA,IAAI,KAAA,CAAM,QAAQ,IAAI,CAAA,IAAK,cAAc,IAAA,EAAM,IAAI,GAAG,OAAO,IAAA;AAAA,EAC/D;AACA,EAAA,OAAO,KAAA;AACT;AAGO,SAAS,wBAAwB,OAAA,EAAqC;AAC3E,EAAA,MAAM,SAAS,OAAA,CAAQ,MAAA;AACvB,EAAA,MAAM,IAAA,GAAO,OAAO,MAAA,KAAW,QAAA,IAAY,WAAW,IAAA,IAAQ,MAAA,IAAU,MAAA,GAAS,MAAA,CAAO,IAAA,GAAO,MAAA;AAC/F,EAAA,IAAI,OAAO,IAAA,KAAS,QAAA,EAAU,OAAO,KAAA;AACrC,EAAA,OAAA,CAAQ,OAAA,CAAQ,MAAA,IAAU,EAAC,EAAG,IAAA;AAAA,IAAK,CAAC,KAAA,KAClC,aAAA,CAAc,KAAK,CAAA,IAAA,CAAM,MAAM,YAAA,EAAc,WAAA,IAAe,EAAC,EAAG,IAAA,CAAK,CAAC,OAAO,CAAA,CAAE,OAAA,IAAW,EAAC,EAAG,IAAA,CAAK,CAAC,MAAM,aAAA,CAAc,CAAA,EAAG,IAAI,CAAC,CAAC;AAAA,GACnI;AACF","file":"chunk-
|
|
1
|
+
{"version":3,"sources":["../src/data-bearing.ts"],"names":[],"mappings":";;;AAKA,SAAS,aAAA,CAAc,QAA6B,IAAA,EAAuB;AACzE,EAAA,IAAI,CAAC,KAAA,CAAM,OAAA,CAAQ,MAAM,GAAG,OAAO,KAAA;AACnC,EAAA,IAAI,MAAA,CAAO,CAAC,CAAA,KAAM,OAAA,IAAW,OAAO,CAAC,CAAA,KAAM,MAAM,OAAO,IAAA;AACxD,EAAA,IAAI,MAAA,CAAO,CAAC,CAAA,KAAM,SAAA,IAAa,OAAO,CAAC,CAAA,KAAM,MAAM,OAAO,IAAA;AAC1D,EAAA,KAAA,MAAW,QAAQ,MAAA,EAAQ;AACzB,IAAA,IAAI,KAAA,CAAM,QAAQ,IAAI,CAAA,IAAK,cAAc,IAAA,EAAM,IAAI,GAAG,OAAO,IAAA;AAAA,EAC/D;AACA,EAAA,OAAO,KAAA;AACT;AAGO,SAAS,wBAAwB,OAAA,EAAqC;AAC3E,EAAA,MAAM,SAAS,OAAA,CAAQ,MAAA;AACvB,EAAA,MAAM,IAAA,GAAO,OAAO,MAAA,KAAW,QAAA,IAAY,WAAW,IAAA,IAAQ,MAAA,IAAU,MAAA,GAAS,MAAA,CAAO,IAAA,GAAO,MAAA;AAC/F,EAAA,IAAI,OAAO,IAAA,KAAS,QAAA,EAAU,OAAO,KAAA;AACrC,EAAA,OAAA,CAAQ,OAAA,CAAQ,MAAA,IAAU,EAAC,EAAG,IAAA;AAAA,IAAK,CAAC,KAAA,KAClC,aAAA,CAAc,KAAK,CAAA,IAAA,CAAM,MAAM,YAAA,EAAc,WAAA,IAAe,EAAC,EAAG,IAAA,CAAK,CAAC,OAAO,CAAA,CAAE,OAAA,IAAW,EAAC,EAAG,IAAA,CAAK,CAAC,MAAM,aAAA,CAAc,CAAA,EAAG,IAAI,CAAC,CAAC;AAAA,GACnI;AACF","file":"chunk-PYYHDYTD.js","sourcesContent":["import type { OrbitalDefinition } from './types/orbital.js';\nimport type { SExpr } from './types/expression.js';\nimport type { TypedEffect } from './types/effect.js';\nimport { isInlineTrait } from './types/trait.js';\n\nfunction touchesRecord(effect: TypedEffect | SExpr, name: string): boolean {\n if (!Array.isArray(effect)) return false;\n if (effect[0] === 'fetch' && effect[1] === name) return true;\n if (effect[0] === 'persist' && effect[2] === name) return true;\n for (const item of effect) {\n if (Array.isArray(item) && touchesRecord(item, name)) return true;\n }\n return false;\n}\n\n/** True when the orbital's own inline traits fetch or persist its primary record. */\nexport function orbitalTouchesOwnRecord(orbital: OrbitalDefinition): boolean {\n const entity = orbital.entity;\n const name = typeof entity === 'object' && entity !== null && 'name' in entity ? entity.name : undefined;\n if (typeof name !== 'string') return false;\n return (orbital.traits ?? []).some((trait) =>\n isInlineTrait(trait) && (trait.stateMachine?.transitions ?? []).some((t) => (t.effects ?? []).some((e) => touchesRecord(e, name))),\n );\n}\n"]}
|
|
@@ -217,7 +217,7 @@ function checkEvalStepWire(v) {
|
|
|
217
217
|
return isRecord(v) && checkEvalStepKind(v["kind"]) && (Array.isArray(v["path"]) && v["path"].every((e) => typeof e === "number" || typeof e === "string")) && (v["value"] === void 0 || accepts((x, q) => any(x, q), v["value"])) && (v["error"] === void 0 || typeof v["error"] === "string");
|
|
218
218
|
}
|
|
219
219
|
function checkEventRequest(v) {
|
|
220
|
-
return isRecord(v) && typeof v["event"] === "string" && (v["eventId"] === void 0 || accepts((x, q) => asEventId(str(x, q)), v["eventId"])) && (v["payload"] === void 0 || accepts((x, q) => rec(x, q), v["payload"])) && (v["entityId"] === void 0 || typeof v["entityId"] === "string") && (v["targetTrait"] === void 0 || typeof v["targetTrait"] === "string") && (v["clientId"] === void 0 || typeof v["clientId"] === "string") && (v["locale"] === void 0 || typeof v["locale"] === "string") && (v["tick"] === void 0 || typeof v["tick"] === "string") && (v["sourceTrait"] === void 0 || typeof v["sourceTrait"] === "string") && (v["runTick"] === void 0 || checkRunTick(v["runTick"])) && (v["traits"] === void 0 || Array.isArray(v["traits"]) && v["traits"].every((e) => checkTraitFrom(e))) && (v["entityByTrait"] === void 0 || isRecord(v["entityByTrait"]) && Object.values(v["entityByTrait"]).every((e) => accepts((x, q) => entityRow(x, q), e))) && (v["behavior"] === void 0 || typeof v["behavior"] === "string") && (v["delivery"] === void 0 || checkDeliveryRecord(v["delivery"])) && (v["dispatchLog"] === void 0 || checkDispatchLog(v["dispatchLog"])) && (v["mount"] === void 0 || Array.isArray(v["mount"]) && v["mount"].every((e) => checkMountSeed(e))) && (v["route"] === void 0 || typeof v["route"] === "string") && (v["residence"] === void 0 || checkLegResidence(v["residence"])) && (v["framesSince"] === void 0 || typeof v["framesSince"] === "number");
|
|
220
|
+
return isRecord(v) && typeof v["event"] === "string" && (v["eventId"] === void 0 || accepts((x, q) => asEventId(str(x, q)), v["eventId"])) && (v["payload"] === void 0 || accepts((x, q) => rec(x, q), v["payload"])) && (v["entityId"] === void 0 || typeof v["entityId"] === "string") && (v["targetTrait"] === void 0 || typeof v["targetTrait"] === "string") && (v["clientId"] === void 0 || typeof v["clientId"] === "string") && (v["locale"] === void 0 || typeof v["locale"] === "string") && (v["tick"] === void 0 || typeof v["tick"] === "string") && (v["sourceTrait"] === void 0 || typeof v["sourceTrait"] === "string") && (v["runTick"] === void 0 || checkRunTick(v["runTick"])) && (v["traits"] === void 0 || Array.isArray(v["traits"]) && v["traits"].every((e) => checkTraitFrom(e))) && (v["entityByTrait"] === void 0 || isRecord(v["entityByTrait"]) && Object.values(v["entityByTrait"]).every((e) => accepts((x, q) => entityRow(x, q), e))) && (v["behavior"] === void 0 || typeof v["behavior"] === "string") && (v["delivery"] === void 0 || checkDeliveryRecord(v["delivery"])) && (v["dispatchLog"] === void 0 || checkDispatchLog(v["dispatchLog"])) && (v["mount"] === void 0 || Array.isArray(v["mount"]) && v["mount"].every((e) => checkMountSeed(e))) && (v["route"] === void 0 || typeof v["route"] === "string") && (v["residence"] === void 0 || checkLegResidence(v["residence"])) && (v["framesSince"] === void 0 || typeof v["framesSince"] === "number") && (v["heldPayload"] === void 0 || typeof v["heldPayload"] === "number");
|
|
221
221
|
}
|
|
222
222
|
function checkEventResponse(v) {
|
|
223
223
|
return isRecord(v) && typeof v["success"] === "boolean" && typeof v["transitioned"] === "boolean" && (isRecord(v["states"]) && Object.values(v["states"]).every((e) => typeof e === "string")) && (Array.isArray(v["emittedEvents"]) && v["emittedEvents"].every((e) => checkEmittedEvent(e))) && (v["data"] === void 0 || isRecord(v["data"]) && Object.values(v["data"]).every((e) => Array.isArray(e) && e.every((e2) => accepts((x, q) => entityRow(x, q), e2)))) && (v["dataRefs"] === void 0 || isRecord(v["dataRefs"]) && Object.values(v["dataRefs"]).every((e) => checkRowSetRef(e))) && (v["frames"] === void 0 || checkFrameDelta(v["frames"])) && (v["clientEffectsByTrait"] === void 0 || Array.isArray(v["clientEffectsByTrait"]) && v["clientEffectsByTrait"].every((e) => checkClientEffectByTrait(e))) && (v["effectResults"] === void 0 || Array.isArray(v["effectResults"]) && v["effectResults"].every((e) => checkServerEffectResult(e))) && (v["guardFailed"] === void 0 || typeof v["guardFailed"] === "string") && (v["rejections"] === void 0 || Array.isArray(v["rejections"]) && v["rejections"].every((e) => checkTransitionRejection(e))) && (v["cascadeTruncated"] === void 0 || Array.isArray(v["cascadeTruncated"]) && v["cascadeTruncated"].every((e) => typeof e === "string")) && (v["transitions"] === void 0 || Array.isArray(v["transitions"]) && v["transitions"].every((e) => checkTransitionHop(e))) && (v["error"] === void 0 || typeof v["error"] === "string");
|
|
@@ -261,12 +261,21 @@ function checkFsGrant(v) {
|
|
|
261
261
|
function checkFsMode(v) {
|
|
262
262
|
return v === "read" || v === "write" || v === "create" || v === "remove" || v === "meta";
|
|
263
263
|
}
|
|
264
|
+
function checkGpuGrant(v) {
|
|
265
|
+
return isRecord(v) && typeof v["target"] === "string" && (Array.isArray(v["kinds"]) && v["kinds"].every((e) => checkGpuKind(e)));
|
|
266
|
+
}
|
|
267
|
+
function checkGpuKind(v) {
|
|
268
|
+
return v === "open" || v === "compute" || v === "render" || v === "readback";
|
|
269
|
+
}
|
|
264
270
|
function checkGrantAnchor(v) {
|
|
265
271
|
return v === "exe" || v === "exe-dir" || v === "cwd" || isRecord(v) && typeof v["env"] === "string";
|
|
266
272
|
}
|
|
267
273
|
function checkGuardVerdict(v) {
|
|
268
274
|
return v === "pass" || v === "fail" || v === "none";
|
|
269
275
|
}
|
|
276
|
+
function checkHeldGpuCompletion(v) {
|
|
277
|
+
return isRecord(v) && (v["orbital"] === void 0 || typeof v["orbital"] === "string") && typeof v["traitName"] === "string" && (v["entityId"] === void 0 || typeof v["entityId"] === "string") && typeof v["event"] === "string" && typeof v["heldPayload"] === "number";
|
|
278
|
+
}
|
|
270
279
|
function checkHopEffect(v) {
|
|
271
280
|
return isRecord(v) && typeof v["type"] === "string" && (Array.isArray(v["args"]) && v["args"].every((e) => accepts((x, q) => any(x, q), e))) && checkHopEffectStatus(v["status"]) && (v["error"] === void 0 || typeof v["error"] === "string");
|
|
272
281
|
}
|
|
@@ -283,13 +292,13 @@ function checkInstanceRef(v) {
|
|
|
283
292
|
return isRecord(v) && typeof v["instance"] === "string" && typeof v["orbital"] === "string" && (v["trait"] === void 0 || typeof v["trait"] === "string");
|
|
284
293
|
}
|
|
285
294
|
function checkIoAnswerWire(v) {
|
|
286
|
-
return isRecord(v) && v["kind"] === "row" && (isRecord(v["result"]) && (accepts((x, q) => entityRow(x, q), v["result"]["ok"]) || v["result"]["ok"] === null) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "rows" && (isRecord(v["result"]) && (Array.isArray(v["result"]["ok"]) && v["result"]["ok"].every((e) => accepts((x, q) => entityRow(x, q), e))) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "page" && (isRecord(v["result"]) && checkRowPage(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "idPage" && (isRecord(v["result"]) && checkRowIdPage(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "queryUnsupported" && typeof v["reason"] === "string" || isRecord(v) && v["kind"] === "wrote" && (isRecord(v["result"]) && (Array.isArray(v["result"]["ok"]) && v["result"]["ok"].every((e) => checkRowWriteOutcome(e))) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "writeUnsupported" && typeof v["reason"] === "string" || isRecord(v) && v["kind"] === "committed" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "boolean" || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "deleted" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "service" && (isRecord(v["result"]) && accepts((x, q) => any(x, q), v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "serviceCancelled" || isRecord(v) && v["kind"] === "serviceDeferred" || isRecord(v) && v["kind"] === "cancelled" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "substrate" && (isRecord(v["result"]) && accepts((x, q) => any(x, q), v["result"]["ok"]) || isRecord(v["result"]) && checkSubstrateFailureWire(v["result"]["error"])) || isRecord(v) && v["kind"] === "pageFacts" && (isRecord(v["result"]) && checkPageFactsWire(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "prompt" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "string" || isRecord(v["result"]) && checkModelFailureWire(v["result"]["error"])) || isRecord(v) && v["kind"] === "embed" && (isRecord(v["result"]) && (Array.isArray(v["result"]["ok"]) && v["result"]["ok"].every((e) => Array.isArray(e) && e.every((e2) => typeof e2 === "number"))) || isRecord(v["result"]) && checkModelFailureWire(v["result"]["error"])) || isRecord(v) && v["kind"] === "tab" && (isRecord(v["result"]) && accepts((x, q) => any(x, q), v["result"]["ok"]) || isRecord(v["result"]) && checkTabFailure(v["result"]["error"])) || isRecord(v) && v["kind"] === "secret" && (isRecord(v["result"]) && (typeof v["result"]["ok"] === "string" || v["result"]["ok"] === null) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "secretSet" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "secretRotate" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "random" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "string" || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "clock" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "number" || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "sealed" && (isRecord(v["result"]) && accepts((x, q) => any(x, q), v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "os" && (isRecord(v["result"]) && accepts((x, q) => any(x, q), v["result"]["ok"]) || isRecord(v["result"]) && checkOsError(v["result"]["error"])) || isRecord(v) && v["kind"] === "credentialStatus" && (isRecord(v["result"]) && checkCredentialStanding(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialForget" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialConnect" && (isRecord(v["result"]) && checkCredentialStanding(v["result"]["ok"]) || isRecord(v["result"]) && checkConnectFailure(v["result"]["error"])) || isRecord(v) && v["kind"] === "credentialStoreList" && (isRecord(v["result"]) && (checkStoreListing(v["result"]["ok"]) || v["result"]["ok"] === null) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialEnvTails" && (isRecord(v["result"]) && checkEnvTails(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialStoreRead" && (isRecord(v["result"]) && (typeof v["result"]["ok"] === "string" || v["result"]["ok"] === null) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialStoreWrite" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialStoreRemove" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "boolean" || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialStoreRotate" && (isRecord(v["result"]) && checkRotateCounts(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialModeRead" && (isRecord(v["result"]) && (typeof v["result"]["ok"] === "string" || v["result"]["ok"] === null) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialModeWrite" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "string" || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "deliver" && (isRecord(v["result"]) && checkAccepted(v["result"]["ok"]) || isRecord(v["result"]) && checkDeliverRefusal(v["result"]["error"]));
|
|
295
|
+
return isRecord(v) && v["kind"] === "row" && (isRecord(v["result"]) && (accepts((x, q) => entityRow(x, q), v["result"]["ok"]) || v["result"]["ok"] === null) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "rows" && (isRecord(v["result"]) && (Array.isArray(v["result"]["ok"]) && v["result"]["ok"].every((e) => accepts((x, q) => entityRow(x, q), e))) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "page" && (isRecord(v["result"]) && checkRowPage(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "idPage" && (isRecord(v["result"]) && checkRowIdPage(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "queryUnsupported" && typeof v["reason"] === "string" || isRecord(v) && v["kind"] === "wrote" && (isRecord(v["result"]) && (Array.isArray(v["result"]["ok"]) && v["result"]["ok"].every((e) => checkRowWriteOutcome(e))) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "writeUnsupported" && typeof v["reason"] === "string" || isRecord(v) && v["kind"] === "committed" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "boolean" || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "deleted" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "service" && (isRecord(v["result"]) && accepts((x, q) => any(x, q), v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "serviceCancelled" || isRecord(v) && v["kind"] === "serviceDeferred" || isRecord(v) && v["kind"] === "cancelled" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "substrate" && (isRecord(v["result"]) && accepts((x, q) => any(x, q), v["result"]["ok"]) || isRecord(v["result"]) && checkSubstrateFailureWire(v["result"]["error"])) || isRecord(v) && v["kind"] === "pageFacts" && (isRecord(v["result"]) && checkPageFactsWire(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "prompt" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "string" || isRecord(v["result"]) && checkModelFailureWire(v["result"]["error"])) || isRecord(v) && v["kind"] === "embed" && (isRecord(v["result"]) && (Array.isArray(v["result"]["ok"]) && v["result"]["ok"].every((e) => Array.isArray(e) && e.every((e2) => typeof e2 === "number"))) || isRecord(v["result"]) && checkModelFailureWire(v["result"]["error"])) || isRecord(v) && v["kind"] === "tab" && (isRecord(v["result"]) && accepts((x, q) => any(x, q), v["result"]["ok"]) || isRecord(v["result"]) && checkTabFailure(v["result"]["error"])) || isRecord(v) && v["kind"] === "secret" && (isRecord(v["result"]) && (typeof v["result"]["ok"] === "string" || v["result"]["ok"] === null) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "secretSet" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "secretRotate" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "random" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "string" || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "clock" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "number" || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "sealed" && (isRecord(v["result"]) && accepts((x, q) => any(x, q), v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "os" && (isRecord(v["result"]) && accepts((x, q) => any(x, q), v["result"]["ok"]) || isRecord(v["result"]) && checkOsError(v["result"]["error"])) || isRecord(v) && v["kind"] === "gpuHeld" && typeof v["ticket"] === "number" || isRecord(v) && v["kind"] === "credentialStatus" && (isRecord(v["result"]) && checkCredentialStanding(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialForget" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialConnect" && (isRecord(v["result"]) && checkCredentialStanding(v["result"]["ok"]) || isRecord(v["result"]) && checkConnectFailure(v["result"]["error"])) || isRecord(v) && v["kind"] === "credentialStoreList" && (isRecord(v["result"]) && (checkStoreListing(v["result"]["ok"]) || v["result"]["ok"] === null) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialEnvTails" && (isRecord(v["result"]) && checkEnvTails(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialStoreRead" && (isRecord(v["result"]) && (typeof v["result"]["ok"] === "string" || v["result"]["ok"] === null) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialStoreWrite" && (isRecord(v["result"]) && v["result"]["ok"] === null || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialStoreRemove" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "boolean" || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialStoreRotate" && (isRecord(v["result"]) && checkRotateCounts(v["result"]["ok"]) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialModeRead" && (isRecord(v["result"]) && (typeof v["result"]["ok"] === "string" || v["result"]["ok"] === null) || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "credentialModeWrite" && (isRecord(v["result"]) && typeof v["result"]["ok"] === "string" || isRecord(v["result"]) && typeof v["result"]["error"] === "string") || isRecord(v) && v["kind"] === "deliver" && (isRecord(v["result"]) && checkAccepted(v["result"]["ok"]) || isRecord(v["result"]) && checkDeliverRefusal(v["result"]["error"]));
|
|
287
296
|
}
|
|
288
297
|
function checkIoReplyWire(v) {
|
|
289
298
|
return isRecord(v) && typeof v["id"] === "number" && checkIoAnswerWire(v["answer"]);
|
|
290
299
|
}
|
|
291
300
|
function checkIoRequestWire(v) {
|
|
292
|
-
return isRecord(v) && v["kind"] === "readRow" && typeof v["entityType"] === "string" && typeof v["id"] === "string" || isRecord(v) && v["kind"] === "listRows" && typeof v["entityType"] === "string" || isRecord(v) && v["kind"] === "queryRows" && typeof v["entityType"] === "string" && checkRowQuery(v["query"]) && checkRowProjection(v["project"]) || isRecord(v) && v["kind"] === "writeRows" && checkRowWriteBatch(v["batch"]) || isRecord(v) && v["kind"] === "commitRows" && (Array.isArray(v["rows"]) && v["rows"].every((e) => checkRowCommit(e))) || isRecord(v) && v["kind"] === "createRow" && typeof v["entityType"] === "string" && accepts((x, q) => any(x, q), v["data"]) || isRecord(v) && v["kind"] === "writeRow" && typeof v["entityType"] === "string" && typeof v["id"] === "string" && accepts((x, q) => any(x, q), v["data"]) || isRecord(v) && v["kind"] === "deleteRow" && typeof v["entityType"] === "string" && typeof v["id"] === "string" || isRecord(v) && v["kind"] === "callService" && typeof v["service"] === "string" && typeof v["method"] === "string" && accepts((x, q) => any(x, q), v["args"]) && (v["key"] === void 0 || typeof v["key"] === "string") && (v["caller"] === void 0 || checkCallerWire(v["caller"])) && (v["site"] === void 0 || checkCallSiteWire(v["site"])) || isRecord(v) && v["kind"] === "cancelCall" && typeof v["key"] === "string" || isRecord(v) && v["kind"] === "substrate" && typeof v["op"] === "string" && (Array.isArray(v["args"]) && v["args"].every((e) => accepts((x, q) => any(x, q), e))) && (v["key"] === void 0 || typeof v["key"] === "string") && (v["site"] === void 0 || checkCallSiteWire(v["site"])) || isRecord(v) && v["kind"] === "pageFacts" && (Array.isArray(v["fields"]) && v["fields"].every((e) => checkPageFactFieldWire(e))) || isRecord(v) && v["kind"] === "prompt" && typeof v["text"] === "string" && typeof v["schema"] === "string" && (v["key"] === void 0 || typeof v["key"] === "string") || isRecord(v) && v["kind"] === "embed" && (Array.isArray(v["texts"]) && v["texts"].every((e) => typeof e === "string")) && (v["key"] === void 0 || typeof v["key"] === "string") || isRecord(v) && v["kind"] === "tab" && checkTabAsk(v["ask"]) && (v["key"] === void 0 || typeof v["key"] === "string") || isRecord(v) && v["kind"] === "secret" && typeof v["name"] === "string" && (v["principal"] === void 0 || typeof v["principal"] === "string") || isRecord(v) && v["kind"] === "secretSet" && typeof v["name"] === "string" && typeof v["value"] === "string" && typeof v["ttlMs"] === "number" && (v["principal"] === void 0 || typeof v["principal"] === "string") || isRecord(v) && v["kind"] === "secretRotate" && typeof v["name"] === "string" && typeof v["value"] === "string" && (v["principal"] === void 0 || typeof v["principal"] === "string") || isRecord(v) && v["kind"] === "deliver" && checkEnvelope(v["envelope"]) && (v["key"] === void 0 || typeof v["key"] === "string") && checkCallSiteWire(v["site"]) || isRecord(v) && v["kind"] === "guest" && typeof v["guest"] === "string" && (Array.isArray(v["targets"]) && v["targets"].every((e) => typeof e === "string")) && typeof v["event"] === "string" && accepts((x, q) => any(x, q), v["payload"]) && checkOsGrants(v["grants"]) && (v["key"] === void 0 || typeof v["key"] === "string") && (v["site"] === void 0 || checkCallSiteWire(v["site"])) || isRecord(v) && v["kind"] === "random" && typeof v["bytes"] === "number" || isRecord(v) && v["kind"] === "clock" || isRecord(v) && v["kind"] === "sealed" && typeof v["op"] === "string" && (Array.isArray(v["args"]) && v["args"].every((e) => accepts((x, q) => any(x, q), e))) || isRecord(v) && v["kind"] === "os" && checkOsOp(v["op"]) && (Array.isArray(v["args"]) && v["args"].every((e) => accepts((x, q) => any(x, q), e))) && (v["key"] === void 0 || typeof v["key"] === "string") && (v["site"] === void 0 || checkCallSiteWire(v["site"])) && (v["principal"] === void 0 || typeof v["principal"] === "string") && (v["orbital"] === void 0 || typeof v["orbital"] === "string") || isRecord(v) && v["kind"] === "credentialStatus" && typeof v["name"] === "string" && (v["principal"] === void 0 || typeof v["principal"] === "string") || isRecord(v) && v["kind"] === "credentialForget" && typeof v["name"] === "string" && (v["principal"] === void 0 || typeof v["principal"] === "string") || isRecord(v) && v["kind"] === "credentialConnect" && checkCredentialGrantWire(v["grant"]) || isRecord(v) && v["kind"] === "credentialStoreList" || isRecord(v) && v["kind"] === "credentialEnvTails" && (Array.isArray(v["names"]) && v["names"].every((e) => typeof e === "string")) || isRecord(v) && v["kind"] === "credentialStoreRead" && typeof v["name"] === "string" || isRecord(v) && v["kind"] === "credentialStoreWrite" && typeof v["service"] === "string" && typeof v["name"] === "string" && typeof v["value"] === "string" || isRecord(v) && v["kind"] === "credentialStoreRemove" && typeof v["name"] === "string" || isRecord(v) && v["kind"] === "credentialStoreRotate" || isRecord(v) && v["kind"] === "credentialModeRead" || isRecord(v) && v["kind"] === "credentialModeWrite" && typeof v["mode"] === "string";
|
|
301
|
+
return isRecord(v) && v["kind"] === "readRow" && typeof v["entityType"] === "string" && typeof v["id"] === "string" || isRecord(v) && v["kind"] === "listRows" && typeof v["entityType"] === "string" || isRecord(v) && v["kind"] === "queryRows" && typeof v["entityType"] === "string" && checkRowQuery(v["query"]) && checkRowProjection(v["project"]) || isRecord(v) && v["kind"] === "writeRows" && checkRowWriteBatch(v["batch"]) || isRecord(v) && v["kind"] === "commitRows" && (Array.isArray(v["rows"]) && v["rows"].every((e) => checkRowCommit(e))) || isRecord(v) && v["kind"] === "createRow" && typeof v["entityType"] === "string" && accepts((x, q) => any(x, q), v["data"]) || isRecord(v) && v["kind"] === "writeRow" && typeof v["entityType"] === "string" && typeof v["id"] === "string" && accepts((x, q) => any(x, q), v["data"]) || isRecord(v) && v["kind"] === "deleteRow" && typeof v["entityType"] === "string" && typeof v["id"] === "string" || isRecord(v) && v["kind"] === "callService" && typeof v["service"] === "string" && typeof v["method"] === "string" && accepts((x, q) => any(x, q), v["args"]) && (v["key"] === void 0 || typeof v["key"] === "string") && (v["caller"] === void 0 || checkCallerWire(v["caller"])) && (v["site"] === void 0 || checkCallSiteWire(v["site"])) || isRecord(v) && v["kind"] === "cancelCall" && typeof v["key"] === "string" || isRecord(v) && v["kind"] === "substrate" && typeof v["op"] === "string" && (Array.isArray(v["args"]) && v["args"].every((e) => accepts((x, q) => any(x, q), e))) && (v["key"] === void 0 || typeof v["key"] === "string") && (v["site"] === void 0 || checkCallSiteWire(v["site"])) || isRecord(v) && v["kind"] === "pageFacts" && (Array.isArray(v["fields"]) && v["fields"].every((e) => checkPageFactFieldWire(e))) || isRecord(v) && v["kind"] === "prompt" && typeof v["text"] === "string" && typeof v["schema"] === "string" && (v["key"] === void 0 || typeof v["key"] === "string") || isRecord(v) && v["kind"] === "embed" && (Array.isArray(v["texts"]) && v["texts"].every((e) => typeof e === "string")) && (v["key"] === void 0 || typeof v["key"] === "string") || isRecord(v) && v["kind"] === "tab" && checkTabAsk(v["ask"]) && (v["key"] === void 0 || typeof v["key"] === "string") || isRecord(v) && v["kind"] === "secret" && typeof v["name"] === "string" && (v["principal"] === void 0 || typeof v["principal"] === "string") || isRecord(v) && v["kind"] === "secretSet" && typeof v["name"] === "string" && typeof v["value"] === "string" && typeof v["ttlMs"] === "number" && (v["principal"] === void 0 || typeof v["principal"] === "string") || isRecord(v) && v["kind"] === "secretRotate" && typeof v["name"] === "string" && typeof v["value"] === "string" && (v["principal"] === void 0 || typeof v["principal"] === "string") || isRecord(v) && v["kind"] === "deliver" && checkEnvelope(v["envelope"]) && (v["key"] === void 0 || typeof v["key"] === "string") && checkCallSiteWire(v["site"]) || isRecord(v) && v["kind"] === "guest" && typeof v["guest"] === "string" && (Array.isArray(v["targets"]) && v["targets"].every((e) => typeof e === "string")) && typeof v["event"] === "string" && accepts((x, q) => any(x, q), v["payload"]) && checkOsGrants(v["grants"]) && (v["key"] === void 0 || typeof v["key"] === "string") && (v["site"] === void 0 || checkCallSiteWire(v["site"])) || isRecord(v) && v["kind"] === "random" && typeof v["bytes"] === "number" || isRecord(v) && v["kind"] === "clock" || isRecord(v) && v["kind"] === "sealed" && typeof v["op"] === "string" && (Array.isArray(v["args"]) && v["args"].every((e) => accepts((x, q) => any(x, q), e))) || isRecord(v) && v["kind"] === "gpu" && typeof v["ticket"] === "number" && checkOsOp(v["op"]) && (v["key"] === void 0 || typeof v["key"] === "string") || isRecord(v) && v["kind"] === "os" && checkOsOp(v["op"]) && (Array.isArray(v["args"]) && v["args"].every((e) => accepts((x, q) => any(x, q), e))) && (v["key"] === void 0 || typeof v["key"] === "string") && (v["site"] === void 0 || checkCallSiteWire(v["site"])) && (v["principal"] === void 0 || typeof v["principal"] === "string") && (v["orbital"] === void 0 || typeof v["orbital"] === "string") || isRecord(v) && v["kind"] === "credentialStatus" && typeof v["name"] === "string" && (v["principal"] === void 0 || typeof v["principal"] === "string") || isRecord(v) && v["kind"] === "credentialForget" && typeof v["name"] === "string" && (v["principal"] === void 0 || typeof v["principal"] === "string") || isRecord(v) && v["kind"] === "credentialConnect" && checkCredentialGrantWire(v["grant"]) || isRecord(v) && v["kind"] === "credentialStoreList" || isRecord(v) && v["kind"] === "credentialEnvTails" && (Array.isArray(v["names"]) && v["names"].every((e) => typeof e === "string")) || isRecord(v) && v["kind"] === "credentialStoreRead" && typeof v["name"] === "string" || isRecord(v) && v["kind"] === "credentialStoreWrite" && typeof v["service"] === "string" && typeof v["name"] === "string" && typeof v["value"] === "string" || isRecord(v) && v["kind"] === "credentialStoreRemove" && typeof v["name"] === "string" || isRecord(v) && v["kind"] === "credentialStoreRotate" || isRecord(v) && v["kind"] === "credentialModeRead" || isRecord(v) && v["kind"] === "credentialModeWrite" && typeof v["mode"] === "string";
|
|
293
302
|
}
|
|
294
303
|
function checkJsonTokenSpec(v) {
|
|
295
304
|
return isRecord(v) && typeof v["clientIdField"] === "string" && typeof v["clientSecretField"] === "string" && typeof v["accessField"] === "string" && (v["refreshField"] === void 0 || (typeof v["refreshField"] === "string" || v["refreshField"] === null)) && (v["expiresInField"] === void 0 || (typeof v["expiresInField"] === "string" || v["expiresInField"] === null)) && (v["refreshEndpoint"] === void 0 || (typeof v["refreshEndpoint"] === "string" || v["refreshEndpoint"] === null)) && (v["refreshBodyField"] === void 0 || (typeof v["refreshBodyField"] === "string" || v["refreshBodyField"] === null));
|
|
@@ -361,19 +370,19 @@ function checkOsGrantFinding(v) {
|
|
|
361
370
|
return isRecord(v) && checkOsGrantFindingCode(v["code"]) && (v["orbital"] === void 0 || typeof v["orbital"] === "string") && (v["call"] === void 0 || typeof v["call"] === "string") && (v["entry"] === void 0 || typeof v["entry"] === "string") && typeof v["site"] === "string" && (v["grant"] === void 0 || typeof v["grant"] === "string") && (v["app"] === void 0 || typeof v["app"] === "boolean") && (v["argument"] === void 0 || typeof v["argument"] === "number") && (v["via"] === void 0 || checkOsGrantVia(v["via"]));
|
|
362
371
|
}
|
|
363
372
|
function checkOsGrantFindingCode(v) {
|
|
364
|
-
return v === "missing" || v === "unused" || v === "entry-invalid" || v === "target-not-static";
|
|
373
|
+
return v === "missing" || v === "unused" || v === "entry-invalid" || v === "target-not-static" || v === "shader-invalid" || v === "binding-mismatch";
|
|
365
374
|
}
|
|
366
375
|
function checkOsGrantVia(v) {
|
|
367
376
|
return v === "config" || v === "config-unresolvable" || v === "computed-path";
|
|
368
377
|
}
|
|
369
378
|
function checkOsGrants(v) {
|
|
370
|
-
return isRecord(v) && (v["fs"] === void 0 || Array.isArray(v["fs"]) && v["fs"].every((e) => checkFsGrant(e))) && (v["exec"] === void 0 || Array.isArray(v["exec"]) && v["exec"].every((e) => typeof e === "string")) && (v["net"] === void 0 || Array.isArray(v["net"]) && v["net"].every((e) => checkNetGrant(e))) && (v["env"] === void 0 || Array.isArray(v["env"]) && v["env"].every((e) => typeof e === "string")) && (v["stdio"] === void 0 || Array.isArray(v["stdio"]) && v["stdio"].every((e) => checkStdioKind(e))) && (v["sys"] === void 0 || Array.isArray(v["sys"]) && v["sys"].every((e) => checkSysKind(e))) && (v["desktop"] === void 0 || Array.isArray(v["desktop"]) && v["desktop"].every((e) => checkDesktopKind(e))) && (v["dev"] === void 0 || Array.isArray(v["dev"]) && v["dev"].every((e) => checkDevGrant(e))) && (v["mem"] === void 0 || Array.isArray(v["mem"]) && v["mem"].every((e) => checkMemGrant(e))) && (v["kernel"] === void 0 || Array.isArray(v["kernel"]) && v["kernel"].every((e) => checkKernelGrant(e))) && (v["ffi"] === void 0 || Array.isArray(v["ffi"]) && v["ffi"].every((e) => checkFfiGrant(e))) && (v["credentials"] === void 0 || Array.isArray(v["credentials"]) && v["credentials"].every((e) => checkCredentialKind(e))) && (v["kv"] === void 0 || isRecord(v["kv"]) && Object.values(v["kv"]).every((e) => Array.isArray(e) && e.every((e2) => checkKvMode(e2)))) && (v["anchored"] === void 0 || checkAnchoredGrants(v["anchored"]));
|
|
379
|
+
return isRecord(v) && (v["fs"] === void 0 || Array.isArray(v["fs"]) && v["fs"].every((e) => checkFsGrant(e))) && (v["exec"] === void 0 || Array.isArray(v["exec"]) && v["exec"].every((e) => typeof e === "string")) && (v["net"] === void 0 || Array.isArray(v["net"]) && v["net"].every((e) => checkNetGrant(e))) && (v["env"] === void 0 || Array.isArray(v["env"]) && v["env"].every((e) => typeof e === "string")) && (v["stdio"] === void 0 || Array.isArray(v["stdio"]) && v["stdio"].every((e) => checkStdioKind(e))) && (v["sys"] === void 0 || Array.isArray(v["sys"]) && v["sys"].every((e) => checkSysKind(e))) && (v["desktop"] === void 0 || Array.isArray(v["desktop"]) && v["desktop"].every((e) => checkDesktopKind(e))) && (v["dev"] === void 0 || Array.isArray(v["dev"]) && v["dev"].every((e) => checkDevGrant(e))) && (v["mem"] === void 0 || Array.isArray(v["mem"]) && v["mem"].every((e) => checkMemGrant(e))) && (v["kernel"] === void 0 || Array.isArray(v["kernel"]) && v["kernel"].every((e) => checkKernelGrant(e))) && (v["ffi"] === void 0 || Array.isArray(v["ffi"]) && v["ffi"].every((e) => checkFfiGrant(e))) && (v["gpu"] === void 0 || Array.isArray(v["gpu"]) && v["gpu"].every((e) => checkGpuGrant(e))) && (v["credentials"] === void 0 || Array.isArray(v["credentials"]) && v["credentials"].every((e) => checkCredentialKind(e))) && (v["kv"] === void 0 || isRecord(v["kv"]) && Object.values(v["kv"]).every((e) => Array.isArray(e) && e.every((e2) => checkKvMode(e2)))) && (v["anchored"] === void 0 || checkAnchoredGrants(v["anchored"]));
|
|
371
380
|
}
|
|
372
381
|
function checkOsGrantsReport(v) {
|
|
373
382
|
return isRecord(v) && (Array.isArray(v["findings"]) && v["findings"].every((e) => checkOsGrantFinding(e)));
|
|
374
383
|
}
|
|
375
384
|
function checkOsOp(v) {
|
|
376
|
-
return v === "os/read-file" || v === "os/write-file" || v === "os/append-file" || v === "os/open" || v === "os/close" || v === "os/read" || v === "os/write" || v === "os/seek" || v === "os/truncate" || v === "os/fsync" || v === "os/copy" || v === "os/rename" || v === "os/remove" || v === "os/link" || v === "os/symlink" || v === "os/readlink" || v === "os/watch-files" || v === "os/mkdir" || v === "os/rmdir" || v === "os/list-dir" || v === "os/glob" || v === "os/mktemp" || v === "os/realpath" || v === "os/cwd" || v === "os/chdir" || v === "os/stat" || v === "os/lstat" || v === "os/access" || v === "os/exists" || v === "os/chmod" || v === "os/chown" || v === "os/utimes" || v === "os/spawn" || v === "os/wait" || v === "os/kill" || v === "os/pid" || v === "os/ppid" || v === "os/current-exe" || v === "os/watch-process" || v === "os/watch-signal" || v === "os/getenv" || v === "os/setenv" || v === "os/unsetenv" || v === "os/environ" || v === "os/watch-env" || v === "os/stdin-read" || v === "os/stdout-write" || v === "os/stderr-write" || v === "os/isatty" || v === "os/tty-size" || v === "os/tcp-connect" || v === "os/tcp-listen" || v === "os/tls-upgrade" || v === "os/send" || v === "os/recv" || v === "os/udp-bind" || v === "os/sendto" || v === "os/recvfrom" || v === "os/dns-resolve" || v === "os/shutdown" || v === "os/watch-port" || v === "os/fetch" || v === "os/clock-monotonic" || v === "os/uid" || v === "os/gid" || v === "os/username" || v === "os/group-of" || v === "os/watch-cron" || v === "os/cpu-usage" || v === "os/memory-info" || v === "os/uptime" || v === "os/load-avg" || v === "os/hostname" || v === "os/uname" || v === "os/disk-usage" || v === "os/mounts" || v === "os/disk-io" || v === "os/network-interfaces" || v === "os/network-stats" || v === "os/network-connected" || v === "os/default-gateway" || v === "os/battery-status" || v === "os/ac-power" || v === "os/thermal-zones" || v === "os/notify" || v === "os/speak" || v === "os/brightness-get" || v === "os/brightness-set" || v === "os/volume-get" || v === "os/volume-set" || v === "os/volume-mute" || v === "os/suspend" || v === "os/hibernate" || v === "os/mmio-read" || v === "os/mmio-write" || v === "os/irq-wait" || v === "os/irq-ack" || v === "kv/get" || v === "kv/put" || v === "kv/delete" || v === "kv/scan" || v === "kv/batch" || v === "mem/arena-new" || v === "mem/arena-drop" || v === "mem/alloc" || v === "mem/free" || v === "mem/borrow" || v === "mem/release" || v === "mem/write" || v === "mem/freeze" || v === "mem/atomic-load" || v === "mem/atomic-store" || v === "mem/atomic-add" || v === "mem/atomic-cas" || v === "kernel/queue-front" || v === "kernel/queue-back" || v === "ffi/call";
|
|
385
|
+
return v === "os/read-file" || v === "os/write-file" || v === "os/append-file" || v === "os/open" || v === "os/close" || v === "os/read" || v === "os/write" || v === "os/seek" || v === "os/truncate" || v === "os/fsync" || v === "os/copy" || v === "os/rename" || v === "os/remove" || v === "os/link" || v === "os/symlink" || v === "os/readlink" || v === "os/watch-files" || v === "os/mkdir" || v === "os/rmdir" || v === "os/list-dir" || v === "os/glob" || v === "os/mktemp" || v === "os/realpath" || v === "os/cwd" || v === "os/chdir" || v === "os/stat" || v === "os/lstat" || v === "os/access" || v === "os/exists" || v === "os/chmod" || v === "os/chown" || v === "os/utimes" || v === "os/spawn" || v === "os/wait" || v === "os/kill" || v === "os/pid" || v === "os/ppid" || v === "os/current-exe" || v === "os/watch-process" || v === "os/watch-signal" || v === "os/getenv" || v === "os/setenv" || v === "os/unsetenv" || v === "os/environ" || v === "os/watch-env" || v === "os/stdin-read" || v === "os/stdout-write" || v === "os/stderr-write" || v === "os/isatty" || v === "os/tty-size" || v === "os/tcp-connect" || v === "os/tcp-listen" || v === "os/tls-upgrade" || v === "os/send" || v === "os/recv" || v === "os/udp-bind" || v === "os/sendto" || v === "os/recvfrom" || v === "os/dns-resolve" || v === "os/shutdown" || v === "os/watch-port" || v === "os/fetch" || v === "os/clock-monotonic" || v === "os/uid" || v === "os/gid" || v === "os/username" || v === "os/group-of" || v === "os/watch-cron" || v === "os/cpu-usage" || v === "os/memory-info" || v === "os/uptime" || v === "os/load-avg" || v === "os/hostname" || v === "os/uname" || v === "os/disk-usage" || v === "os/mounts" || v === "os/disk-io" || v === "os/network-interfaces" || v === "os/network-stats" || v === "os/network-connected" || v === "os/default-gateway" || v === "os/battery-status" || v === "os/ac-power" || v === "os/thermal-zones" || v === "os/notify" || v === "os/speak" || v === "os/brightness-get" || v === "os/brightness-set" || v === "os/volume-get" || v === "os/volume-set" || v === "os/volume-mute" || v === "os/suspend" || v === "os/hibernate" || v === "os/mmio-read" || v === "os/mmio-write" || v === "os/irq-wait" || v === "os/irq-ack" || v === "kv/get" || v === "kv/put" || v === "kv/delete" || v === "kv/scan" || v === "kv/batch" || v === "mem/arena-new" || v === "mem/arena-drop" || v === "mem/alloc" || v === "mem/free" || v === "mem/borrow" || v === "mem/release" || v === "mem/write" || v === "mem/freeze" || v === "mem/atomic-load" || v === "mem/atomic-store" || v === "mem/atomic-add" || v === "mem/atomic-cas" || v === "kernel/queue-front" || v === "kernel/queue-back" || v === "ffi/call" || v === "gpu/device-open" || v === "gpu/device-close" || v === "gpu/buffer-create" || v === "gpu/texture-create" || v === "gpu/sampler-create" || v === "gpu/query-create" || v === "gpu/shader-create" || v === "gpu/pipeline-create" || v === "gpu/bind-group-create" || v === "gpu/submit" || v === "gpu/release";
|
|
377
386
|
}
|
|
378
387
|
function checkPageFactFieldWire(v) {
|
|
379
388
|
return v === "hostname" || v === "referrer" || v === "screenWidth" || v === "href";
|
|
@@ -748,7 +757,7 @@ function buildEvalStepWire(v, p) {
|
|
|
748
757
|
return obj(v, p, null, (r0) => ({ "kind": buildEvalStepKind(r0["kind"], p + ".kind"), "path": list(r0["path"], p + ".path", (e1, q1) => typeof e1 === "number" ? num(e1, q1) : typeof e1 === "string" ? str(e1, q1) : fail(miss(q1, "a number | a string"))), ...r0["value"] === void 0 || r0["value"] === null ? {} : { "value": any(r0["value"], p + ".value") }, ...r0["error"] === void 0 || r0["error"] === null ? {} : { "error": str(r0["error"], p + ".error") } }));
|
|
749
758
|
}
|
|
750
759
|
function buildEventRequest(v, p) {
|
|
751
|
-
return obj(v, p, null, (r0) => ({ "event": str(r0["event"], p + ".event"), ...r0["eventId"] === void 0 || r0["eventId"] === null ? {} : { "eventId": asEventId(str(r0["eventId"], p + ".eventId")) }, ...r0["payload"] === void 0 || r0["payload"] === null ? {} : { "payload": rec(r0["payload"], p + ".payload") }, ...r0["entityId"] === void 0 || r0["entityId"] === null ? {} : { "entityId": str(r0["entityId"], p + ".entityId") }, ...r0["targetTrait"] === void 0 || r0["targetTrait"] === null ? {} : { "targetTrait": str(r0["targetTrait"], p + ".targetTrait") }, ...r0["clientId"] === void 0 || r0["clientId"] === null ? {} : { "clientId": str(r0["clientId"], p + ".clientId") }, ...r0["locale"] === void 0 || r0["locale"] === null ? {} : { "locale": str(r0["locale"], p + ".locale") }, ...r0["tick"] === void 0 || r0["tick"] === null ? {} : { "tick": str(r0["tick"], p + ".tick") }, ...r0["sourceTrait"] === void 0 || r0["sourceTrait"] === null ? {} : { "sourceTrait": str(r0["sourceTrait"], p + ".sourceTrait") }, ...r0["runTick"] === void 0 || r0["runTick"] === null ? {} : { "runTick": buildRunTick(r0["runTick"], p + ".runTick") }, ...r0["traits"] === void 0 || r0["traits"] === null ? {} : { "traits": list(r0["traits"], p + ".traits", (e1, q1) => buildTraitFrom(e1, q1)) }, ...r0["entityByTrait"] === void 0 || r0["entityByTrait"] === null ? {} : { "entityByTrait": dict(r0["entityByTrait"], p + ".entityByTrait", (e1, q1) => entityRow(e1, q1)) }, ...r0["behavior"] === void 0 || r0["behavior"] === null ? {} : { "behavior": str(r0["behavior"], p + ".behavior") }, ...r0["delivery"] === void 0 || r0["delivery"] === null ? {} : { "delivery": buildDeliveryRecord(r0["delivery"], p + ".delivery") }, ...r0["dispatchLog"] === void 0 || r0["dispatchLog"] === null ? {} : { "dispatchLog": buildDispatchLog(r0["dispatchLog"], p + ".dispatchLog") }, ...r0["mount"] === void 0 || r0["mount"] === null ? {} : { "mount": list(r0["mount"], p + ".mount", (e1, q1) => buildMountSeed(e1, q1)) }, ...r0["route"] === void 0 || r0["route"] === null ? {} : { "route": str(r0["route"], p + ".route") }, ...r0["residence"] === void 0 || r0["residence"] === null ? {} : { "residence": buildLegResidence(r0["residence"], p + ".residence") }, ...r0["framesSince"] === void 0 || r0["framesSince"] === null ? {} : { "framesSince": int(r0["framesSince"], p + ".framesSince", 0, Number.MAX_SAFE_INTEGER, "u64") } }));
|
|
760
|
+
return obj(v, p, null, (r0) => ({ "event": str(r0["event"], p + ".event"), ...r0["eventId"] === void 0 || r0["eventId"] === null ? {} : { "eventId": asEventId(str(r0["eventId"], p + ".eventId")) }, ...r0["payload"] === void 0 || r0["payload"] === null ? {} : { "payload": rec(r0["payload"], p + ".payload") }, ...r0["entityId"] === void 0 || r0["entityId"] === null ? {} : { "entityId": str(r0["entityId"], p + ".entityId") }, ...r0["targetTrait"] === void 0 || r0["targetTrait"] === null ? {} : { "targetTrait": str(r0["targetTrait"], p + ".targetTrait") }, ...r0["clientId"] === void 0 || r0["clientId"] === null ? {} : { "clientId": str(r0["clientId"], p + ".clientId") }, ...r0["locale"] === void 0 || r0["locale"] === null ? {} : { "locale": str(r0["locale"], p + ".locale") }, ...r0["tick"] === void 0 || r0["tick"] === null ? {} : { "tick": str(r0["tick"], p + ".tick") }, ...r0["sourceTrait"] === void 0 || r0["sourceTrait"] === null ? {} : { "sourceTrait": str(r0["sourceTrait"], p + ".sourceTrait") }, ...r0["runTick"] === void 0 || r0["runTick"] === null ? {} : { "runTick": buildRunTick(r0["runTick"], p + ".runTick") }, ...r0["traits"] === void 0 || r0["traits"] === null ? {} : { "traits": list(r0["traits"], p + ".traits", (e1, q1) => buildTraitFrom(e1, q1)) }, ...r0["entityByTrait"] === void 0 || r0["entityByTrait"] === null ? {} : { "entityByTrait": dict(r0["entityByTrait"], p + ".entityByTrait", (e1, q1) => entityRow(e1, q1)) }, ...r0["behavior"] === void 0 || r0["behavior"] === null ? {} : { "behavior": str(r0["behavior"], p + ".behavior") }, ...r0["delivery"] === void 0 || r0["delivery"] === null ? {} : { "delivery": buildDeliveryRecord(r0["delivery"], p + ".delivery") }, ...r0["dispatchLog"] === void 0 || r0["dispatchLog"] === null ? {} : { "dispatchLog": buildDispatchLog(r0["dispatchLog"], p + ".dispatchLog") }, ...r0["mount"] === void 0 || r0["mount"] === null ? {} : { "mount": list(r0["mount"], p + ".mount", (e1, q1) => buildMountSeed(e1, q1)) }, ...r0["route"] === void 0 || r0["route"] === null ? {} : { "route": str(r0["route"], p + ".route") }, ...r0["residence"] === void 0 || r0["residence"] === null ? {} : { "residence": buildLegResidence(r0["residence"], p + ".residence") }, ...r0["framesSince"] === void 0 || r0["framesSince"] === null ? {} : { "framesSince": int(r0["framesSince"], p + ".framesSince", 0, Number.MAX_SAFE_INTEGER, "u64") }, ...r0["heldPayload"] === void 0 || r0["heldPayload"] === null ? {} : { "heldPayload": int(r0["heldPayload"], p + ".heldPayload", 0, Number.MAX_SAFE_INTEGER, "u64") } }));
|
|
752
761
|
}
|
|
753
762
|
function buildEventResponse(v, p) {
|
|
754
763
|
return obj(v, p, null, (r0) => ({ "success": r0["success"] === void 0 ? false : bool(r0["success"], p + ".success"), "transitioned": r0["transitioned"] === void 0 ? false : bool(r0["transitioned"], p + ".transitioned"), "states": r0["states"] === void 0 ? {} : dict(r0["states"], p + ".states", (e1, q1) => str(e1, q1)), "emittedEvents": r0["emittedEvents"] === void 0 ? [] : list(r0["emittedEvents"], p + ".emittedEvents", (e1, q1) => buildEmittedEvent(e1, q1)), ...r0["data"] === void 0 || r0["data"] === null ? {} : { "data": dict(r0["data"], p + ".data", (e1, q1) => list(e1, q1, (e2, q2) => entityRow(e2, q2))) }, ...r0["dataRefs"] === void 0 || r0["dataRefs"] === null ? {} : { "dataRefs": dict(r0["dataRefs"], p + ".dataRefs", (e1, q1) => buildRowSetRef(e1, q1)) }, ...r0["frames"] === void 0 || r0["frames"] === null ? {} : { "frames": buildFrameDelta(r0["frames"], p + ".frames") }, ...r0["clientEffectsByTrait"] === void 0 || r0["clientEffectsByTrait"] === null ? {} : { "clientEffectsByTrait": list(r0["clientEffectsByTrait"], p + ".clientEffectsByTrait", (e1, q1) => buildClientEffectByTrait(e1, q1)) }, ...r0["effectResults"] === void 0 || r0["effectResults"] === null ? {} : { "effectResults": list(r0["effectResults"], p + ".effectResults", (e1, q1) => buildServerEffectResult(e1, q1)) }, ...r0["guardFailed"] === void 0 || r0["guardFailed"] === null ? {} : { "guardFailed": str(r0["guardFailed"], p + ".guardFailed") }, ...r0["rejections"] === void 0 || r0["rejections"] === null ? {} : { "rejections": list(r0["rejections"], p + ".rejections", (e1, q1) => buildTransitionRejection(e1, q1)) }, ...r0["cascadeTruncated"] === void 0 || r0["cascadeTruncated"] === null ? {} : { "cascadeTruncated": list(r0["cascadeTruncated"], p + ".cascadeTruncated", (e1, q1) => str(e1, q1)) }, ...r0["transitions"] === void 0 || r0["transitions"] === null ? {} : { "transitions": list(r0["transitions"], p + ".transitions", (e1, q1) => buildTransitionHop(e1, q1)) }, ...r0["error"] === void 0 || r0["error"] === null ? {} : { "error": str(r0["error"], p + ".error") } }));
|
|
@@ -792,12 +801,21 @@ function buildFsGrant(v, p) {
|
|
|
792
801
|
function buildFsMode(v, p) {
|
|
793
802
|
return oneOf(v, p, ["read", "write", "create", "remove", "meta"]);
|
|
794
803
|
}
|
|
804
|
+
function buildGpuGrant(v, p) {
|
|
805
|
+
return obj(v, p, ["target", "kinds"], (r0) => ({ "target": str(r0["target"], p + ".target"), "kinds": list(r0["kinds"], p + ".kinds", (e1, q1) => buildGpuKind(e1, q1)) }));
|
|
806
|
+
}
|
|
807
|
+
function buildGpuKind(v, p) {
|
|
808
|
+
return oneOf(v, p, ["open", "compute", "render", "readback"]);
|
|
809
|
+
}
|
|
795
810
|
function buildGrantAnchor(v, p) {
|
|
796
811
|
return v === "exe" ? lit(v, p, "exe") : v === "exe-dir" ? lit(v, p, "exe-dir") : v === "cwd" ? lit(v, p, "cwd") : isRecord(v) && typeof v["env"] === "string" ? obj(v, p, null, (r0) => ({ "env": str(r0["env"], p + ".env") })) : fail(miss(p, '"exe" | "exe-dir" | "cwd" | an object'));
|
|
797
812
|
}
|
|
798
813
|
function buildGuardVerdict(v, p) {
|
|
799
814
|
return oneOf(v, p, ["pass", "fail", "none"]);
|
|
800
815
|
}
|
|
816
|
+
function buildHeldGpuCompletion(v, p) {
|
|
817
|
+
return obj(v, p, null, (r0) => ({ ...r0["orbital"] === void 0 || r0["orbital"] === null ? {} : { "orbital": str(r0["orbital"], p + ".orbital") }, "traitName": str(r0["traitName"], p + ".traitName"), ...r0["entityId"] === void 0 || r0["entityId"] === null ? {} : { "entityId": str(r0["entityId"], p + ".entityId") }, "event": str(r0["event"], p + ".event"), "heldPayload": int(r0["heldPayload"], p + ".heldPayload", 0, Number.MAX_SAFE_INTEGER, "u64") }));
|
|
818
|
+
}
|
|
801
819
|
function buildHopEffect(v, p) {
|
|
802
820
|
return obj(v, p, null, (r0) => ({ "type": str(r0["type"], p + ".type"), "args": list(r0["args"], p + ".args", (e1, q1) => any(e1, q1)), "status": buildHopEffectStatus(r0["status"], p + ".status"), ...r0["error"] === void 0 || r0["error"] === null ? {} : { "error": str(r0["error"], p + ".error") } }));
|
|
803
821
|
}
|
|
@@ -814,13 +832,13 @@ function buildInstanceRef(v, p) {
|
|
|
814
832
|
return obj(v, p, null, (r0) => ({ "instance": str(r0["instance"], p + ".instance"), "orbital": str(r0["orbital"], p + ".orbital"), ...r0["trait"] === void 0 || r0["trait"] === null ? {} : { "trait": str(r0["trait"], p + ".trait") } }));
|
|
815
833
|
}
|
|
816
834
|
function buildIoAnswerWire(v, p) {
|
|
817
|
-
return rec(v, p)["kind"] === "row" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "row"), "result": isRecord(r0["result"]) && (accepts((x, q) => entityRow(x, q), r0["result"]["ok"]) || r0["result"]["ok"] === null) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": r1["ok"] === null ? null : entityRow(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "rows" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "rows"), "result": isRecord(r0["result"]) && (Array.isArray(r0["result"]["ok"]) && r0["result"]["ok"].every((e) => accepts((x, q) => entityRow(x, q), e))) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": list(r1["ok"], p + ".result.ok", (e2, q2) => entityRow(e2, q2)) })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "page" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "page"), "result": isRecord(r0["result"]) && checkRowPage(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildRowPage(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "idPage" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "idPage"), "result": isRecord(r0["result"]) && checkRowIdPage(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildRowIdPage(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "queryUnsupported" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "queryUnsupported"), "reason": str(r0["reason"], p + ".reason") })) : rec(v, p)["kind"] === "wrote" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "wrote"), "result": isRecord(r0["result"]) && (Array.isArray(r0["result"]["ok"]) && r0["result"]["ok"].every((e) => checkRowWriteOutcome(e))) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": list(r1["ok"], p + ".result.ok", (e2, q2) => buildRowWriteOutcome(e2, q2)) })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "writeUnsupported" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "writeUnsupported"), "reason": str(r0["reason"], p + ".reason") })) : rec(v, p)["kind"] === "committed" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "committed"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "boolean" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": bool(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "deleted" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "deleted"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "service" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "service"), "result": isRecord(r0["result"]) && accepts((x, q) => any(x, q), r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": any(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "serviceCancelled" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "serviceCancelled") })) : rec(v, p)["kind"] === "serviceDeferred" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "serviceDeferred") })) : rec(v, p)["kind"] === "cancelled" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "cancelled"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "substrate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "substrate"), "result": isRecord(r0["result"]) && accepts((x, q) => any(x, q), r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": any(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkSubstrateFailureWire(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildSubstrateFailureWire(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "pageFacts" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "pageFacts"), "result": isRecord(r0["result"]) && checkPageFactsWire(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildPageFactsWire(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "prompt" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "prompt"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkModelFailureWire(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildModelFailureWire(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "embed" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "embed"), "result": isRecord(r0["result"]) && (Array.isArray(r0["result"]["ok"]) && r0["result"]["ok"].every((e) => Array.isArray(e) && e.every((e2) => typeof e2 === "number"))) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": list(r1["ok"], p + ".result.ok", (e2, q2) => list(e2, q2, (e3, q3) => num(e3, q3))) })) : isRecord(r0["result"]) && checkModelFailureWire(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildModelFailureWire(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "tab" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "tab"), "result": isRecord(r0["result"]) && accepts((x, q) => any(x, q), r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": any(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkTabFailure(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildTabFailure(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "secret" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secret"), "result": isRecord(r0["result"]) && (typeof r0["result"]["ok"] === "string" || r0["result"]["ok"] === null) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": r1["ok"] === null ? null : str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "secretSet" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secretSet"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "secretRotate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secretRotate"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "random" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "random"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "clock" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "clock"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "number" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": num(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "sealed" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "sealed"), "result": isRecord(r0["result"]) && accepts((x, q) => any(x, q), r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": any(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "os" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "os"), "result": isRecord(r0["result"]) && accepts((x, q) => any(x, q), r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": any(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkOsError(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildOsError(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialStatus" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStatus"), "result": isRecord(r0["result"]) && checkCredentialStanding(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildCredentialStanding(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialForget" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialForget"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialConnect" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialConnect"), "result": isRecord(r0["result"]) && checkCredentialStanding(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildCredentialStanding(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkConnectFailure(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildConnectFailure(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialStoreList" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreList"), "result": isRecord(r0["result"]) && (checkStoreListing(r0["result"]["ok"]) || r0["result"]["ok"] === null) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": r1["ok"] === null ? null : buildStoreListing(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialEnvTails" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialEnvTails"), "result": isRecord(r0["result"]) && checkEnvTails(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildEnvTails(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialStoreRead" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRead"), "result": isRecord(r0["result"]) && (typeof r0["result"]["ok"] === "string" || r0["result"]["ok"] === null) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": r1["ok"] === null ? null : str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialStoreWrite" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreWrite"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialStoreRemove" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRemove"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "boolean" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": bool(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialStoreRotate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRotate"), "result": isRecord(r0["result"]) && checkRotateCounts(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildRotateCounts(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialModeRead" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialModeRead"), "result": isRecord(r0["result"]) && (typeof r0["result"]["ok"] === "string" || r0["result"]["ok"] === null) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": r1["ok"] === null ? null : str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialModeWrite" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialModeWrite"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "deliver" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "deliver"), "result": isRecord(r0["result"]) && checkAccepted(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildAccepted(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkDeliverRefusal(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildDeliverRefusal(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : fail(unknownTag(p, "kind", rec(v, p)["kind"]));
|
|
835
|
+
return rec(v, p)["kind"] === "row" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "row"), "result": isRecord(r0["result"]) && (accepts((x, q) => entityRow(x, q), r0["result"]["ok"]) || r0["result"]["ok"] === null) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": r1["ok"] === null ? null : entityRow(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "rows" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "rows"), "result": isRecord(r0["result"]) && (Array.isArray(r0["result"]["ok"]) && r0["result"]["ok"].every((e) => accepts((x, q) => entityRow(x, q), e))) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": list(r1["ok"], p + ".result.ok", (e2, q2) => entityRow(e2, q2)) })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "page" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "page"), "result": isRecord(r0["result"]) && checkRowPage(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildRowPage(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "idPage" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "idPage"), "result": isRecord(r0["result"]) && checkRowIdPage(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildRowIdPage(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "queryUnsupported" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "queryUnsupported"), "reason": str(r0["reason"], p + ".reason") })) : rec(v, p)["kind"] === "wrote" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "wrote"), "result": isRecord(r0["result"]) && (Array.isArray(r0["result"]["ok"]) && r0["result"]["ok"].every((e) => checkRowWriteOutcome(e))) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": list(r1["ok"], p + ".result.ok", (e2, q2) => buildRowWriteOutcome(e2, q2)) })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "writeUnsupported" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "writeUnsupported"), "reason": str(r0["reason"], p + ".reason") })) : rec(v, p)["kind"] === "committed" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "committed"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "boolean" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": bool(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "deleted" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "deleted"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "service" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "service"), "result": isRecord(r0["result"]) && accepts((x, q) => any(x, q), r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": any(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "serviceCancelled" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "serviceCancelled") })) : rec(v, p)["kind"] === "serviceDeferred" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "serviceDeferred") })) : rec(v, p)["kind"] === "cancelled" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "cancelled"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "substrate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "substrate"), "result": isRecord(r0["result"]) && accepts((x, q) => any(x, q), r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": any(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkSubstrateFailureWire(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildSubstrateFailureWire(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "pageFacts" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "pageFacts"), "result": isRecord(r0["result"]) && checkPageFactsWire(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildPageFactsWire(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "prompt" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "prompt"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkModelFailureWire(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildModelFailureWire(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "embed" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "embed"), "result": isRecord(r0["result"]) && (Array.isArray(r0["result"]["ok"]) && r0["result"]["ok"].every((e) => Array.isArray(e) && e.every((e2) => typeof e2 === "number"))) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": list(r1["ok"], p + ".result.ok", (e2, q2) => list(e2, q2, (e3, q3) => num(e3, q3))) })) : isRecord(r0["result"]) && checkModelFailureWire(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildModelFailureWire(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "tab" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "tab"), "result": isRecord(r0["result"]) && accepts((x, q) => any(x, q), r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": any(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkTabFailure(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildTabFailure(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "secret" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secret"), "result": isRecord(r0["result"]) && (typeof r0["result"]["ok"] === "string" || r0["result"]["ok"] === null) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": r1["ok"] === null ? null : str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "secretSet" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secretSet"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "secretRotate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secretRotate"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "random" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "random"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "clock" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "clock"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "number" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": num(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "sealed" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "sealed"), "result": isRecord(r0["result"]) && accepts((x, q) => any(x, q), r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": any(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "os" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "os"), "result": isRecord(r0["result"]) && accepts((x, q) => any(x, q), r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": any(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkOsError(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildOsError(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "gpuHeld" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "gpuHeld"), "ticket": int(r0["ticket"], p + ".ticket", 0, Number.MAX_SAFE_INTEGER, "u64") })) : rec(v, p)["kind"] === "credentialStatus" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStatus"), "result": isRecord(r0["result"]) && checkCredentialStanding(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildCredentialStanding(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialForget" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialForget"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialConnect" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialConnect"), "result": isRecord(r0["result"]) && checkCredentialStanding(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildCredentialStanding(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkConnectFailure(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildConnectFailure(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialStoreList" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreList"), "result": isRecord(r0["result"]) && (checkStoreListing(r0["result"]["ok"]) || r0["result"]["ok"] === null) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": r1["ok"] === null ? null : buildStoreListing(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialEnvTails" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialEnvTails"), "result": isRecord(r0["result"]) && checkEnvTails(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildEnvTails(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialStoreRead" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRead"), "result": isRecord(r0["result"]) && (typeof r0["result"]["ok"] === "string" || r0["result"]["ok"] === null) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": r1["ok"] === null ? null : str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialStoreWrite" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreWrite"), "result": isRecord(r0["result"]) && r0["result"]["ok"] === null ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": nul(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialStoreRemove" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRemove"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "boolean" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": bool(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialStoreRotate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRotate"), "result": isRecord(r0["result"]) && checkRotateCounts(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildRotateCounts(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialModeRead" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialModeRead"), "result": isRecord(r0["result"]) && (typeof r0["result"]["ok"] === "string" || r0["result"]["ok"] === null) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": r1["ok"] === null ? null : str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "credentialModeWrite" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialModeWrite"), "result": isRecord(r0["result"]) && typeof r0["result"]["ok"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": str(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && typeof r0["result"]["error"] === "string" ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": str(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : rec(v, p)["kind"] === "deliver" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "deliver"), "result": isRecord(r0["result"]) && checkAccepted(r0["result"]["ok"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "ok": buildAccepted(r1["ok"], p + ".result.ok") })) : isRecord(r0["result"]) && checkDeliverRefusal(r0["result"]["error"]) ? obj(r0["result"], p + ".result", null, (r1) => ({ "error": buildDeliverRefusal(r1["error"], p + ".result.error") })) : fail(miss(p + ".result", "an object | an object")) })) : fail(unknownTag(p, "kind", rec(v, p)["kind"]));
|
|
818
836
|
}
|
|
819
837
|
function buildIoReplyWire(v, p) {
|
|
820
838
|
return obj(v, p, null, (r0) => ({ "id": int(r0["id"], p + ".id", 0, Number.MAX_SAFE_INTEGER, "u64"), "answer": buildIoAnswerWire(r0["answer"], p + ".answer") }));
|
|
821
839
|
}
|
|
822
840
|
function buildIoRequestWire(v, p) {
|
|
823
|
-
return rec(v, p)["kind"] === "readRow" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "readRow"), "entityType": str(r0["entityType"], p + ".entityType"), "id": str(r0["id"], p + ".id") })) : rec(v, p)["kind"] === "listRows" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "listRows"), "entityType": str(r0["entityType"], p + ".entityType") })) : rec(v, p)["kind"] === "queryRows" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "queryRows"), "entityType": str(r0["entityType"], p + ".entityType"), "query": buildRowQuery(r0["query"], p + ".query"), "project": buildRowProjection(r0["project"], p + ".project") })) : rec(v, p)["kind"] === "writeRows" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "writeRows"), "batch": buildRowWriteBatch(r0["batch"], p + ".batch") })) : rec(v, p)["kind"] === "commitRows" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "commitRows"), "rows": list(r0["rows"], p + ".rows", (e1, q1) => buildRowCommit(e1, q1)) })) : rec(v, p)["kind"] === "createRow" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "createRow"), "entityType": str(r0["entityType"], p + ".entityType"), "data": any(r0["data"], p + ".data") })) : rec(v, p)["kind"] === "writeRow" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "writeRow"), "entityType": str(r0["entityType"], p + ".entityType"), "id": str(r0["id"], p + ".id"), "data": any(r0["data"], p + ".data") })) : rec(v, p)["kind"] === "deleteRow" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "deleteRow"), "entityType": str(r0["entityType"], p + ".entityType"), "id": str(r0["id"], p + ".id") })) : rec(v, p)["kind"] === "callService" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "callService"), "service": str(r0["service"], p + ".service"), "method": str(r0["method"], p + ".method"), "args": any(r0["args"], p + ".args"), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") }, ...r0["caller"] === void 0 || r0["caller"] === null ? {} : { "caller": buildCallerWire(r0["caller"], p + ".caller") }, ...r0["site"] === void 0 || r0["site"] === null ? {} : { "site": buildCallSiteWire(r0["site"], p + ".site") } })) : rec(v, p)["kind"] === "cancelCall" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "cancelCall"), "key": str(r0["key"], p + ".key") })) : rec(v, p)["kind"] === "substrate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "substrate"), "op": str(r0["op"], p + ".op"), "args": list(r0["args"], p + ".args", (e1, q1) => any(e1, q1)), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") }, ...r0["site"] === void 0 || r0["site"] === null ? {} : { "site": buildCallSiteWire(r0["site"], p + ".site") } })) : rec(v, p)["kind"] === "pageFacts" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "pageFacts"), "fields": list(r0["fields"], p + ".fields", (e1, q1) => buildPageFactFieldWire(e1, q1)) })) : rec(v, p)["kind"] === "prompt" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "prompt"), "text": str(r0["text"], p + ".text"), "schema": str(r0["schema"], p + ".schema"), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") } })) : rec(v, p)["kind"] === "embed" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "embed"), "texts": list(r0["texts"], p + ".texts", (e1, q1) => str(e1, q1)), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") } })) : rec(v, p)["kind"] === "tab" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "tab"), "ask": buildTabAsk(r0["ask"], p + ".ask"), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") } })) : rec(v, p)["kind"] === "secret" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secret"), "name": str(r0["name"], p + ".name"), ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") } })) : rec(v, p)["kind"] === "secretSet" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secretSet"), "name": str(r0["name"], p + ".name"), "value": str(r0["value"], p + ".value"), "ttlMs": int(r0["ttlMs"], p + ".ttlMs", 0, Number.MAX_SAFE_INTEGER, "u64"), ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") } })) : rec(v, p)["kind"] === "secretRotate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secretRotate"), "name": str(r0["name"], p + ".name"), "value": str(r0["value"], p + ".value"), ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") } })) : rec(v, p)["kind"] === "deliver" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "deliver"), "envelope": buildEnvelope(r0["envelope"], p + ".envelope"), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") }, "site": buildCallSiteWire(r0["site"], p + ".site") })) : rec(v, p)["kind"] === "guest" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "guest"), "guest": str(r0["guest"], p + ".guest"), "targets": list(r0["targets"], p + ".targets", (e1, q1) => str(e1, q1)), "event": str(r0["event"], p + ".event"), "payload": any(r0["payload"], p + ".payload"), "grants": buildOsGrants(r0["grants"], p + ".grants"), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") }, ...r0["site"] === void 0 || r0["site"] === null ? {} : { "site": buildCallSiteWire(r0["site"], p + ".site") } })) : rec(v, p)["kind"] === "random" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "random"), "bytes": int(r0["bytes"], p + ".bytes", 0, 4294967295, "u32") })) : rec(v, p)["kind"] === "clock" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "clock") })) : rec(v, p)["kind"] === "sealed" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "sealed"), "op": str(r0["op"], p + ".op"), "args": list(r0["args"], p + ".args", (e1, q1) => any(e1, q1)) })) : rec(v, p)["kind"] === "os" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "os"), "op": buildOsOp(r0["op"], p + ".op"), "args": list(r0["args"], p + ".args", (e1, q1) => any(e1, q1)), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") }, ...r0["site"] === void 0 || r0["site"] === null ? {} : { "site": buildCallSiteWire(r0["site"], p + ".site") }, ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") }, ...r0["orbital"] === void 0 || r0["orbital"] === null ? {} : { "orbital": str(r0["orbital"], p + ".orbital") } })) : rec(v, p)["kind"] === "credentialStatus" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStatus"), "name": str(r0["name"], p + ".name"), ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") } })) : rec(v, p)["kind"] === "credentialForget" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialForget"), "name": str(r0["name"], p + ".name"), ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") } })) : rec(v, p)["kind"] === "credentialConnect" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialConnect"), "grant": buildCredentialGrantWire(r0["grant"], p + ".grant") })) : rec(v, p)["kind"] === "credentialStoreList" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreList") })) : rec(v, p)["kind"] === "credentialEnvTails" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialEnvTails"), "names": list(r0["names"], p + ".names", (e1, q1) => str(e1, q1)) })) : rec(v, p)["kind"] === "credentialStoreRead" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRead"), "name": str(r0["name"], p + ".name") })) : rec(v, p)["kind"] === "credentialStoreWrite" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreWrite"), "service": str(r0["service"], p + ".service"), "name": str(r0["name"], p + ".name"), "value": str(r0["value"], p + ".value") })) : rec(v, p)["kind"] === "credentialStoreRemove" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRemove"), "name": str(r0["name"], p + ".name") })) : rec(v, p)["kind"] === "credentialStoreRotate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRotate") })) : rec(v, p)["kind"] === "credentialModeRead" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialModeRead") })) : rec(v, p)["kind"] === "credentialModeWrite" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialModeWrite"), "mode": str(r0["mode"], p + ".mode") })) : fail(unknownTag(p, "kind", rec(v, p)["kind"]));
|
|
841
|
+
return rec(v, p)["kind"] === "readRow" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "readRow"), "entityType": str(r0["entityType"], p + ".entityType"), "id": str(r0["id"], p + ".id") })) : rec(v, p)["kind"] === "listRows" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "listRows"), "entityType": str(r0["entityType"], p + ".entityType") })) : rec(v, p)["kind"] === "queryRows" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "queryRows"), "entityType": str(r0["entityType"], p + ".entityType"), "query": buildRowQuery(r0["query"], p + ".query"), "project": buildRowProjection(r0["project"], p + ".project") })) : rec(v, p)["kind"] === "writeRows" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "writeRows"), "batch": buildRowWriteBatch(r0["batch"], p + ".batch") })) : rec(v, p)["kind"] === "commitRows" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "commitRows"), "rows": list(r0["rows"], p + ".rows", (e1, q1) => buildRowCommit(e1, q1)) })) : rec(v, p)["kind"] === "createRow" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "createRow"), "entityType": str(r0["entityType"], p + ".entityType"), "data": any(r0["data"], p + ".data") })) : rec(v, p)["kind"] === "writeRow" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "writeRow"), "entityType": str(r0["entityType"], p + ".entityType"), "id": str(r0["id"], p + ".id"), "data": any(r0["data"], p + ".data") })) : rec(v, p)["kind"] === "deleteRow" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "deleteRow"), "entityType": str(r0["entityType"], p + ".entityType"), "id": str(r0["id"], p + ".id") })) : rec(v, p)["kind"] === "callService" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "callService"), "service": str(r0["service"], p + ".service"), "method": str(r0["method"], p + ".method"), "args": any(r0["args"], p + ".args"), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") }, ...r0["caller"] === void 0 || r0["caller"] === null ? {} : { "caller": buildCallerWire(r0["caller"], p + ".caller") }, ...r0["site"] === void 0 || r0["site"] === null ? {} : { "site": buildCallSiteWire(r0["site"], p + ".site") } })) : rec(v, p)["kind"] === "cancelCall" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "cancelCall"), "key": str(r0["key"], p + ".key") })) : rec(v, p)["kind"] === "substrate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "substrate"), "op": str(r0["op"], p + ".op"), "args": list(r0["args"], p + ".args", (e1, q1) => any(e1, q1)), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") }, ...r0["site"] === void 0 || r0["site"] === null ? {} : { "site": buildCallSiteWire(r0["site"], p + ".site") } })) : rec(v, p)["kind"] === "pageFacts" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "pageFacts"), "fields": list(r0["fields"], p + ".fields", (e1, q1) => buildPageFactFieldWire(e1, q1)) })) : rec(v, p)["kind"] === "prompt" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "prompt"), "text": str(r0["text"], p + ".text"), "schema": str(r0["schema"], p + ".schema"), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") } })) : rec(v, p)["kind"] === "embed" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "embed"), "texts": list(r0["texts"], p + ".texts", (e1, q1) => str(e1, q1)), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") } })) : rec(v, p)["kind"] === "tab" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "tab"), "ask": buildTabAsk(r0["ask"], p + ".ask"), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") } })) : rec(v, p)["kind"] === "secret" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secret"), "name": str(r0["name"], p + ".name"), ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") } })) : rec(v, p)["kind"] === "secretSet" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secretSet"), "name": str(r0["name"], p + ".name"), "value": str(r0["value"], p + ".value"), "ttlMs": int(r0["ttlMs"], p + ".ttlMs", 0, Number.MAX_SAFE_INTEGER, "u64"), ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") } })) : rec(v, p)["kind"] === "secretRotate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "secretRotate"), "name": str(r0["name"], p + ".name"), "value": str(r0["value"], p + ".value"), ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") } })) : rec(v, p)["kind"] === "deliver" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "deliver"), "envelope": buildEnvelope(r0["envelope"], p + ".envelope"), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") }, "site": buildCallSiteWire(r0["site"], p + ".site") })) : rec(v, p)["kind"] === "guest" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "guest"), "guest": str(r0["guest"], p + ".guest"), "targets": list(r0["targets"], p + ".targets", (e1, q1) => str(e1, q1)), "event": str(r0["event"], p + ".event"), "payload": any(r0["payload"], p + ".payload"), "grants": buildOsGrants(r0["grants"], p + ".grants"), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") }, ...r0["site"] === void 0 || r0["site"] === null ? {} : { "site": buildCallSiteWire(r0["site"], p + ".site") } })) : rec(v, p)["kind"] === "random" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "random"), "bytes": int(r0["bytes"], p + ".bytes", 0, 4294967295, "u32") })) : rec(v, p)["kind"] === "clock" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "clock") })) : rec(v, p)["kind"] === "sealed" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "sealed"), "op": str(r0["op"], p + ".op"), "args": list(r0["args"], p + ".args", (e1, q1) => any(e1, q1)) })) : rec(v, p)["kind"] === "gpu" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "gpu"), "ticket": int(r0["ticket"], p + ".ticket", 0, Number.MAX_SAFE_INTEGER, "u64"), "op": buildOsOp(r0["op"], p + ".op"), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") } })) : rec(v, p)["kind"] === "os" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "os"), "op": buildOsOp(r0["op"], p + ".op"), "args": list(r0["args"], p + ".args", (e1, q1) => any(e1, q1)), ...r0["key"] === void 0 || r0["key"] === null ? {} : { "key": str(r0["key"], p + ".key") }, ...r0["site"] === void 0 || r0["site"] === null ? {} : { "site": buildCallSiteWire(r0["site"], p + ".site") }, ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") }, ...r0["orbital"] === void 0 || r0["orbital"] === null ? {} : { "orbital": str(r0["orbital"], p + ".orbital") } })) : rec(v, p)["kind"] === "credentialStatus" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStatus"), "name": str(r0["name"], p + ".name"), ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") } })) : rec(v, p)["kind"] === "credentialForget" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialForget"), "name": str(r0["name"], p + ".name"), ...r0["principal"] === void 0 || r0["principal"] === null ? {} : { "principal": str(r0["principal"], p + ".principal") } })) : rec(v, p)["kind"] === "credentialConnect" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialConnect"), "grant": buildCredentialGrantWire(r0["grant"], p + ".grant") })) : rec(v, p)["kind"] === "credentialStoreList" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreList") })) : rec(v, p)["kind"] === "credentialEnvTails" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialEnvTails"), "names": list(r0["names"], p + ".names", (e1, q1) => str(e1, q1)) })) : rec(v, p)["kind"] === "credentialStoreRead" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRead"), "name": str(r0["name"], p + ".name") })) : rec(v, p)["kind"] === "credentialStoreWrite" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreWrite"), "service": str(r0["service"], p + ".service"), "name": str(r0["name"], p + ".name"), "value": str(r0["value"], p + ".value") })) : rec(v, p)["kind"] === "credentialStoreRemove" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRemove"), "name": str(r0["name"], p + ".name") })) : rec(v, p)["kind"] === "credentialStoreRotate" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialStoreRotate") })) : rec(v, p)["kind"] === "credentialModeRead" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialModeRead") })) : rec(v, p)["kind"] === "credentialModeWrite" ? obj(v, p, null, (r0) => ({ "kind": lit(r0["kind"], p + ".kind", "credentialModeWrite"), "mode": str(r0["mode"], p + ".mode") })) : fail(unknownTag(p, "kind", rec(v, p)["kind"]));
|
|
824
842
|
}
|
|
825
843
|
function buildJsonTokenSpec(v, p) {
|
|
826
844
|
return obj(v, p, null, (r0) => ({ "clientIdField": str(r0["clientIdField"], p + ".clientIdField"), "clientSecretField": str(r0["clientSecretField"], p + ".clientSecretField"), "accessField": str(r0["accessField"], p + ".accessField"), ...r0["refreshField"] === void 0 || r0["refreshField"] === null ? {} : { "refreshField": r0["refreshField"] === null ? null : str(r0["refreshField"], p + ".refreshField") }, ...r0["expiresInField"] === void 0 || r0["expiresInField"] === null ? {} : { "expiresInField": r0["expiresInField"] === null ? null : str(r0["expiresInField"], p + ".expiresInField") }, ...r0["refreshEndpoint"] === void 0 || r0["refreshEndpoint"] === null ? {} : { "refreshEndpoint": r0["refreshEndpoint"] === null ? null : str(r0["refreshEndpoint"], p + ".refreshEndpoint") }, ...r0["refreshBodyField"] === void 0 || r0["refreshBodyField"] === null ? {} : { "refreshBodyField": r0["refreshBodyField"] === null ? null : str(r0["refreshBodyField"], p + ".refreshBodyField") } }));
|
|
@@ -892,19 +910,19 @@ function buildOsGrantFinding(v, p) {
|
|
|
892
910
|
return obj(v, p, null, (r0) => ({ "code": buildOsGrantFindingCode(r0["code"], p + ".code"), ...r0["orbital"] === void 0 || r0["orbital"] === null ? {} : { "orbital": str(r0["orbital"], p + ".orbital") }, ...r0["call"] === void 0 || r0["call"] === null ? {} : { "call": str(r0["call"], p + ".call") }, ...r0["entry"] === void 0 || r0["entry"] === null ? {} : { "entry": str(r0["entry"], p + ".entry") }, "site": str(r0["site"], p + ".site"), ...r0["grant"] === void 0 || r0["grant"] === null ? {} : { "grant": str(r0["grant"], p + ".grant") }, ...r0["app"] === void 0 || r0["app"] === null ? {} : { "app": bool(r0["app"], p + ".app") }, ...r0["argument"] === void 0 || r0["argument"] === null ? {} : { "argument": int(r0["argument"], p + ".argument", 0, Number.MAX_SAFE_INTEGER, "usize") }, ...r0["via"] === void 0 || r0["via"] === null ? {} : { "via": buildOsGrantVia(r0["via"], p + ".via") } }));
|
|
893
911
|
}
|
|
894
912
|
function buildOsGrantFindingCode(v, p) {
|
|
895
|
-
return oneOf(v, p, ["missing", "unused", "entry-invalid", "target-not-static"]);
|
|
913
|
+
return oneOf(v, p, ["missing", "unused", "entry-invalid", "target-not-static", "shader-invalid", "binding-mismatch"]);
|
|
896
914
|
}
|
|
897
915
|
function buildOsGrantVia(v, p) {
|
|
898
916
|
return oneOf(v, p, ["config", "config-unresolvable", "computed-path"]);
|
|
899
917
|
}
|
|
900
918
|
function buildOsGrants(v, p) {
|
|
901
|
-
return obj(v, p, ["fs", "exec", "net", "env", "stdio", "sys", "desktop", "dev", "mem", "kernel", "ffi", "credentials", "kv", "anchored"], (r0) => ({ ...r0["fs"] === void 0 || r0["fs"] === null ? {} : { "fs": list(r0["fs"], p + ".fs", (e1, q1) => buildFsGrant(e1, q1)) }, ...r0["exec"] === void 0 || r0["exec"] === null ? {} : { "exec": list(r0["exec"], p + ".exec", (e1, q1) => str(e1, q1)) }, ...r0["net"] === void 0 || r0["net"] === null ? {} : { "net": list(r0["net"], p + ".net", (e1, q1) => buildNetGrant(e1, q1)) }, ...r0["env"] === void 0 || r0["env"] === null ? {} : { "env": list(r0["env"], p + ".env", (e1, q1) => str(e1, q1)) }, ...r0["stdio"] === void 0 || r0["stdio"] === null ? {} : { "stdio": list(r0["stdio"], p + ".stdio", (e1, q1) => buildStdioKind(e1, q1)) }, ...r0["sys"] === void 0 || r0["sys"] === null ? {} : { "sys": list(r0["sys"], p + ".sys", (e1, q1) => buildSysKind(e1, q1)) }, ...r0["desktop"] === void 0 || r0["desktop"] === null ? {} : { "desktop": list(r0["desktop"], p + ".desktop", (e1, q1) => buildDesktopKind(e1, q1)) }, ...r0["dev"] === void 0 || r0["dev"] === null ? {} : { "dev": list(r0["dev"], p + ".dev", (e1, q1) => buildDevGrant(e1, q1)) }, ...r0["mem"] === void 0 || r0["mem"] === null ? {} : { "mem": list(r0["mem"], p + ".mem", (e1, q1) => buildMemGrant(e1, q1)) }, ...r0["kernel"] === void 0 || r0["kernel"] === null ? {} : { "kernel": list(r0["kernel"], p + ".kernel", (e1, q1) => buildKernelGrant(e1, q1)) }, ...r0["ffi"] === void 0 || r0["ffi"] === null ? {} : { "ffi": list(r0["ffi"], p + ".ffi", (e1, q1) => buildFfiGrant(e1, q1)) }, ...r0["credentials"] === void 0 || r0["credentials"] === null ? {} : { "credentials": list(r0["credentials"], p + ".credentials", (e1, q1) => buildCredentialKind(e1, q1)) }, ...r0["kv"] === void 0 || r0["kv"] === null ? {} : { "kv": dict(r0["kv"], p + ".kv", (e1, q1) => list(e1, q1, (e2, q2) => buildKvMode(e2, q2))) }, ...r0["anchored"] === void 0 || r0["anchored"] === null ? {} : { "anchored": buildAnchoredGrants(r0["anchored"], p + ".anchored") } }));
|
|
919
|
+
return obj(v, p, ["fs", "exec", "net", "env", "stdio", "sys", "desktop", "dev", "mem", "kernel", "ffi", "gpu", "credentials", "kv", "anchored"], (r0) => ({ ...r0["fs"] === void 0 || r0["fs"] === null ? {} : { "fs": list(r0["fs"], p + ".fs", (e1, q1) => buildFsGrant(e1, q1)) }, ...r0["exec"] === void 0 || r0["exec"] === null ? {} : { "exec": list(r0["exec"], p + ".exec", (e1, q1) => str(e1, q1)) }, ...r0["net"] === void 0 || r0["net"] === null ? {} : { "net": list(r0["net"], p + ".net", (e1, q1) => buildNetGrant(e1, q1)) }, ...r0["env"] === void 0 || r0["env"] === null ? {} : { "env": list(r0["env"], p + ".env", (e1, q1) => str(e1, q1)) }, ...r0["stdio"] === void 0 || r0["stdio"] === null ? {} : { "stdio": list(r0["stdio"], p + ".stdio", (e1, q1) => buildStdioKind(e1, q1)) }, ...r0["sys"] === void 0 || r0["sys"] === null ? {} : { "sys": list(r0["sys"], p + ".sys", (e1, q1) => buildSysKind(e1, q1)) }, ...r0["desktop"] === void 0 || r0["desktop"] === null ? {} : { "desktop": list(r0["desktop"], p + ".desktop", (e1, q1) => buildDesktopKind(e1, q1)) }, ...r0["dev"] === void 0 || r0["dev"] === null ? {} : { "dev": list(r0["dev"], p + ".dev", (e1, q1) => buildDevGrant(e1, q1)) }, ...r0["mem"] === void 0 || r0["mem"] === null ? {} : { "mem": list(r0["mem"], p + ".mem", (e1, q1) => buildMemGrant(e1, q1)) }, ...r0["kernel"] === void 0 || r0["kernel"] === null ? {} : { "kernel": list(r0["kernel"], p + ".kernel", (e1, q1) => buildKernelGrant(e1, q1)) }, ...r0["ffi"] === void 0 || r0["ffi"] === null ? {} : { "ffi": list(r0["ffi"], p + ".ffi", (e1, q1) => buildFfiGrant(e1, q1)) }, ...r0["gpu"] === void 0 || r0["gpu"] === null ? {} : { "gpu": list(r0["gpu"], p + ".gpu", (e1, q1) => buildGpuGrant(e1, q1)) }, ...r0["credentials"] === void 0 || r0["credentials"] === null ? {} : { "credentials": list(r0["credentials"], p + ".credentials", (e1, q1) => buildCredentialKind(e1, q1)) }, ...r0["kv"] === void 0 || r0["kv"] === null ? {} : { "kv": dict(r0["kv"], p + ".kv", (e1, q1) => list(e1, q1, (e2, q2) => buildKvMode(e2, q2))) }, ...r0["anchored"] === void 0 || r0["anchored"] === null ? {} : { "anchored": buildAnchoredGrants(r0["anchored"], p + ".anchored") } }));
|
|
902
920
|
}
|
|
903
921
|
function buildOsGrantsReport(v, p) {
|
|
904
922
|
return obj(v, p, null, (r0) => ({ "findings": list(r0["findings"], p + ".findings", (e1, q1) => buildOsGrantFinding(e1, q1)) }));
|
|
905
923
|
}
|
|
906
924
|
function buildOsOp(v, p) {
|
|
907
|
-
return oneOf(v, p, ["os/read-file", "os/write-file", "os/append-file", "os/open", "os/close", "os/read", "os/write", "os/seek", "os/truncate", "os/fsync", "os/copy", "os/rename", "os/remove", "os/link", "os/symlink", "os/readlink", "os/watch-files", "os/mkdir", "os/rmdir", "os/list-dir", "os/glob", "os/mktemp", "os/realpath", "os/cwd", "os/chdir", "os/stat", "os/lstat", "os/access", "os/exists", "os/chmod", "os/chown", "os/utimes", "os/spawn", "os/wait", "os/kill", "os/pid", "os/ppid", "os/current-exe", "os/watch-process", "os/watch-signal", "os/getenv", "os/setenv", "os/unsetenv", "os/environ", "os/watch-env", "os/stdin-read", "os/stdout-write", "os/stderr-write", "os/isatty", "os/tty-size", "os/tcp-connect", "os/tcp-listen", "os/tls-upgrade", "os/send", "os/recv", "os/udp-bind", "os/sendto", "os/recvfrom", "os/dns-resolve", "os/shutdown", "os/watch-port", "os/fetch", "os/clock-monotonic", "os/uid", "os/gid", "os/username", "os/group-of", "os/watch-cron", "os/cpu-usage", "os/memory-info", "os/uptime", "os/load-avg", "os/hostname", "os/uname", "os/disk-usage", "os/mounts", "os/disk-io", "os/network-interfaces", "os/network-stats", "os/network-connected", "os/default-gateway", "os/battery-status", "os/ac-power", "os/thermal-zones", "os/notify", "os/speak", "os/brightness-get", "os/brightness-set", "os/volume-get", "os/volume-set", "os/volume-mute", "os/suspend", "os/hibernate", "os/mmio-read", "os/mmio-write", "os/irq-wait", "os/irq-ack", "kv/get", "kv/put", "kv/delete", "kv/scan", "kv/batch", "mem/arena-new", "mem/arena-drop", "mem/alloc", "mem/free", "mem/borrow", "mem/release", "mem/write", "mem/freeze", "mem/atomic-load", "mem/atomic-store", "mem/atomic-add", "mem/atomic-cas", "kernel/queue-front", "kernel/queue-back", "ffi/call"]);
|
|
925
|
+
return oneOf(v, p, ["os/read-file", "os/write-file", "os/append-file", "os/open", "os/close", "os/read", "os/write", "os/seek", "os/truncate", "os/fsync", "os/copy", "os/rename", "os/remove", "os/link", "os/symlink", "os/readlink", "os/watch-files", "os/mkdir", "os/rmdir", "os/list-dir", "os/glob", "os/mktemp", "os/realpath", "os/cwd", "os/chdir", "os/stat", "os/lstat", "os/access", "os/exists", "os/chmod", "os/chown", "os/utimes", "os/spawn", "os/wait", "os/kill", "os/pid", "os/ppid", "os/current-exe", "os/watch-process", "os/watch-signal", "os/getenv", "os/setenv", "os/unsetenv", "os/environ", "os/watch-env", "os/stdin-read", "os/stdout-write", "os/stderr-write", "os/isatty", "os/tty-size", "os/tcp-connect", "os/tcp-listen", "os/tls-upgrade", "os/send", "os/recv", "os/udp-bind", "os/sendto", "os/recvfrom", "os/dns-resolve", "os/shutdown", "os/watch-port", "os/fetch", "os/clock-monotonic", "os/uid", "os/gid", "os/username", "os/group-of", "os/watch-cron", "os/cpu-usage", "os/memory-info", "os/uptime", "os/load-avg", "os/hostname", "os/uname", "os/disk-usage", "os/mounts", "os/disk-io", "os/network-interfaces", "os/network-stats", "os/network-connected", "os/default-gateway", "os/battery-status", "os/ac-power", "os/thermal-zones", "os/notify", "os/speak", "os/brightness-get", "os/brightness-set", "os/volume-get", "os/volume-set", "os/volume-mute", "os/suspend", "os/hibernate", "os/mmio-read", "os/mmio-write", "os/irq-wait", "os/irq-ack", "kv/get", "kv/put", "kv/delete", "kv/scan", "kv/batch", "mem/arena-new", "mem/arena-drop", "mem/alloc", "mem/free", "mem/borrow", "mem/release", "mem/write", "mem/freeze", "mem/atomic-load", "mem/atomic-store", "mem/atomic-add", "mem/atomic-cas", "kernel/queue-front", "kernel/queue-back", "ffi/call", "gpu/device-open", "gpu/device-close", "gpu/buffer-create", "gpu/texture-create", "gpu/sampler-create", "gpu/query-create", "gpu/shader-create", "gpu/pipeline-create", "gpu/bind-group-create", "gpu/submit", "gpu/release"]);
|
|
908
926
|
}
|
|
909
927
|
function buildPageFactFieldWire(v, p) {
|
|
910
928
|
return oneOf(v, p, ["hostname", "referrer", "screenWidth", "href"]);
|
|
@@ -1209,6 +1227,18 @@ function isFrameWire(value) {
|
|
|
1209
1227
|
function decodeFrameWire(value) {
|
|
1210
1228
|
return buildFrameWire(value, "FrameWire");
|
|
1211
1229
|
}
|
|
1230
|
+
function isHeldGpuCompletion(value) {
|
|
1231
|
+
return checkHeldGpuCompletion(value);
|
|
1232
|
+
}
|
|
1233
|
+
function decodeHeldGpuCompletion(value) {
|
|
1234
|
+
return buildHeldGpuCompletion(value, "HeldGpuCompletion");
|
|
1235
|
+
}
|
|
1236
|
+
function isIoAnswerWire(value) {
|
|
1237
|
+
return checkIoAnswerWire(value);
|
|
1238
|
+
}
|
|
1239
|
+
function decodeIoAnswerWire(value) {
|
|
1240
|
+
return buildIoAnswerWire(value, "IoAnswerWire");
|
|
1241
|
+
}
|
|
1212
1242
|
function isIoReplyWire(value) {
|
|
1213
1243
|
return checkIoReplyWire(value);
|
|
1214
1244
|
}
|
|
@@ -1288,6 +1318,6 @@ function decodeValidationJsonOutput(value) {
|
|
|
1288
1318
|
return buildValidationJsonOutput(value, "ValidationJsonOutput");
|
|
1289
1319
|
}
|
|
1290
1320
|
|
|
1291
|
-
export { decodeAppliedWire, decodeDispatchWire, decodeEntered, decodeEventRequest, decodeEventResponse, decodeFiredTick, decodeFoldProgressWire, decodeFoldedNextWire, decodeFrameWire, decodeIoReplyWire, decodeIoRequestWire, decodeMountWire, decodeNextWire, decodeOsGrantsReport, decodePlayedStep, decodeProveReport, decodeResolveProgressWire, decodeServerProgressWire, decodeSnapshotWire, decodeStepRefusal, decodeStepReport, decodeValidationJsonOutput, isAppliedWire, isDispatchWire, isEntered, isEventRequest, isEventResponse, isFiredTick, isFoldProgressWire, isFoldedNextWire, isFrameWire, isIoReplyWire, isIoRequestWire, isMountWire, isNextWire, isOsGrantsReport, isPlayedStep, isProveReport, isResolveProgressWire, isServerProgressWire, isSnapshotWire, isStepRefusal, isStepReport, isValidationJsonOutput };
|
|
1292
|
-
//# sourceMappingURL=chunk-
|
|
1293
|
-
//# sourceMappingURL=chunk-
|
|
1321
|
+
export { decodeAppliedWire, decodeDispatchWire, decodeEntered, decodeEventRequest, decodeEventResponse, decodeFiredTick, decodeFoldProgressWire, decodeFoldedNextWire, decodeFrameWire, decodeHeldGpuCompletion, decodeIoAnswerWire, decodeIoReplyWire, decodeIoRequestWire, decodeMountWire, decodeNextWire, decodeOsGrantsReport, decodePlayedStep, decodeProveReport, decodeResolveProgressWire, decodeServerProgressWire, decodeSnapshotWire, decodeStepRefusal, decodeStepReport, decodeValidationJsonOutput, isAppliedWire, isDispatchWire, isEntered, isEventRequest, isEventResponse, isFiredTick, isFoldProgressWire, isFoldedNextWire, isFrameWire, isHeldGpuCompletion, isIoAnswerWire, isIoReplyWire, isIoRequestWire, isMountWire, isNextWire, isOsGrantsReport, isPlayedStep, isProveReport, isResolveProgressWire, isServerProgressWire, isSnapshotWire, isStepRefusal, isStepReport, isValidationJsonOutput };
|
|
1322
|
+
//# sourceMappingURL=chunk-VIHQKKTZ.js.map
|
|
1323
|
+
//# sourceMappingURL=chunk-VIHQKKTZ.js.map
|