Warning
This repository IS NOT a full port of Sky Protocol's spells-mainnet repo.
It does not work with regular spells and should only be used for the purposes of testing and debugging the source code verification for spells.
We use Sepolia only to not waste real ETH deploying contracts.
Staging repo for MakerDAO executive spells.
$ git clone [email protected]:makerdao/spells-mainnet.git
$ dapp update$ makeSet ETH_RPC_URL to a Mainnet node.
$ export ETH_RPC_URL=<Mainnet URL>
$ make testSet ETH_RPC_URL to a Mainnet node.
$ export ETH_RPC_URL=<Mainnet URL>
$ make test-forgeSet ETH_RPC_URL to a Mainnet node and ensure ETH_GAS_LIMIT is set to a high enough number to deploy the contract.
$ export ETH_RPC_URL=<Mainnet URL>
$ export ETH_GAS_LIMIT=5000000
$ export ETH_GAS_PRICE=$(seth --to-wei 100 "gwei")
$ make deployA few helpful tips to estimate gas. You can use the following to get a gas estimate for the deploy.
make all
make estimateOnce you have that, add another million gas as a buffer against out-of-gas errors. Set ETH_GAS_LIMIT to this value.
export ETH_GAS_LIMIT="$((<value from previous step> + 0))"
export ETH_GAS_LIMIT=$(bc <<< "$ETH_GAS_LIMIT + 1000000")You should also check current gas prices on your favorite site (e.g. https://ethgasstation.info/) and put that gwei value in the ETH_GAS_PRICE line.
export ETH_GAS_PRICE=$(seth --to-wei 420 "gwei")- Create Tenderly account (no trial period needed atm) https://dashboard.tenderly.co/register
- Note down
TENDERLY_USERandTENDERLY_PROJECTvalues
- Note down
- Create Tenderly access token (on the account level!) https://dashboard.tenderly.co/account/authorization
- Note down
TENDERLY_ACCESS_KEYvalues
- Note down
- Export required env vars via
exportor createscripts/cast-on-tenderly/.envfile with them:ETH_RPC_URL="" TENDERLY_USER="" TENDERLY_PROJECT="" TENDERLY_ACCESS_KEY=""
- Execute
make cast-on-tenderly spell=0x..., with the address of the spell that hasn't been casted yet- The execution should finish with
successfully casted
- The execution should finish with
- Open the
public explorer urlprinted into the console (it should require no credentials)