Open nadir-akhtar opened 2 days ago
Reading tracefile ./lcov.info.pruned
|Lines |Functions|Branches
Filename |Rate Num|Rate Num|Rate Num
================================================================================
[src/contracts/]
core/AVSDirectory.sol |85.2% 27|88.9% 9| - 0
core/DelegationManager.sol |96.5% 198|92.3% 39| - 0
core/RewardsCoordinator.sol |93.0% 128|84.8% 33| - 0
core/StrategyManager.sol |97.6% 83| 100% 24| - 0
libraries/BeaconChainProofs.sol | 100% 22| 100% 11| - 0
libraries/BytesLib.sol | 0.0% 156| 0.0% 14| - 0
libraries/EIP1271SignatureUtils.sol | 100% 3| 100% 1| - 0
libraries/Endian.sol | 100% 2| 100% 1| - 0
libraries/Merkle.sol | 100% 38| 100% 5| - 0
libraries/StructuredLinkedList.sol | 0.0% 45| 0.0% 19| - 0
permissions/Pausable.sol |95.7% 23|90.9% 11| - 0
permissions/PauserRegistry.sol | 100% 12| 100% 6| - 0
pods/EigenPod.sol | 100% 122|96.2% 26| - 0
pods/EigenPodManager.sol | 100% 75|92.9% 14| - 0
strategies/EigenStrategy.sol | 0.0% 10| 0.0% 5| - 0
strategies/StrategyBase.sol |90.9% 44|78.9% 19| - 0
strategies/StrategyBaseTVLLimits.sol | 100% 12| 100% 6| - 0
strategies/StrategyFactory.sol | 100% 35| 100% 9| - 0
token/BackingEigen.sol |83.3% 30|69.2% 13| - 0
token/Eigen.sol |45.0% 40|61.5% 13| - 0
utils/UpgradeableSignatureCheckingUtils.sol | 0.0% 6| 0.0% 4| - 0
================================================================================
Total:|75.6% 1111|76.2% 282| - 0
Creating example scripts for deploying, queueing, and executing contract upgrades
The PR adds
script/Release_Template.sol
, a template file providing abstract contracts for a variety of scripting use cases. A release script can inherit and override relevant functions with lightweight and straightforward syntax. Below are the contexts for using each script:EOABuilder
: An EOA performing a deploy, returning aDeployment
object.MultisigBuilder
: A multisig performing some direct action (e.g. sending tokens, acting as a role on a contract), returning a Safe MetaTransactionData object.MultisigBuilder
script transforms calls into MultiSendCallOnly calls, meaning any number of calls (not accounting for gas) can be batched into one transaction by a multisig.OpsTimelockBuilder
: A specialized nested multisig action performing aqueue()
andexecute()
queue()
refers to queueing a transaction in the Timelock andexecute()
refers to forwarding that transaction after some delay to the Executor Multisig. You can see more details on the EigenLayer admin structure here.Furthermore,
script/releases/v0.1-eigenpod/
contains an example set of scripts inheriting and implementing functions for each aforementioned abstract contract. These scripts are purely for demonstration.DeployEigenPod.s.sol
: Deploys a single contract,EigenPod
.UpgradeEigenPod.s.sol
: Sends a dummy call to the Timelock, plus an upgrade to theeigenPod
to some pending implementation.UpgradeViaTimelock.s.sol
: Queues up a transaction in the Timelock, then later allows for the same transaction to be executed.=======================================
To run this locally, try the following commands.
Deploy
forge script script/releases/v0.1-eigenpod/DeployEigenPod.s.sol -s "deploy(string memory)" "script/configs/zipzoop.json"
Example Output
Execute
forge script script/releases/v0.1-eigenpod/UpgradeEigenPod.s.sol -s "execute(string memory)" "script/configs/zipzoop.json"
Example Output
Queue
forge script script/releases/v0.1-eigenpod/UpgradeViaTimelock.s.sol -s "queue(string memory)" "script/configs/zipzoop.json"
Example Output
Execute after Queue
forge script script/releases/v0.1-eigenpod/UpgradeViaTimelock.s.sol -s "execute(string memory)" "script/configs/zipzoop.json"
Example Output