@sig-net/midnight 0.14.0 → 0.15.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/README.md CHANGED
@@ -83,7 +83,7 @@ Set up your contract for integration with the Sig Network MPC's sign bidirection
83
83
 
84
84
  Compile with the pinned toolchain (currently `compact update 0.33.0-rc.2`) and always pass `--feature-zkir-v3`: compiled output without it is not compatible with the ledger-9 matched stack (node, indexer, proof server).
85
85
 
86
- 2. Declare the required Sig Network protocol state in your ledger (plus recommended deployer identity and initialisation state). The event map can sit at ANY ledger field: each notification your contract registers names the field position holding it (runtime step 1), and the MPC reads the authenticated request from there.
86
+ 2. Declare the required Sig Network protocol state in your ledger (plus recommended deployer identity and initialisation state). The event map can sit at ANY ledger field: each notification your contract registers carries the map's resolved ledger-tree path (see [The request map's ledger-tree path](#the-request-maps-ledger-tree-path)), and the MPC reads the authenticated request from there.
87
87
 
88
88
  ```compact
89
89
  // Required: Map of SignBidirectionalEvent signature requests, configured by transaction type.
@@ -141,6 +141,22 @@ Set up your contract for integration with the Sig Network MPC's sign bidirection
141
141
  }
142
142
  ```
143
143
 
144
+ ### The request map's ledger-tree path
145
+
146
+ Each notification must tell the MPC where your `signBidirectionalEventMap` sits in your contract's compiled on-chain state, so the MPC can read the authenticated request out of raw contract state. The location is a path in the state tree, passed to `constructSignBidirectionalEventNotificationV1` as two arguments:
147
+
148
+ - `requestsPathDepth`: the number of meaningful entries in the path (1 to 4).
149
+ - `requestsPath`: the path itself, zero padded to 4 entries.
150
+
151
+ The path shape comes from how compactc lays out state. The compiler packs a contract's public ledger fields into a tree whose array nodes hold at most 15 entries. With 15 or fewer fields, field N sits directly in the root array, at path `[N]` (depth 1). With more than 15 fields, the compiler groups the fields into segments of at most 15 (the remainder segment first) and the root array holds the segments. Each grouping adds one level to the tree and one entry to every field's path. A 20-field contract splits 5 + 15: field 4 sits at `[0, 4]` and field 19 sits at `[1, 14]` (depth 2).
152
+
153
+ Do not derive the path by hand: the compiler records it in your compiled artifacts. Compile your contract, then look up your map's `"index"` in `managed/<contract>/compiler/contract-info.json` (a bare number `4` means path `[4]`). The generated `managed/<contract>/contract/index.js` accessors walk the same indices, for example `state.asArray()[1].asArray()[14]` for a map recorded at `[1, 14]`. That path packs as `requestsPathDepth = 2` and `requestsPath = [1, 14, 0, 0]`.
154
+
155
+ The two caller contracts in the [sig-net/midnight-integration](https://github.com/sig-net/midnight-integration) repository are worked examples of each case:
156
+
157
+ - [`test-caller-contract`](https://github.com/sig-net/midnight-integration/tree/main/packages/test-caller-contract): the flat case, where its 8-field ledger stores the map at field 4, so notifications carry depth `1` and path `[4, 0, 0, 0]`.
158
+ - [`test-caller-contract-20-field`](https://github.com/sig-net/midnight-integration/tree/main/packages/test-caller-contract-20-field): the chunked case, where its 20 fields split 5 + 15, so the map at field 19 packs as depth `2` and path `[1, 14, 0, 0]`.
159
+
144
160
  ### Runtime
145
161
 
146
162
  Each interaction with your contract that executes a transaction on a foreign chain runs these 5 steps.
@@ -158,8 +174,8 @@ const reader = new SignetRequestResponseReader({
158
174
  // Address of YOUR deployed contract
159
175
  requesterContractAddress: myContractAddress,
160
176
 
161
- // signBidirectionalEventMap's field position (Setup step 2)
162
- requesterRequestsIndexField: 0,
177
+ // signBidirectionalEventMap's ledger-tree path (see The request map's ledger-tree path)
178
+ requesterRequestsPath: [0],
163
179
 
164
180
  // Address of the Signet singleton contract
165
181
  signetContractAddress,
@@ -186,10 +202,15 @@ const expectedSigner = deriveEvmAddress(mpcRootPublicKey, myContractAddress, "my
186
202
  signBidirectionalEventMap.insert(requestId, disclose(request));
187
203
 
188
204
  // Notify the MPC of the SignBidirectionalEvent and the location of your signBidirectionalEventMap.
189
- // The location is 0 here based on the position of the declaration in Setup step 2.
205
+ // The map is at ledger field 0 (Setup step 2), so its path is [0] at depth 1
206
+ // (see The request map's ledger-tree path).
190
207
  signetSigner.signBidirectional(
191
208
  requestId,
192
- constructSignBidirectionalEventNotificationV1(kernel.self(), 0 as Uint<8>),
209
+ constructSignBidirectionalEventNotificationV1(
210
+ kernel.self(),
211
+ 1 as Uint<8>, // requestsPathDepth
212
+ [0, 0, 0, 0] as Vector<4, Uint<8>>, // requestsPath, zero padded
213
+ ),
193
214
  );
194
215
  ```
195
216
 
@@ -25,11 +25,22 @@
25
25
  }
26
26
  },
27
27
  {
28
- "name": "requestsIndexField",
28
+ "name": "requestsPathDepth",
29
29
  "type": {
30
30
  "type-name": "Uint",
31
31
  "maxval": 255
32
32
  }
33
+ },
34
+ {
35
+ "name": "requestsPath",
36
+ "type": {
37
+ "type-name": "Vector",
38
+ "length": 4,
39
+ "type": {
40
+ "type-name": "Uint",
41
+ "maxval": 255
42
+ }
43
+ }
33
44
  }
34
45
  ],
35
46
  "result-type": {
@@ -7,26 +7,26 @@
7
7
  "type": "directory",
8
8
  "contract-info.json": {
9
9
  "type": "file",
10
- "size": 7955,
11
- "hash": "bdc0fba992f5d93b36bfe0a807b35d05943505a5fc9dc48c46ba33a4269c65c9"
10
+ "size": 8200,
11
+ "hash": "07a63a0b166c651d4f9eb662029bacc81b0825311959ac67405d3996c064a84c"
12
12
  }
13
13
  },
14
14
  "contract": {
15
15
  "type": "directory",
16
16
  "index.d.ts": {
17
17
  "type": "file",
18
- "size": 6388,
19
- "hash": "c8f837fb853f415edca32eb789a5391a327ad168dd1d48e8b7eb72eadc5d7af8"
18
+ "size": 6518,
19
+ "hash": "9c63efc21d21c87c4a1989454c35158c8d783fd86131a5697edfd5e8f9db4bba"
20
20
  },
21
21
  "index.js": {
22
22
  "type": "file",
23
- "size": 48928,
24
- "hash": "cd4412517d099f20ca53775c282192bf5b5ea4727b2b63fd7d8e2e311bbc8a6c"
23
+ "size": 49867,
24
+ "hash": "63808b43f8f0f7674971b1fe67ed6ef933004094fe48571969839dcdbbe1c589"
25
25
  },
26
26
  "index.js.map": {
27
27
  "type": "file",
28
- "size": 4664,
29
- "hash": "26117f20d193b8494ad25ae56f22e64233b403ff613a6a880a426604e9f55c21"
28
+ "size": 4763,
29
+ "hash": "f4f3622ea5f12911ee4ff19ffccf1b03d35f1c07a49ce0a48c1768d7903fc2d7"
30
30
  }
31
31
  }
32
32
  }
@@ -12,9 +12,10 @@ export type ProvableCircuits<PS> = {
12
12
  export type PureCircuits = {
13
13
  constructSignBidirectionalEventNotificationV1(callerAddress_0: { bytes: Uint8Array
14
14
  },
15
- requestsIndexField_0: bigint): { version: bigint,
16
- payload: Uint8Array
17
- };
15
+ requestsPathDepth_0: bigint,
16
+ requestsPath_0: bigint[]): { version: bigint,
17
+ payload: Uint8Array
18
+ };
18
19
  signetKeyHash(pk_0: __compactRuntime.Secp256k1Point): Uint8Array;
19
20
  evmAddressAbiWord(addr_0: Uint8Array): Uint8Array;
20
21
  numericAbiWord(value_0: bigint): Uint8Array;
@@ -43,9 +44,10 @@ export type Circuits<PS> = {
43
44
  constructSignBidirectionalEventNotificationV1(context: __compactRuntime.CircuitContext<PS>,
44
45
  callerAddress_0: { bytes: Uint8Array
45
46
  },
46
- requestsIndexField_0: bigint): Promise<__compactRuntime.CircuitResults<PS, { version: bigint,
47
- payload: Uint8Array
48
- }>>;
47
+ requestsPathDepth_0: bigint,
48
+ requestsPath_0: bigint[]): Promise<__compactRuntime.CircuitResults<PS, { version: bigint,
49
+ payload: Uint8Array
50
+ }>>;
49
51
  signetKeyHash(context: __compactRuntime.CircuitContext<PS>,
50
52
  pk_0: __compactRuntime.Secp256k1Point): Promise<__compactRuntime.CircuitResults<PS, Uint8Array>>;
51
53
  evmAddressAbiWord(context: __compactRuntime.CircuitContext<PS>,
@@ -84,28 +84,30 @@ class _ContractAddress_0 {
84
84
 
85
85
  const _descriptor_11 = new _ContractAddress_0();
86
86
 
87
- const _descriptor_12 = new __compactRuntime.CompactTypeBytes(128);
87
+ const _descriptor_12 = new __compactRuntime.CompactTypeVector(4, _descriptor_3);
88
+
89
+ const _descriptor_13 = new __compactRuntime.CompactTypeBytes(128);
88
90
 
89
91
  class _SignBidirectionalEventNotification_0 {
90
92
  alignment() {
91
- return _descriptor_3.alignment().concat(_descriptor_12.alignment());
93
+ return _descriptor_3.alignment().concat(_descriptor_13.alignment());
92
94
  }
93
95
  fromValue(value_0) {
94
96
  return {
95
97
  version: _descriptor_3.fromValue(value_0),
96
- payload: _descriptor_12.fromValue(value_0)
98
+ payload: _descriptor_13.fromValue(value_0)
97
99
  }
98
100
  }
99
101
  toValue(value_0) {
100
- return _descriptor_3.toValue(value_0.version).concat(_descriptor_12.toValue(value_0.payload));
102
+ return _descriptor_3.toValue(value_0.version).concat(_descriptor_13.toValue(value_0.payload));
101
103
  }
102
104
  }
103
105
 
104
- const _descriptor_13 = new _SignBidirectionalEventNotification_0();
106
+ const _descriptor_14 = new _SignBidirectionalEventNotification_0();
105
107
 
106
- const _descriptor_14 = __compactRuntime.CompactTypeSecp256k1Scalar;
108
+ const _descriptor_15 = __compactRuntime.CompactTypeSecp256k1Scalar;
107
109
 
108
- const _descriptor_15 = __compactRuntime.CompactTypeSecp256k1Base;
110
+ const _descriptor_16 = __compactRuntime.CompactTypeSecp256k1Base;
109
111
 
110
112
  class _tuple_0 {
111
113
  alignment() {
@@ -122,7 +124,7 @@ class _tuple_0 {
122
124
  }
123
125
  }
124
126
 
125
- const _descriptor_16 = new _tuple_0();
127
+ const _descriptor_17 = new _tuple_0();
126
128
 
127
129
  class _tuple_1 {
128
130
  alignment() {
@@ -139,7 +141,7 @@ class _tuple_1 {
139
141
  }
140
142
  }
141
143
 
142
- const _descriptor_17 = new _tuple_1();
144
+ const _descriptor_18 = new _tuple_1();
143
145
 
144
146
  class _tuple_2 {
145
147
  alignment() {
@@ -156,26 +158,26 @@ class _tuple_2 {
156
158
  }
157
159
  }
158
160
 
159
- const _descriptor_18 = new _tuple_2();
161
+ const _descriptor_19 = new _tuple_2();
160
162
 
161
163
  class _Secp256k1EcdsaSignature_0 {
162
164
  alignment() {
163
- return _descriptor_14.alignment().concat(_descriptor_14.alignment());
165
+ return _descriptor_15.alignment().concat(_descriptor_15.alignment());
164
166
  }
165
167
  fromValue(value_0) {
166
168
  return {
167
- r: _descriptor_14.fromValue(value_0),
168
- s: _descriptor_14.fromValue(value_0)
169
+ r: _descriptor_15.fromValue(value_0),
170
+ s: _descriptor_15.fromValue(value_0)
169
171
  }
170
172
  }
171
173
  toValue(value_0) {
172
- return _descriptor_14.toValue(value_0.r).concat(_descriptor_14.toValue(value_0.s));
174
+ return _descriptor_15.toValue(value_0.r).concat(_descriptor_15.toValue(value_0.s));
173
175
  }
174
176
  }
175
177
 
176
- const _descriptor_19 = new _Secp256k1EcdsaSignature_0();
178
+ const _descriptor_20 = new _Secp256k1EcdsaSignature_0();
177
179
 
178
- const _descriptor_20 = new __compactRuntime.CompactTypeUnsignedInteger(18446744073709551615n, 8);
180
+ const _descriptor_21 = new __compactRuntime.CompactTypeUnsignedInteger(18446744073709551615n, 8);
179
181
 
180
182
  class _Either_0 {
181
183
  alignment() {
@@ -193,9 +195,9 @@ class _Either_0 {
193
195
  }
194
196
  }
195
197
 
196
- const _descriptor_21 = new _Either_0();
198
+ const _descriptor_22 = new _Either_0();
197
199
 
198
- const _descriptor_22 = new __compactRuntime.CompactTypeUnsignedInteger(4294967295n, 4);
200
+ const _descriptor_23 = new __compactRuntime.CompactTypeUnsignedInteger(4294967295n, 4);
199
201
 
200
202
  export class Contract {
201
203
  witnesses;
@@ -343,15 +345,15 @@ export class Contract {
343
345
  return result_0;
344
346
  }
345
347
  _keccak256_0(value_0) {
346
- const result_0 = __compactRuntime.keccak256(_descriptor_18, value_0);
348
+ const result_0 = __compactRuntime.keccak256(_descriptor_19, value_0);
347
349
  return result_0;
348
350
  }
349
351
  _keccak256_1(value_0) {
350
- const result_0 = __compactRuntime.keccak256(_descriptor_16, value_0);
352
+ const result_0 = __compactRuntime.keccak256(_descriptor_17, value_0);
351
353
  return result_0;
352
354
  }
353
355
  _keccak256_2(value_0) {
354
- const result_0 = __compactRuntime.keccak256(_descriptor_17, value_0);
356
+ const result_0 = __compactRuntime.keccak256(_descriptor_18, value_0);
355
357
  return result_0;
356
358
  }
357
359
  _mul_0(x_0, y_0) {
@@ -379,13 +381,18 @@ export class Contract {
379
381
  return result_0;
380
382
  }
381
383
  _constructSignBidirectionalEventNotificationV1_0(callerAddress_0,
382
- requestsIndexField_0)
384
+ requestsPathDepth_0,
385
+ requestsPath_0)
383
386
  {
384
387
  return { version: 1n,
385
388
  payload:
386
389
  Uint8Array.from([...Array.from(callerAddress_0.bytes, BigInt),
387
- requestsIndexField_0,
388
- ...Array.from(new Uint8Array(95), BigInt)],
390
+ requestsPathDepth_0,
391
+ requestsPath_0[0],
392
+ requestsPath_0[1],
393
+ requestsPath_0[2],
394
+ requestsPath_0[3],
395
+ ...Array.from(new Uint8Array(91), BigInt)],
389
396
  Number) };
390
397
  }
391
398
  _calculateSignetAttestationDigest_0(requestId_0, serializedOutput_0) {
@@ -446,13 +453,13 @@ export class Contract {
446
453
  32,
447
454
  this._reverseBytes32_0(respondBidirectionalEvent_0.signature.bigR.x),
448
455
  'Secp256k1Scalar',
449
- 'Signet.compact line 349 char 12'),
456
+ 'Signet.compact line 389 char 12'),
450
457
  s:
451
458
  __compactRuntime.convertBytesToField(115792089237316195423570985008687907852837564279074904382605163141518161494336n,
452
459
  32,
453
460
  this._reverseBytes32_0(respondBidirectionalEvent_0.signature.s),
454
461
  'Secp256k1Scalar',
455
- 'Signet.compact line 350 char 12') },
462
+ 'Signet.compact line 390 char 12') },
456
463
  mpcResponseKey_0);
457
464
  }
458
465
  _signetKeyHash_0(pk_0) { return this._persistentHash_0(pk_0); }
@@ -464,7 +471,7 @@ export class Contract {
464
471
  _numericAbiWord_0(value_0) {
465
472
  const le_0 = Array.from(__compactRuntime.convertBigintToBytes(16,
466
473
  value_0,
467
- 'Signet.compact line 431 char 17'),
474
+ 'Signet.compact line 471 char 17'),
468
475
  BigInt);
469
476
  return Uint8Array.from([...Array.from(new Uint8Array(16), BigInt),
470
477
  le_0[15],
@@ -496,7 +503,7 @@ export class Contract {
496
503
  ((e, i) => e.slice(i, i+16))(word_0,
497
504
  Number(0n)),
498
505
  'Field',
499
- 'Signet.compact line 450 char 12')
506
+ 'Signet.compact line 490 char 12')
500
507
  ===
501
508
  0n,
502
509
  'ABI word exceeds Uint<128>');
@@ -505,77 +512,77 @@ export class Contract {
505
512
  ((e, i) => e.slice(i, i+1))(word_0,
506
513
  Number(16n)),
507
514
  'Field',
508
- 'Signet.compact line 451 char 17');
515
+ 'Signet.compact line 491 char 17');
509
516
  const b1_0 = __compactRuntime.addField(__compactRuntime.mulField(b0_0, 256n),
510
517
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
511
518
  1,
512
519
  ((e, i) => e.slice(i, i+1))(word_0,
513
520
  Number(17n)),
514
521
  'Field',
515
- 'Signet.compact line 452 char 30'));
522
+ 'Signet.compact line 492 char 30'));
516
523
  const b2_0 = __compactRuntime.addField(__compactRuntime.mulField(b1_0, 256n),
517
524
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
518
525
  1,
519
526
  ((e, i) => e.slice(i, i+1))(word_0,
520
527
  Number(18n)),
521
528
  'Field',
522
- 'Signet.compact line 453 char 30'));
529
+ 'Signet.compact line 493 char 30'));
523
530
  const b3_0 = __compactRuntime.addField(__compactRuntime.mulField(b2_0, 256n),
524
531
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
525
532
  1,
526
533
  ((e, i) => e.slice(i, i+1))(word_0,
527
534
  Number(19n)),
528
535
  'Field',
529
- 'Signet.compact line 454 char 30'));
536
+ 'Signet.compact line 494 char 30'));
530
537
  const b4_0 = __compactRuntime.addField(__compactRuntime.mulField(b3_0, 256n),
531
538
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
532
539
  1,
533
540
  ((e, i) => e.slice(i, i+1))(word_0,
534
541
  Number(20n)),
535
542
  'Field',
536
- 'Signet.compact line 455 char 30'));
543
+ 'Signet.compact line 495 char 30'));
537
544
  const b5_0 = __compactRuntime.addField(__compactRuntime.mulField(b4_0, 256n),
538
545
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
539
546
  1,
540
547
  ((e, i) => e.slice(i, i+1))(word_0,
541
548
  Number(21n)),
542
549
  'Field',
543
- 'Signet.compact line 456 char 30'));
550
+ 'Signet.compact line 496 char 30'));
544
551
  const b6_0 = __compactRuntime.addField(__compactRuntime.mulField(b5_0, 256n),
545
552
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
546
553
  1,
547
554
  ((e, i) => e.slice(i, i+1))(word_0,
548
555
  Number(22n)),
549
556
  'Field',
550
- 'Signet.compact line 457 char 30'));
557
+ 'Signet.compact line 497 char 30'));
551
558
  const b7_0 = __compactRuntime.addField(__compactRuntime.mulField(b6_0, 256n),
552
559
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
553
560
  1,
554
561
  ((e, i) => e.slice(i, i+1))(word_0,
555
562
  Number(23n)),
556
563
  'Field',
557
- 'Signet.compact line 458 char 30'));
564
+ 'Signet.compact line 498 char 30'));
558
565
  const b8_0 = __compactRuntime.addField(__compactRuntime.mulField(b7_0, 256n),
559
566
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
560
567
  1,
561
568
  ((e, i) => e.slice(i, i+1))(word_0,
562
569
  Number(24n)),
563
570
  'Field',
564
- 'Signet.compact line 459 char 30'));
571
+ 'Signet.compact line 499 char 30'));
565
572
  const b9_0 = __compactRuntime.addField(__compactRuntime.mulField(b8_0, 256n),
566
573
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
567
574
  1,
568
575
  ((e, i) => e.slice(i, i+1))(word_0,
569
576
  Number(25n)),
570
577
  'Field',
571
- 'Signet.compact line 460 char 30'));
578
+ 'Signet.compact line 500 char 30'));
572
579
  const b10_0 = __compactRuntime.addField(__compactRuntime.mulField(b9_0, 256n),
573
580
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
574
581
  1,
575
582
  ((e, i) => e.slice(i, i+1))(word_0,
576
583
  Number(26n)),
577
584
  'Field',
578
- 'Signet.compact line 461 char 30'));
585
+ 'Signet.compact line 501 char 30'));
579
586
  const b11_0 = __compactRuntime.addField(__compactRuntime.mulField(b10_0,
580
587
  256n),
581
588
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
@@ -583,7 +590,7 @@ export class Contract {
583
590
  ((e, i) => e.slice(i, i+1))(word_0,
584
591
  Number(27n)),
585
592
  'Field',
586
- 'Signet.compact line 462 char 30'));
593
+ 'Signet.compact line 502 char 30'));
587
594
  const b12_0 = __compactRuntime.addField(__compactRuntime.mulField(b11_0,
588
595
  256n),
589
596
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
@@ -591,7 +598,7 @@ export class Contract {
591
598
  ((e, i) => e.slice(i, i+1))(word_0,
592
599
  Number(28n)),
593
600
  'Field',
594
- 'Signet.compact line 463 char 30'));
601
+ 'Signet.compact line 503 char 30'));
595
602
  const b13_0 = __compactRuntime.addField(__compactRuntime.mulField(b12_0,
596
603
  256n),
597
604
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
@@ -599,7 +606,7 @@ export class Contract {
599
606
  ((e, i) => e.slice(i, i+1))(word_0,
600
607
  Number(29n)),
601
608
  'Field',
602
- 'Signet.compact line 464 char 30'));
609
+ 'Signet.compact line 504 char 30'));
603
610
  const b14_0 = __compactRuntime.addField(__compactRuntime.mulField(b13_0,
604
611
  256n),
605
612
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
@@ -607,7 +614,7 @@ export class Contract {
607
614
  ((e, i) => e.slice(i, i+1))(word_0,
608
615
  Number(30n)),
609
616
  'Field',
610
- 'Signet.compact line 465 char 30'));
617
+ 'Signet.compact line 505 char 30'));
611
618
  const b15_0 = __compactRuntime.addField(__compactRuntime.mulField(b14_0,
612
619
  256n),
613
620
  __compactRuntime.convertBytesToUint(52435875175126190479447740508185965837690552500527637822603658699938581184512n,
@@ -615,10 +622,10 @@ export class Contract {
615
622
  ((e, i) => e.slice(i, i+1))(word_0,
616
623
  Number(31n)),
617
624
  'Field',
618
- 'Signet.compact line 466 char 30'));
625
+ 'Signet.compact line 506 char 30'));
619
626
  return ((t1) => {
620
627
  if (t1 > 340282366920938463463374607431768211455n) {
621
- throw new __compactRuntime.CompactError('Signet.compact line 467 char 12: cast from Field or Uint value to smaller Uint value failed: ' + t1 + ' is greater than 340282366920938463463374607431768211455');
628
+ throw new __compactRuntime.CompactError('Signet.compact line 507 char 12: cast from Field or Uint value to smaller Uint value failed: ' + t1 + ' is greater than 340282366920938463463374607431768211455');
622
629
  }
623
630
  return t1;
624
631
  })(b15_0);
@@ -629,7 +636,7 @@ export class Contract {
629
636
  ((e, i) => e.slice(i, i+31))(word_0,
630
637
  Number(0n)),
631
638
  'Field',
632
- 'Signet.compact line 473 char 12')
639
+ 'Signet.compact line 513 char 12')
633
640
  ===
634
641
  0n,
635
642
  'ABI word is not a canonical Boolean');
@@ -638,7 +645,7 @@ export class Contract {
638
645
  ((e, i) => e.slice(i, i+1))(word_0,
639
646
  Number(31n)),
640
647
  'Field',
641
- 'Signet.compact line 474 char 18');
648
+ 'Signet.compact line 514 char 18');
642
649
  __compactRuntime.assert(last_0 === 0n || last_0 === 1n,
643
650
  'ABI word is not a canonical Boolean');
644
651
  return last_0 === 1n;
@@ -688,27 +695,36 @@ const _emptyContext = {
688
695
  const _dummyContract = new Contract({ });
689
696
  export const pureCircuits = {
690
697
  constructSignBidirectionalEventNotificationV1: (...args_0) => {
691
- if (args_0.length !== 2) {
692
- throw new __compactRuntime.CompactError(`constructSignBidirectionalEventNotificationV1: expected 2 arguments (as invoked from Typescript), received ${args_0.length}`);
698
+ if (args_0.length !== 3) {
699
+ throw new __compactRuntime.CompactError(`constructSignBidirectionalEventNotificationV1: expected 3 arguments (as invoked from Typescript), received ${args_0.length}`);
693
700
  }
694
701
  const callerAddress_0 = args_0[0];
695
- const requestsIndexField_0 = args_0[1];
702
+ const requestsPathDepth_0 = args_0[1];
703
+ const requestsPath_0 = args_0[2];
696
704
  if (!(typeof(callerAddress_0) === 'object' && callerAddress_0.bytes.buffer instanceof ArrayBuffer && callerAddress_0.bytes.BYTES_PER_ELEMENT === 1 && callerAddress_0.bytes.length === 32)) {
697
705
  __compactRuntime.typeError('constructSignBidirectionalEventNotificationV1',
698
706
  'argument 1',
699
- 'Signet.compact line 218 char 3',
707
+ 'Signet.compact line 247 char 3',
700
708
  'struct ContractAddress<bytes: Bytes<32>>',
701
709
  callerAddress_0)
702
710
  }
703
- if (!(typeof(requestsIndexField_0) === 'bigint' && requestsIndexField_0 >= 0n && requestsIndexField_0 <= 255n)) {
711
+ if (!(typeof(requestsPathDepth_0) === 'bigint' && requestsPathDepth_0 >= 0n && requestsPathDepth_0 <= 255n)) {
704
712
  __compactRuntime.typeError('constructSignBidirectionalEventNotificationV1',
705
713
  'argument 2',
706
- 'Signet.compact line 218 char 3',
714
+ 'Signet.compact line 247 char 3',
707
715
  'Uint<0..256>',
708
- requestsIndexField_0)
716
+ requestsPathDepth_0)
717
+ }
718
+ if (!(Array.isArray(requestsPath_0) && requestsPath_0.length === 4 && requestsPath_0.every((t) => typeof(t) === 'bigint' && t >= 0n && t <= 255n))) {
719
+ __compactRuntime.typeError('constructSignBidirectionalEventNotificationV1',
720
+ 'argument 3',
721
+ 'Signet.compact line 247 char 3',
722
+ 'Vector<4, Uint<0..256>>',
723
+ requestsPath_0)
709
724
  }
710
725
  return _dummyContract._constructSignBidirectionalEventNotificationV1_0(callerAddress_0,
711
- requestsIndexField_0);
726
+ requestsPathDepth_0,
727
+ requestsPath_0);
712
728
  },
713
729
  signetKeyHash: (...args_0) => {
714
730
  if (args_0.length !== 1) {
@@ -725,7 +741,7 @@ export const pureCircuits = {
725
741
  if (!(addr_0.buffer instanceof ArrayBuffer && addr_0.BYTES_PER_ELEMENT === 1 && addr_0.length === 20)) {
726
742
  __compactRuntime.typeError('evmAddressAbiWord',
727
743
  'argument 1',
728
- 'Signet.compact line 422 char 3',
744
+ 'Signet.compact line 462 char 3',
729
745
  'Bytes<20>',
730
746
  addr_0)
731
747
  }
@@ -739,7 +755,7 @@ export const pureCircuits = {
739
755
  if (!(typeof(value_0) === 'bigint' && value_0 >= 0n && value_0 <= 340282366920938463463374607431768211455n)) {
740
756
  __compactRuntime.typeError('numericAbiWord',
741
757
  'argument 1',
742
- 'Signet.compact line 428 char 3',
758
+ 'Signet.compact line 468 char 3',
743
759
  'Uint<0..340282366920938463463374607431768211456>',
744
760
  value_0)
745
761
  }
@@ -753,7 +769,7 @@ export const pureCircuits = {
753
769
  if (!(typeof(value_0) === 'boolean')) {
754
770
  __compactRuntime.typeError('boolAbiWord',
755
771
  'argument 1',
756
- 'Signet.compact line 441 char 3',
772
+ 'Signet.compact line 481 char 3',
757
773
  'Boolean',
758
774
  value_0)
759
775
  }
@@ -767,7 +783,7 @@ export const pureCircuits = {
767
783
  if (!(word_0.buffer instanceof ArrayBuffer && word_0.BYTES_PER_ELEMENT === 1 && word_0.length === 32)) {
768
784
  __compactRuntime.typeError('abiWordToUint128',
769
785
  'argument 1',
770
- 'Signet.compact line 449 char 3',
786
+ 'Signet.compact line 489 char 3',
771
787
  'Bytes<32>',
772
788
  word_0)
773
789
  }
@@ -781,7 +797,7 @@ export const pureCircuits = {
781
797
  if (!(word_0.buffer instanceof ArrayBuffer && word_0.BYTES_PER_ELEMENT === 1 && word_0.length === 32)) {
782
798
  __compactRuntime.typeError('abiWordToBool',
783
799
  'argument 1',
784
- 'Signet.compact line 472 char 3',
800
+ 'Signet.compact line 512 char 3',
785
801
  'Bytes<32>',
786
802
  word_0)
787
803
  }
@@ -4,5 +4,5 @@
4
4
  "sourceRoot": "../../../",
5
5
  "sources": ["src/circuits.compact", "src/./Signet.compact", "compiler/zkir-v3-library.compact"],
6
6
  "names": [],
7
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAAA;;;;;;;;;;MCyNE,MAAA,6CAWC;;OAAA;MAkID,MAAA,aAEC;;OAAA;MA6DD,MAAA,iBAEC;;OAAA;MAID,MAAA,cASC;;OAAA;MAID,MAAA,WAEC;;OAAA;MAMD,MAAA,gBAmBC;;OAAA;MAID,MAAA,aAKC;;OAAA;MD3bH,MAAA,iCAKC;;OAAA;MAED,MAAA,kCAKC;;OAAA;MAED,MAAA,mCAKC;;OAAA;MAED,MAAA,iCAYC;;OAAA;;;;GACA;EAnED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmEC;EEvCD,AAAA,yBAA8B;UACtB,iBAAI;UACJ,gCACQ;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;0CACA;;;;gDACP;;;;EAqBT,AAAA,wBACiB,WACA,OACA;UAET,oCAA2C;UAC3C,2BAAS;UAAT,MAAA;UAAA,MAAA;UACA,kBAAyB;UACzB,mBAA0B,KAAG;UAC7B,mBAA0B,KAAG;UAC7B,+CAA6C;gDAAW,MAAI;;;;8GAC1C;;;;;WAA2C;;EA/FrE,AAAA,kBAAA;oEAAA;;;EAAA,AAAA,aAAA;gEAAA;;;EAAA,AAAA,aAAA;gEAAA;;;EAAA,A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;;UAFqC,MAAe;;;;;;;;+CAAf,MAAe;GAEpD;EAID,AAAA,cASC;;;;UATkC,OAAgB;;;;;;;;4CAAhB,OAAgB;GASlD;EAID,AAAA,WAEC;;;;UAF+B,OAAc;;;;;;;;yCAAd,OAAc;GAE7C;EAMD,AAAA,gBAmBC;;;;UAnBoC,MAAe;;;;;;;;8CAAf,MAAe;GAmBnD;EAID,AAAA,aAKC;;;;UALiC,MAAe;;;;;;;;2CAAf,MAAe;GAKhD;EDneH,AAAA,iCAKC;;;;UAJC,WAAoB;UACpB,kBAA0B;;;;;;;;;;;;;;;+DAD1B,WAAoB;+DACpB,kBAA0B;GAG3B;EAED,AAAA,kCAKC;;;;UAJC,WAAoB;UACpB,kBAA2B;;;;;;;;;;;;;;;gEAD3B,WAAoB;gEACpB,kBAA2B;GAG5B;EAED,AAAA,mCAKC;;;;UAJC,WAAoB;UACpB,kBAA4B;;;;;;;;;;;;;;;iEAD5B,WAAoB;iEACpB,kBAA4B;GAG7B;EAED,AAAA,iCAYC;;;;UAXC,WAAoB;UACpB,kBAA2B;UAC3B,2BAAoD;UACpD,gBAA8B;;;;;;;;;;;;;;;;;;;;;;+DAH9B,WAAoB;+DACpB,kBAA2B;+DAC3B,2BAAoD;+DACpD,gBAA8B;GAQ/B;;;;;;"
8
8
  }
@@ -38,13 +38,13 @@ export interface SignetRequestsLedger {
38
38
  *
39
39
  * @param raw - Raw contract state, e.g. `queryContractState(address).data`
40
40
  * from the indexer or `ctx.currentQueryContext.state` from the simulator.
41
- * @param requestsIndexField - Ledger field position of the request index.
42
- * @param nonceField - Ledger field position of the request counter.
41
+ * @param requestsIndexPath - Resolved ledger-tree path of the request index.
42
+ * @param noncePath - Resolved ledger-tree path of the request counter.
43
43
  * @returns The decoded {@link SignetRequestsLedger}.
44
44
  * @throws Error if a field is missing, has the wrong state-value shape, or a
45
45
  * record matches no capacity split.
46
46
  */
47
- export declare function readSignetRequestsLedgerFromState(raw: RawContractState, requestsIndexField: number, nonceField: number): SignetRequestsLedger;
47
+ export declare function readSignetRequestsLedgerFromState(raw: RawContractState, requestsIndexPath: readonly number[], noncePath: readonly number[]): SignetRequestsLedger;
48
48
  /**
49
49
  * Look up ONE request by id in a contract's request index at an arbitrary
50
50
  * ledger field, the single-record sibling of
@@ -66,9 +66,10 @@ export declare function readSignetRequestsLedgerFromState(raw: RawContractState,
66
66
  * fieldIndex, …).requestsIndex.get(requestId)`.
67
67
  *
68
68
  * @param raw - Raw contract state, e.g. `queryContractState(address).data`.
69
- * @param fieldIndex - Ledger field position of the request index in `raw`.
69
+ * @param requestsPath - Resolved ledger-tree path of the request index in
70
+ * `raw`, as the notification carries it.
70
71
  * @param requestId - The request id to look up.
71
72
  * @returns The stored request record, or `undefined` when it is not a member.
72
73
  */
73
- export declare function lookupSignetRequestAt(raw: RawContractState, fieldIndex: number, requestId: RequestIdHex): SignBidirectionalEvent | undefined;
74
+ export declare function lookupSignetRequestAt(raw: RawContractState, requestsPath: readonly number[], requestId: RequestIdHex): SignBidirectionalEvent | undefined;
74
75
  //# sourceMappingURL=signature-requests-state-reader.d.ts.map