@clowder-ai/plugin-contract 0.1.0-beta.2 → 0.1.0-beta.4
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/conformance/index.d.ts +1 -0
- package/dist/conformance/index.d.ts.map +1 -1
- package/dist/conformance/index.js +1 -0
- package/dist/conformance/index.js.map +1 -1
- package/dist/conformance/stdio-harness/child-process-harness.d.ts +65 -0
- package/dist/conformance/stdio-harness/child-process-harness.d.ts.map +1 -0
- package/dist/conformance/stdio-harness/child-process-harness.js +296 -0
- package/dist/conformance/stdio-harness/child-process-harness.js.map +1 -0
- package/dist/conformance/stdio-harness/dual-transport-oracle.d.ts +26 -0
- package/dist/conformance/stdio-harness/dual-transport-oracle.d.ts.map +1 -0
- package/dist/conformance/stdio-harness/dual-transport-oracle.js +32 -0
- package/dist/conformance/stdio-harness/dual-transport-oracle.js.map +1 -0
- package/dist/conformance/stdio-harness/harness-process-spawn.d.ts +27 -0
- package/dist/conformance/stdio-harness/harness-process-spawn.d.ts.map +1 -0
- package/dist/conformance/stdio-harness/harness-process-spawn.js +43 -0
- package/dist/conformance/stdio-harness/harness-process-spawn.js.map +1 -0
- package/dist/conformance/stdio-harness/index.d.ts +5 -0
- package/dist/conformance/stdio-harness/index.d.ts.map +1 -0
- package/dist/conformance/stdio-harness/index.js +4 -0
- package/dist/conformance/stdio-harness/index.js.map +1 -0
- package/dist/conformance/stdio-harness/ndjson-frame.d.ts +31 -0
- package/dist/conformance/stdio-harness/ndjson-frame.d.ts.map +1 -0
- package/dist/conformance/stdio-harness/ndjson-frame.js +125 -0
- package/dist/conformance/stdio-harness/ndjson-frame.js.map +1 -0
- package/dist/conformance/stdio-harness/node-process-tree-runtime.d.ts +15 -0
- package/dist/conformance/stdio-harness/node-process-tree-runtime.d.ts.map +1 -0
- package/dist/conformance/stdio-harness/node-process-tree-runtime.js +78 -0
- package/dist/conformance/stdio-harness/node-process-tree-runtime.js.map +1 -0
- package/dist/conformance/stdio-harness/process-tree-controller.d.ts +51 -0
- package/dist/conformance/stdio-harness/process-tree-controller.d.ts.map +1 -0
- package/dist/conformance/stdio-harness/process-tree-controller.js +162 -0
- package/dist/conformance/stdio-harness/process-tree-controller.js.map +1 -0
- package/dist/conformance/stdio-harness/windows-sentinel.d.ts +15 -0
- package/dist/conformance/stdio-harness/windows-sentinel.d.ts.map +1 -0
- package/dist/conformance/stdio-harness/windows-sentinel.js +160 -0
- package/dist/conformance/stdio-harness/windows-sentinel.js.map +1 -0
- package/dist/conformance/stdio-harness/wire-shape.d.ts +18 -0
- package/dist/conformance/stdio-harness/wire-shape.d.ts.map +1 -0
- package/dist/conformance/stdio-harness/wire-shape.js +2 -0
- package/dist/conformance/stdio-harness/wire-shape.js.map +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -1
- package/dist/wire/constants.d.ts +36 -0
- package/dist/wire/constants.d.ts.map +1 -0
- package/dist/wire/constants.js +36 -0
- package/dist/wire/constants.js.map +1 -0
- package/dist/wire/disposition-fixtures.d.ts +99 -0
- package/dist/wire/disposition-fixtures.d.ts.map +1 -0
- package/dist/wire/disposition-fixtures.js +623 -0
- package/dist/wire/disposition-fixtures.js.map +1 -0
- package/dist/wire/disposition.d.ts +100 -0
- package/dist/wire/disposition.d.ts.map +1 -0
- package/dist/wire/disposition.js +205 -0
- package/dist/wire/disposition.js.map +1 -0
- package/dist/wire/envelope.d.ts +253 -0
- package/dist/wire/envelope.d.ts.map +1 -0
- package/dist/wire/envelope.js +19 -0
- package/dist/wire/envelope.js.map +1 -0
- package/dist/wire/errors.d.ts +222 -0
- package/dist/wire/errors.d.ts.map +1 -0
- package/dist/wire/errors.js +153 -0
- package/dist/wire/errors.js.map +1 -0
- package/dist/wire/grants.d.ts +57 -0
- package/dist/wire/grants.d.ts.map +1 -0
- package/dist/wire/grants.js +59 -0
- package/dist/wire/grants.js.map +1 -0
- package/dist/wire/handshake.d.ts +100 -0
- package/dist/wire/handshake.d.ts.map +1 -0
- package/dist/wire/handshake.js +70 -0
- package/dist/wire/handshake.js.map +1 -0
- package/dist/wire/index.d.ts +26 -0
- package/dist/wire/index.d.ts.map +1 -0
- package/dist/wire/index.js +45 -0
- package/dist/wire/index.js.map +1 -0
- package/dist/wire/registry.d.ts +90 -0
- package/dist/wire/registry.d.ts.map +1 -0
- package/dist/wire/registry.js +232 -0
- package/dist/wire/registry.js.map +1 -0
- package/dist/wire/request-id.d.ts +34 -0
- package/dist/wire/request-id.d.ts.map +1 -0
- package/dist/wire/request-id.js +40 -0
- package/dist/wire/request-id.js.map +1 -0
- package/dist/wire/row-shapes.d.ts +212 -0
- package/dist/wire/row-shapes.d.ts.map +1 -0
- package/dist/wire/row-shapes.js +59 -0
- package/dist/wire/row-shapes.js.map +1 -0
- package/dist/wire/wire-uint53.d.ts +26 -0
- package/dist/wire/wire-uint53.d.ts.map +1 -0
- package/dist/wire/wire-uint53.js +32 -0
- package/dist/wire/wire-uint53.js.map +1 -0
- package/package.json +3 -3
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"windows-sentinel.js","sourceRoot":"","sources":["../../../src/conformance/stdio-harness/windows-sentinel.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,GAEN,MAAM,oBAAoB,CAAC;AA0B5B,MAAM,uBAAuB,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAqEzC,CAAC;AAEF,MAAM,UAAU,oBAAoB,CAAC,OAA+B;IAClE,MAAM,IAAI,GAAG,KAAK,CAChB,OAAO,CAAC,QAAQ,EAChB,CAAC,IAAI,EAAE,uBAAuB,CAAC,EAC/B;QACE,GAAG,EAAE,OAAO,CAAC,GAAG;QAChB,GAAG,EAAE,OAAO,CAAC,GAAG;QAChB,KAAK,EAAE,CAAC,MAAM,EAAE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CAAC;QACH,CAAC;QACD,YAAY,EAAE,CAAC,QAAQ,EAAE,EAAE;YACzB,IAAI,UAAU,KAAK,SAAS,EAAE,CAAC;gBAC7B,aAAa,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;YAC/B,CAAC;iBAAM,CAAC;gBACN,MAAM,IAAI,GAAG,UAAU,CAAC;gBACxB,cAAc,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;YACzD,CAAC;QACH,CAAC;QACD,YAAY,EAAE,CAAC,MAAM,EAAE,EAAE;YACvB,IAAI,IAAI,CAAC,SAAS,EAAE,CAAC;gBACnB,IAAI,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE;oBAC9C,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;wBACnB,kBAAkB,CAAC,KAAK,CAAC,CAAC;oBAC5B,CAAC;gBACH,CAAC,CAAC,CAAC;YACL,CAAC;QACH,CAAC;KACF,CAAC;AACJ,CAAC;AAED,SAAS,iBAAiB,CAAC,OAAgB;IACzC,OAAO,CACL,OAAO,OAAO,KAAK,QAAQ;QAC3B,OAAO,KAAK,IAAI;QAChB,MAAM,IAAI,OAAO;QACjB,CAAC,OAAO,CAAC,IAAI,KAAK,cAAc,IAAI,OAAO,CAAC,IAAI,KAAK,aAAa,CAAC,CACpE,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { HarnessChild } from './child-process-harness.js';
|
|
2
|
+
import type { DecodedNdjsonFrame, JsonObject } from './ndjson-frame.js';
|
|
3
|
+
/**
|
|
4
|
+
* Deliberate seam for the P-1a contract output.
|
|
5
|
+
*
|
|
6
|
+
* This skeleton owns process and frame transport only. The #1165 frozen
|
|
7
|
+
* shape (rev11) is now shape-approved; the wire module mechanizes its
|
|
8
|
+
* 12-row registry, disposition table, and closed error envelopes. This
|
|
9
|
+
* seam will be replaced by a concrete codec backed by those wire types
|
|
10
|
+
* when the handshake rows (1, 2) reach CLOSED leaf closure.
|
|
11
|
+
*/
|
|
12
|
+
export interface HarnessWireShape<Outbound, Inbound> {
|
|
13
|
+
readonly status: 'shape-approved';
|
|
14
|
+
encode(message: Outbound): JsonObject;
|
|
15
|
+
decode(frame: DecodedNdjsonFrame): Inbound;
|
|
16
|
+
performHelloReady(child: HarnessChild): Promise<void>;
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=wire-shape.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wire-shape.d.ts","sourceRoot":"","sources":["../../../src/conformance/stdio-harness/wire-shape.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC/D,OAAO,KAAK,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAExE;;;;;;;;GAQG;AACH,MAAM,WAAW,gBAAgB,CAAC,QAAQ,EAAE,OAAO;IACjD,QAAQ,CAAC,MAAM,EAAE,gBAAgB,CAAC;IAClC,MAAM,CAAC,OAAO,EAAE,QAAQ,GAAG,UAAU,CAAC;IACtC,MAAM,CAAC,KAAK,EAAE,kBAAkB,GAAG,OAAO,CAAC;IAC3C,iBAAiB,CAAC,KAAK,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CACvD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wire-shape.js","sourceRoot":"","sources":["../../../src/conformance/stdio-harness/wire-shape.ts"],"names":[],"mappings":""}
|
package/dist/index.d.ts
CHANGED
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAGH,cAAc,kBAAkB,CAAC;AACjC,cAAc,uBAAuB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAGH,cAAc,kBAAkB,CAAC;AACjC,cAAc,uBAAuB,CAAC;AAItC,cAAc,iBAAiB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -33,4 +33,7 @@
|
|
|
33
33
|
// Re-export everything from the types barrel
|
|
34
34
|
export * from './types/index.js';
|
|
35
35
|
export * from './validation/index.js';
|
|
36
|
+
// Wire protocol types, constants, registry, and validators
|
|
37
|
+
// Mechanized from #1165 frozen shape (rev11, SHA 7e26e5af…)
|
|
38
|
+
export * from './wire/index.js';
|
|
36
39
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,6CAA6C;AAC7C,cAAc,kBAAkB,CAAC;AACjC,cAAc,uBAAuB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,6CAA6C;AAC7C,cAAc,kBAAkB,CAAC;AACjC,cAAc,uBAAuB,CAAC;AAEtC,2DAA2D;AAC3D,4DAA4D;AAC5D,cAAc,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Wire-protocol framing constants.
|
|
3
|
+
* Every value is mechanized verbatim from the #1165 frozen shape (rev11).
|
|
4
|
+
* This module defines nothing new.
|
|
5
|
+
*/
|
|
6
|
+
/** Maximum raw UTF-8 bytes per frame, excluding the LF terminator. */
|
|
7
|
+
export declare const MAX_FRAME_BYTES: 1048576;
|
|
8
|
+
/** The v0 wire protocol version. */
|
|
9
|
+
export declare const WIRE_VERSION: "0.1.0";
|
|
10
|
+
/** The contract version this wire shape mechanizes. */
|
|
11
|
+
export declare const CONTRACT_VERSION: "0.1.0";
|
|
12
|
+
/** JSON-RPC version constant (exact string). */
|
|
13
|
+
export declare const JSONRPC_VERSION: "2.0";
|
|
14
|
+
/**
|
|
15
|
+
* Maximum payload bytes per element payload (frozen x-clowder-bounds).
|
|
16
|
+
* Open-membered payloads (MediaRefElementPayload, RichBlockElementPayload)
|
|
17
|
+
* are bounded by this ceiling alone — no structural narrowing.
|
|
18
|
+
*/
|
|
19
|
+
export declare const MAX_ELEMENT_PAYLOAD_BYTES: 65536;
|
|
20
|
+
/**
|
|
21
|
+
* Maximum total payload bytes per message (frozen x-clowder-bounds).
|
|
22
|
+
*/
|
|
23
|
+
export declare const MAX_TOTAL_PAYLOAD_BYTES: 262144;
|
|
24
|
+
/**
|
|
25
|
+
* Maximum elements per draft operation (frozen).
|
|
26
|
+
*/
|
|
27
|
+
export declare const MAX_ELEMENTS_PER_OPERATION: 32;
|
|
28
|
+
/**
|
|
29
|
+
* Maximum elements per message envelope (frozen).
|
|
30
|
+
*/
|
|
31
|
+
export declare const MAX_ELEMENTS_PER_MESSAGE: 128;
|
|
32
|
+
/**
|
|
33
|
+
* Maximum whisper targets (frozen).
|
|
34
|
+
*/
|
|
35
|
+
export declare const MAX_WHISPER_TARGETS: 16;
|
|
36
|
+
//# sourceMappingURL=constants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/wire/constants.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,sEAAsE;AACtE,eAAO,MAAM,eAAe,EAAG,OAAkB,CAAC;AAElD,oCAAoC;AACpC,eAAO,MAAM,YAAY,EAAG,OAAgB,CAAC;AAE7C,uDAAuD;AACvD,eAAO,MAAM,gBAAgB,EAAG,OAAgB,CAAC;AAEjD,gDAAgD;AAChD,eAAO,MAAM,eAAe,EAAG,KAAc,CAAC;AAE9C;;;;GAIG;AACH,eAAO,MAAM,yBAAyB,EAAG,KAAe,CAAC;AAEzD;;GAEG;AACH,eAAO,MAAM,uBAAuB,EAAG,MAAgB,CAAC;AAExD;;GAEG;AACH,eAAO,MAAM,0BAA0B,EAAG,EAAW,CAAC;AAEtD;;GAEG;AACH,eAAO,MAAM,wBAAwB,EAAG,GAAY,CAAC;AAErD;;GAEG;AACH,eAAO,MAAM,mBAAmB,EAAG,EAAW,CAAC"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Wire-protocol framing constants.
|
|
3
|
+
* Every value is mechanized verbatim from the #1165 frozen shape (rev11).
|
|
4
|
+
* This module defines nothing new.
|
|
5
|
+
*/
|
|
6
|
+
/** Maximum raw UTF-8 bytes per frame, excluding the LF terminator. */
|
|
7
|
+
export const MAX_FRAME_BYTES = 1_048_576;
|
|
8
|
+
/** The v0 wire protocol version. */
|
|
9
|
+
export const WIRE_VERSION = '0.1.0';
|
|
10
|
+
/** The contract version this wire shape mechanizes. */
|
|
11
|
+
export const CONTRACT_VERSION = '0.1.0';
|
|
12
|
+
/** JSON-RPC version constant (exact string). */
|
|
13
|
+
export const JSONRPC_VERSION = '2.0';
|
|
14
|
+
/**
|
|
15
|
+
* Maximum payload bytes per element payload (frozen x-clowder-bounds).
|
|
16
|
+
* Open-membered payloads (MediaRefElementPayload, RichBlockElementPayload)
|
|
17
|
+
* are bounded by this ceiling alone — no structural narrowing.
|
|
18
|
+
*/
|
|
19
|
+
export const MAX_ELEMENT_PAYLOAD_BYTES = 65_536;
|
|
20
|
+
/**
|
|
21
|
+
* Maximum total payload bytes per message (frozen x-clowder-bounds).
|
|
22
|
+
*/
|
|
23
|
+
export const MAX_TOTAL_PAYLOAD_BYTES = 262_144;
|
|
24
|
+
/**
|
|
25
|
+
* Maximum elements per draft operation (frozen).
|
|
26
|
+
*/
|
|
27
|
+
export const MAX_ELEMENTS_PER_OPERATION = 32;
|
|
28
|
+
/**
|
|
29
|
+
* Maximum elements per message envelope (frozen).
|
|
30
|
+
*/
|
|
31
|
+
export const MAX_ELEMENTS_PER_MESSAGE = 128;
|
|
32
|
+
/**
|
|
33
|
+
* Maximum whisper targets (frozen).
|
|
34
|
+
*/
|
|
35
|
+
export const MAX_WHISPER_TARGETS = 16;
|
|
36
|
+
//# sourceMappingURL=constants.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/wire/constants.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,sEAAsE;AACtE,MAAM,CAAC,MAAM,eAAe,GAAG,SAAkB,CAAC;AAElD,oCAAoC;AACpC,MAAM,CAAC,MAAM,YAAY,GAAG,OAAgB,CAAC;AAE7C,uDAAuD;AACvD,MAAM,CAAC,MAAM,gBAAgB,GAAG,OAAgB,CAAC;AAEjD,gDAAgD;AAChD,MAAM,CAAC,MAAM,eAAe,GAAG,KAAc,CAAC;AAE9C;;;;GAIG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAAG,MAAe,CAAC;AAEzD;;GAEG;AACH,MAAM,CAAC,MAAM,uBAAuB,GAAG,OAAgB,CAAC;AAExD;;GAEG;AACH,MAAM,CAAC,MAAM,0BAA0B,GAAG,EAAW,CAAC;AAEtD;;GAEG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAY,CAAC;AAErD;;GAEG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,EAAW,CAAC"}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Disposition conformance fixture vectors — machine-readable test data
|
|
3
|
+
* for the pre-dispatch disposition table (T-A through T-L).
|
|
4
|
+
*
|
|
5
|
+
* Mechanized VERBATIM from §3.8-1 of the #1165 frozen plan (rev11,
|
|
6
|
+
* SHA 7e26e5af). Each vector carries:
|
|
7
|
+
* - A raw frame (the input to a pre-dispatch classifier)
|
|
8
|
+
* - Machine-readable pre-state with correlation records + cross-frame oracle
|
|
9
|
+
* - The expected unique T-class assignment
|
|
10
|
+
* - For respond classes: a type-checked closed-arm error envelope
|
|
11
|
+
* - For close/accept classes: null response markers
|
|
12
|
+
*
|
|
13
|
+
* These are DATA — they do not classify. A future classifier
|
|
14
|
+
* implementation would be tested against these vectors.
|
|
15
|
+
*
|
|
16
|
+
* Coverage per §3.8-1 (frozen enumerations, not arbitrary counts):
|
|
17
|
+
* - 9 response-candidate sub-cases (RESPONSE_CANDIDATE_CASES)
|
|
18
|
+
* "your R9 correction #5's five required cases plus four controls"
|
|
19
|
+
* - 7 notification-partition sub-cases (NOTIFICATION_PARTITION_CASES)
|
|
20
|
+
* "your correction #4's five, the idless-envelope fixture,
|
|
21
|
+
* and the R8 row-10 value-failure fixture"
|
|
22
|
+
* - All 12 T-classes have ≥1 vector
|
|
23
|
+
* - Pre-state mutual-exclusivity proof pairs:
|
|
24
|
+
* ping nonce (T-H-3 / T-L-2), row-9 deliveryId (T-H-9 / T-L-4)
|
|
25
|
+
*
|
|
26
|
+
* Response frames are DERIVED from type-checked ClosedWireErrorResponse
|
|
27
|
+
* objects, not hand-written strings.
|
|
28
|
+
*
|
|
29
|
+
* Partition records carry {vectorId, expectedClass} per case (FC-70-4).
|
|
30
|
+
* Tests verify both existence AND class correctness per key.
|
|
31
|
+
*/
|
|
32
|
+
import type { DispositionClass, DispositionOutcome } from './disposition.js';
|
|
33
|
+
import type { WireMethodName } from './registry.js';
|
|
34
|
+
export declare const CLOSED_ERROR_ARM_NAMES: readonly ["ParseErrorEnvelope", "InvalidRequestNullIdEnvelope", "InvalidRequestValidIdEnvelope", "MethodNotFoundEnvelope", "InvalidParamsEnvelope", "InternalErrorEnvelope", "HandshakeRejectedEnvelope", "DeliveryRejectedEnvelope", "DomainErrorEnvelope", "DeadlineExpiredEnvelope", "SnapshotUnavailableEnvelope"];
|
|
35
|
+
export type ClosedErrorArmName = (typeof CLOSED_ERROR_ARM_NAMES)[number];
|
|
36
|
+
/**
|
|
37
|
+
* Original request fields needed for cross-frame semantic oracle validation.
|
|
38
|
+
* Optional: only populated for rows that have cross-frame invariants.
|
|
39
|
+
*/
|
|
40
|
+
export interface RequestSnapshot {
|
|
41
|
+
/** Row 11 ping: the nonce that must be echoed byte-equal in the result. */
|
|
42
|
+
readonly nonce?: string;
|
|
43
|
+
/** Row 9 deliver: the deliveryId that must match byte-equal in the ack. */
|
|
44
|
+
readonly deliveryId?: string;
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* A single in-flight request record for pre-state correlation.
|
|
48
|
+
* The method field is a closed WireMethodName, not a bare string —
|
|
49
|
+
* the compiler catches typos and detects registry drift.
|
|
50
|
+
*/
|
|
51
|
+
export interface InFlightRecord {
|
|
52
|
+
readonly id: string;
|
|
53
|
+
readonly method: WireMethodName;
|
|
54
|
+
/** Original request fields for cross-frame semantic oracle. */
|
|
55
|
+
readonly requestSnapshot?: RequestSnapshot;
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Machine-readable pre-state for state-dependent classification.
|
|
59
|
+
* Without this, T-H vs T-L cannot be distinguished from rawFrame alone.
|
|
60
|
+
*/
|
|
61
|
+
export interface FixturePreState {
|
|
62
|
+
readonly inFlightRequests: readonly InFlightRecord[];
|
|
63
|
+
}
|
|
64
|
+
export interface DispositionFixtureVector {
|
|
65
|
+
readonly id: string;
|
|
66
|
+
readonly rawFrame: string;
|
|
67
|
+
readonly rawFrameEncoding: 'utf8' | 'hex';
|
|
68
|
+
readonly preState: FixturePreState;
|
|
69
|
+
readonly expectedClass: DispositionClass;
|
|
70
|
+
readonly expectedOutcome: DispositionOutcome;
|
|
71
|
+
readonly expectedErrorArm: ClosedErrorArmName | null;
|
|
72
|
+
readonly expectedErrorCode: number | null;
|
|
73
|
+
readonly expectedResponseFrame: string | null;
|
|
74
|
+
readonly description: string;
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* A single named case from the frozen plan's partition enumeration.
|
|
78
|
+
*/
|
|
79
|
+
export interface PartitionCase {
|
|
80
|
+
readonly vectorId: string;
|
|
81
|
+
readonly expectedClass: DispositionClass;
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* 9 response-candidate sub-cases per §3.8-1:
|
|
85
|
+
* "your R9 correction #5's five required cases plus four controls"
|
|
86
|
+
*
|
|
87
|
+
* A "response candidate" enters the response lane: no method + at least
|
|
88
|
+
* one of result/error. Controls prove the boundary: frames with method
|
|
89
|
+
* that exit to T-F/T-K/T-D despite carrying result/error.
|
|
90
|
+
*/
|
|
91
|
+
export declare const RESPONSE_CANDIDATE_CASES: Readonly<Record<string, PartitionCase>>;
|
|
92
|
+
/**
|
|
93
|
+
* 7 notification-partition sub-cases per §3.8-1:
|
|
94
|
+
* "your correction #4's five, the idless-envelope fixture,
|
|
95
|
+
* and the R8 row-10 value-failure fixture"
|
|
96
|
+
*/
|
|
97
|
+
export declare const NOTIFICATION_PARTITION_CASES: Readonly<Record<string, PartitionCase>>;
|
|
98
|
+
export declare const DISPOSITION_FIXTURE_VECTORS: readonly DispositionFixtureVector[];
|
|
99
|
+
//# sourceMappingURL=disposition-fixtures.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"disposition-fixtures.d.ts","sourceRoot":"","sources":["../../src/wire/disposition-fixtures.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAE7E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAmBpD,eAAO,MAAM,sBAAsB,wTAYzB,CAAC;AAEX,MAAM,MAAM,kBAAkB,GAAG,CAAC,OAAO,sBAAsB,CAAC,CAAC,MAAM,CAAC,CAAC;AAkDzE;;;GAGG;AACH,M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