@aztec/ethereum 0.0.1-commit.7b97ef96e → 0.0.1-commit.7cbc774
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/dest/client.d.ts +16 -2
- package/dest/client.d.ts.map +1 -1
- package/dest/client.js +27 -7
- package/dest/config.d.ts +8 -6
- package/dest/config.d.ts.map +1 -1
- package/dest/config.js +11 -9
- package/dest/contracts/chain_state_override.d.ts +78 -0
- package/dest/contracts/chain_state_override.d.ts.map +1 -0
- package/dest/contracts/chain_state_override.js +137 -0
- package/dest/contracts/empire_base.d.ts +1 -3
- package/dest/contracts/empire_base.d.ts.map +1 -1
- package/dest/contracts/fee_asset_price_oracle.d.ts +6 -2
- package/dest/contracts/fee_asset_price_oracle.d.ts.map +1 -1
- package/dest/contracts/fee_asset_price_oracle.js +11 -6
- package/dest/contracts/governance.d.ts +108 -33
- package/dest/contracts/governance.d.ts.map +1 -1
- package/dest/contracts/governance.js +193 -12
- package/dest/contracts/governance_proposer.d.ts +33 -3
- package/dest/contracts/governance_proposer.d.ts.map +1 -1
- package/dest/contracts/governance_proposer.js +51 -9
- package/dest/contracts/inbox.d.ts +3 -3
- package/dest/contracts/inbox.d.ts.map +1 -1
- package/dest/contracts/inbox.js +12 -7
- package/dest/contracts/index.d.ts +3 -3
- package/dest/contracts/index.d.ts.map +1 -1
- package/dest/contracts/index.js +2 -2
- package/dest/contracts/multicall.d.ts +127 -12
- package/dest/contracts/multicall.d.ts.map +1 -1
- package/dest/contracts/multicall.js +201 -94
- package/dest/contracts/outbox.d.ts +21 -4
- package/dest/contracts/outbox.d.ts.map +1 -1
- package/dest/contracts/outbox.js +29 -6
- package/dest/contracts/registry.d.ts +3 -1
- package/dest/contracts/registry.d.ts.map +1 -1
- package/dest/contracts/registry.js +30 -1
- package/dest/contracts/rollup.d.ts +5258 -29
- package/dest/contracts/rollup.d.ts.map +1 -1
- package/dest/contracts/rollup.js +362 -69
- package/dest/contracts/{tally_slashing_proposer.d.ts → slashing_proposer.d.ts} +3 -4
- package/dest/contracts/slashing_proposer.d.ts.map +1 -0
- package/dest/contracts/{tally_slashing_proposer.js → slashing_proposer.js} +13 -15
- package/dest/deploy_aztec_l1_contracts.d.ts +3 -6
- package/dest/deploy_aztec_l1_contracts.d.ts.map +1 -1
- package/dest/deploy_aztec_l1_contracts.js +2 -4
- package/dest/generated/l1-contracts-defaults.d.ts +2 -2
- package/dest/generated/l1-contracts-defaults.js +2 -2
- package/dest/l1_artifacts.d.ts +13409 -15883
- package/dest/l1_artifacts.d.ts.map +1 -1
- package/dest/l1_artifacts.js +9 -24
- package/dest/l1_contract_addresses.d.ts +61 -65
- package/dest/l1_contract_addresses.d.ts.map +1 -1
- package/dest/l1_contract_addresses.js +101 -82
- package/dest/l1_reader.d.ts +5 -5
- package/dest/l1_reader.d.ts.map +1 -1
- package/dest/l1_reader.js +9 -7
- package/dest/l1_tx_utils/l1_tx_utils.d.ts +12 -3
- package/dest/l1_tx_utils/l1_tx_utils.d.ts.map +1 -1
- package/dest/l1_tx_utils/l1_tx_utils.js +61 -60
- package/dest/l1_tx_utils/readonly_l1_tx_utils.d.ts +1 -1
- package/dest/l1_tx_utils/readonly_l1_tx_utils.d.ts.map +1 -1
- package/dest/l1_tx_utils/readonly_l1_tx_utils.js +8 -4
- package/dest/l1_tx_utils/tx_delayer.d.ts +5 -3
- package/dest/l1_tx_utils/tx_delayer.d.ts.map +1 -1
- package/dest/l1_tx_utils/tx_delayer.js +7 -5
- package/dest/publisher_manager.d.ts +21 -7
- package/dest/publisher_manager.d.ts.map +1 -1
- package/dest/publisher_manager.js +81 -7
- package/dest/queries.d.ts +13 -2
- package/dest/queries.d.ts.map +1 -1
- package/dest/queries.js +62 -3
- package/dest/test/chain_monitor.d.ts +23 -3
- package/dest/test/chain_monitor.d.ts.map +1 -1
- package/dest/test/chain_monitor.js +38 -2
- package/dest/test/eth_cheat_codes.d.ts +12 -4
- package/dest/test/eth_cheat_codes.d.ts.map +1 -1
- package/dest/test/eth_cheat_codes.js +17 -4
- package/dest/test/rollup_cheat_codes.d.ts +31 -3
- package/dest/test/rollup_cheat_codes.d.ts.map +1 -1
- package/dest/test/rollup_cheat_codes.js +59 -7
- package/dest/test/start_anvil.d.ts +23 -3
- package/dest/test/start_anvil.d.ts.map +1 -1
- package/dest/test/start_anvil.js +143 -29
- package/dest/utils.d.ts +8 -1
- package/dest/utils.d.ts.map +1 -1
- package/dest/utils.js +35 -12
- package/package.json +6 -8
- package/src/client.ts +28 -2
- package/src/config.ts +21 -13
- package/src/contracts/chain_state_override.ts +200 -0
- package/src/contracts/empire_base.ts +0 -2
- package/src/contracts/fee_asset_price_oracle.ts +10 -5
- package/src/contracts/governance.ts +266 -9
- package/src/contracts/governance_proposer.ts +52 -5
- package/src/contracts/inbox.ts +13 -5
- package/src/contracts/index.ts +2 -2
- package/src/contracts/multicall.ts +243 -105
- package/src/contracts/outbox.ts +38 -8
- package/src/contracts/registry.ts +31 -1
- package/src/contracts/rollup.ts +411 -79
- package/src/contracts/{tally_slashing_proposer.ts → slashing_proposer.ts} +14 -16
- package/src/deploy_aztec_l1_contracts.ts +1 -5
- package/src/generated/l1-contracts-defaults.ts +2 -2
- package/src/l1_artifacts.ts +12 -35
- package/src/l1_contract_addresses.ts +120 -94
- package/src/l1_reader.ts +17 -10
- package/src/l1_tx_utils/l1_tx_utils.ts +58 -42
- package/src/l1_tx_utils/readonly_l1_tx_utils.ts +8 -4
- package/src/l1_tx_utils/tx_delayer.ts +16 -7
- package/src/publisher_manager.ts +105 -10
- package/src/queries.ts +70 -4
- package/src/test/chain_monitor.ts +65 -3
- package/src/test/eth_cheat_codes.ts +16 -4
- package/src/test/rollup_cheat_codes.ts +64 -6
- package/src/test/start_anvil.ts +177 -29
- package/src/utils.ts +35 -14
- package/dest/contracts/empire_slashing_proposer.d.ts +0 -69
- package/dest/contracts/empire_slashing_proposer.d.ts.map +0 -1
- package/dest/contracts/empire_slashing_proposer.js +0 -216
- package/dest/contracts/tally_slashing_proposer.d.ts.map +0 -1
- package/src/contracts/empire_slashing_proposer.ts +0 -265
|
@@ -85,14 +85,26 @@ export class EthCheatCodes {
|
|
|
85
85
|
}
|
|
86
86
|
|
|
87
87
|
/**
|
|
88
|
-
* Get the
|
|
89
|
-
*
|
|
88
|
+
* Get the timestamp of the latest mined L1 block.
|
|
89
|
+
* Note: this is NOT the current time — it's the discrete timestamp of the last block.
|
|
90
|
+
* Between blocks, the actual chain time advances but no new block reflects it.
|
|
91
|
+
* @returns The latest block timestamp in seconds
|
|
90
92
|
*/
|
|
91
|
-
public async
|
|
93
|
+
public async lastBlockTimestamp(): Promise<number> {
|
|
92
94
|
const res = await this.doRpcCall('eth_getBlockByNumber', ['latest', true]);
|
|
93
95
|
return parseInt(res.timestamp, 16);
|
|
94
96
|
}
|
|
95
97
|
|
|
98
|
+
/**
|
|
99
|
+
* Get the timestamp of the pending L1 block — the block that anvil will mine next.
|
|
100
|
+
* Reflects any prior `setNextBlockTimestamp` call or the configured block interval.
|
|
101
|
+
* @returns The pending block timestamp in seconds.
|
|
102
|
+
*/
|
|
103
|
+
public async nextBlockTimestamp(): Promise<number> {
|
|
104
|
+
const res = await this.doRpcCall('eth_getBlockByNumber', ['pending', false]);
|
|
105
|
+
return parseInt(res.timestamp, 16);
|
|
106
|
+
}
|
|
107
|
+
|
|
96
108
|
/**
|
|
97
109
|
* Advance the chain by a number of blocks
|
|
98
110
|
* @param numberOfBlocks - The number of blocks to mine
|
|
@@ -552,7 +564,7 @@ export class EthCheatCodes {
|
|
|
552
564
|
}
|
|
553
565
|
|
|
554
566
|
public async syncDateProvider() {
|
|
555
|
-
const timestamp = await this.
|
|
567
|
+
const timestamp = await this.lastBlockTimestamp();
|
|
556
568
|
if ('setTime' in this.dateProvider) {
|
|
557
569
|
this.dateProvider.setTime(timestamp * 1000);
|
|
558
570
|
}
|
|
@@ -15,6 +15,7 @@ import {
|
|
|
15
15
|
getContract,
|
|
16
16
|
hexToBigInt,
|
|
17
17
|
http,
|
|
18
|
+
keccak256,
|
|
18
19
|
} from 'viem';
|
|
19
20
|
|
|
20
21
|
import { EthCheatCodes } from './eth_cheat_codes.js';
|
|
@@ -53,7 +54,17 @@ export class RollupCheatCodes {
|
|
|
53
54
|
/** Returns the current slot */
|
|
54
55
|
public async getSlot(): Promise<SlotNumber> {
|
|
55
56
|
const ts = BigInt((await this.client.getBlock()).timestamp);
|
|
56
|
-
return
|
|
57
|
+
return this.getSlotAt(ts);
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/** Returns the slot number at a given timestamp. */
|
|
61
|
+
public async getSlotAt(timestamp: bigint): Promise<SlotNumber> {
|
|
62
|
+
return SlotNumber.fromBigInt(await this.rollup.read.getSlotAt([timestamp]));
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
/** Returns the timestamp for the start of a given slot. */
|
|
66
|
+
public async getTimestampForSlot(slot: SlotNumber): Promise<bigint> {
|
|
67
|
+
return await this.rollup.read.getTimestampForSlot([BigInt(slot)]);
|
|
57
68
|
}
|
|
58
69
|
|
|
59
70
|
/** Returns the number of seconds until the start of the given slot based on L1 block timestamp. */
|
|
@@ -168,6 +179,21 @@ export class RollupCheatCodes {
|
|
|
168
179
|
return [timestamp, nextSlot];
|
|
169
180
|
}
|
|
170
181
|
|
|
182
|
+
/**
|
|
183
|
+
* Warps L1 time to the start of an explicit absolute slot. Unlike `advanceSlots(N)` which is
|
|
184
|
+
* relative to the current L1 timestamp at call time and therefore races with real-time
|
|
185
|
+
* progression between query and warp, this lands at the slot regardless of latency.
|
|
186
|
+
*
|
|
187
|
+
* Throws if the requested slot is in the past relative to current L1 time (anvil cannot
|
|
188
|
+
* rewind).
|
|
189
|
+
*/
|
|
190
|
+
public async advanceToSlot(slot: SlotNumber) {
|
|
191
|
+
const timestamp = await this.rollup.read.getTimestampForSlot([BigInt(slot)]);
|
|
192
|
+
await this.ethCheatCodes.warp(Number(timestamp), { silent: true, resetBlockInterval: true });
|
|
193
|
+
this.logger.warn(`Advanced to slot ${slot}`, { timestamp });
|
|
194
|
+
return timestamp;
|
|
195
|
+
}
|
|
196
|
+
|
|
171
197
|
/**
|
|
172
198
|
* Warps time in L1 equivalent to however many slots.
|
|
173
199
|
* @param howMany - The number of slots to advance.
|
|
@@ -259,12 +285,14 @@ export class RollupCheatCodes {
|
|
|
259
285
|
});
|
|
260
286
|
}
|
|
261
287
|
|
|
262
|
-
public insertOutbox(epoch: EpochNumber, outHash: bigint) {
|
|
288
|
+
public insertOutbox(epoch: EpochNumber, numCheckpointsInEpoch: number, outHash: bigint) {
|
|
263
289
|
return this.ethCheatCodes.execWithPausedAnvil(async () => {
|
|
264
290
|
const outboxAddress = await this.rollup.read.getOutbox();
|
|
265
|
-
const epochRootSlot = OutboxContract.getEpochRootStorageSlot(epoch);
|
|
291
|
+
const epochRootSlot = OutboxContract.getEpochRootStorageSlot(epoch, numCheckpointsInEpoch);
|
|
266
292
|
await this.ethCheatCodes.store(EthAddress.fromString(outboxAddress), epochRootSlot, outHash);
|
|
267
|
-
this.logger.warn(
|
|
293
|
+
this.logger.warn(
|
|
294
|
+
`Advanced outbox to epoch ${epoch} numCheckpointsInEpoch ${numCheckpointsInEpoch} with out hash ${outHash}`,
|
|
295
|
+
);
|
|
268
296
|
});
|
|
269
297
|
}
|
|
270
298
|
|
|
@@ -313,7 +341,8 @@ export class RollupCheatCodes {
|
|
|
313
341
|
}
|
|
314
342
|
|
|
315
343
|
/**
|
|
316
|
-
* Directly updates proving cost per mana.
|
|
344
|
+
* Directly updates proving cost per mana. Throws if the on-chain tx reverts
|
|
345
|
+
* (e.g. rate-limit cooldown, step cap, or floor) instead of silently succeeding.
|
|
317
346
|
* @param ethValue - The new proving cost per mana in ETH
|
|
318
347
|
*/
|
|
319
348
|
public async setProvingCostPerMana(ethValue: bigint) {
|
|
@@ -323,8 +352,37 @@ export class RollupCheatCodes {
|
|
|
323
352
|
chain: this.client.chain,
|
|
324
353
|
gasLimit: 1000000n,
|
|
325
354
|
});
|
|
326
|
-
await this.client.waitForTransactionReceipt({ hash });
|
|
355
|
+
const receipt = await this.client.waitForTransactionReceipt({ hash });
|
|
356
|
+
if (receipt.status !== 'success') {
|
|
357
|
+
throw new Error(
|
|
358
|
+
`setProvingCostPerMana(${ethValue}) reverted on L1 (tx ${hash}). ` +
|
|
359
|
+
`Likely FeeLib rate-limit (30-day cooldown or 1.5x step cap); ` +
|
|
360
|
+
`use clearProvingCostCooldown() between successive updates.`,
|
|
361
|
+
);
|
|
362
|
+
}
|
|
327
363
|
this.logger.warn(`Updated proving cost per mana to ${ethValue}`);
|
|
328
364
|
});
|
|
329
365
|
}
|
|
366
|
+
|
|
367
|
+
/**
|
|
368
|
+
* Resets the 30-day proving-cost update cooldown enforced by FeeLib.updateProvingCostPerMana
|
|
369
|
+
* by zeroing `FeeStore.provingCostLastUpdate` directly in contract storage. Use between
|
|
370
|
+
* successive setProvingCostPerMana / bumpProvingCostPerMana calls so the later update can
|
|
371
|
+
* land instead of reverting. Does not touch L1 time, so PXE/tx-expiration state stays intact.
|
|
372
|
+
*
|
|
373
|
+
* @note This is tightly coupled to the `FeeStore` layout in
|
|
374
|
+
* l1-contracts/src/core/libraries/rollup/FeeLib.sol:
|
|
375
|
+
* slot + 0: CompressedFeeConfig config (uint256)
|
|
376
|
+
* slot + 1: L1GasOracleValues l1GasOracleValues (14+14+4 bytes, packed)
|
|
377
|
+
* slot + 2: uint64 provingCostLastUpdate (only member — zeroing the slot is safe)
|
|
378
|
+
* If the struct layout changes, update the offset below.
|
|
379
|
+
*/
|
|
380
|
+
public async clearProvingCostCooldown() {
|
|
381
|
+
const feeStoreBaseSlot = hexToBigInt(keccak256(Buffer.from('aztec.fee.storage', 'utf-8')));
|
|
382
|
+
const provingCostLastUpdateSlot = feeStoreBaseSlot + 2n;
|
|
383
|
+
await this.ethCheatCodes.store(EthAddress.fromString(this.rollup.address), provingCostLastUpdateSlot, 0n, {
|
|
384
|
+
silent: true,
|
|
385
|
+
});
|
|
386
|
+
this.logger.warn(`Cleared proving-cost update cooldown`);
|
|
387
|
+
}
|
|
330
388
|
}
|
package/src/test/start_anvil.ts
CHANGED
|
@@ -1,10 +1,19 @@
|
|
|
1
1
|
import { createLogger } from '@aztec/foundation/log';
|
|
2
2
|
import { makeBackoff, retry } from '@aztec/foundation/retry';
|
|
3
|
+
import type { TestDateProvider } from '@aztec/foundation/timer';
|
|
3
4
|
import { fileURLToPath } from '@aztec/foundation/url';
|
|
4
5
|
|
|
5
|
-
import { type
|
|
6
|
+
import { type ChildProcess, spawn } from 'child_process';
|
|
6
7
|
import { dirname, resolve } from 'path';
|
|
7
8
|
|
|
9
|
+
/** Minimal interface matching the @viem/anvil Anvil shape used by callers. */
|
|
10
|
+
export interface Anvil {
|
|
11
|
+
readonly port: number;
|
|
12
|
+
readonly host: string;
|
|
13
|
+
readonly status: 'listening' | 'idle';
|
|
14
|
+
stop(): Promise<void>;
|
|
15
|
+
}
|
|
16
|
+
|
|
8
17
|
/**
|
|
9
18
|
* Ensures there's a running Anvil instance and returns the RPC URL.
|
|
10
19
|
*/
|
|
@@ -16,56 +25,195 @@ export async function startAnvil(
|
|
|
16
25
|
captureMethodCalls?: boolean;
|
|
17
26
|
accounts?: number;
|
|
18
27
|
chainId?: number;
|
|
19
|
-
/** The hardfork to use
|
|
28
|
+
/** The hardfork to use (e.g. 'cancun', 'latest'). */
|
|
20
29
|
hardfork?: string;
|
|
30
|
+
/**
|
|
31
|
+
* Number of slots per epoch used by anvil to compute the 'finalized' and 'safe' block tags.
|
|
32
|
+
* Anvil reports `finalized = latest - slotsInAnEpoch * 2`.
|
|
33
|
+
* Defaults to 1 so the finalized block advances immediately, making tests that check
|
|
34
|
+
* L1-finality-based logic work without needing hundreds of mined blocks.
|
|
35
|
+
*/
|
|
36
|
+
slotsInAnEpoch?: number;
|
|
37
|
+
/**
|
|
38
|
+
* If provided, the date provider will be synced to anvil's block time on every mined block.
|
|
39
|
+
* This keeps the dateProvider in lockstep with anvil's chain time, avoiding drift between
|
|
40
|
+
* the wall clock and the L1 chain when computing L1 slot timestamps.
|
|
41
|
+
*/
|
|
42
|
+
dateProvider?: TestDateProvider;
|
|
21
43
|
} = {},
|
|
22
44
|
): Promise<{ anvil: Anvil; methodCalls?: string[]; rpcUrl: string; stop: () => Promise<void> }> {
|
|
23
45
|
const anvilBinary = resolve(dirname(fileURLToPath(import.meta.url)), '../../', 'scripts/anvil_kill_wrapper.sh');
|
|
24
46
|
const logger = opts.log ? createLogger('ethereum:anvil') : undefined;
|
|
25
47
|
const methodCalls = opts.captureMethodCalls ? ([] as string[]) : undefined;
|
|
26
48
|
|
|
27
|
-
let
|
|
49
|
+
let detectedPort: number | undefined;
|
|
28
50
|
|
|
29
|
-
// Start anvil.
|
|
30
|
-
// We go via a wrapper script to ensure if the parent dies, anvil dies.
|
|
31
51
|
const anvil = await retry(
|
|
32
52
|
async () => {
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
host
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
accounts
|
|
40
|
-
|
|
41
|
-
|
|
53
|
+
const port = opts.port ?? (process.env.ANVIL_PORT ? parseInt(process.env.ANVIL_PORT) : 8545);
|
|
54
|
+
const args: string[] = [
|
|
55
|
+
'--host',
|
|
56
|
+
'127.0.0.1',
|
|
57
|
+
'--port',
|
|
58
|
+
String(port),
|
|
59
|
+
'--accounts',
|
|
60
|
+
String(opts.accounts ?? 20),
|
|
61
|
+
'--gas-limit',
|
|
62
|
+
String(45_000_000),
|
|
63
|
+
'--chain-id',
|
|
64
|
+
String(opts.chainId ?? 31337),
|
|
65
|
+
];
|
|
66
|
+
if (opts.l1BlockTime !== undefined) {
|
|
67
|
+
args.push('--block-time', String(opts.l1BlockTime));
|
|
68
|
+
}
|
|
69
|
+
if (opts.hardfork !== undefined) {
|
|
70
|
+
args.push('--hardfork', opts.hardfork);
|
|
71
|
+
}
|
|
72
|
+
args.push('--slots-in-an-epoch', String(opts.slotsInAnEpoch ?? 1));
|
|
73
|
+
|
|
74
|
+
const child = spawn(anvilBinary, args, {
|
|
75
|
+
stdio: ['ignore', 'pipe', 'pipe'],
|
|
76
|
+
env: { ...process.env, RAYON_NUM_THREADS: '1' },
|
|
42
77
|
});
|
|
43
78
|
|
|
44
|
-
//
|
|
45
|
-
|
|
46
|
-
|
|
79
|
+
// Wait for "Listening on" or an early exit.
|
|
80
|
+
await new Promise<void>((resolve, reject) => {
|
|
81
|
+
let stderr = '';
|
|
82
|
+
|
|
83
|
+
const onStdout = (data: Buffer) => {
|
|
84
|
+
const text = data.toString();
|
|
85
|
+
logger?.debug(text.trim());
|
|
86
|
+
methodCalls?.push(...(text.match(/eth_[^\s]+/g) || []));
|
|
87
|
+
|
|
88
|
+
if (detectedPort === undefined && text.includes('Listening on')) {
|
|
89
|
+
const match = text.match(/Listening on ([^:]+):(\d+)/);
|
|
90
|
+
if (match) {
|
|
91
|
+
detectedPort = parseInt(match[2]);
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
if (detectedPort !== undefined) {
|
|
95
|
+
child.stdout?.removeListener('data', onStdout);
|
|
96
|
+
child.stderr?.removeListener('data', onStderr);
|
|
97
|
+
child.removeListener('close', onClose);
|
|
98
|
+
resolve();
|
|
99
|
+
}
|
|
100
|
+
};
|
|
47
101
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
}
|
|
102
|
+
const onStderr = (data: Buffer) => {
|
|
103
|
+
stderr += data.toString();
|
|
104
|
+
logger?.debug(data.toString().trim());
|
|
105
|
+
};
|
|
106
|
+
|
|
107
|
+
const onClose = (code: number | null) => {
|
|
108
|
+
child.stdout?.removeListener('data', onStdout);
|
|
109
|
+
child.stderr?.removeListener('data', onStderr);
|
|
110
|
+
reject(new Error(`Anvil exited with code ${code} before listening. stderr: ${stderr}`));
|
|
111
|
+
};
|
|
112
|
+
|
|
113
|
+
child.stdout?.on('data', onStdout);
|
|
114
|
+
child.stderr?.on('data', onStderr);
|
|
115
|
+
child.once('close', onClose);
|
|
52
116
|
});
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
117
|
+
|
|
118
|
+
// Continue piping for logging, method-call capture, and/or dateProvider sync after startup.
|
|
119
|
+
if (logger || opts.captureMethodCalls || opts.dateProvider) {
|
|
120
|
+
child.stdout?.on('data', (data: Buffer) => {
|
|
121
|
+
const text = data.toString();
|
|
122
|
+
logger?.debug(text.trim());
|
|
123
|
+
methodCalls?.push(...(text.match(/eth_[^\s]+/g) || []));
|
|
124
|
+
if (opts.dateProvider) {
|
|
125
|
+
syncDateProviderFromAnvilOutput(text, opts.dateProvider);
|
|
126
|
+
}
|
|
127
|
+
});
|
|
128
|
+
child.stderr?.on('data', (data: Buffer) => {
|
|
129
|
+
logger?.debug(data.toString().trim());
|
|
130
|
+
});
|
|
131
|
+
} else {
|
|
132
|
+
// Consume streams so the child process doesn't block on full pipe buffers.
|
|
133
|
+
child.stdout?.resume();
|
|
134
|
+
child.stderr?.resume();
|
|
56
135
|
}
|
|
57
136
|
|
|
58
|
-
return
|
|
137
|
+
return child;
|
|
59
138
|
},
|
|
60
139
|
'Start anvil',
|
|
61
140
|
makeBackoff([5, 5, 5]),
|
|
62
141
|
);
|
|
63
142
|
|
|
64
|
-
if (!
|
|
143
|
+
if (!detectedPort) {
|
|
65
144
|
throw new Error('Failed to start anvil');
|
|
66
145
|
}
|
|
67
146
|
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
147
|
+
const port = detectedPort;
|
|
148
|
+
let status: 'listening' | 'idle' = 'listening';
|
|
149
|
+
|
|
150
|
+
anvil.once('close', () => {
|
|
151
|
+
status = 'idle';
|
|
152
|
+
});
|
|
153
|
+
|
|
154
|
+
const stop = async () => {
|
|
155
|
+
if (status === 'idle') {
|
|
156
|
+
return;
|
|
157
|
+
}
|
|
158
|
+
await killChild(anvil);
|
|
159
|
+
};
|
|
160
|
+
|
|
161
|
+
const anvilObj: Anvil = {
|
|
162
|
+
port,
|
|
163
|
+
host: '127.0.0.1',
|
|
164
|
+
get status() {
|
|
165
|
+
return status;
|
|
166
|
+
},
|
|
167
|
+
stop,
|
|
168
|
+
};
|
|
169
|
+
|
|
170
|
+
return { anvil: anvilObj, methodCalls, stop, rpcUrl: `http://127.0.0.1:${port}` };
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
/** Extracts block time from anvil stdout and syncs the dateProvider. */
|
|
174
|
+
function syncDateProviderFromAnvilOutput(text: string, dateProvider: TestDateProvider): void {
|
|
175
|
+
// Anvil logs mined blocks as:
|
|
176
|
+
// Block Time: "Fri, 20 Mar 2026 02:10:46 +0000"
|
|
177
|
+
const match = text.match(/Block Time:\s*"([^"]+)"/);
|
|
178
|
+
if (match) {
|
|
179
|
+
const blockTimeMs = new Date(match[1]).getTime();
|
|
180
|
+
if (!isNaN(blockTimeMs)) {
|
|
181
|
+
dateProvider.setTime(blockTimeMs);
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
/** Send SIGTERM, wait up to 5 s, then SIGKILL. All timers are always cleared. */
|
|
187
|
+
function killChild(child: ChildProcess): Promise<void> {
|
|
188
|
+
return new Promise<void>(resolve => {
|
|
189
|
+
if (child.exitCode !== null || child.killed) {
|
|
190
|
+
child.stdout?.destroy();
|
|
191
|
+
child.stderr?.destroy();
|
|
192
|
+
resolve();
|
|
193
|
+
return;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
let killTimer: NodeJS.Timeout | undefined;
|
|
197
|
+
|
|
198
|
+
const onClose = () => {
|
|
199
|
+
if (killTimer !== undefined) {
|
|
200
|
+
clearTimeout(killTimer);
|
|
201
|
+
}
|
|
202
|
+
// Destroy stdio streams so their PipeWrap handles don't keep the event loop alive.
|
|
203
|
+
child.stdout?.destroy();
|
|
204
|
+
child.stderr?.destroy();
|
|
205
|
+
resolve();
|
|
206
|
+
};
|
|
207
|
+
|
|
208
|
+
child.once('close', onClose);
|
|
209
|
+
child.kill('SIGTERM');
|
|
210
|
+
|
|
211
|
+
killTimer = setTimeout(() => {
|
|
212
|
+
killTimer = undefined;
|
|
213
|
+
child.kill('SIGKILL');
|
|
214
|
+
}, 5000);
|
|
215
|
+
|
|
216
|
+
// Ensure the timer does not prevent Node from exiting.
|
|
217
|
+
killTimer.unref();
|
|
218
|
+
});
|
|
71
219
|
}
|
package/src/utils.ts
CHANGED
|
@@ -170,6 +170,21 @@ function getNestedErrorData(error: unknown): string | undefined {
|
|
|
170
170
|
return undefined;
|
|
171
171
|
}
|
|
172
172
|
|
|
173
|
+
/**
|
|
174
|
+
* Truncates an error message to a safe length for log renderers.
|
|
175
|
+
* LogExplorer can only render up to 2500 characters in its summary view.
|
|
176
|
+
* We cap at 2000 to leave room for decorating context added by callers.
|
|
177
|
+
*/
|
|
178
|
+
function truncateErrorMessage(message: string): string {
|
|
179
|
+
const MAX = 2000;
|
|
180
|
+
const CHUNK = 950;
|
|
181
|
+
if (message.length <= MAX) {
|
|
182
|
+
return message;
|
|
183
|
+
}
|
|
184
|
+
const truncated = message.length - 2 * CHUNK;
|
|
185
|
+
return message.slice(0, CHUNK) + `...${truncated} characters truncated...` + message.slice(-CHUNK);
|
|
186
|
+
}
|
|
187
|
+
|
|
173
188
|
/**
|
|
174
189
|
* Formats a Viem error into a FormattedViemError instance.
|
|
175
190
|
* @param error - The error to format.
|
|
@@ -232,22 +247,10 @@ export function formatViemError(error: any, abi: Abi = ErrorsAbi): FormattedViem
|
|
|
232
247
|
|
|
233
248
|
// If it's a regular Error instance, return it with its message
|
|
234
249
|
if (error instanceof Error) {
|
|
235
|
-
return new FormattedViemError(error.message, (error as any)?.metaMessages);
|
|
250
|
+
return new FormattedViemError(truncateErrorMessage(error.message), (error as any)?.metaMessages);
|
|
236
251
|
}
|
|
237
252
|
|
|
238
|
-
|
|
239
|
-
const length = body.length;
|
|
240
|
-
// LogExplorer can only render up to 2500 characters in it's summary view. Try to keep the whole message below this number
|
|
241
|
-
// Limit the error to 2000 chacaters in order to allow code higher up to decorate this error with extra details (up to 500 characters)
|
|
242
|
-
if (length > 2000) {
|
|
243
|
-
const chunk = 950;
|
|
244
|
-
const truncated = length - 2 * chunk;
|
|
245
|
-
return new FormattedViemError(
|
|
246
|
-
body.slice(0, chunk) + `...${truncated} characters truncated...` + body.slice(-1 * chunk),
|
|
247
|
-
);
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
return new FormattedViemError(body);
|
|
253
|
+
return new FormattedViemError(truncateErrorMessage(String(error)));
|
|
251
254
|
}
|
|
252
255
|
|
|
253
256
|
function stripAbis(obj: any) {
|
|
@@ -273,6 +276,24 @@ function stripAbis(obj: any) {
|
|
|
273
276
|
});
|
|
274
277
|
}
|
|
275
278
|
|
|
279
|
+
/**
|
|
280
|
+
* Best-effort decode of a raw revert payload (`0x...`) against an ABI.
|
|
281
|
+
* Returns a human-readable `ErrorName(arg1, arg2, ...)` string, or `undefined` if the selector
|
|
282
|
+
* is unknown or the payload is empty. Use to surface decoded error names alongside the raw
|
|
283
|
+
* payload in log lines for operators.
|
|
284
|
+
*/
|
|
285
|
+
export function tryDecodeRevertReason(data: Hex | undefined, abi: Abi): string | undefined {
|
|
286
|
+
if (!data || data === '0x') {
|
|
287
|
+
return undefined;
|
|
288
|
+
}
|
|
289
|
+
try {
|
|
290
|
+
const decoded = decodeErrorResult({ abi, data });
|
|
291
|
+
return `${decoded.errorName}(${decoded.args?.join(', ') ?? ''})`;
|
|
292
|
+
} catch {
|
|
293
|
+
return undefined;
|
|
294
|
+
}
|
|
295
|
+
}
|
|
296
|
+
|
|
276
297
|
export function tryGetCustomErrorName(err: any) {
|
|
277
298
|
try {
|
|
278
299
|
// See https://viem.sh/docs/contract/simulateContract#handling-custom-errors
|
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
import { SlotNumber } from '@aztec/foundation/branded-types';
|
|
2
|
-
import { EthAddress } from '@aztec/foundation/eth-address';
|
|
3
|
-
import EventEmitter from 'events';
|
|
4
|
-
import { type Hex, type Log, type TypedDataDefinition } from 'viem';
|
|
5
|
-
import type { L1TxRequest, L1TxUtils } from '../l1_tx_utils/index.js';
|
|
6
|
-
import type { ViemClient } from '../types.js';
|
|
7
|
-
import { type IEmpireBase } from './empire_base.js';
|
|
8
|
-
export declare class ProposalAlreadyExecutedError extends Error {
|
|
9
|
-
constructor(round: bigint);
|
|
10
|
-
}
|
|
11
|
-
export declare class EmpireSlashingProposerContract extends EventEmitter implements IEmpireBase {
|
|
12
|
-
readonly client: ViemClient;
|
|
13
|
-
private readonly logger;
|
|
14
|
-
private readonly proposer;
|
|
15
|
-
readonly type: "empire";
|
|
16
|
-
constructor(client: ViemClient, address: Hex | EthAddress);
|
|
17
|
-
get address(): EthAddress;
|
|
18
|
-
getQuorumSize(): Promise<bigint>;
|
|
19
|
-
getRoundSize(): Promise<bigint>;
|
|
20
|
-
getLifetimeInRounds(): Promise<bigint>;
|
|
21
|
-
getExecutionDelayInRounds(): Promise<bigint>;
|
|
22
|
-
getCurrentRound(): Promise<bigint>;
|
|
23
|
-
computeRound(slot: SlotNumber): Promise<bigint>;
|
|
24
|
-
getInstance(): Promise<`0x${string}`>;
|
|
25
|
-
getRoundInfo(rollupAddress: Hex, round: bigint): Promise<{
|
|
26
|
-
lastSignalSlot: SlotNumber;
|
|
27
|
-
payloadWithMostSignals: Hex;
|
|
28
|
-
quorumReached: boolean;
|
|
29
|
-
executed: boolean;
|
|
30
|
-
}>;
|
|
31
|
-
getPayloadSignals(rollupAddress: Hex, round: bigint, payload: Hex): Promise<bigint>;
|
|
32
|
-
createSignalRequest(payload: Hex): L1TxRequest;
|
|
33
|
-
createSignalRequestWithSignature(payload: Hex, slot: SlotNumber, chainId: number, signerAddress: Hex, signer: (msg: TypedDataDefinition) => Promise<Hex>): Promise<L1TxRequest>;
|
|
34
|
-
/** Checks if a payload was ever submitted to governance via submitRoundWinner. */
|
|
35
|
-
hasPayloadBeenProposed(payload: Hex, fromBlock: bigint): Promise<boolean>;
|
|
36
|
-
listenToSubmittablePayloads(callback: (args: {
|
|
37
|
-
payload: `0x${string}`;
|
|
38
|
-
round: bigint;
|
|
39
|
-
}) => unknown): import("viem").WatchContractEventReturnType;
|
|
40
|
-
listenToPayloadSubmitted(callback: (args: {
|
|
41
|
-
round: bigint;
|
|
42
|
-
payload: `0x${string}`;
|
|
43
|
-
}) => unknown): import("viem").WatchContractEventReturnType;
|
|
44
|
-
listenToSignalCasted(callback: (args: {
|
|
45
|
-
round: bigint;
|
|
46
|
-
payload: `0x${string}`;
|
|
47
|
-
signaler: `0x${string}`;
|
|
48
|
-
}) => unknown): import("viem").WatchContractEventReturnType;
|
|
49
|
-
/** Creates an L1TxRequest to submit the round winner for the given round. */
|
|
50
|
-
buildExecuteRoundRequest(round: bigint): L1TxRequest;
|
|
51
|
-
/** Tries to extract a PayloadSubmitted event from the given logs. */
|
|
52
|
-
tryExtractPayloadSubmittedEvent(logs: Log[]): {
|
|
53
|
-
eventName: "PayloadSubmitted";
|
|
54
|
-
args: {
|
|
55
|
-
payload: `0x${string}`;
|
|
56
|
-
round: bigint;
|
|
57
|
-
};
|
|
58
|
-
} | undefined;
|
|
59
|
-
/**
|
|
60
|
-
* Wait for a round to be reached.
|
|
61
|
-
*
|
|
62
|
-
* @param round - The round to wait for.
|
|
63
|
-
* @param pollingIntervalSeconds - The interval in seconds to poll for the round.
|
|
64
|
-
* @returns True if the round was reached, false otherwise.
|
|
65
|
-
*/
|
|
66
|
-
waitForRound(round: bigint, pollingIntervalSeconds?: number): Promise<boolean>;
|
|
67
|
-
executeRound(txUtils: L1TxUtils, round: bigint | number): ReturnType<typeof txUtils.sendAndMonitorTransaction>;
|
|
68
|
-
}
|
|
69
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZW1waXJlX3NsYXNoaW5nX3Byb3Bvc2VyLmQudHMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvY29udHJhY3RzL2VtcGlyZV9zb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