Skip to content

Commit c6f2078

Browse files
authored
Bold migration changes (#87)
* Bold Migration Support * small fixes * update custom.ts * lint * add sepolia * enable sourcify
1 parent cf67cd0 commit c6f2078

File tree

6 files changed

+21
-18
lines changed

6 files changed

+21
-18
lines changed

scripts/boldUpgradeCommon.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ export interface Config {
8787
threshold: number
8888
replenishRateInBasis: number
8989
}
90+
espressoTEEVerifier: string
9091
}
9192
validators: string[]
9293
}
@@ -202,7 +203,6 @@ export const validateConfig = async (
202203
}
203204
}
204205
}
205-
206206
// check delaybuffer settings
207207
if (config.settings.isDelayBufferable) {
208208
if (config.settings.bufferConfig.max === 0) {

scripts/deployment.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@ async function main() {
7373
RollupAdminLogic: contracts.rollupAdmin.address,
7474
RollupUserLogic: contracts.rollupUser.address,
7575
UpgradeExecutor: contracts.upgradeExecutor.address,
76-
ValidatorUtils: contracts.validatorUtils.address,
7776
ValidatorWalletCreator: contracts.validatorWalletCreator.address,
7877
RollupCreator: contracts.rollupCreator.address,
7978
DeployHelper: contracts.deployHelper.address,

scripts/files/configs/custom.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,13 @@ export const custom: Config = {
3636
smallStepLeafSize: 2 ** 23, // do not change unless you know what you're doing
3737
numBigStepLevel: 1, // do not change unless you know what you're doing
3838
maxDataSize: 117964, // if you're an L3, this should be set to 104857
39-
isDelayBufferable: true, // it is recommended to keep this as true, even if you don't use the feature
39+
isDelayBufferable: false, // keep this as false for Espresso Integration
4040
bufferConfig: {
4141
max: 2 ** 32 - 1, // maximum buffer size, set artificially high to disable
4242
threshold: 2 ** 32 - 1, // keep above typical posting frequency. set artificially high to disable
4343
replenishRateInBasis: 500, // 5% replenishment rate
4444
},
45+
espressoTEEVerifier: '', // address of the TEE verifier
4546
},
4647
// validators to be whitelisted on the new rollup
4748
validators: [],

scripts/files/templatesV3.1.ts

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -58,27 +58,27 @@ export const templates: {
5858
11155111: {
5959
eth: {
6060
bridge: '0x331Edb39Eb823602484cD9F28bBC34cE4B9e76D9',
61-
sequencerInbox: '0x9a4332b77d150AB19388e7F01B686De91a3Eadf1',
61+
sequencerInbox: '0x79C5c3c8355daDC0d48D37eDC3Cb5ac73cB5b9d2',
6262
delayBufferableSequencerInbox:
63-
'0x6F753199ebe6aAb140838185c7D5ef17b46f7f88',
63+
'0xa9CF9009cF206f287a0DaB15BafA733D926Cd8D5',
6464
inbox: '0x10cf5c20F6b774dBDC68FAa58dE00406cfB07dc7',
6565
rollupEventInbox: '0x048506cA2683d137C25a34fE055339CE522Ddd00',
6666
outbox: '0x829856Cf500eA1cA32eB922b73c6872250682E28',
6767
},
6868
erc20: {
6969
bridge: '0xE46b560190Aa928fBCE2AF3060bC655EBD42C078',
70-
sequencerInbox: '0xB3748F67a36C4e006935AB96bCcF48E0732b1626',
70+
sequencerInbox: '0xBf7369FfA156112d5fD69809d9d522CDd6F6FF2b',
7171
delayBufferableSequencerInbox:
72-
'0xfA93a2dcdE904fcF60233bA820336cbd71DB253B',
72+
'0xbD354C43f413AE54B316eE174e032346FA3B4F79',
7373
inbox: '0xF3dF0Ed5B5a205df214d04DAEE9d9b5621AD83bA',
7474
rollupEventInbox: '0xfE91F555Ce6892C4D357Be2fBC6d2f485072a39f',
7575
outbox: '0x2f61CF4C5C57026AA74d41F254147e931b0b4314',
7676
},
77-
rollupUserLogic: '0x8c7ff54b854E40b52192C7eE89235d41f2d7fC58',
78-
rollupAdminLogic: '0xEC81CC24cebe8511CD1B742Ff910b447FeB9dF66',
77+
rollupUserLogic: '0xBfBb290467d8bb057aAc85BA4Dace287D3BB996E',
78+
rollupAdminLogic: '0xd0e617fb878533253F69C55E4a15aEBA7016FBac',
7979
challengeManagerTemplate: '0x6B21677CeAd8bF6526d4A27D144579c9eB46f0eB',
8080
osp: '0x1B9bd7B42516220f7A3e8a620Df7045b9b9A5ef1',
81-
rollupCreator: '0x687Bc1D23390875a868Db158DA1cDC8998E31640',
81+
rollupCreator: '0x0D7D6fB89f6a45d7c9F7dc3F2e6183445d14C8b1',
8282
},
8383

8484
// Arbitrum One
@@ -139,7 +139,7 @@ export const templates: {
139139
421614: {
140140
eth: {
141141
bridge: '0x860b23D7CD5797274D6BE385F6A629C734DFB448',
142-
sequencerInbox: '0x72198537ffabDc70dc7a8c1A0B7532BA2eadCBEd',
142+
sequencerInbox: '0xFedf426884f8713b5d7cE84F41e3acAe625Bf23a',
143143
delayBufferableSequencerInbox:
144144
'0x23Cb9fca677B5cf04D859D5d98aDc93016C97EC4',
145145
inbox: '0x476B0126252E56E103918FFf6eD7eb80Ad97Ddbb',
@@ -148,18 +148,18 @@ export const templates: {
148148
},
149149
erc20: {
150150
bridge: '0x646dE495dca9E006760a64D19Df01369B42f862a',
151-
sequencerInbox: '0xd70Ee45dFe94CFDf7c05231cc87F77C541a32340',
151+
sequencerInbox: '0x6220f0d597E224871E734c124199cC29Aa6FB463',
152152
delayBufferableSequencerInbox:
153153
'0x968306A79555234Fb796090479df3E0F805cD32A',
154154
inbox: '0x975c02Cd7d879602638068F3edB1bda092e43bfB',
155155
rollupEventInbox: '0x0b0731c4C66D5805b55d8BD0086546248510449B',
156156
outbox: '0xD5f920B14F5EDA221776F5FeE948e36DffE43c5D',
157157
},
158-
rollupUserLogic: '0xe9F561c87E1289C5eA60814f522922a1619897AE',
159-
rollupAdminLogic: '0x7FA087B469E26B653F3B495c537a8796B42AD883',
158+
rollupUserLogic: '0x66BEd0aF80663A453d5019E0Bd30c646e8C53c89',
159+
rollupAdminLogic: '0x2b464Da7f89A99b70E94aa5EDe66742712875687',
160160
challengeManagerTemplate: '0x22DD61cF5e1f19A4D98C08478E2f83DFb3FCe44C',
161161
osp: '0x61287c070a7281165666D367953f9A12c7616550',
162-
rollupCreator: '0x5F45675AC8DDF7d45713b2c7D191B287475C16cF',
162+
rollupCreator: '0x73FEaCB3EB0653D7DC208DB5424Df93a8CFf7604',
163163
},
164164

165165
// Base

src/bridge/SequencerInbox.sol

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,10 +141,11 @@ contract SequencerInbox is DelegateCallAware, GasRefundEnabled, ISequencerInbox
141141
bool internal immutable hostChainIsArbitrum = ArbitrumChecker.runningOnArbitrum();
142142
// True if the chain this SequencerInbox is deployed on uses custom fee token
143143
bool public immutable isUsingFeeToken;
144+
IEspressoTEEVerifier public espressoTEEVerifier;
145+
144146
// True if the SequencerInbox is delay bufferable
145147
bool public immutable isDelayBufferable;
146148

147-
IEspressoTEEVerifier public espressoTEEVerifier;
148149

149150
constructor(
150151
uint256 _maxDataSize,

src/rollup/BOLDUpgradeAction.sol

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@ contract BOLDUpgradeAction {
171171
uint256 public immutable BIGSTEP_LEAF_SIZE;
172172
uint256 public immutable SMALLSTEP_LEAF_SIZE;
173173
uint8 public immutable NUM_BIGSTEP_LEVEL;
174+
address public immutable ESPRESSO_TEE_VERIFIER;
174175

175176
address public immutable EXCESS_STAKE_RECEIVER;
176177
IOldRollup public immutable OLD_ROLLUP;
@@ -236,6 +237,7 @@ contract BOLDUpgradeAction {
236237
uint64 challengeGracePeriodBlocks;
237238
bool isDelayBufferable;
238239
BufferConfig bufferConfig;
240+
address espressoTEEVerifier;
239241
}
240242

241243
// Unfortunately these are not discoverable on-chain, so we need to supply them
@@ -318,6 +320,7 @@ contract BOLDUpgradeAction {
318320
MAX = settings.bufferConfig.max;
319321
THRESHOLD = settings.bufferConfig.threshold;
320322
REPLENISH_RATE_IN_BASIS = settings.bufferConfig.replenishRateInBasis;
323+
ESPRESSO_TEE_VERIFIER = settings.espressoTEEVerifier;
321324
}
322325

323326
/// @dev Refund the existing stakers, pause and upgrade the current rollup to
@@ -393,8 +396,7 @@ contract BOLDUpgradeAction {
393396
numBigStepLevel: NUM_BIGSTEP_LEVEL,
394397
challengeGracePeriodBlocks: CHALLENGE_GRACE_PERIOD_BLOCKS,
395398
bufferConfig: bufferConfig,
396-
// TODO: fix during migration
397-
espressoTEEVerifier: address(0)
399+
espressoTEEVerifier: ESPRESSO_TEE_VERIFIER
398400
});
399401
}
400402

0 commit comments

Comments
 (0)