Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

try out a delegatecall used module #182

Closed
wants to merge 96 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
96 commits
Select commit Hold shift + click to select a range
2fe35e6
feat: logic wip
johnnyonline Sep 9, 2024
47a5837
pre-redesign
johnnyonline Sep 10, 2024
9843a92
feat: new design layout wip
johnnyonline Sep 13, 2024
812a0a1
feat: tests wip
johnnyonline Sep 14, 2024
8958973
feat: tests wip
johnnyonline Sep 14, 2024
48f6183
feat: tests wip
johnnyonline Sep 15, 2024
4d1049c
feat: tests wip
johnnyonline Sep 15, 2024
c594ec4
feat: pre req withdrawal tests
johnnyonline Sep 16, 2024
9aefcf8
feat: pre precision fix
johnnyonline Sep 16, 2024
a724e59
feat: setup tests wip
johnnyonline Sep 17, 2024
2f54591
fix: tests
johnnyonline Sep 17, 2024
7b35647
fix: https://github.com/yieldnest/yieldnest-protocol/pull/164#discuss…
johnnyonline Sep 19, 2024
92540f4
fix: move withdraw logic to strategy manager
johnnyonline Sep 19, 2024
4731a19
chore: remove comments
johnnyonline Sep 19, 2024
02260f0
chore: remove redundant deps
johnnyonline Sep 19, 2024
cc5c202
feat: refactor token wrapping
johnnyonline Sep 23, 2024
fc6afc0
fix: ci
johnnyonline Sep 24, 2024
a9ff9bc
chore: remove console.log
johnnyonline Sep 24, 2024
24b72b5
chore: add curly brackets
johnnyonline Sep 24, 2024
2de43b7
feat: move toUserAssetAmount to LSDWrapper
johnnyonline Sep 25, 2024
9895e89
fix: event
johnnyonline Sep 25, 2024
6e73ce7
chore: add natspec
johnnyonline Sep 25, 2024
8ba709a
feat: optimize getStakedAssetsBalances
johnnyonline Sep 26, 2024
2ae7917
feat: bundle call
johnnyonline Sep 26, 2024
be925af
feat: optimize gas on getStakedAssetsBalances()
johnnyonline Sep 27, 2024
471afc7
feat: optimize gas on getStakedAssetsBalances() with solady
johnnyonline Sep 27, 2024
2918a37
feat: remove from inner loop poc - costs more gas
johnnyonline Sep 27, 2024
9803beb
fix: revert last poc
johnnyonline Sep 28, 2024
e057891
fix: slashing is not accounted for bug - before testing
johnnyonline Sep 28, 2024
3e72400
fix: fix the fix
johnnyonline Sep 28, 2024
961b82f
feat: getStakedAssetsBalances caching poc - wip
johnnyonline Sep 28, 2024
9d06c29
feat: finish updateTokenStakingNodesBalances
johnnyonline Sep 30, 2024
f4ba006
fix: natspec
johnnyonline Oct 1, 2024
6854acc
fix: natspec
johnnyonline Oct 1, 2024
7b645bc
feat: small gas optimization
johnnyonline Oct 1, 2024
6c43014
chore: cleanup test file
johnnyonline Oct 1, 2024
c0acfa0
fix: tests
johnnyonline Oct 2, 2024
7323c90
feat: preview redeem tests
johnnyonline Oct 2, 2024
ad31f80
feat: asset registry tests
johnnyonline Oct 2, 2024
a59e397
Merge branch 'release-candidate' into yneigen-withdrawals
johnnyonline Oct 3, 2024
40db1d2
fix: https://github.com/yieldnest/yieldnest-protocol/pull/164#discuss…
johnnyonline Oct 3, 2024
1cab439
feat: small gas save
johnnyonline Oct 3, 2024
753bec9
chore: https://github.com/yieldnest/yieldnest-protocol/pull/164#discu…
johnnyonline Oct 3, 2024
cb91223
chore: https://github.com/yieldnest/yieldnest-protocol/pull/164#discu…
johnnyonline Oct 4, 2024
8c786c7
fix: add event
johnnyonline Oct 4, 2024
d78bbc0
feat: https://github.com/yieldnest/yieldnest-protocol/pull/164#discus…
johnnyonline Oct 4, 2024
8f79bf7
fix issue with public strategy parameter
danoctavian Oct 4, 2024
e90f9a8
recalculate updateTokenStakingNodesBalances only when completing with…
danoctavian Oct 5, 2024
9abcb26
add test and full implementation of _getStakedAssetBalanceForNode
danoctavian Oct 6, 2024
2bbcf0a
make functions external for reading staked balances
danoctavian Oct 6, 2024
8946815
remove unused assertions
danoctavian Oct 6, 2024
1e80692
add test completeQueuedWithdrawals
danoctavian Oct 6, 2024
c62f249
add test for completeQueuedWithdrawals
danoctavian Oct 6, 2024
fdf6a69
add event to updates
danoctavian Oct 6, 2024
b3b7b11
enhance PrincipalWithdrawalProcessed event
danoctavian Oct 6, 2024
06f25ee
assert totalAssets stays the same after withdrawal completion
danoctavian Oct 6, 2024
1145d04
add natspec
danoctavian Oct 7, 2024
2ee2884
perform storage write only if values changed
danoctavian Oct 7, 2024
bb4bf49
add optional updating of stakedAssets
danoctavian Oct 7, 2024
fb74082
feat: ynFoo deployment script
johnnyonline Oct 10, 2024
940dba9
chore: remove commented out
johnnyonline Oct 10, 2024
522420b
feat: ynfoo depl
johnnyonline Oct 10, 2024
2d2faf9
feat: merge RC
johnnyonline Oct 15, 2024
7412dff
fix: https://github.com/yieldnest/yieldnest-protocol/pull/164#discuss…
johnnyonline Oct 15, 2024
d44da58
fix: https://github.com/yieldnest/yieldnest-protocol/pull/164#discuss…
johnnyonline Oct 15, 2024
a84dc08
fix: https://github.com/yieldnest/yieldnest-protocol/pull/164#discuss…
johnnyonline Oct 15, 2024
1de23e6
fix: https://github.com/yieldnest/yieldnest-protocol/pull/164#discuss…
johnnyonline Oct 17, 2024
691771a
fix https://github.com/yieldnest/yieldnest-protocol/pull/164#discussi…
johnnyonline Oct 17, 2024
ba302f1
fix: https://github.com/yieldnest/yieldnest-protocol/pull/164#discuss…
johnnyonline Oct 17, 2024
faa2212
feat: ynupgrader wip
johnnyonline Oct 19, 2024
cee5a5a
fix ynEigenViewer code
danoctavian Sep 17, 2024
b4f6ebb
add updated test for ynEigenViewer
danoctavian Sep 17, 2024
202a014
make the current files ammenable for running upgradeability scripts
danoctavian Sep 17, 2024
6c5f9d0
expand AssetInfo
danoctavian Sep 17, 2024
69fc32d
add natspec and sections
danoctavian Sep 17, 2024
b800dea
add assertion for total assets
danoctavian Sep 17, 2024
a921388
add deployment files
danoctavian Sep 17, 2024
e732ee6
update upgrade script to work with new changes to BaseYnEigenScript
danoctavian Sep 18, 2024
beae5c7
remove previously unverifiable deployment
danoctavian Oct 19, 2024
ef2d55b
feat: claim preview and temp deployment stuff
johnnyonline Oct 21, 2024
bc40825
feat: merge rcMerge branch 'release-candidate' into yneigen-withdrawals
johnnyonline Oct 21, 2024
3d06491
chore: rename test temp name
johnnyonline Oct 21, 2024
6fddda4
fix: zokyo m3
johnnyonline Oct 21, 2024
6c507eb
fix: zokyo l7
johnnyonline Oct 21, 2024
180618d
fix: zokyo l9
johnnyonline Oct 21, 2024
dabe169
fix: zokyo l11
johnnyonline Oct 21, 2024
225b9fc
fix: zokyo l14
johnnyonline Oct 21, 2024
c5f0683
fix: zokyo l17
johnnyonline Oct 21, 2024
2871083
fix: zokyo l18
johnnyonline Oct 21, 2024
33d2a55
delete README blank space
danoctavian Oct 21, 2024
2e19b53
Merge pull request #166 from yieldnest/fix/yneigenviewer-total-assets
danoctavian Oct 21, 2024
3e162d9
add disable initializers to RedemptionAssetsVault
danoctavian Oct 21, 2024
c959a36
chore: manually revert l11
johnnyonline Oct 22, 2024
e6189cb
try out a delegatecall used module
danoctavian Oct 23, 2024
0a001f5
fix oeth wrapping
danoctavian Oct 23, 2024
eaf990c
attempt at using delegatecall
danoctavian Oct 23, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@
[submodule "lib/eigenlayer-contracts"]
path = lib/eigenlayer-contracts
url = https://github.com/layr-labs/eigenlayer-contracts
commit = bda003385c5fec59e35196dc14d01f17d1eb7001
commit = bda003385c5fec59e35196dc14d01f17d1eb7001
4 changes: 0 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,6 @@
| ynETH Redemption Assets Vault | [`0xF0207Ffa0b793E009DF9Df62fEE95B8FC6c93EcF`](https://etherscan.io/address/0x5D6e53c42E3B37f82F693937BC508940769c5caf) |
| WithdrawalsProcessor | [`0x61810a90128ee5c5f5a3730f0449da9e9480f888`](https://etherscan.io/address/0x6d052CdEd3F64aea51f6051F33b68b42016C5FbA) |





## Holesky

### Contracts
Expand Down
2 changes: 1 addition & 1 deletion deployments/YnLSDe-1.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,4 @@
"proxyAdmin-ynEigenViewer": "0x40fBdD124e80fF168574Fa7823440E574345307E",
"tokenStakingNodeImplementation": "0x57e1D090B1aF526CD4174019D5b9702EEBE236FA",
"upgradeTimelock": "0xbB73f8a5B0074b27c6df026c77fA08B0111D017A"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
{
"transactions": [
{
"hash": "0x6645dc197a9f650c593571384bf632b68982fc986dc0c750f4f9acd5c828f2e4",
"transactionType": "CREATE",
"contractName": "ynEigenViewer",
"contractAddress": "0xbea193a39958bc175b10cc1dfc742e5a3ebaafaf",
"function": null,
"arguments": [
"0xaD31546AdbfE1EcD7137310508f112039a35b6F7",
"0x071bdC8eDcdD66730f45a3D3A6F794FAA37C75ED",
"0x5c20D1a85C7d9acB503135a498E26Eb55d806552",
"0xd68C29263F6dC2Ff8D9307b3AfAcD6D6fDeFbB3A"
],
"transaction": {
"from": "0xd7d4a7f14265b0a69ae482b85b0a8496c3f99fb9",
"gas": "0x15c9de",
"value": "0x0",
"input": "0x61010060405234801562000011575f80fd5b506040516200143238038062001432833981016040819052620000349162000073565b6001600160a01b0393841660805291831660a052821660c0521660e052620000cd565b80516001600160a01b03811681146200006e575f80fd5b919050565b5f805f806080858703121562000087575f80fd5b620000928562000057565b9350620000a26020860162000057565b9250620000b26040860162000057565b9150620000c26060860162000057565b905092959194509250565b60805160a05160c05160e0516112de620001545f395f818161015d015261063b01525f8181610136015261076301525f818160ef015281816103a2015281816107ec0152818161086f0152818161093701528181610bee01528181610d110152610d6801525f8181610184015281816101cd015281816102e6015261044c01526112de5ff3fe608060405234801561000f575f80fd5b506004361061009b575f3560e01c80637c0867af116100635780637c0867af14610131578063949db65814610158578063979d7e861461017f5780639d8e2177146101a6578063b8f82b26146101b5575f80fd5b8063075c2b191461009f5780632e0f2625146100bd5780633ff36802146100d557806363f7bad5146100ea578063679aefce14610129575b5f80fd5b6100a76101c8565b6040516100b49190610e2c565b60405180910390f35b6100c7620f424081565b6040519081526020016100b4565b6100dd61075f565b6040516100b49190610ef0565b6101117f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020016100b4565b6100c76107e8565b6101117f000000000000000000000000000000000000000000000000000000000000000081565b6101117f000000000000000000000000000000000000000000000000000000000000000081565b6101117f000000000000000000000000000000000000000000000000000000000000000081565b6100c7670de0b6b3a764000081565b6100c76101c3366004610f53565b610933565b60605f7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166367e4ac2c6040518163ffffffff1660e01b81526004015f60405180830381865afa158015610226573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f1916820160405261024d9190810190610fe5565b80519091508067ffffffffffffffff81111561026b5761026b610f7d565b6040519080825280602002602001820160405280156102e057816020015b6102cd6040518060e001604052805f6001600160a01b0316815260200160608152602001606081526020015f81526020015f81526020015f81526020015f81525090565b8152602001906001900390816102895790505b5092505f7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663613e85ff6040518163ffffffff1660e01b81526004015f60405180830381865afa15801561033f573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f19168201604052610366919081019061107f565b90508051821461039f578051604051631f4bb7c160e31b8152610396918491600401918252602082015260400190565b60405180910390fd5b5f7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166301e1d1146040518163ffffffff1660e01b8152600401602060405180830381865afa1580156103fc573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906104209190611100565b90505f5b83811015610757575f83828151811061043f5761043f611117565b602002602001015190505f7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316631cbf960d88858151811061048b5761048b611117565b6020026020010151846040518363ffffffff1660e01b81526004016104c59291906001600160a01b03929092168252602082015260400190565b602060405180830381865afa1580156104e0573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906105049190611100565b90506040518060e0016040528088858151811061052357610523611117565b60200260200101516001600160a01b0316815260200188858151811061054b5761054b611117565b60200260200101516001600160a01b03166306fdde036040518163ffffffff1660e01b81526004015f60405180830381865afa15801561058d573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f191682016040526105b4919081019061112b565b81526020018885815181106105cb576105cb611117565b60200260200101516001600160a01b03166395d89b416040518163ffffffff1660e01b81526004015f60405180830381865afa15801561060d573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f19168201604052610634919081019061112b565b81526020017f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316630ba9d8ca8a878151811061067a5761067a611117565b60200260200101516040518263ffffffff1660e01b81526004016106ad91906001600160a01b0391909116815260200190565b602060405180830381865afa1580156106c8573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906106ec9190611100565b81526020015f831180156106ff57505f86115b610709575f610721565b85610717620f4240856111ba565b61072191906111dd565b81526020018281526020018381525088848151811061074257610742611117565b60209081029190910101525050600101610424565b505050505090565b60607f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663a1174e7d6040518163ffffffff1660e01b81526004015f60405180830381865afa1580156107bc573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f191682016040526107e391908101906111fc565b905090565b5f807f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166318160ddd6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610846573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061086a9190611100565b90505f7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166301e1d1146040518163ffffffff1660e01b8152600401602060405180830381865afa1580156108c9573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108ed9190611100565b90508115806108fa575080155b1561090f57670de0b6b3a76400009250505090565b8161092282670de0b6b3a76400006111ba565b61092c91906111dd565b9250505090565b5f807f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166352f94f986040518163ffffffff1660e01b8152600401602060405180830381865afa158015610991573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906109b59190611286565b90505f816001600160a01b0316634e6c97666040518163ffffffff1660e01b8152600401602060405180830381865afa1580156109f4573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610a189190611286565b90505f826001600160a01b031663c1fe3e486040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a57573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610a7b9190611286565b90505f836001600160a01b031663daba667d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610aba573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610ade9190611286565b90505f846001600160a01b0316634aa07e646040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b1d573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610b419190611286565b9050836001600160a01b0316886001600160a01b031603610c67576040516363737ac960e11b8152600481018890525f906001600160a01b0384169063c6e6f59290602401602060405180830381865afa158015610ba1573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610bc59190611100565b604051635c7c159360e11b81526001600160a01b038581166004830152602482018390529192507f00000000000000000000000000000000000000000000000000000000000000009091169063b8f82b26906044015b602060405180830381865afa158015610c36573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610c5a9190611100565b9650505050505050610dd9565b826001600160a01b0316886001600160a01b031603610d425760405162b0e38960e81b8152600481018890525f906001600160a01b0383169063b0e3890090602401602060405180830381865afa158015610cc4573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610ce89190611100565b604051635c7c159360e11b81526001600160a01b038481166004830152602482018390529192507f00000000000000000000000000000000000000000000000000000000000000009091169063b8f82b2690604401610c1b565b604051635c7c159360e11b81526001600160a01b038981166004830152602482018990527f0000000000000000000000000000000000000000000000000000000000000000169063b8f82b2690604401602060405180830381865afa158015610dad573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610dd19190611100565b955050505050505b92915050565b5f5b83811015610df9578181015183820152602001610de1565b50505f910152565b5f8151808452610e18816020860160208601610ddf565b601f01601f19169290920160200192915050565b5f60208083018184528085518083526040925060408601915060408160051b8701018488015f5b83811015610ee257888303603f19018552815180516001600160a01b031684528781015160e089860181905290610e8c82870182610e01565b9150508782015185820389870152610ea48282610e01565b606084810151908801526080808501519088015260a0808501519088015260c093840151939096019290925250509386019390860190600101610e53565b509098975050505050505050565b602080825282518282018190525f9190848201906040850190845b81811015610f305783516001600160a01b031683529284019291840191600101610f0b565b50909695505050505050565b6001600160a01b0381168114610f50575f80fd5b50565b5f8060408385031215610f64575f80fd5b8235610f6f81610f3c565b946020939093013593505050565b634e487b7160e01b5f52604160045260245ffd5b604051601f8201601f1916810167ffffffffffffffff81118282101715610fba57610fba610f7d565b604052919050565b5f67ffffffffffffffff821115610fdb57610fdb610f7d565b5060051b60200190565b5f6020808385031215610ff6575f80fd5b825167ffffffffffffffff81111561100c575f80fd5b8301601f8101851361101c575f80fd5b805161102f61102a82610fc2565b610f91565b81815260059190911b8201830190838101908783111561104d575f80fd5b928401925b8284101561107457835161106581610f3c565b82529284019290840190611052565b979650505050505050565b5f6020808385031215611090575f80fd5b825167ffffffffffffffff8111156110a6575f80fd5b8301601f810185136110b6575f80fd5b80516110c461102a82610fc2565b81815260059190911b820183019083810190878311156110e2575f80fd5b928401925b82841015611074578351825292840192908401906110e7565b5f60208284031215611110575f80fd5b5051919050565b634e487b7160e01b5f52603260045260245ffd5b5f6020828403121561113b575f80fd5b815167ffffffffffffffff80821115611152575f80fd5b818401915084601f830112611165575f80fd5b81518181111561117757611177610f7d565b61118a601f8201601f1916602001610f91565b91508082528560208285010111156111a0575f80fd5b6111b1816020840160208601610ddf565b50949350505050565b8082028115828204841417610dd957634e487b7160e01b5f52601160045260245ffd5b5f826111f757634e487b7160e01b5f52601260045260245ffd5b500490565b5f602080838503121561120d575f80fd5b825167ffffffffffffffff811115611223575f80fd5b8301601f81018513611233575f80fd5b805161124161102a82610fc2565b81815260059190911b8201830190838101908783111561125f575f80fd5b928401925b8284101561107457835161127781610f3c565b82529284019290840190611264565b5f60208284031215611296575f80fd5b81516112a181610f3c565b939250505056fea2646970667358221220e13239e732eae37dd9a6fb584eb86ca47b27fbdc7f5b4ca923c907d0704f12f464736f6c63430008180033000000000000000000000000ad31546adbfe1ecd7137310508f112039a35b6f7000000000000000000000000071bdc8edcdd66730f45a3d3a6f794faa37c75ed0000000000000000000000005c20d1a85c7d9acb503135a498e26eb55d806552000000000000000000000000d68c29263f6dc2ff8d9307b3afacd6d6fdefbb3a",
"nonce": "0x177",
"chainId": "0x4268"
},
"additionalContracts": [],
"isFixedGasLimit": false
}
],
"receipts": [
{
"status": "0x1",
"cumulativeGasUsed": "0x2bb913",
"logs": [],
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"type": "0x2",
"transactionHash": "0x6645dc197a9f650c593571384bf632b68982fc986dc0c750f4f9acd5c828f2e4",
"transactionIndex": "0x13",
"blockHash": "0x9014d974e965c1a7c95b79dc6b6381b0ce49b5ba682420eb76af13d53aed6a41",
"blockNumber": "0x23eec4",
"gasUsed": "0x10c2ab",
"effectiveGasPrice": "0xa301bb",
"from": "0xd7d4a7f14265b0a69ae482b85b0a8496c3f99fb9",
"to": null,
"contractAddress": "0xbea193a39958bc175b10cc1dfc742e5a3ebaafaf"
}
],
"libraries": [],
"pending": [],
"returns": {},
"timestamp": 1726598187,
"chain": 17000,
"commit": "aedbbd9"
}
46 changes: 46 additions & 0 deletions deployments/ynLSDe-17000-ynFoo.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
{
"ADMIN": "0x743b91CDB1C694D4F51bCDA3a4A59DcC0d02b913",
"DEFAULT_SIGNER": "0x72fdBD51085bDa5eEEd3b55D1a46E2e92f0837a5",
"EIGEN_STRATEGY_ADMIN": "0x743b91CDB1C694D4F51bCDA3a4A59DcC0d02b913",
"PAUSE_ADMIN": "0x743b91CDB1C694D4F51bCDA3a4A59DcC0d02b913",
"PROXY_ADMIN_OWNER": "0x743b91CDB1C694D4F51bCDA3a4A59DcC0d02b913",
"STAKING_ADMIN": "0x743b91CDB1C694D4F51bCDA3a4A59DcC0d02b913",
"STAKING_NODES_OPERATOR": "0x9Dd8F69b62ddFd990241530F47dcEd0Dad7f7d39",
"STRATEGY_CONTROLLER": "0x1234567890123456789012345678901234567890",
"TOKEN_STAKING_NODE_CREATOR": "0x9Dd8F69b62ddFd990241530F47dcEd0Dad7f7d39",
"UNPAUSE_ADMIN": "0x743b91CDB1C694D4F51bCDA3a4A59DcC0d02b913",
"YNDev": "0x9Dd8F69b62ddFd990241530F47dcEd0Dad7f7d39",
"YnSecurityCouncil": "0x743b91CDB1C694D4F51bCDA3a4A59DcC0d02b913",
"implementation-assetRegistry": "0x156e0382068C3f96a629f51dcF99cEA5250B9eda",
"implementation-eigenStrategyManager": "0x251D14a2FB3cf3E35CE2355fBC7943257bcCcA08",
"implementation-lsdWrapper": "0xD0F77441B70c84aa3366a9F79F2fD16618739aB0",
"implementation-rateProvider": "0x17969afC774ec28802F1316cd4474c537114600A",
"implementation-redemptionAssetsVault": "0xB510d24856795F4B7Bb6e977E14D3157Ceeaa7FE",
"implementation-tokenStakingNodesManager": "0xeD44B98Bd50cd5e128B420495bd9DA384A291B9A",
"implementation-withdrawalQueueManager": "0x108D8d8d89B3459ec37c0E71A51C8a6771aC488c",
"implementation-ynEigenDepositAdapter": "0x11830FF94221F2Ef34176AD85A6cCAa2f41C95fa",
"implementation-ynEigenViewer": "0xe30c24d5E6Cf5320a9ad550853b80d6e506fcb5b",
"implementation-ynLSDe": "0x552f4b850d4963D914E6B2C011B5FE475468d3B8",
"proxy-assetRegistry": "0x726cc095C893c2ff6d572C1B2F26e0Ed08484302",
"proxy-eigenStrategyManager": "0x6e18EfFF496b108522bdCF5db92e97c5EE8a2DEd",
"proxy-lsdWrapper": "0xb94FA8D53313b4B6c69DC20489C78E2AF54C5B61",
"proxy-rateProvider": "0x0E68FedE865158D7501e5Ce5033B4fca9123CA98",
"proxy-redemptionAssetsVault": "0xAF920e9D61b91e1b8e39AE6bFBa5Fa73C2f32A34",
"proxy-tokenStakingNodesManager": "0x8c1717166F02911960bD4A31A8C725909A2de39e",
"proxy-withdrawalQueueManager": "0x34354efDF0931d37020e7331363403930c9e251e",
"proxy-ynEigenDepositAdapter": "0x6196F39D95805Fc6186c191E640e8fad156633Ff",
"proxy-ynEigenViewer": "0xb80EecB2904DAd7410B3af6bE897E01dca8CF475",
"proxy-ynLSDe": "0x73961FEcac088A52DdCe286E6935b6bd9Bf391E5",
"proxyAdmin-assetRegistry": "0xBBD351d0137c2C5f44CB8FE1DF4f5398FC8711df",
"proxyAdmin-eigenStrategyManager": "0x44377f05b1b9521F10320319B01C2D781f624719",
"proxyAdmin-lsdWrapper": "0x0432DD28B89b28911b90808861E68885646B9E6E",
"proxyAdmin-rateProvider": "0x65b32cBEcfb849Aa6fD89e6DA1a894Ee7899acD7",
"proxyAdmin-redemptionAssetsVault": "0x890c0367eB82FF4114FcA95CdEbEbD12b61a2a9d",
"proxyAdmin-tokenStakingNodesManager": "0x5a153929A995950B72F4606dfAECb60fBDDaB4Af",
"proxyAdmin-withdrawalQueueManager": "0x84376C30FC35a69C22271ECBA4ca26037a2f8e4E",
"proxyAdmin-ynEigenDepositAdapter": "0x14a87CA41091ddBa399e41b4bC174330dF378dCE",
"proxyAdmin-ynEigenViewer": "0x121dAa9722E2C8e56C35693d7c6913fEd57D5552",
"proxyAdmin-ynLSDe": "0x1745fAAf07167B2D33DE831C1E4e3344090138b4",
"tokenStakingNodeImplementation": "0xc7Fb9046f1db5A36D635Ad1E70D425b779b29840",
"upgradeTimelock": "0x56664FFcCfF6BB282CcA96808AF03d9042e1f799"
}
45 changes: 44 additions & 1 deletion script/upgrades/GenerateYnLSDeUpgradeTxData.s.sol
Original file line number Diff line number Diff line change
Expand Up @@ -7,19 +7,62 @@ import {ProxyAdmin} from "@openzeppelin/contracts/proxy/transparent/ProxyAdmin.s

import {BaseYnEigenScript} from "script/ynEigen/BaseYnEigenScript.s.sol";

/**
* @title GenerateYnLSDeUpgradeTxData
* @dev This script generates the transaction data needed to upgrade a specific contract in the YnLSDe system.
*
* USAGE:
* --------
* To run this script, use the following command in your terminal:
*
* TOKEN=[token name] CONTRACT_TO_UPGRADE=[contract identifier] NEW_IMPLEMENTATION=[implementation address] forge script script/upgrades/GenerateYnLSDeUpgradeTxData.s.sol --legacy --rpc-url [rpc url]
*
*
* Where:
* - TOKEN: The name of the token (e.g., ynLSDe)
* - CONTRACT_TO_UPGRADE: The name of the contract to be upgraded (e.g., rateProvider)
* - NEW_IMPLEMENTATION: The address of the new implementation contract
*
*
*
* EXAMPLE:
* --------
* # Upgrade rateProvider of ynLSDe on Holesky to the given implementation
* TOKEN=ynLSDe CONTRACT_TO_UPGRADE=rateProvider NEW_IMPLEMENTATION=0x48c3dfd4d14e7899c4adbf8e2d5aef6af585d305 forge script script/upgrades/GenerateYnLSDeUpgradeTxData.s.sol --legacy --rpc-url https://rpc.ankr.com/eth_holesky
*
* This command will:
* 1. Set the token name to 'ynLSDe'
* 2. Specify 'rateProvider' as the contract to upgrade
* 3. Set the new implementation address to 0x48c3dfd4d14e7899c4adbf8e2d5aef6af585d305
* 4. Use the Holesky testnet RPC URL for execution
*
* The script will then generate and display the necessary transaction data for the upgrade process.
* --------
*/

contract GenerateYnLSDeUpgradeTxData is BaseYnEigenScript {
Deployment deployment;

string internal _tokenName;

function tokenName() internal view override returns (string memory) {
return _tokenName;
}

function run() external {
deployment = loadDeployment();

console.log("=== Upgrade Information ===");
console.log("Current Block Number: %s", block.number);
console.log("Current Chain ID: %s", block.chainid);

_tokenName = vm.envString("TOKEN");
string memory contractToUpgrade = vm.envString("CONTRACT_TO_UPGRADE");
address newImplementation = vm.envAddress("NEW_IMPLEMENTATION");

console.log("Token Name: %s", _tokenName);

deployment = loadDeployment();

console.log("=== Contract Upgrade Details ===");
console.log("Contract to upgrade: %s", contractToUpgrade);
console.log("Contract address: %s", vm.toString(getProxyAddress(contractToUpgrade)));
Expand Down
Loading
Loading