@aztec/end-to-end 0.85.0-nightly.20250417 → 0.85.0-nightly.20250420

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.
@@ -2,7 +2,7 @@ import { BBNativePrivateKernelProver } from '@aztec/bb-prover';
2
2
  import { BBWASMBundlePrivateKernelProver } from '@aztec/bb-prover/wasm/bundle';
3
3
  import { createLogger, logger } from '@aztec/foundation/log';
4
4
  import { WASMSimulator } from '@aztec/simulator/client';
5
- import { decode } from '@msgpack/msgpack';
5
+ import { Decoder } from 'msgpackr';
6
6
  import assert from 'node:assert';
7
7
  import { readFile, readdir, writeFile } from 'node:fs/promises';
8
8
  import { join } from 'node:path';
@@ -131,8 +131,10 @@ async function main() {
131
131
  const userLog = createLogger('client_ivc_flows:data_processor');
132
132
  for (const flow of flows){
133
133
  userLog.info(`Processing flow ${flow}`);
134
- const bytecode = await readFile(join(ivcFolder, flow, 'acir.msgpack'));
135
- const acirStack = decode(bytecode);
134
+ const ivcInputs = await readFile(join(ivcFolder, flow, 'ivc-inputs.msgpack'));
135
+ const stepsFromFile = new Decoder({
136
+ useRecords: false
137
+ }).unpack(ivcInputs);
136
138
  const witnesses = await readFile(join(ivcFolder, flow, 'witnesses.json'));
137
139
  const witnessStack = JSON.parse(witnesses.toString()).map((witnessMap)=>{
138
140
  return new Map(Object.entries(witnessMap).map(([k, v])=>[
@@ -145,8 +147,11 @@ async function main() {
145
147
  const privateExecutionSteps = executionSteps.map((step, i)=>({
146
148
  functionName: step.fnName,
147
149
  gateCount: step.gateCount,
148
- bytecode: acirStack[i],
149
- witness: witnessStack[i]
150
+ bytecode: stepsFromFile[i].bytecode,
151
+ // TODO(AD) do we still want to take this from witness.json?
152
+ witness: witnessStack[i],
153
+ // This can be left empty. If so, the prover will generate a vk on the fly (~25% slower).
154
+ vk: Buffer.from([])
150
155
  }));
151
156
  let stats;
152
157
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
@@ -283,6 +283,11 @@ export declare class P2PNetworkTest {
283
283
  setupAccount(): Promise<void>;
284
284
  deploySpamContract(): Promise<void>;
285
285
  removeInitialNode(): Promise<void>;
286
+ sendDummyTx(): Promise<{
287
+ receipt: import("viem").TransactionReceipt;
288
+ gasPrice: import("@aztec/ethereum").GasPrice;
289
+ }>;
290
+ private _sendDummyTx;
286
291
  setup(): Promise<void>;
287
292
  stopNodes(nodes: AztecNodeService[]): Promise<void>;
288
293
  teardown(): Promise<void>;
@@ -1 +1 @@
1
- {"version":3,"file":"p2p_network.d.ts","sourceRoot":"","sources":["../../src/e2e_p2p/p2p_network.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAClE,OAAO,KAAK,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAC3E,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,iBAAiB,CAAC;AAElE,OAAO,EAAE,YAAY,EAA0B,MAAM,sBAAsB,CAAC;AAC5E,OAAO,EAAE,KAAK,MAAM,EAAgB,MAAM,uBAAuB,CAAC;AAElE,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAC7D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAE1D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAC;AAa9D,OAAO,EAEL,KAAK,iBAAiB,EAGvB,MAAM,iCAAiC,CAAC;AAOzC,eAAO,MAAM,mBAAmB,QAA0C,CAAC;AAE3E,eAAO,MAAM,2BAA2B;;;CAGvC,CAAC;AAEF,qBAAa,cAAc;IA0BhB,gBAAgB,EAAE,MAAM;IACxB,YAAY,EAAE,MAAM;IAC3B,OAAO,CAAC,aAAa;IAGrB,OAAO,CAAC,WAAW,CAAC;IA9BtB,OAAO,CAAC,eAAe,CAAmB;IACnC,qBAAqB,EAAE,KAAK,MAAM,EAAE,CAAC;IACrC,WAAW;;;;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E,MAAM,CAAC;QACjB,aAAa,EAAE,MAAM,CAAC;QACtB,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,aAAa,CAAC,EAAE,OAAO,CAAC,eAAe,CAAC,CAAC;KAC1C;IAcD,IAAI,aAAa,uBAKhB;IAEK,gBAAgB;IActB,aAAa;;;;;;;;;IA0BP,kBAAkB;IA2DlB,YAAY;IAYZ,kBAAkB;IAoBlB,iBAAiB;IAmBjB,WAAW;;;;YAOH,YAAY;IAQpB,KAAK;IAaL,SAAS,CAAC,KAAK,EAAE,gBAAgB,EAAE;IAanC,QAAQ;CAKf"}
@@ -1,5 +1,5 @@
1
1
  import { getSchnorrWalletWithSecretKey } from '@aztec/accounts/schnorr';
2
- import { RollupContract, getExpectedAddress, getL1ContractsConfigEnvVars } from '@aztec/ethereum';
2
+ import { L1TxUtils, RollupContract, getExpectedAddress, getL1ContractsConfigEnvVars } from '@aztec/ethereum';
3
3
  import { ChainMonitor, EthCheatCodesWithState } from '@aztec/ethereum/test';
4
4
  import { createLogger } from '@aztec/foundation/log';
5
5
  import { ForwarderAbi, ForwarderBytecode, RollupAbi, TestERC20Abi } from '@aztec/l1-artifacts';
@@ -170,13 +170,7 @@ export class P2PNetworkTest {
170
170
  this.logger.debug('Warp failed, time already satisfied');
171
171
  }
172
172
  // Send and await a tx to make sure we mine a block for the warp to correctly progress.
173
- await deployL1ContractsValues.publicClient.waitForTransactionReceipt({
174
- hash: await deployL1ContractsValues.walletClient.sendTransaction({
175
- to: this.baseAccount.address,
176
- value: 1n,
177
- account: this.baseAccount
178
- })
179
- });
173
+ await this._sendDummyTx(deployL1ContractsValues.publicClient, deployL1ContractsValues.walletClient);
180
174
  // Set the system time in the node, only after we have warped the time and waited for a block
181
175
  // Time is only set in the NEXT block
182
176
  dateProvider.setTime(Number(timestamp) * 1000);
@@ -208,13 +202,7 @@ export class P2PNetworkTest {
208
202
  async removeInitialNode() {
209
203
  await this.snapshotManager.snapshot('remove-inital-validator', async ({ deployL1ContractsValues, aztecNode, dateProvider })=>{
210
204
  // Send and await a tx to make sure we mine a block for the warp to correctly progress.
211
- const receipt = await deployL1ContractsValues.publicClient.waitForTransactionReceipt({
212
- hash: await deployL1ContractsValues.walletClient.sendTransaction({
213
- to: this.baseAccount.address,
214
- value: 1n,
215
- account: this.baseAccount
216
- })
217
- });
205
+ const { receipt } = await this._sendDummyTx(deployL1ContractsValues.publicClient, deployL1ContractsValues.walletClient);
218
206
  const block = await deployL1ContractsValues.publicClient.getBlock({
219
207
  blockNumber: receipt.blockNumber
220
208
  });
@@ -222,6 +210,16 @@ export class P2PNetworkTest {
222
210
  await aztecNode.stop();
223
211
  });
224
212
  }
213
+ async sendDummyTx() {
214
+ return await this._sendDummyTx(this.ctx.deployL1ContractsValues.publicClient, this.ctx.deployL1ContractsValues.walletClient);
215
+ }
216
+ async _sendDummyTx(publicClient, walletClient) {
217
+ const l1TxUtils = new L1TxUtils(publicClient, walletClient);
218
+ return await l1TxUtils.sendAndMonitorTransaction({
219
+ to: walletClient.account.address,
220
+ value: 1n
221
+ });
222
+ }
225
223
  async setup() {
226
224
  this.ctx = await this.snapshotManager.setup();
227
225
  const sponsoredFPCAddress = await getSponsoredFPCAddress();
@@ -208,7 +208,7 @@ const { E2E_DATA_PATH: dataPath } = process.env;
208
208
  }, {
209
209
  prefilledPublicData
210
210
  });
211
- this.proverNode.start();
211
+ await this.proverNode.start();
212
212
  this.logger.warn(`Proofs are now enabled`);
213
213
  return this;
214
214
  }
@@ -560,7 +560,7 @@ export async function createAndSyncProverNode(proverNodePrivateKey, aztecNodeCon
560
560
  getLogger().info(`Created and synced prover node`, {
561
561
  publisherAddress: l1TxUtils.walletClient.account.address
562
562
  });
563
- proverNode.start();
563
+ await proverNode.start();
564
564
  return proverNode;
565
565
  }
566
566
  function createDelayedL1TxUtils(aztecNodeConfig, privateKey, logName) {
@@ -1 +1 @@
1
- {"version":3,"file":"capture_private_execution_steps.d.ts","sourceRoot":"","sources":["../../src/shared/capture_private_execution_steps.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,KAAK,EACV,2BAA2B,EAC3B,YAAY,EACZ,aAAa,EACb,oBAAoB,EACrB,MAAM,2BAA2B,CAAC;AA0BnC,wBAAsB,oCAAoC,CACxD,KAAK,EAAE,MAAM,EACb,WAAW,EAAE,2BAA2B,GAAG,YAAY,EACvD,IAAI,CAAC,EAAE,IAAI,CAAC,oBAAoB,GAAG,aAAa,EAAE,aAAa,CAAC,EAChE,aAAa,CAAC,EAAE,MAAM,iBAqCvB"}
1
+ {"version":3,"file":"capture_private_execution_steps.d.ts","sourceRoot":"","sources":["../../src/shared/capture_private_execution_steps.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,KAAK,EACV,2BAA2B,EAC3B,YAAY,EACZ,aAAa,EACb,oBAAoB,EACrB,MAAM,2BAA2B,CAAC;AASnC,wBAAsB,oCAAoC,CACxD,KAAK,EAAE,MAAM,EACb,WAAW,EAAE,2BAA2B,GAAG,YAAY,EACvD,IAAI,CAAC,EAAE,IAAI,CAAC,oBAAoB,GAAG,aAAa,EAAE,aAAa,CAAC,EAChE,aAAa,CAAC,EAAE,MAAM,iBAsCvB"}
@@ -2,25 +2,10 @@
2
2
  * This module exposes the ability to capture the private exection steps that go into our "Client IVC" prover.
3
3
  * These are used for debugging and benchmarking barretenberg (the prover component).
4
4
  */ import { createLogger } from '@aztec/foundation/log';
5
- import { serializeWitness } from '@aztec/noir-noirc_abi';
6
- import { encode } from '@msgpack/msgpack';
5
+ import { serializePrivateExecutionSteps } from '@aztec/stdlib/kernel';
7
6
  import { promises as fs } from 'fs';
8
7
  import path from 'path';
9
8
  const logger = createLogger('e2e:capture-private-execution-steps');
10
- // TODO(#7371): This is duplicated.
11
- // Longer term we won't use this hacked together msgpack format
12
- // Leaving duplicated as this eventually bb will provide a serialization
13
- // helper for passing to a generic msgpack RPC endpoint.
14
- async function _createClientIvcProofFiles(directory, executionSteps) {
15
- const acirPath = path.join(directory, 'acir.msgpack');
16
- const witnessPath = path.join(directory, 'witnesses.msgpack');
17
- await fs.writeFile(acirPath, encode(executionSteps.map((map)=>map.bytecode)));
18
- await fs.writeFile(witnessPath, encode(executionSteps.map((map)=>serializeWitness(map.witness))));
19
- return {
20
- acirPath,
21
- witnessPath
22
- };
23
- }
24
9
  export async function capturePrivateExecutionStepsIfEnvSet(label, interaction, opts, expectedSteps) {
25
10
  // Not included in env_var.ts as internal to e2e tests.
26
11
  const ivcFolder = process.env.CAPTURE_IVC_FOLDER;
@@ -45,7 +30,8 @@ export async function capturePrivateExecutionStepsIfEnvSet(label, interaction, o
45
30
  recursive: true
46
31
  });
47
32
  // Write the client IVC files read by the prover.
48
- await _createClientIvcProofFiles(resultsDirectory, result.executionSteps);
33
+ const ivcInputsPath = path.join(resultsDirectory, 'ivc-inputs.msgpack');
34
+ await fs.writeFile(ivcInputsPath, serializePrivateExecutionSteps(result.executionSteps));
49
35
  if (profileMode === 'full') {
50
36
  // If we have gate counts, write the steps in human-readable format.
51
37
  await fs.writeFile(path.join(resultsDirectory, 'steps.json'), JSON.stringify(result.executionSteps.map((step)=>({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aztec/end-to-end",
3
- "version": "0.85.0-nightly.20250417",
3
+ "version": "0.85.0-nightly.20250420",
4
4
  "type": "module",
5
5
  "exports": "./dest/index.js",
6
6
  "inherits": [
@@ -25,41 +25,40 @@
25
25
  "formatting": "run -T prettier --check ./src && run -T eslint ./src"
26
26
  },
27
27
  "dependencies": {
28
- "@aztec/accounts": "0.85.0-nightly.20250417",
29
- "@aztec/archiver": "0.85.0-nightly.20250417",
30
- "@aztec/aztec": "0.85.0-nightly.20250417",
31
- "@aztec/aztec-node": "0.85.0-nightly.20250417",
32
- "@aztec/aztec.js": "0.85.0-nightly.20250417",
33
- "@aztec/bb-prover": "0.85.0-nightly.20250417",
34
- "@aztec/blob-lib": "0.85.0-nightly.20250417",
35
- "@aztec/blob-sink": "0.85.0-nightly.20250417",
36
- "@aztec/bot": "0.85.0-nightly.20250417",
37
- "@aztec/cli": "0.85.0-nightly.20250417",
38
- "@aztec/constants": "0.85.0-nightly.20250417",
39
- "@aztec/entrypoints": "0.85.0-nightly.20250417",
40
- "@aztec/epoch-cache": "0.85.0-nightly.20250417",
41
- "@aztec/ethereum": "0.85.0-nightly.20250417",
42
- "@aztec/foundation": "0.85.0-nightly.20250417",
43
- "@aztec/kv-store": "0.85.0-nightly.20250417",
44
- "@aztec/l1-artifacts": "0.85.0-nightly.20250417",
45
- "@aztec/merkle-tree": "0.85.0-nightly.20250417",
46
- "@aztec/noir-contracts.js": "0.85.0-nightly.20250417",
47
- "@aztec/noir-noirc_abi": "0.85.0-nightly.20250417",
48
- "@aztec/noir-protocol-circuits-types": "0.85.0-nightly.20250417",
49
- "@aztec/p2p": "0.85.0-nightly.20250417",
50
- "@aztec/protocol-contracts": "0.85.0-nightly.20250417",
51
- "@aztec/prover-client": "0.85.0-nightly.20250417",
52
- "@aztec/prover-node": "0.85.0-nightly.20250417",
53
- "@aztec/pxe": "0.85.0-nightly.20250417",
54
- "@aztec/sequencer-client": "0.85.0-nightly.20250417",
55
- "@aztec/simulator": "0.85.0-nightly.20250417",
56
- "@aztec/stdlib": "0.85.0-nightly.20250417",
57
- "@aztec/telemetry-client": "0.85.0-nightly.20250417",
58
- "@aztec/validator-client": "0.85.0-nightly.20250417",
59
- "@aztec/world-state": "0.85.0-nightly.20250417",
28
+ "@aztec/accounts": "0.85.0-nightly.20250420",
29
+ "@aztec/archiver": "0.85.0-nightly.20250420",
30
+ "@aztec/aztec": "0.85.0-nightly.20250420",
31
+ "@aztec/aztec-node": "0.85.0-nightly.20250420",
32
+ "@aztec/aztec.js": "0.85.0-nightly.20250420",
33
+ "@aztec/bb-prover": "0.85.0-nightly.20250420",
34
+ "@aztec/blob-lib": "0.85.0-nightly.20250420",
35
+ "@aztec/blob-sink": "0.85.0-nightly.20250420",
36
+ "@aztec/bot": "0.85.0-nightly.20250420",
37
+ "@aztec/cli": "0.85.0-nightly.20250420",
38
+ "@aztec/constants": "0.85.0-nightly.20250420",
39
+ "@aztec/entrypoints": "0.85.0-nightly.20250420",
40
+ "@aztec/epoch-cache": "0.85.0-nightly.20250420",
41
+ "@aztec/ethereum": "0.85.0-nightly.20250420",
42
+ "@aztec/foundation": "0.85.0-nightly.20250420",
43
+ "@aztec/kv-store": "0.85.0-nightly.20250420",
44
+ "@aztec/l1-artifacts": "0.85.0-nightly.20250420",
45
+ "@aztec/merkle-tree": "0.85.0-nightly.20250420",
46
+ "@aztec/noir-contracts.js": "0.85.0-nightly.20250420",
47
+ "@aztec/noir-noirc_abi": "0.85.0-nightly.20250420",
48
+ "@aztec/noir-protocol-circuits-types": "0.85.0-nightly.20250420",
49
+ "@aztec/p2p": "0.85.0-nightly.20250420",
50
+ "@aztec/protocol-contracts": "0.85.0-nightly.20250420",
51
+ "@aztec/prover-client": "0.85.0-nightly.20250420",
52
+ "@aztec/prover-node": "0.85.0-nightly.20250420",
53
+ "@aztec/pxe": "0.85.0-nightly.20250420",
54
+ "@aztec/sequencer-client": "0.85.0-nightly.20250420",
55
+ "@aztec/simulator": "0.85.0-nightly.20250420",
56
+ "@aztec/stdlib": "0.85.0-nightly.20250420",
57
+ "@aztec/telemetry-client": "0.85.0-nightly.20250420",
58
+ "@aztec/validator-client": "0.85.0-nightly.20250420",
59
+ "@aztec/world-state": "0.85.0-nightly.20250420",
60
60
  "@iarna/toml": "^2.2.5",
61
61
  "@jest/globals": "^29.5.0",
62
- "@msgpack/msgpack": "^3.0.0-beta2",
63
62
  "@noble/curves": "^1.0.0",
64
63
  "@swc/core": "^1.4.11",
65
64
  "@swc/jest": "^0.2.36",
@@ -84,6 +83,7 @@
84
83
  "lodash.compact": "^3.0.1",
85
84
  "lodash.every": "^4.6.0",
86
85
  "lodash.omit": "^4.5.0",
86
+ "msgpackr": "^1.11.2",
87
87
  "process": "^0.11.10",
88
88
  "stream-browserify": "^3.0.0",
89
89
  "string-argv": "^0.3.2",
@@ -5,7 +5,7 @@ import { createLogger, logger } from '@aztec/foundation/log';
5
5
  import { WASMSimulator } from '@aztec/simulator/client';
6
6
  import type { PrivateExecutionStep } from '@aztec/stdlib/kernel';
7
7
 
8
- import { decode } from '@msgpack/msgpack';
8
+ import { Decoder } from 'msgpackr';
9
9
  import assert from 'node:assert';
10
10
  import { readFile, readdir, writeFile } from 'node:fs/promises';
11
11
  import { join } from 'node:path';
@@ -149,9 +149,10 @@ async function main() {
149
149
 
150
150
  for (const flow of flows) {
151
151
  userLog.info(`Processing flow ${flow}`);
152
- const bytecode = await readFile(join(ivcFolder, flow, 'acir.msgpack'));
153
- const acirStack = decode(bytecode) as Buffer[];
152
+ const ivcInputs = await readFile(join(ivcFolder, flow, 'ivc-inputs.msgpack'));
153
+ const stepsFromFile: PrivateExecutionStep[] = new Decoder({ useRecords: false }).unpack(ivcInputs);
154
154
  const witnesses = await readFile(join(ivcFolder, flow, 'witnesses.json'));
155
+
155
156
  const witnessStack = JSON.parse(witnesses.toString()).map((witnessMap: Record<string, string>) => {
156
157
  return new Map<number, string>(Object.entries(witnessMap).map(([k, v]) => [Number(k), v]));
157
158
  });
@@ -160,8 +161,11 @@ async function main() {
160
161
  const privateExecutionSteps: PrivateExecutionStep[] = executionSteps.map((step, i) => ({
161
162
  functionName: step.fnName,
162
163
  gateCount: step.gateCount,
163
- bytecode: acirStack[i],
164
+ bytecode: stepsFromFile[i].bytecode,
165
+ // TODO(AD) do we still want to take this from witness.json?
164
166
  witness: witnessStack[i],
167
+ // This can be left empty. If so, the prover will generate a vk on the fly (~25% slower).
168
+ vk: Buffer.from([]),
165
169
  }));
166
170
  let stats: { duration: number; eventName: string; proofSize: number } | undefined;
167
171
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
@@ -2,7 +2,14 @@ import { getSchnorrWalletWithSecretKey } from '@aztec/accounts/schnorr';
2
2
  import type { InitialAccountData } from '@aztec/accounts/testing';
3
3
  import type { AztecNodeConfig, AztecNodeService } from '@aztec/aztec-node';
4
4
  import type { AccountWalletWithSecretKey } from '@aztec/aztec.js';
5
- import { RollupContract, getExpectedAddress, getL1ContractsConfigEnvVars } from '@aztec/ethereum';
5
+ import {
6
+ L1TxUtils,
7
+ RollupContract,
8
+ type ViemPublicClient,
9
+ type ViemWalletClient,
10
+ getExpectedAddress,
11
+ getL1ContractsConfigEnvVars,
12
+ } from '@aztec/ethereum';
6
13
  import { ChainMonitor, EthCheatCodesWithState } from '@aztec/ethereum/test';
7
14
  import { type Logger, createLogger } from '@aztec/foundation/log';
8
15
  import { ForwarderAbi, ForwarderBytecode, RollupAbi, TestERC20Abi } from '@aztec/l1-artifacts';
@@ -232,13 +239,7 @@ export class P2PNetworkTest {
232
239
  }
233
240
 
234
241
  // Send and await a tx to make sure we mine a block for the warp to correctly progress.
235
- await deployL1ContractsValues.publicClient.waitForTransactionReceipt({
236
- hash: await deployL1ContractsValues.walletClient.sendTransaction({
237
- to: this.baseAccount.address,
238
- value: 1n,
239
- account: this.baseAccount,
240
- }),
241
- });
242
+ await this._sendDummyTx(deployL1ContractsValues.publicClient, deployL1ContractsValues.walletClient);
242
243
 
243
244
  // Set the system time in the node, only after we have warped the time and waited for a block
244
245
  // Time is only set in the NEXT block
@@ -284,13 +285,10 @@ export class P2PNetworkTest {
284
285
  'remove-inital-validator',
285
286
  async ({ deployL1ContractsValues, aztecNode, dateProvider }) => {
286
287
  // Send and await a tx to make sure we mine a block for the warp to correctly progress.
287
- const receipt = await deployL1ContractsValues.publicClient.waitForTransactionReceipt({
288
- hash: await deployL1ContractsValues.walletClient.sendTransaction({
289
- to: this.baseAccount.address,
290
- value: 1n,
291
- account: this.baseAccount,
292
- }),
293
- });
288
+ const { receipt } = await this._sendDummyTx(
289
+ deployL1ContractsValues.publicClient,
290
+ deployL1ContractsValues.walletClient,
291
+ );
294
292
  const block = await deployL1ContractsValues.publicClient.getBlock({
295
293
  blockNumber: receipt.blockNumber,
296
294
  });
@@ -301,6 +299,21 @@ export class P2PNetworkTest {
301
299
  );
302
300
  }
303
301
 
302
+ async sendDummyTx() {
303
+ return await this._sendDummyTx(
304
+ this.ctx.deployL1ContractsValues.publicClient,
305
+ this.ctx.deployL1ContractsValues.walletClient,
306
+ );
307
+ }
308
+
309
+ private async _sendDummyTx(publicClient: ViemPublicClient, walletClient: ViemWalletClient) {
310
+ const l1TxUtils = new L1TxUtils(publicClient, walletClient);
311
+ return await l1TxUtils.sendAndMonitorTransaction({
312
+ to: walletClient.account!.address,
313
+ value: 1n,
314
+ });
315
+ }
316
+
304
317
  async setup() {
305
318
  this.ctx = await this.snapshotManager.setup();
306
319
 
@@ -308,7 +308,7 @@ export class FullProverTest {
308
308
  },
309
309
  { prefilledPublicData },
310
310
  );
311
- this.proverNode.start();
311
+ await this.proverNode.start();
312
312
 
313
313
  this.logger.warn(`Proofs are now enabled`);
314
314
  return this;
@@ -828,7 +828,7 @@ export async function createAndSyncProverNode(
828
828
  { prefilledPublicData },
829
829
  );
830
830
  getLogger().info(`Created and synced prover node`, { publisherAddress: l1TxUtils.walletClient.account.address });
831
- proverNode.start();
831
+ await proverNode.start();
832
832
  return proverNode;
833
833
  }
834
834
 
@@ -9,30 +9,13 @@ import type {
9
9
  ProfileMethodOptions,
10
10
  } from '@aztec/aztec.js/contracts';
11
11
  import { createLogger } from '@aztec/foundation/log';
12
- import { serializeWitness } from '@aztec/noir-noirc_abi';
13
- import type { PrivateExecutionStep } from '@aztec/stdlib/kernel';
12
+ import { serializePrivateExecutionSteps } from '@aztec/stdlib/kernel';
14
13
 
15
- import { encode } from '@msgpack/msgpack';
16
14
  import { promises as fs } from 'fs';
17
15
  import path from 'path';
18
16
 
19
17
  const logger = createLogger('e2e:capture-private-execution-steps');
20
18
 
21
- // TODO(#7371): This is duplicated.
22
- // Longer term we won't use this hacked together msgpack format
23
- // Leaving duplicated as this eventually bb will provide a serialization
24
- // helper for passing to a generic msgpack RPC endpoint.
25
- async function _createClientIvcProofFiles(directory: string, executionSteps: PrivateExecutionStep[]) {
26
- const acirPath = path.join(directory, 'acir.msgpack');
27
- const witnessPath = path.join(directory, 'witnesses.msgpack');
28
- await fs.writeFile(acirPath, encode(executionSteps.map(map => map.bytecode)));
29
- await fs.writeFile(witnessPath, encode(executionSteps.map(map => serializeWitness(map.witness))));
30
- return {
31
- acirPath,
32
- witnessPath,
33
- };
34
- }
35
-
36
19
  export async function capturePrivateExecutionStepsIfEnvSet(
37
20
  label: string,
38
21
  interaction: ContractFunctionInteraction | DeployMethod,
@@ -56,7 +39,8 @@ export async function capturePrivateExecutionStepsIfEnvSet(
56
39
  logger.info(`Writing private execution steps to ${resultsDirectory}`);
57
40
  await fs.mkdir(resultsDirectory, { recursive: true });
58
41
  // Write the client IVC files read by the prover.
59
- await _createClientIvcProofFiles(resultsDirectory, result.executionSteps);
42
+ const ivcInputsPath = path.join(resultsDirectory, 'ivc-inputs.msgpack');
43
+ await fs.writeFile(ivcInputsPath, serializePrivateExecutionSteps(result.executionSteps));
60
44
  if (profileMode === 'full') {
61
45
  // If we have gate counts, write the steps in human-readable format.
62
46
  await fs.writeFile(