@aztec/cli 2.0.0-nightly.20250817 → 2.0.0-nightly.20250819
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/cmds/l1/index.d.ts.map +1 -1
- package/dest/cmds/l1/index.js +0 -8
- package/package.json +22 -22
- package/src/cmds/l1/index.ts +0 -29
- package/dest/cmds/l1/deploy_l1_verifier.d.ts +0 -4
- package/dest/cmds/l1/deploy_l1_verifier.d.ts.map +0 -1
- package/dest/cmds/l1/deploy_l1_verifier.js +0 -18
- package/src/cmds/l1/deploy_l1_verifier.ts +0 -50
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/cmds/l1/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AAG3D,OAAO,EAAE,KAAK,OAAO,EAAU,MAAM,WAAW,CAAC;AAajD,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAW3D,wBAAgB,cAAc,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/cmds/l1/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AAG3D,OAAO,EAAE,KAAK,OAAO,EAAU,MAAM,WAAW,CAAC;AAajD,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAW3D,wBAAgB,cAAc,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,WAghB/E"}
|
package/dest/cmds/l1/index.js
CHANGED
|
@@ -170,14 +170,6 @@ export function injectCommands(program, log, debugLogger) {
|
|
|
170
170
|
debugLogger
|
|
171
171
|
});
|
|
172
172
|
});
|
|
173
|
-
program.command('deploy-l1-verifier').description('Deploys the rollup verifier contract').addOption(l1RpcUrlsOption).addOption(l1ChainIdOption).option('--l1-private-key <string>', 'The L1 private key to use for deployment', PRIVATE_KEY).option('-m, --mnemonic <string>', 'The mnemonic to use in deployment', 'test test test test test test test test test test test junk').option('-i, --mnemonic-index <number>', 'The index of the mnemonic to use in deployment', (arg)=>parseInt(arg), 0).requiredOption('--verifier <verifier>', 'Either mock or real', 'real').action(async (options)=>{
|
|
174
|
-
const { deployMockVerifier, deployUltraHonkVerifier } = await import('./deploy_l1_verifier.js');
|
|
175
|
-
if (options.verifier === 'mock') {
|
|
176
|
-
await deployMockVerifier(options.l1RpcUrls, options.l1ChainId, options.l1PrivateKey, options.mnemonic, log);
|
|
177
|
-
} else {
|
|
178
|
-
await deployUltraHonkVerifier(options.l1RpcUrls, options.l1ChainId, options.l1PrivateKey, options.mnemonic, options.mnemonicIndex, log);
|
|
179
|
-
}
|
|
180
|
-
});
|
|
181
173
|
program.command('bridge-erc20').description('Bridges ERC20 tokens to L2.').argument('<amount>', 'The amount of Fee Juice to mint and bridge.', parseBigint).argument('<recipient>', 'Aztec address of the recipient.', parseAztecAddress).addOption(l1RpcUrlsOption).option('-m, --mnemonic <string>', 'The mnemonic to use for deriving the Ethereum address that will mint and bridge', 'test test test test test test test test test test test junk').option('--mint', 'Mint the tokens on L1', false).option('--private', 'If the bridge should use the private flow', false).addOption(l1ChainIdOption).requiredOption('-t, --token <string>', 'The address of the token to bridge', parseEthereumAddress).requiredOption('-p, --portal <string>', 'The address of the portal contract', parseEthereumAddress).option('-f, --faucet <string>', 'The address of the faucet contract (only used if minting)', parseEthereumAddress).option('--l1-private-key <string>', 'The private key to use for deployment', PRIVATE_KEY).option('--json', 'Output the claim in JSON format').action(async (amount, recipient, options)=>{
|
|
182
174
|
const { bridgeERC20 } = await import('./bridge_erc20.js');
|
|
183
175
|
await bridgeERC20(amount, recipient, options.l1RpcUrls, options.l1ChainId, options.l1PrivateKey, options.mnemonic, options.token, options.faucet, options.portal, options.private, options.mint, options.json, log, debugLogger);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aztec/cli",
|
|
3
|
-
"version": "2.0.0-nightly.
|
|
3
|
+
"version": "2.0.0-nightly.20250819",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"exports": {
|
|
6
6
|
"./contracts": "./dest/cmds/contracts/index.js",
|
|
@@ -69,16 +69,16 @@
|
|
|
69
69
|
]
|
|
70
70
|
},
|
|
71
71
|
"dependencies": {
|
|
72
|
-
"@aztec/archiver": "2.0.0-nightly.
|
|
73
|
-
"@aztec/aztec.js": "2.0.0-nightly.
|
|
74
|
-
"@aztec/constants": "2.0.0-nightly.
|
|
75
|
-
"@aztec/entrypoints": "2.0.0-nightly.
|
|
76
|
-
"@aztec/ethereum": "2.0.0-nightly.
|
|
77
|
-
"@aztec/foundation": "2.0.0-nightly.
|
|
78
|
-
"@aztec/l1-artifacts": "2.0.0-nightly.
|
|
79
|
-
"@aztec/p2p": "2.0.0-nightly.
|
|
80
|
-
"@aztec/stdlib": "2.0.0-nightly.
|
|
81
|
-
"@aztec/world-state": "2.0.0-nightly.
|
|
72
|
+
"@aztec/archiver": "2.0.0-nightly.20250819",
|
|
73
|
+
"@aztec/aztec.js": "2.0.0-nightly.20250819",
|
|
74
|
+
"@aztec/constants": "2.0.0-nightly.20250819",
|
|
75
|
+
"@aztec/entrypoints": "2.0.0-nightly.20250819",
|
|
76
|
+
"@aztec/ethereum": "2.0.0-nightly.20250819",
|
|
77
|
+
"@aztec/foundation": "2.0.0-nightly.20250819",
|
|
78
|
+
"@aztec/l1-artifacts": "2.0.0-nightly.20250819",
|
|
79
|
+
"@aztec/p2p": "2.0.0-nightly.20250819",
|
|
80
|
+
"@aztec/stdlib": "2.0.0-nightly.20250819",
|
|
81
|
+
"@aztec/world-state": "2.0.0-nightly.20250819",
|
|
82
82
|
"@iarna/toml": "^2.2.5",
|
|
83
83
|
"@libp2p/peer-id-factory": "^3.0.4",
|
|
84
84
|
"commander": "^12.1.0",
|
|
@@ -90,8 +90,8 @@
|
|
|
90
90
|
"viem": "2.23.7"
|
|
91
91
|
},
|
|
92
92
|
"devDependencies": {
|
|
93
|
-
"@aztec/accounts": "2.0.0-nightly.
|
|
94
|
-
"@aztec/protocol-contracts": "2.0.0-nightly.
|
|
93
|
+
"@aztec/accounts": "2.0.0-nightly.20250819",
|
|
94
|
+
"@aztec/protocol-contracts": "2.0.0-nightly.20250819",
|
|
95
95
|
"@jest/globals": "^30.0.0",
|
|
96
96
|
"@types/jest": "^30.0.0",
|
|
97
97
|
"@types/lodash.chunk": "^4.2.9",
|
|
@@ -107,15 +107,15 @@
|
|
|
107
107
|
"typescript": "^5.3.3"
|
|
108
108
|
},
|
|
109
109
|
"peerDependencies": {
|
|
110
|
-
"@aztec/accounts": "2.0.0-nightly.
|
|
111
|
-
"@aztec/bb-prover": "2.0.0-nightly.
|
|
112
|
-
"@aztec/ethereum": "2.0.0-nightly.
|
|
113
|
-
"@aztec/l1-artifacts": "2.0.0-nightly.
|
|
114
|
-
"@aztec/noir-contracts.js": "2.0.0-nightly.
|
|
115
|
-
"@aztec/noir-protocol-circuits-types": "2.0.0-nightly.
|
|
116
|
-
"@aztec/noir-test-contracts.js": "2.0.0-nightly.
|
|
117
|
-
"@aztec/protocol-contracts": "2.0.0-nightly.
|
|
118
|
-
"@aztec/stdlib": "2.0.0-nightly.
|
|
110
|
+
"@aztec/accounts": "2.0.0-nightly.20250819",
|
|
111
|
+
"@aztec/bb-prover": "2.0.0-nightly.20250819",
|
|
112
|
+
"@aztec/ethereum": "2.0.0-nightly.20250819",
|
|
113
|
+
"@aztec/l1-artifacts": "2.0.0-nightly.20250819",
|
|
114
|
+
"@aztec/noir-contracts.js": "2.0.0-nightly.20250819",
|
|
115
|
+
"@aztec/noir-protocol-circuits-types": "2.0.0-nightly.20250819",
|
|
116
|
+
"@aztec/noir-test-contracts.js": "2.0.0-nightly.20250819",
|
|
117
|
+
"@aztec/protocol-contracts": "2.0.0-nightly.20250819",
|
|
118
|
+
"@aztec/stdlib": "2.0.0-nightly.20250819"
|
|
119
119
|
},
|
|
120
120
|
"files": [
|
|
121
121
|
"dest",
|
package/src/cmds/l1/index.ts
CHANGED
|
@@ -438,35 +438,6 @@ export function injectCommands(program: Command, log: LogFn, debugLogger: Logger
|
|
|
438
438
|
});
|
|
439
439
|
});
|
|
440
440
|
|
|
441
|
-
program
|
|
442
|
-
.command('deploy-l1-verifier')
|
|
443
|
-
.description('Deploys the rollup verifier contract')
|
|
444
|
-
.addOption(l1RpcUrlsOption)
|
|
445
|
-
.addOption(l1ChainIdOption)
|
|
446
|
-
.option('--l1-private-key <string>', 'The L1 private key to use for deployment', PRIVATE_KEY)
|
|
447
|
-
.option(
|
|
448
|
-
'-m, --mnemonic <string>',
|
|
449
|
-
'The mnemonic to use in deployment',
|
|
450
|
-
'test test test test test test test test test test test junk',
|
|
451
|
-
)
|
|
452
|
-
.option('-i, --mnemonic-index <number>', 'The index of the mnemonic to use in deployment', arg => parseInt(arg), 0)
|
|
453
|
-
.requiredOption('--verifier <verifier>', 'Either mock or real', 'real')
|
|
454
|
-
.action(async options => {
|
|
455
|
-
const { deployMockVerifier, deployUltraHonkVerifier } = await import('./deploy_l1_verifier.js');
|
|
456
|
-
if (options.verifier === 'mock') {
|
|
457
|
-
await deployMockVerifier(options.l1RpcUrls, options.l1ChainId, options.l1PrivateKey, options.mnemonic, log);
|
|
458
|
-
} else {
|
|
459
|
-
await deployUltraHonkVerifier(
|
|
460
|
-
options.l1RpcUrls,
|
|
461
|
-
options.l1ChainId,
|
|
462
|
-
options.l1PrivateKey,
|
|
463
|
-
options.mnemonic,
|
|
464
|
-
options.mnemonicIndex,
|
|
465
|
-
log,
|
|
466
|
-
);
|
|
467
|
-
}
|
|
468
|
-
});
|
|
469
|
-
|
|
470
441
|
program
|
|
471
442
|
.command('bridge-erc20')
|
|
472
443
|
.description('Bridges ERC20 tokens to L2.')
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import type { LogFn } from '@aztec/foundation/log';
|
|
2
|
-
export declare function deployUltraHonkVerifier(ethRpcUrls: string[], l1ChainId: string, privateKey: string | undefined, mnemonic: string, mnemonicIndex: number, log: LogFn): Promise<void>;
|
|
3
|
-
export declare function deployMockVerifier(ethRpcUrls: string[], l1ChainId: string, privateKey: string | undefined, mnemonic: string, log: LogFn): Promise<void>;
|
|
4
|
-
//# sourceMappingURL=deploy_l1_verifier.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"deploy_l1_verifier.d.ts","sourceRoot":"","sources":["../../../src/cmds/l1/deploy_l1_verifier.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAKnD,wBAAsB,uBAAuB,CAC3C,UAAU,EAAE,MAAM,EAAE,EACpB,SAAS,EAAE,MAAM,EACjB,UAAU,EAAE,MAAM,GAAG,SAAS,EAC9B,QAAQ,EAAE,MAAM,EAChB,aAAa,EAAE,MAAM,EACrB,GAAG,EAAE,KAAK,iBAeX;AAED,wBAAsB,kBAAkB,CACtC,UAAU,EAAE,MAAM,EAAE,EACpB,SAAS,EAAE,MAAM,EACjB,UAAU,EAAE,MAAM,GAAG,SAAS,EAC9B,QAAQ,EAAE,MAAM,EAChB,GAAG,EAAE,KAAK,iBAeX"}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { createEthereumChain, createExtendedL1Client, deployL1Contract } from '@aztec/ethereum';
|
|
2
|
-
import { HonkVerifierAbi, HonkVerifierBytecode } from '@aztec/l1-artifacts';
|
|
3
|
-
import { mnemonicToAccount, privateKeyToAccount } from 'viem/accounts';
|
|
4
|
-
export async function deployUltraHonkVerifier(ethRpcUrls, l1ChainId, privateKey, mnemonic, mnemonicIndex, log) {
|
|
5
|
-
const account = !privateKey ? mnemonicToAccount(mnemonic, {
|
|
6
|
-
addressIndex: mnemonicIndex
|
|
7
|
-
}) : privateKeyToAccount(`${privateKey.startsWith('0x') ? '' : '0x'}${privateKey}`);
|
|
8
|
-
const extendedClient = createExtendedL1Client(ethRpcUrls, account, createEthereumChain(ethRpcUrls, l1ChainId).chainInfo);
|
|
9
|
-
const { address: verifierAddress } = await deployL1Contract(extendedClient, HonkVerifierAbi, HonkVerifierBytecode);
|
|
10
|
-
log(`Deployed honk verifier at ${verifierAddress}`);
|
|
11
|
-
log(`Rollup accepts only real proofs now`);
|
|
12
|
-
}
|
|
13
|
-
export async function deployMockVerifier(ethRpcUrls, l1ChainId, privateKey, mnemonic, log) {
|
|
14
|
-
const extendedClient = createExtendedL1Client(ethRpcUrls, privateKey ?? mnemonic, createEthereumChain(ethRpcUrls, l1ChainId).chainInfo);
|
|
15
|
-
const { MockVerifierAbi, MockVerifierBytecode } = await import('@aztec/l1-artifacts');
|
|
16
|
-
const { address: mockVerifierAddress } = await deployL1Contract(extendedClient, MockVerifierAbi, MockVerifierBytecode);
|
|
17
|
-
log(`Deployed MockVerifier at ${mockVerifierAddress.toString()}`);
|
|
18
|
-
}
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import { createEthereumChain, createExtendedL1Client, deployL1Contract } from '@aztec/ethereum';
|
|
2
|
-
import type { LogFn } from '@aztec/foundation/log';
|
|
3
|
-
import { HonkVerifierAbi, HonkVerifierBytecode } from '@aztec/l1-artifacts';
|
|
4
|
-
|
|
5
|
-
import { mnemonicToAccount, privateKeyToAccount } from 'viem/accounts';
|
|
6
|
-
|
|
7
|
-
export async function deployUltraHonkVerifier(
|
|
8
|
-
ethRpcUrls: string[],
|
|
9
|
-
l1ChainId: string,
|
|
10
|
-
privateKey: string | undefined,
|
|
11
|
-
mnemonic: string,
|
|
12
|
-
mnemonicIndex: number,
|
|
13
|
-
log: LogFn,
|
|
14
|
-
) {
|
|
15
|
-
const account = !privateKey
|
|
16
|
-
? mnemonicToAccount(mnemonic!, { addressIndex: mnemonicIndex })
|
|
17
|
-
: privateKeyToAccount(`${privateKey.startsWith('0x') ? '' : '0x'}${privateKey}` as `0x${string}`);
|
|
18
|
-
const extendedClient = createExtendedL1Client(
|
|
19
|
-
ethRpcUrls,
|
|
20
|
-
account,
|
|
21
|
-
createEthereumChain(ethRpcUrls, l1ChainId).chainInfo,
|
|
22
|
-
);
|
|
23
|
-
|
|
24
|
-
const { address: verifierAddress } = await deployL1Contract(extendedClient, HonkVerifierAbi, HonkVerifierBytecode);
|
|
25
|
-
log(`Deployed honk verifier at ${verifierAddress}`);
|
|
26
|
-
|
|
27
|
-
log(`Rollup accepts only real proofs now`);
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
export async function deployMockVerifier(
|
|
31
|
-
ethRpcUrls: string[],
|
|
32
|
-
l1ChainId: string,
|
|
33
|
-
privateKey: string | undefined,
|
|
34
|
-
mnemonic: string,
|
|
35
|
-
log: LogFn,
|
|
36
|
-
) {
|
|
37
|
-
const extendedClient = createExtendedL1Client(
|
|
38
|
-
ethRpcUrls,
|
|
39
|
-
privateKey ?? mnemonic,
|
|
40
|
-
createEthereumChain(ethRpcUrls, l1ChainId).chainInfo,
|
|
41
|
-
);
|
|
42
|
-
const { MockVerifierAbi, MockVerifierBytecode } = await import('@aztec/l1-artifacts');
|
|
43
|
-
|
|
44
|
-
const { address: mockVerifierAddress } = await deployL1Contract(
|
|
45
|
-
extendedClient,
|
|
46
|
-
MockVerifierAbi,
|
|
47
|
-
MockVerifierBytecode,
|
|
48
|
-
);
|
|
49
|
-
log(`Deployed MockVerifier at ${mockVerifierAddress.toString()}`);
|
|
50
|
-
}
|