Skip to content

Commit

Permalink
fix serialization bug.
Browse files Browse the repository at this point in the history
update snapshots.

Co-authored-by: Alex Gherghisan <[email protected]>
  • Loading branch information
Mitchell Tracy and alexghr committed Feb 2, 2024
1 parent 7500369 commit 3e0b3ed
Show file tree
Hide file tree
Showing 9 changed files with 18,763 additions and 870 deletions.
62 changes: 31 additions & 31 deletions yarn-project/circuits.js/src/abis/__snapshots__/abis.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -10,41 +10,41 @@ exports[`abis Computes an empty sideeffect hash 1`] = `"0x27b1d0839a5b23baf12a8

exports[`abis compute private call stack item hash 1`] = `
Fr {
"asBigInt": 2538893743621542769113965831489475193028088869221520738485857489526782477042n,
"asBigInt": 1058108273519211057958983017403656079426177248613466485863012056136969809881n,
"asBuffer": {
"data": [
5,
2,
86,
222,
57,
41,
140,
244,
156,
246,
130,
229,
216,
20,
236,
212,
248,
127,
77,
87,
131,
206,
91,
232,
191,
24,
71,
1,
209,
33,
31,
201,
184,
56,
89,
168,
20,
236,
48,
194,
242,
151,
136,
165,
186,
107,
37,
17,
119,
4,
83,
102,
195,
226,
180,
18,
253,
220,
202,
174,
239,
217,
],
"type": "Buffer",
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,41 +2,41 @@

exports[`PrivateCallStackItem computes hash 1`] = `
Fr {
"asBigInt": 8008891951297996625543609944740044699833919064006676167413082300732616429718n,
"asBigInt": 9863016068749090736597089217395332987261861243138085912865970371247004412709n,
"asBuffer": {
"data": [
17,
180,
223,
72,
220,
5,
64,
99,
2,
54,
249,
241,
192,
24,
194,
161,
129,
136,
212,
25,
98,
34,
205,
8,
60,
50,
98,
21,
206,
68,
238,
103,
15,
170,
83,
16,
215,
198,
142,
109,
208,
170,
255,
213,
239,
82,
127,
177,
202,
57,
71,
80,
150,
176,
101,
103,
69,
251,
253,
215,
107,
37,
],
"type": "Buffer",
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,41 +2,41 @@

exports[`PrivateCircuitPublicInputs hash matches snapshot 1`] = `
Fr {
"asBigInt": 7655509707748365385586683354008259293573299722789964529445054772581519738939n,
"asBigInt": 17965057432304162663609649222224826000756674060660466974194339783441351638025n,
"asBuffer": {
"data": [
16,
236,
221,
108,
242,
63,
20,
45,
47,
147,
239,
244,
141,
4,
39,
183,
220,
183,
64,
232,
229,
199,
125,
34,
72,
231,
214,
40,
82,
141,
21,
179,
158,
65,
218,
247,
23,
13,
105,
121,
159,
29,
162,
114,
51,
52,
186,
54,
94,
72,
59,
196,
233,
228,
61,
55,
62,
71,
106,
218,
252,
9,
],
"type": "Buffer",
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export class KernelCircuitPublicInputsFinal {
) {}

toBuffer() {
return serializeToBuffer(this.aggregationObject, this.end, this.constants, this.isPrivate);
return serializeToBuffer(this.aggregationObject, this.endMeta, this.end, this.constants, this.isPrivate);
}

/**
Expand Down
2 changes: 1 addition & 1 deletion yarn-project/circuits.js/src/tests/factories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ export function makeKernelPublicInputs(seed = 1, fullAccumulatedData = true): Ke
export function makePrivateKernelPublicInputsFinal(seed = 1): PrivateKernelPublicInputsFinal {
return new PrivateKernelPublicInputsFinal(
makeAggregationObject(seed),
FinalAccumulatedData.empty(),
makeFinalAccumulatedData(seed, true),
makeFinalAccumulatedData(seed, true),
makeConstantData(seed + 0x100),
);
Expand Down
Loading

0 comments on commit 3e0b3ed

Please sign in to comment.