@aztec/cli 2.1.0-rc.9 → 3.0.0-devnet.2

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.
Files changed (146) hide show
  1. package/README.md +1 -427
  2. package/dest/cmds/aztec_node/block_number.d.ts +3 -0
  3. package/dest/cmds/aztec_node/block_number.d.ts.map +1 -0
  4. package/dest/cmds/aztec_node/block_number.js +10 -0
  5. package/dest/cmds/aztec_node/get_block.d.ts +3 -0
  6. package/dest/cmds/aztec_node/get_block.d.ts.map +1 -0
  7. package/dest/cmds/aztec_node/get_block.js +9 -0
  8. package/dest/cmds/aztec_node/get_current_base_fee.d.ts +3 -0
  9. package/dest/cmds/aztec_node/get_current_base_fee.d.ts.map +1 -0
  10. package/dest/cmds/aztec_node/get_current_base_fee.js +7 -0
  11. package/dest/cmds/aztec_node/get_l1_to_l2_message_witness.d.ts +5 -0
  12. package/dest/cmds/aztec_node/get_l1_to_l2_message_witness.d.ts.map +1 -0
  13. package/dest/cmds/aztec_node/get_l1_to_l2_message_witness.js +12 -0
  14. package/dest/cmds/aztec_node/get_logs.d.ts +6 -0
  15. package/dest/cmds/aztec_node/get_logs.d.ts.map +1 -0
  16. package/dest/cmds/{pxe → aztec_node}/get_logs.js +4 -4
  17. package/dest/cmds/aztec_node/get_node_info.d.ts +3 -0
  18. package/dest/cmds/aztec_node/get_node_info.d.ts.map +1 -0
  19. package/dest/cmds/{pxe → aztec_node}/get_node_info.js +3 -8
  20. package/dest/cmds/aztec_node/index.d.ts.map +1 -0
  21. package/dest/cmds/aztec_node/index.js +28 -0
  22. package/dest/cmds/infrastructure/index.d.ts +2 -2
  23. package/dest/cmds/infrastructure/index.d.ts.map +1 -1
  24. package/dest/cmds/infrastructure/index.js +7 -8
  25. package/dest/cmds/infrastructure/sequencers.d.ts +2 -3
  26. package/dest/cmds/infrastructure/sequencers.d.ts.map +1 -1
  27. package/dest/cmds/infrastructure/sequencers.js +4 -3
  28. package/dest/cmds/infrastructure/setup_l2_contract.d.ts +1 -1
  29. package/dest/cmds/infrastructure/setup_l2_contract.d.ts.map +1 -1
  30. package/dest/cmds/infrastructure/setup_l2_contract.js +10 -25
  31. package/dest/cmds/l1/advance_epoch.d.ts +1 -1
  32. package/dest/cmds/l1/advance_epoch.d.ts.map +1 -1
  33. package/dest/cmds/l1/advance_epoch.js +6 -5
  34. package/dest/cmds/l1/assume_proven_through.d.ts +1 -1
  35. package/dest/cmds/l1/assume_proven_through.d.ts.map +1 -1
  36. package/dest/cmds/l1/assume_proven_through.js +7 -6
  37. package/dest/cmds/l1/bridge_erc20.d.ts +1 -1
  38. package/dest/cmds/l1/bridge_erc20.d.ts.map +1 -1
  39. package/dest/cmds/l1/bridge_erc20.js +1 -1
  40. package/dest/cmds/l1/deploy_l1_contracts.d.ts +1 -1
  41. package/dest/cmds/l1/deploy_l1_contracts.d.ts.map +1 -1
  42. package/dest/cmds/l1/deploy_l1_contracts.js +3 -3
  43. package/dest/cmds/l1/deploy_new_rollup.d.ts +1 -1
  44. package/dest/cmds/l1/deploy_new_rollup.d.ts.map +1 -1
  45. package/dest/cmds/l1/deploy_new_rollup.js +4 -4
  46. package/dest/cmds/l1/get_l1_addresses.d.ts +1 -1
  47. package/dest/cmds/l1/get_l1_addresses.d.ts.map +1 -1
  48. package/dest/cmds/l1/index.d.ts.map +1 -1
  49. package/dest/cmds/l1/index.js +7 -7
  50. package/dest/cmds/l1/update_l1_validators.d.ts.map +1 -1
  51. package/dest/cmds/l1/update_l1_validators.js +4 -3
  52. package/dest/cmds/misc/generate_secret_and_hash.js +1 -1
  53. package/dest/cmds/misc/generate_secret_key.d.ts +1 -1
  54. package/dest/cmds/misc/generate_secret_key.d.ts.map +1 -1
  55. package/dest/cmds/misc/generate_secret_key.js +1 -1
  56. package/dest/config/cached_fetch.d.ts +1 -1
  57. package/dest/config/cached_fetch.d.ts.map +1 -1
  58. package/dest/config/cached_fetch.js +1 -1
  59. package/dest/config/chain_l2_config.d.ts +7 -6
  60. package/dest/config/chain_l2_config.d.ts.map +1 -1
  61. package/dest/config/chain_l2_config.js +103 -40
  62. package/dest/config/enrich_env.js +1 -1
  63. package/dest/utils/aztec.d.ts +2 -8
  64. package/dest/utils/aztec.d.ts.map +1 -1
  65. package/dest/utils/aztec.js +6 -31
  66. package/dest/utils/commands.d.ts +6 -7
  67. package/dest/utils/commands.d.ts.map +1 -1
  68. package/dest/utils/commands.js +5 -6
  69. package/dest/utils/inspect.d.ts +3 -10
  70. package/dest/utils/inspect.d.ts.map +1 -1
  71. package/dest/utils/inspect.js +13 -95
  72. package/dest/utils/setup_contracts.d.ts +1 -3
  73. package/dest/utils/setup_contracts.d.ts.map +1 -1
  74. package/dest/utils/setup_contracts.js +2 -22
  75. package/package.json +26 -25
  76. package/src/cmds/aztec_node/block_number.ts +9 -0
  77. package/src/cmds/aztec_node/get_block.ts +10 -0
  78. package/src/cmds/aztec_node/get_current_base_fee.ts +9 -0
  79. package/src/cmds/aztec_node/get_l1_to_l2_message_witness.ts +27 -0
  80. package/src/cmds/{pxe → aztec_node}/get_logs.ts +8 -7
  81. package/src/cmds/{pxe → aztec_node}/get_node_info.ts +5 -16
  82. package/src/cmds/aztec_node/index.ts +87 -0
  83. package/src/cmds/infrastructure/index.ts +7 -17
  84. package/src/cmds/infrastructure/sequencers.ts +6 -6
  85. package/src/cmds/infrastructure/setup_l2_contract.ts +13 -30
  86. package/src/cmds/l1/advance_epoch.ts +6 -5
  87. package/src/cmds/l1/assume_proven_through.ts +7 -6
  88. package/src/cmds/l1/bridge_erc20.ts +3 -1
  89. package/src/cmds/l1/deploy_l1_contracts.ts +4 -3
  90. package/src/cmds/l1/deploy_new_rollup.ts +4 -2
  91. package/src/cmds/l1/get_l1_addresses.ts +1 -1
  92. package/src/cmds/l1/index.ts +7 -5
  93. package/src/cmds/l1/update_l1_validators.ts +4 -3
  94. package/src/cmds/misc/generate_secret_and_hash.ts +1 -1
  95. package/src/cmds/misc/generate_secret_key.ts +1 -1
  96. package/src/config/cached_fetch.ts +1 -1
  97. package/src/config/chain_l2_config.ts +133 -47
  98. package/src/config/enrich_env.ts +1 -1
  99. package/src/utils/aztec.ts +6 -40
  100. package/src/utils/commands.ts +8 -10
  101. package/src/utils/inspect.ts +18 -111
  102. package/src/utils/setup_contracts.ts +4 -43
  103. package/dest/cmds/pxe/add_contract.d.ts +0 -5
  104. package/dest/cmds/pxe/add_contract.d.ts.map +0 -1
  105. package/dest/cmds/pxe/add_contract.js +0 -29
  106. package/dest/cmds/pxe/block_number.d.ts +0 -3
  107. package/dest/cmds/pxe/block_number.d.ts.map +0 -1
  108. package/dest/cmds/pxe/block_number.js +0 -10
  109. package/dest/cmds/pxe/get_account.d.ts +0 -4
  110. package/dest/cmds/pxe/get_account.d.ts.map +0 -1
  111. package/dest/cmds/pxe/get_account.js +0 -10
  112. package/dest/cmds/pxe/get_accounts.d.ts +0 -3
  113. package/dest/cmds/pxe/get_accounts.d.ts.map +0 -1
  114. package/dest/cmds/pxe/get_accounts.js +0 -25
  115. package/dest/cmds/pxe/get_block.d.ts +0 -3
  116. package/dest/cmds/pxe/get_block.d.ts.map +0 -1
  117. package/dest/cmds/pxe/get_block.js +0 -9
  118. package/dest/cmds/pxe/get_contract_data.d.ts +0 -4
  119. package/dest/cmds/pxe/get_contract_data.d.ts.map +0 -1
  120. package/dest/cmds/pxe/get_contract_data.js +0 -31
  121. package/dest/cmds/pxe/get_current_base_fee.d.ts +0 -3
  122. package/dest/cmds/pxe/get_current_base_fee.d.ts.map +0 -1
  123. package/dest/cmds/pxe/get_current_base_fee.js +0 -7
  124. package/dest/cmds/pxe/get_l1_to_l2_message_witness.d.ts +0 -4
  125. package/dest/cmds/pxe/get_l1_to_l2_message_witness.d.ts.map +0 -1
  126. package/dest/cmds/pxe/get_l1_to_l2_message_witness.js +0 -11
  127. package/dest/cmds/pxe/get_logs.d.ts +0 -4
  128. package/dest/cmds/pxe/get_logs.d.ts.map +0 -1
  129. package/dest/cmds/pxe/get_node_info.d.ts +0 -3
  130. package/dest/cmds/pxe/get_node_info.d.ts.map +0 -1
  131. package/dest/cmds/pxe/get_pxe_info.d.ts +0 -3
  132. package/dest/cmds/pxe/get_pxe_info.d.ts.map +0 -1
  133. package/dest/cmds/pxe/get_pxe_info.js +0 -11
  134. package/dest/cmds/pxe/index.d.ts.map +0 -1
  135. package/dest/cmds/pxe/index.js +0 -55
  136. package/src/cmds/pxe/add_contract.ts +0 -41
  137. package/src/cmds/pxe/block_number.ts +0 -9
  138. package/src/cmds/pxe/get_account.ts +0 -16
  139. package/src/cmds/pxe/get_accounts.ts +0 -35
  140. package/src/cmds/pxe/get_block.ts +0 -10
  141. package/src/cmds/pxe/get_contract_data.ts +0 -51
  142. package/src/cmds/pxe/get_current_base_fee.ts +0 -9
  143. package/src/cmds/pxe/get_l1_to_l2_message_witness.ts +0 -25
  144. package/src/cmds/pxe/get_pxe_info.ts +0 -13
  145. package/src/cmds/pxe/index.ts +0 -170
  146. /package/dest/cmds/{pxe → aztec_node}/index.d.ts +0 -0
@@ -1,10 +1,9 @@
1
1
  import { DefaultL1ContractsConfig } from '@aztec/ethereum';
2
2
  import { EthAddress } from '@aztec/foundation/eth-address';
3
- import path, { join } from 'path';
3
+ import path from 'path';
4
4
  import publicIncludeMetrics from '../../public_include_metric_prefixes.json' with {
5
5
  type: 'json'
6
6
  };
7
- import { cachedFetch } from './cached_fetch.js';
8
7
  import { enrichEthAddressVar, enrichVar } from './enrich_env.js';
9
8
  const SNAPSHOTS_URL = 'https://aztec-labs-snapshots.com';
10
9
  const defaultDBMapSizeKb = 128 * 1_024 * 1_024; // 128 GB
@@ -48,6 +47,7 @@ export const stagingIgnitionL2ChainConfig = {
48
47
  l1ChainId: 11155111,
49
48
  testAccounts: false,
50
49
  sponsoredFPC: false,
50
+ disableTransactions: true,
51
51
  p2pEnabled: true,
52
52
  p2pBootstrapNodes: [],
53
53
  seqMinTxsPerBlock: 0,
@@ -64,7 +64,6 @@ export const stagingIgnitionL2ChainConfig = {
64
64
  publicMetricsCollectFrom: [
65
65
  'sequencer'
66
66
  ],
67
- txPoolDeleteTxsAfterReorg: false,
68
67
  /** How many seconds an L1 slot lasts. */ ethereumSlotDuration: 12,
69
68
  /** How many seconds an L2 slots lasts (must be multiple of ethereum slot duration). */ aztecSlotDuration: 72,
70
69
  /** How many L2 slots an epoch lasts. */ aztecEpochDuration: 32,
@@ -75,7 +74,6 @@ export const stagingIgnitionL2ChainConfig = {
75
74
  slashingRoundSizeInEpochs: 4,
76
75
  slashingLifetimeInRounds: 40,
77
76
  slashingExecutionDelayInRounds: 28,
78
- slashingDisableDuration: 5 * 24 * 60 * 60,
79
77
  slashAmountSmall: 2_000n * 10n ** 18n,
80
78
  slashAmountMedium: 10_000n * 10n ** 18n,
81
79
  slashAmountLarge: 50_000n * 10n ** 18n,
@@ -85,9 +83,9 @@ export const stagingIgnitionL2ChainConfig = {
85
83
  /** The mana target for the rollup */ manaTarget: 0n,
86
84
  exitDelaySeconds: 5 * 24 * 60 * 60,
87
85
  /** The proving cost per mana */ provingCostPerMana: 0n,
86
+ localEjectionThreshold: 196_000n * 10n ** 18n,
88
87
  ejectionThreshold: 100_000n * 10n ** 18n,
89
88
  activationThreshold: 200_000n * 10n ** 18n,
90
- localEjectionThreshold: 196_000n * 10n ** 18n,
91
89
  governanceProposerRoundSize: 300,
92
90
  governanceProposerQuorum: 151,
93
91
  // Node slashing config
@@ -107,6 +105,7 @@ export const stagingIgnitionL2ChainConfig = {
107
105
  slashGracePeriodL2Slots: 32 * 4,
108
106
  slashOffenseExpirationRounds: 8,
109
107
  sentinelEnabled: true,
108
+ slashingDisableDuration: 5 * 24 * 60 * 60,
110
109
  slashExecuteRoundsLookBack: 4,
111
110
  ...DefaultNetworkDBMapSizeConfig
112
111
  };
@@ -114,6 +113,7 @@ export const stagingPublicL2ChainConfig = {
114
113
  l1ChainId: 11155111,
115
114
  testAccounts: false,
116
115
  sponsoredFPC: true,
116
+ disableTransactions: false,
117
117
  p2pEnabled: true,
118
118
  p2pBootstrapNodes: [],
119
119
  seqMinTxsPerBlock: 0,
@@ -130,7 +130,43 @@ export const stagingPublicL2ChainConfig = {
130
130
  'sequencer'
131
131
  ],
132
132
  maxTxPoolSize: 100_000_000,
133
- txPoolDeleteTxsAfterReorg: true,
133
+ // Deployment stuff
134
+ /** How many seconds an L1 slot lasts. */ ethereumSlotDuration: 12,
135
+ /** How many seconds an L2 slots lasts (must be multiple of ethereum slot duration). */ aztecSlotDuration: 36,
136
+ /** How many L2 slots an epoch lasts. */ aztecEpochDuration: 32,
137
+ /** The target validator committee size. */ aztecTargetCommitteeSize: 48,
138
+ /** The number of epochs to lag behind the current epoch for validator selection. */ lagInEpochs: DefaultL1ContractsConfig.lagInEpochs,
139
+ /** The local ejection threshold for a validator. Stricter than ejectionThreshold but local to a specific rollup */ localEjectionThreshold: DefaultL1ContractsConfig.localEjectionThreshold,
140
+ /** The number of epochs after an epoch ends that proofs are still accepted. */ aztecProofSubmissionEpochs: 1,
141
+ /** The deposit amount for a validator */ activationThreshold: DefaultL1ContractsConfig.activationThreshold,
142
+ /** The minimum stake for a validator. */ ejectionThreshold: DefaultL1ContractsConfig.ejectionThreshold,
143
+ /** The slashing round size */ slashingRoundSizeInEpochs: DefaultL1ContractsConfig.slashingRoundSizeInEpochs,
144
+ /** Governance proposing round size */ governanceProposerRoundSize: DefaultL1ContractsConfig.governanceProposerRoundSize,
145
+ /** The mana target for the rollup */ manaTarget: DefaultL1ContractsConfig.manaTarget,
146
+ /** The proving cost per mana */ provingCostPerMana: DefaultL1ContractsConfig.provingCostPerMana,
147
+ /** Exit delay for stakers */ exitDelaySeconds: DefaultL1ContractsConfig.exitDelaySeconds,
148
+ ...DefaultSlashConfig,
149
+ ...DefaultNetworkDBMapSizeConfig
150
+ };
151
+ export const nextNetL2ChainConfig = {
152
+ l1ChainId: 11155111,
153
+ testAccounts: true,
154
+ sponsoredFPC: true,
155
+ p2pEnabled: true,
156
+ disableTransactions: false,
157
+ p2pBootstrapNodes: [],
158
+ seqMinTxsPerBlock: 0,
159
+ seqMaxTxsPerBlock: 8,
160
+ realProofs: true,
161
+ snapshotsUrls: [],
162
+ autoUpdate: 'config-and-version',
163
+ autoUpdateUrl: '',
164
+ publicIncludeMetrics,
165
+ publicMetricsCollectorUrl: '',
166
+ publicMetricsCollectFrom: [
167
+ ''
168
+ ],
169
+ maxTxPoolSize: 100_000_000,
134
170
  // Deployment stuff
135
171
  /** How many seconds an L1 slot lasts. */ ethereumSlotDuration: 12,
136
172
  /** How many seconds an L2 slots lasts (must be multiple of ethereum slot duration). */ aztecSlotDuration: 36,
@@ -154,9 +190,10 @@ export const testnetL2ChainConfig = {
154
190
  testAccounts: false,
155
191
  sponsoredFPC: true,
156
192
  p2pEnabled: true,
193
+ disableTransactions: true,
157
194
  p2pBootstrapNodes: [],
158
195
  seqMinTxsPerBlock: 0,
159
- seqMaxTxsPerBlock: 20,
196
+ seqMaxTxsPerBlock: 0,
160
197
  realProofs: true,
161
198
  snapshotsUrls: [
162
199
  `${SNAPSHOTS_URL}/testnet/`
@@ -169,7 +206,6 @@ export const testnetL2ChainConfig = {
169
206
  publicMetricsCollectFrom: [
170
207
  'sequencer'
171
208
  ],
172
- txPoolDeleteTxsAfterReorg: true,
173
209
  // Deployment stuff
174
210
  /** How many seconds an L1 slot lasts. */ ethereumSlotDuration: 12,
175
211
  /** How many seconds an L2 slots lasts (must be multiple of ethereum slot duration). */ aztecSlotDuration: 36,
@@ -182,47 +218,47 @@ export const testnetL2ChainConfig = {
182
218
  /** The local ejection threshold for a validator. Stricter than ejectionThreshold but local to a specific rollup */ localEjectionThreshold: DefaultL1ContractsConfig.localEjectionThreshold,
183
219
  /** The slashing round size */ slashingRoundSizeInEpochs: DefaultL1ContractsConfig.slashingRoundSizeInEpochs,
184
220
  /** Governance proposing round size */ governanceProposerRoundSize: DefaultL1ContractsConfig.governanceProposerRoundSize,
185
- /** The mana target for the rollup */ manaTarget: DefaultL1ContractsConfig.manaTarget,
221
+ /** The mana target for the rollup */ manaTarget: 0n,
186
222
  /** The proving cost per mana */ provingCostPerMana: DefaultL1ContractsConfig.provingCostPerMana,
187
223
  /** Exit delay for stakers */ exitDelaySeconds: DefaultL1ContractsConfig.exitDelaySeconds,
188
224
  ...DefaultSlashConfig,
189
225
  slashPrunePenalty: 0n,
190
226
  slashDataWithholdingPenalty: 0n,
191
- slashInactivityPenalty: DefaultL1ContractsConfig.slashAmountMedium,
192
227
  ...DefaultNetworkDBMapSizeConfig
193
228
  };
194
- export const ignitionL2ChainConfig = {
229
+ export const mainnetL2ChainConfig = {
195
230
  l1ChainId: 1,
196
231
  testAccounts: false,
197
232
  sponsoredFPC: false,
198
233
  p2pEnabled: true,
234
+ disableTransactions: true,
199
235
  p2pBootstrapNodes: [],
200
236
  seqMinTxsPerBlock: 0,
201
237
  seqMaxTxsPerBlock: 0,
202
238
  realProofs: true,
203
239
  snapshotsUrls: [
204
- `${SNAPSHOTS_URL}/ignition/`
240
+ `${SNAPSHOTS_URL}/mainnet/`
205
241
  ],
206
242
  autoUpdate: 'notify',
207
- autoUpdateUrl: 'https://storage.googleapis.com/aztec-testnet/auto-update/ignition.json',
243
+ autoUpdateUrl: 'https://storage.googleapis.com/aztec-mainnet/auto-update/mainnet.json',
208
244
  maxTxPoolSize: 100_000_000,
209
245
  publicIncludeMetrics,
210
246
  publicMetricsCollectorUrl: 'https://telemetry.alpha-testnet.aztec-labs.com/v1/metrics',
211
247
  publicMetricsCollectFrom: [
212
248
  'sequencer'
213
249
  ],
214
- txPoolDeleteTxsAfterReorg: false,
215
250
  /** How many seconds an L1 slot lasts. */ ethereumSlotDuration: 12,
216
251
  /** How many seconds an L2 slots lasts (must be multiple of ethereum slot duration). */ aztecSlotDuration: 72,
217
252
  /** How many L2 slots an epoch lasts. */ aztecEpochDuration: 32,
218
253
  /** The target validator committee size. */ aztecTargetCommitteeSize: 24,
219
- /** The number of epochs to lag behind the current epoch for validator selection. */ lagInEpochs: 2,
220
254
  /** The number of epochs after an epoch ends that proofs are still accepted. */ aztecProofSubmissionEpochs: 1,
221
255
  /** How many sequencers must agree with a slash for it to be executed. */ slashingQuorum: 65,
256
+ /** The number of epochs to lag behind the current epoch for validator selection. */ lagInEpochs: 2,
257
+ localEjectionThreshold: 196_000n * 10n ** 18n,
258
+ slashingDisableDuration: 5 * 24 * 60 * 60,
222
259
  slashingRoundSizeInEpochs: 4,
223
260
  slashingLifetimeInRounds: 40,
224
261
  slashingExecutionDelayInRounds: 28,
225
- slashingDisableDuration: 5 * 24 * 60 * 60,
226
262
  slashAmountSmall: 2_000n * 10n ** 18n,
227
263
  slashAmountMedium: 10_000n * 10n ** 18n,
228
264
  slashAmountLarge: 50_000n * 10n ** 18n,
@@ -234,7 +270,6 @@ export const ignitionL2ChainConfig = {
234
270
  /** The proving cost per mana */ provingCostPerMana: 0n,
235
271
  ejectionThreshold: 100_000n * 10n ** 18n,
236
272
  activationThreshold: 200_000n * 10n ** 18n,
237
- localEjectionThreshold: 196_000n * 10n ** 18n,
238
273
  governanceProposerRoundSize: 300,
239
274
  governanceProposerQuorum: 151,
240
275
  // Node slashing config
@@ -257,16 +292,44 @@ export const ignitionL2ChainConfig = {
257
292
  slashExecuteRoundsLookBack: 4,
258
293
  ...DefaultNetworkDBMapSizeConfig
259
294
  };
260
- const BOOTNODE_CACHE_DURATION_MS = 60 * 60 * 1000; // 1 hour;
261
- export async function getBootnodes(networkName, cacheDir) {
262
- const url = `http://static.aztec.network/${networkName}/bootnodes.json`;
263
- const data = await cachedFetch(url, {
264
- cacheDurationMs: BOOTNODE_CACHE_DURATION_MS,
265
- cacheFile: cacheDir ? join(cacheDir, networkName, 'bootnodes.json') : undefined
266
- });
267
- return data?.bootnodes;
268
- }
269
- export async function getL2ChainConfig(networkName, cacheDir) {
295
+ export const devnetL2ChainConfig = {
296
+ l1ChainId: 11155111,
297
+ testAccounts: true,
298
+ sponsoredFPC: true,
299
+ p2pEnabled: true,
300
+ disableTransactions: false,
301
+ p2pBootstrapNodes: [],
302
+ seqMinTxsPerBlock: 0,
303
+ seqMaxTxsPerBlock: 8,
304
+ realProofs: false,
305
+ snapshotsUrls: [],
306
+ autoUpdate: 'config-and-version',
307
+ autoUpdateUrl: '',
308
+ publicIncludeMetrics,
309
+ publicMetricsCollectorUrl: '',
310
+ publicMetricsCollectFrom: [
311
+ ''
312
+ ],
313
+ maxTxPoolSize: 100_000_000,
314
+ // Deployment stuff
315
+ /** How many seconds an L1 slot lasts. */ ethereumSlotDuration: 12,
316
+ /** How many seconds an L2 slots lasts (must be multiple of ethereum slot duration). */ aztecSlotDuration: 36,
317
+ /** How many L2 slots an epoch lasts. */ aztecEpochDuration: 8,
318
+ /** The target validator committee size. */ aztecTargetCommitteeSize: 1,
319
+ /** The number of epochs to lag behind the current epoch for validator selection. */ lagInEpochs: 1,
320
+ /** The local ejection threshold for a validator. Stricter than ejectionThreshold but local to a specific rollup */ localEjectionThreshold: DefaultL1ContractsConfig.localEjectionThreshold,
321
+ /** The number of epochs after an epoch ends that proofs are still accepted. */ aztecProofSubmissionEpochs: 1,
322
+ /** The deposit amount for a validator */ activationThreshold: DefaultL1ContractsConfig.activationThreshold,
323
+ /** The minimum stake for a validator. */ ejectionThreshold: DefaultL1ContractsConfig.ejectionThreshold,
324
+ /** The slashing round size */ slashingRoundSizeInEpochs: DefaultL1ContractsConfig.slashingRoundSizeInEpochs,
325
+ /** Governance proposing round size */ governanceProposerRoundSize: DefaultL1ContractsConfig.governanceProposerRoundSize,
326
+ /** The mana target for the rollup */ manaTarget: DefaultL1ContractsConfig.manaTarget,
327
+ /** The proving cost per mana */ provingCostPerMana: DefaultL1ContractsConfig.provingCostPerMana,
328
+ /** Exit delay for stakers */ exitDelaySeconds: DefaultL1ContractsConfig.exitDelaySeconds,
329
+ ...DefaultSlashConfig,
330
+ ...DefaultNetworkDBMapSizeConfig
331
+ };
332
+ export function getL2ChainConfig(networkName) {
270
333
  let config;
271
334
  if (networkName === 'staging-public') {
272
335
  config = {
@@ -280,31 +343,30 @@ export async function getL2ChainConfig(networkName, cacheDir) {
280
343
  config = {
281
344
  ...stagingIgnitionL2ChainConfig
282
345
  };
283
- } else if (networkName === 'ignition') {
346
+ } else if (networkName === 'mainnet') {
284
347
  config = {
285
- ...ignitionL2ChainConfig
348
+ ...mainnetL2ChainConfig
349
+ };
350
+ } else if (networkName === 'next-net') {
351
+ config = {
352
+ ...nextNetL2ChainConfig
353
+ };
354
+ } else if (networkName === 'devnet') {
355
+ config = {
356
+ ...devnetL2ChainConfig
286
357
  };
287
- }
288
- if (!config) {
289
- return undefined;
290
- }
291
- // If the bootnodes are not set, get them from the network
292
- const bootnodeKey = 'BOOTSTRAP_NODES';
293
- if (!process.env[bootnodeKey]) {
294
- config.p2pBootstrapNodes = await getBootnodes(networkName, cacheDir);
295
358
  }
296
359
  return config;
297
360
  }
298
361
  function getDefaultDataDir(networkName) {
299
362
  return path.join(process.env.HOME || '~', '.aztec', networkName, 'data');
300
363
  }
301
- export async function enrichEnvironmentWithChainConfig(networkName) {
364
+ export function enrichEnvironmentWithChainConfig(networkName) {
302
365
  if (networkName === 'local') {
303
366
  return;
304
367
  }
305
368
  enrichVar('DATA_DIRECTORY', getDefaultDataDir(networkName));
306
- const cacheDir = process.env.DATA_DIRECTORY ? join(process.env.DATA_DIRECTORY, 'cache') : undefined;
307
- const config = await getL2ChainConfig(networkName, cacheDir);
369
+ const config = getL2ChainConfig(networkName);
308
370
  if (!config) {
309
371
  throw new Error(`Unknown network name: ${networkName}`);
310
372
  }
@@ -378,4 +440,5 @@ export async function enrichEnvironmentWithChainConfig(networkName) {
378
440
  enrichVar('SLASH_OFFENSE_EXPIRATION_ROUNDS', config.slashOffenseExpirationRounds.toString());
379
441
  enrichVar('SLASH_MAX_PAYLOAD_SIZE', config.slashMaxPayloadSize.toString());
380
442
  enrichVar('SENTINEL_ENABLED', config.sentinelEnabled.toString());
443
+ enrichVar('TRANSACTIONS_DISABLED', config.disableTransactions.toString());
381
444
  }
@@ -1,4 +1,4 @@
1
- import { EthAddress } from '@aztec/aztec.js';
1
+ import { EthAddress } from '@aztec/aztec.js/addresses';
2
2
  export function enrichVar(envVar, value) {
3
3
  // Don't override
4
4
  if (process.env[envVar] || value === undefined) {
@@ -1,5 +1,5 @@
1
- import { EthAddress, type PXE } from '@aztec/aztec.js';
2
1
  import { type ContractArtifact, type FunctionAbi } from '@aztec/aztec.js/abi';
2
+ import { EthAddress } from '@aztec/aztec.js/addresses';
3
3
  import { type DeployL1ContractsReturnType, type L1ContractsConfig, type Operator, RollupContract } from '@aztec/ethereum';
4
4
  import { Fr } from '@aztec/foundation/fields';
5
5
  import type { LogFn, Logger } from '@aztec/foundation/log';
@@ -19,7 +19,7 @@ export declare function getFunctionAbi(artifact: ContractArtifact, fnName: strin
19
19
  * @param mnemonic - The mnemonic to be used in contract deployment.
20
20
  */
21
21
  export declare function deployAztecContracts(rpcUrls: string[], chainId: number, privateKey: string | undefined, mnemonic: string, mnemonicIndex: number, salt: number | undefined, initialValidators: Operator[], genesisArchiveRoot: Fr, feeJuicePortalInitialBalance: bigint, acceleratedTestDeployments: boolean, config: L1ContractsConfig, existingToken: EthAddress | undefined, realVerifier: boolean, createVerificationJson: string | false, debugLogger: Logger): Promise<DeployL1ContractsReturnType>;
22
- export declare function deployNewRollupContracts(registryAddress: EthAddress, rpcUrls: string[], chainId: number, privateKey: string | undefined, mnemonic: string, mnemonicIndex: number, salt: number | undefined, initialValidators: Operator[], genesisArchiveRoot: Fr, feeJuicePortalInitialBalance: bigint, config: L1ContractsConfig, realVerifier: boolean, logger: Logger): Promise<{
22
+ export declare function deployNewRollupContracts(registryAddress: EthAddress, rpcUrls: string[], chainId: number, privateKey: string | undefined, mnemonic: string, mnemonicIndex: number, salt: number | undefined, initialValidators: Operator[], genesisArchiveRoot: Fr, feeJuicePortalInitialBalance: bigint, config: L1ContractsConfig, realVerifier: boolean, createVerificationJson: string | false, logger: Logger): Promise<{
23
23
  rollup: RollupContract;
24
24
  slashFactoryAddress: EthAddress;
25
25
  }>;
@@ -60,10 +60,4 @@ export declare const stripLeadingHex: (hex: string) => string;
60
60
  */
61
61
  export declare const addLeadingHex: (hex: string) => `0x${string}`;
62
62
  export declare function prettyPrintNargoToml(config: NoirPackageConfig): string;
63
- /**
64
- * Checks that Private eXecution Environment (PXE) version matches the expected one by this CLI. Throws if not.
65
- * @param pxe - PXE client.
66
- * @param expectedVersionRange - Expected version by CLI.
67
- */
68
- export declare function checkServerVersion(pxe: PXE, expectedVersionRange: string): Promise<void>;
69
63
  //# sourceMappingURL=aztec.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"aztec.d.ts","sourceRoot":"","sources":["../../src/utils/aztec.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,KAAK,GAAG,EAAE,MAAM,iBAAiB,CAAC;AACvD,OAAO,EACL,KAAK,gBAAgB,EACrB,KAAK,WAAW,EAIjB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,KAAK,2BAA2B,EAChC,KAAK,iBAAiB,EACtB,KAAK,QAAQ,EACb,cAAc,EACf,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EAAE,EAAE,EAAE,MAAM,0BAA0B,CAAC;AAC9C,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAShE;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,QAAQ,EAAE,gBAAgB,EAAE,MAAM,EAAE,MAAM,GAAG,WAAW,CAMtF;AAED;;;;;;GAMG;AACH,wBAAsB,oBAAoB,CACxC,OAAO,EAAE,MAAM,EAAE,EACjB,OAAO,EAAE,MAAM,EACf,UAAU,EAAE,MAAM,GAAG,SAAS,EAC9B,QAAQ,EAAE,MAAM,EAChB,aAAa,EAAE,MAAM,EACrB,IAAI,EAAE,MAAM,GAAG,SAAS,EACxB,iBAAiB,EAAE,QAAQ,EAAE,EAC7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@aztec/aztec.js/abi';
2
+ import { EthAddress } from '@aztec/aztec.js/addresses';
3
3
  import { SecretValue } from '@aztec/foundation/config';
4
4
  import { Fr } from '@aztec/foundation/fields';
5
- import { protocolContractTreeRoot } from '@aztec/protocol-contracts';
5
+ import { protocolContractsHash } from '@aztec/protocol-contracts';
6
6
  import TOML from '@iarna/toml';
7
7
  import { readFile } from 'fs/promises';
8
- import { gtr, ltr, satisfies, valid } from 'semver';
9
8
  import { encodeArgs } from './encoding.js';
10
9
  /**
11
10
  * Helper to get an ABI function or throw error if it doesn't exist.
@@ -35,7 +34,7 @@ import { encodeArgs } from './encoding.js';
35
34
  const { getVKTreeRoot } = await import('@aztec/noir-protocol-circuits-types/vk-tree');
36
35
  const result = await deployL1Contracts(chain.rpcUrls, account, chain.chainInfo, debugLogger, {
37
36
  vkTreeRoot: getVKTreeRoot(),
38
- protocolContractTreeRoot,
37
+ protocolContractsHash,
39
38
  genesisArchiveRoot,
40
39
  salt,
41
40
  initialValidators,
@@ -47,7 +46,7 @@ import { encodeArgs } from './encoding.js';
47
46
  }, config, createVerificationJson);
48
47
  return result;
49
48
  }
50
- export async function deployNewRollupContracts(registryAddress, rpcUrls, chainId, privateKey, mnemonic, mnemonicIndex, salt, initialValidators, genesisArchiveRoot, feeJuicePortalInitialBalance, config, realVerifier, logger) {
49
+ export async function deployNewRollupContracts(registryAddress, rpcUrls, chainId, privateKey, mnemonic, mnemonicIndex, salt, initialValidators, genesisArchiveRoot, feeJuicePortalInitialBalance, config, realVerifier, createVerificationJson, logger) {
51
50
  const { createEthereumChain, deployRollupForUpgrade, createExtendedL1Client } = await import('@aztec/ethereum');
52
51
  const { mnemonicToAccount, privateKeyToAccount } = await import('viem/accounts');
53
52
  const { getVKTreeRoot } = await import('@aztec/noir-protocol-circuits-types/vk-tree');
@@ -75,13 +74,13 @@ export async function deployNewRollupContracts(registryAddress, rpcUrls, chainId
75
74
  const { rollup, slashFactoryAddress } = await deployRollupForUpgrade(client, {
76
75
  salt,
77
76
  vkTreeRoot: getVKTreeRoot(),
78
- protocolContractTreeRoot,
77
+ protocolContractsHash,
79
78
  genesisArchiveRoot,
80
79
  initialValidators,
81
80
  feeJuicePortalInitialBalance,
82
81
  realVerifier,
83
82
  ...config
84
- }, registryAddress, logger, config);
83
+ }, registryAddress, logger, config, createVerificationJson);
85
84
  return {
86
85
  rollup,
87
86
  slashFactoryAddress
@@ -178,27 +177,3 @@ export async function deployNewRollupContracts(registryAddress, rpcUrls, chainId
178
177
  });
179
178
  return partialToml + '\n[dependencies]\n' + dependenciesToml.join('\n') + '\n';
180
179
  }
181
- /** Mismatch between server and client versions. */ class VersionMismatchError extends Error {
182
- }
183
- /**
184
- * Checks that Private eXecution Environment (PXE) version matches the expected one by this CLI. Throws if not.
185
- * @param pxe - PXE client.
186
- * @param expectedVersionRange - Expected version by CLI.
187
- */ export async function checkServerVersion(pxe, expectedVersionRange) {
188
- const serverName = 'Aztec Node';
189
- const { nodeVersion } = await pxe.getNodeInfo();
190
- if (!nodeVersion) {
191
- throw new VersionMismatchError(`Couldn't determine ${serverName} version. You may run into issues.`);
192
- }
193
- if (!nodeVersion || !valid(nodeVersion)) {
194
- throw new VersionMismatchError(`Missing or invalid version identifier for ${serverName} (${nodeVersion ?? 'empty'}).`);
195
- } else if (!satisfies(nodeVersion, expectedVersionRange)) {
196
- if (gtr(nodeVersion, expectedVersionRange)) {
197
- throw new VersionMismatchError(`${serverName} is running version ${nodeVersion} which is newer than the expected by this CLI (${expectedVersionRange}). Consider upgrading your CLI to a newer version.`);
198
- } else if (ltr(nodeVersion, expectedVersionRange)) {
199
- throw new VersionMismatchError(`${serverName} is running version ${nodeVersion} which is older than the expected by this CLI (${expectedVersionRange}). Consider upgrading your ${serverName} to a newer version.`);
200
- } else {
201
- throw new VersionMismatchError(`${serverName} is running version ${nodeVersion} which does not match the expected by this CLI (${expectedVersionRange}).`);
202
- }
203
- }
204
- }
@@ -1,11 +1,10 @@
1
1
  import { FunctionSelector } from '@aztec/aztec.js/abi';
2
- import { AztecAddress } from '@aztec/aztec.js/addresses';
3
- import { EthAddress } from '@aztec/aztec.js/eth_address';
2
+ import { AztecAddress, EthAddress } from '@aztec/aztec.js/addresses';
4
3
  import { Fr } from '@aztec/aztec.js/fields';
5
- import { LogId } from '@aztec/aztec.js/log_id';
6
- import { TxHash } from '@aztec/aztec.js/tx_hash';
4
+ import { LogId } from '@aztec/aztec.js/log';
5
+ import { TxHash } from '@aztec/aztec.js/tx';
7
6
  import type { LogFn } from '@aztec/foundation/log';
8
- import type { PXE } from '@aztec/stdlib/interfaces/client';
7
+ import type { PXE } from '@aztec/pxe/server';
9
8
  import { PublicKeys } from '@aztec/stdlib/keys';
10
9
  import { type Command, Option } from 'commander';
11
10
  /**
@@ -16,8 +15,8 @@ export declare const getLocalhost: () => Promise<string>;
16
15
  export declare const LOCALHOST: string;
17
16
  export declare const ETHEREUM_HOSTS: string, PRIVATE_KEY: string | undefined, MNEMONIC: string | undefined, API_KEY: string | undefined, CLI_VERSION: string | undefined;
18
17
  export declare function addOptions(program: Command, options: Option[]): Command;
19
- export declare const makePxeOption: (mandatory: boolean) => Option;
20
- export declare const pxeOption: Option;
18
+ export declare const makeNodeOption: (mandatory: boolean) => Option;
19
+ export declare const nodeOption: Option;
21
20
  export declare const l1ChainIdOption: Option;
22
21
  export declare const createSecretKeyOption: (description: string, mandatory: boolean, argsParser?: (value: string, previous: Fr) => Fr) => Option;
23
22
  export declare const logJson: (log: LogFn) => (obj: object) => void;
@@ -1 +1 @@
1
- {"version":3,"file":"commands.d.ts","sourceRoot":"","sources":["../../src/utils/commands.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AACzD,OAAO,EAAE,EAAE,EAAE,MAAM,wBAAwB,CAAC;AAC5C,OAAO,EAA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,GAAG,EAAE,CAMvD;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,SAAS,EAAE,MAAM,GAAG,EAAE,CAMpD;AAED;;;;;GAKG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,MAAM,GAAG,EAAE,CAyB5C;AAED;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,EAAE,GAAG,EAAE,EAAE,CAElD;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,MAAM,CAcjE"}
@@ -1,9 +1,8 @@
1
1
  import { FunctionSelector } from '@aztec/aztec.js/abi';
2
- import { AztecAddress } from '@aztec/aztec.js/addresses';
3
- import { EthAddress } from '@aztec/aztec.js/eth_address';
2
+ import { AztecAddress, EthAddress } from '@aztec/aztec.js/addresses';
4
3
  import { Fr } from '@aztec/aztec.js/fields';
5
- import { LogId } from '@aztec/aztec.js/log_id';
6
- import { TxHash } from '@aztec/aztec.js/tx_hash';
4
+ import { LogId } from '@aztec/aztec.js/log';
5
+ import { TxHash } from '@aztec/aztec.js/tx';
7
6
  import { PublicKeys } from '@aztec/stdlib/keys';
8
7
  import { CommanderError, InvalidArgumentError, Option } from 'commander';
9
8
  import { lookup } from 'dns/promises';
@@ -18,8 +17,8 @@ export function addOptions(program, options) {
18
17
  options.forEach((option)=>program.addOption(option));
19
18
  return program;
20
19
  }
21
- export const makePxeOption = (mandatory)=>new Option('-u, --rpc-url <string>', 'URL of the PXE').env('PXE_URL').default(`http://${LOCALHOST}:8080`).conflicts('remote-pxe').makeOptionMandatory(mandatory);
22
- export const pxeOption = makePxeOption(true);
20
+ export const makeNodeOption = (mandatory)=>new Option('-n, --node-url <string>', 'URL of the Aztec node').env('AZTEC_NODE_URL').default(`http://${LOCALHOST}:8080`).makeOptionMandatory(mandatory);
21
+ export const nodeOption = makeNodeOption(true);
23
22
  export const l1ChainIdOption = new Option('-c, --l1-chain-id <number>', 'Chain ID of the ethereum host').env('L1_CHAIN_ID').default(31337).argParser((value)=>{
24
23
  const parsedValue = Number(value);
25
24
  if (isNaN(parsedValue)) {
@@ -1,17 +1,10 @@
1
- import type { ContractArtifact, Fr } from '@aztec/aztec.js';
2
1
  import type { LogFn } from '@aztec/foundation/log';
3
- import type { PXE } from '@aztec/stdlib/interfaces/client';
2
+ import type { AztecNode } from '@aztec/stdlib/interfaces/client';
4
3
  import type { TxHash } from '@aztec/stdlib/tx';
5
- export declare function inspectBlock(pxe: PXE, blockNumber: number, log: LogFn, opts?: {
4
+ export declare function inspectBlock(aztecNode: AztecNode, blockNumber: number, log: LogFn, opts?: {
6
5
  showTxs?: boolean;
7
6
  }): Promise<void>;
8
- export declare function inspectTx(pxe: PXE, txHash: TxHash, log: LogFn, opts?: {
7
+ export declare function inspectTx(aztecNode: AztecNode, txHash: TxHash, log: LogFn, opts?: {
9
8
  includeBlockInfo?: boolean;
10
- artifactMap?: ArtifactMap;
11
9
  }): Promise<void>;
12
- type ArtifactMap = Record<string, ContractArtifactWithClassId>;
13
- type ContractArtifactWithClassId = ContractArtifact & {
14
- classId: Fr;
15
- };
16
- export {};
17
10
  //# sourceMappingURL=inspect.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"inspect.d.ts","sourceRoot":"","sources":["../../src/utils/inspect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAgB,gBAAgB,EAAE,EAAE,EAAE,MAAM,iBAAiB,CAAC;AAC1E,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAGnD,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,iCAAiC,CAAC;AAE3D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAE/C,wBAAsB,YAAY,CAAC,GAAG,EAAE,GAAG,EAAE,WAAW,EAAE,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,IAAI,GAAE;IAAE,OAAO,CAAC,EAAE,O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