-
Notifications
You must be signed in to change notification settings - Fork 27
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Goerli Executive Spell Review Checklist
TL;DR: missing RwaLiquidationOracle.bump
for changed parameters in RWA007-A
and RWA015-A
and some nitpicks.
Goerli 2023-10-11
Spell Actions (Per Exec Sheet):
- Non-Scope Defined Parameter Changes - WBTC DC-IAM Changes
- Reduce the WBTC-A DC-IAM Target Available Debt (
gap
) from 10 million DAI to 2 million DAI. - Reduce the WBTC-B DC-IAM Target Available Debt (
gap
) from 5 million DAI to 2 million DAI. - Reduce the WBTC-C DC-IAM Target Available Debt (
gap
) from 10 million DAI to 2 million DAI.
- Reduce the WBTC-A DC-IAM Target Available Debt (
- Stability Fee Changes
- Increase the ETH-A Stability Fee (SF) by 1.55%, from 3.70% to 5.25%.
- Increase the ETH-B Stability Fee (SF) by 1.55%, from 4.20% to 5.75%.
- Increase the ETH-C Stability Fee (SF) by 1.55%, from 3.45% to 5.00%.
- Increase WBTC-A Stability Fee (SF) by 0.06%, from 5.8% to 5.86%
❌ Wrong comment in the code - Increase WBTC-B Stability Fee (SF) by 0.06%, from 5.8% to 6.36%
❌ Wrong comment in the code and invalid action in sheet - Increase WBTC-C Stability Fee (SF) by 0.06%, from 5.8% to 5.61%
❌ Wrong comment in the code and invalid action in sheet
- Initial RETH-A Offboarding
- Set rETH-A Debt Ceiling (
line
) to 0 (zero). - Remove RETH-A from
Autoline
.
- Set rETH-A Debt Ceiling (
- Reconfiguring Andromeda RWA015-A
- Set the Maximum Debt Ceiling (line) to 3 billion DAI.
- Reconfiguring Clydesdale RWA007-A
- Reactivate the Debt Ceiling Instant Access Module for this vault type.
- Set the Target Available Debt (gap) to 50 million DAI.
- Set the Ceiling Increase Cooldown (ttl) to 86400 (24 hours).
- Set the Maximum Debt Ceiling (line) to 3 billion DAI.
-
Set up Governance Facilitator Streams⚠️ Ignored on Goerli- ~~JanSky | 2023-10-01 00:00:00 to 2024-~~09-30 23:59:59 | 504,000.00 DAI | 0xf3F868534FAD48EF5a228Fe78669cf242745a755
-
VoteWizard | 2023-10-01 00:00:00 to 2024-09-30 23:59:59 | 504,000.00 DAI | 0x9E72629dF4fcaA2c2F5813FbbDc55064345431b1 -
JanSky | 2023-10-01 00:00:00 to 2024-09-30 23:59:59 | 216.00 MKR | 0xf3F868534FAD48EF5a228Fe78669cf242745a755
- USDP-PSM Facilitation Incentives
- DAO Resolution 1: Initial Setup (copy only)
- Add dao_resolution parameter: QmWg43PNNGfEyXnTv1qN8dRXFJz5ZchrmZU8qH57Ki6D62
-
BA Labs MKR Distribution⚠️ Ignored on Goerli-
BA Labs - 175 MKR - 0x5d67d5B1fC7EF4bfF31967bE2D2d7b9323c1521c
-
-
AVC Member Compensation⚠️ Ignored on Goerli-
opensky - 20.85 MKR - 0x8e67ee3bbeb1743dc63093af493f67c3c23c6f04 -
DAI-Vinci - 12.51 MKR - 0x9ee47F0f82F1A6F45C4E1D25Ce95C321D8C8356a -
IamMeeoh - 20.85 MKR - 0x47f7A5d8D27f259582097E1eE59a07a816982AE9 -
ACRE DAOs - 20.85 MKR - 0xBF9226345F601150F64Ea4fEaAE7E40530763cbd -
Harmony - 20.85 MKR - 0xE20A2e231215e9b7Aa308463F1A7490b2ECE55D3 -
Res - 20.85 MKR - 0x8c5c8d76372954922400e4654AF7694e158AB784 -
seedlatam.eth - 20.85 MKR - 0x0087a081a9b430fd8f688c6ac5dd24421bfb060d
-
-
Delegate Compensation⚠️ Ignored on Goerli-
0xDefensor - 41.67 MKR - 0x9542b441d65B6BF4dDdd3d4D2a66D8dCB9EE07a9 -
TRUE NAME - 41.67 MKR - 0x612F7924c367575a0Edf21333D96b15F1B345A5d -
BONAPUBLICA - 41.67 MKR - 0x167c1a762B08D7e78dbF8f24e5C3f1Ab415021D3 -
Navigator - 41.67 MKR - 0x11406a9CC2e37425F15f920F494A51133ac93072 -
vigilant - 34.5 MKR - 0x2474937cB55500601BCCE9f4cb0A0A72Dc226F61 -
Cloaky - 21.06 MKR - 0x869b6d5d8FA7f4FFdaCA4D23FFE0735c5eD1F818 -
UPMaker - 13.89 MKR - 0xbB819DF169670DC71A16F58F55956FE642cc6BcD -
PALC - 13.89 MKR - 0x78Deac4F87BD8007b9cb56B8d53889ed5374e83A -
BLUE - 12.78 MKR - 0xb6C09680D822F162449cdFB8248a7D3FC26Ec9Bf -
PBG - 6.48 MKR - 0x8D4df847dB7FfE0B46AF084fE031F7691C6478c2
-
Development Stage
- Office Hours
- OFF (On Goerli the deployed spell is cast with a pause delay of 60 sec.)
- 30 days spell expiry in constructor (
block.timestamp + 30 days
) - No Exec Doc Hash on Goerli
- Spell Description
- Ensure
description
exactly matches 'Goerli Spell
'
- Ensure
- Local Environment Actions
- Update Foundry by running
foundryup
- Reinstall libraries by running
rm -r lib && git submodule update --init --recursive
Submodule path 'lib/dss-exec-lib': checked out '69b658f35d8618272cd139dfc18c5713caf6b96b' Submodule path 'lib/dss-exec-lib/lib/dss-interfaces': checked out '9bfd7afadd1f8c217ef05850b2555691786286cb' Submodule path 'lib/dss-exec-lib/lib/forge-std': checked out '0aa99eb8456693c015350c5e6c4f442ebe912f77' Submodule path 'lib/dss-exec-lib/lib/forge-std/lib/ds-test': checked out 'cd98eff28324bfac652e63a239a60632a761790b' Submodule path 'lib/dss-test': checked out '7529fa1e043b9195f41549852d9c5bb0714eaa27' Submodule path 'lib/dss-test/lib/dss-interfaces': checked out '9bfd7afadd1f8c217ef05850b2555691786286cb' Submodule path 'lib/dss-test/lib/forge-std': checked out 'aea0b2685bebc883c09f5554d7fb481e85d0564d' Submodule path 'lib/dss-test/lib/forge-std/lib/ds-test': checked out 'cd98eff28324bfac652e63a239a60632a761790b'
- Update Foundry by running
- Rate constants used are correct
- Manual check 1: Calculate rates using
make rates pct=<pct>
(e.g. pct=0.75, for 0.75%) -
Manual check 2: Compare rates used against IPFS rate list - Variable name conforms to
X_PT_Y_Z_PCT_RATE
(e.g.ZERO_PT_SEVEN_FIVE_PCT_RATE
for 0.75%,SIX_PCT_RATE
for 6.00%) - Visibility is
internal
- State mutability is
constant
- Manual check 1: Calculate rates using
- Constants Match
- Precision unit constants used match their defined values
-
RAD = 10 ** 45
- Visibility is
internal
- State mutability is
constant
-
- Math unit constants used match their defined values
-
MILLION = 10 ** 6
-
BILLION = 10 ** 9
- Visibility is
internal
- State mutability is
constant
-
- Precision unit constants used match their defined values
- String Constants
- IPFS hashes or DAO resolutions
- IPFS hashes and DAO resolutions match the exec doc
- The variable is named
dao_resolutions
- if multiple dao resolutions are present
- they are located in the same string constant and are comma separated
- The comment above the the variable states:
Comma-separated list of DAO resolutions IPFS hashes
- Must be TOP LEVEL (or ds pause will reject)
- Name of the variable matches purpose per EXEC DOC
- Visibility is
public
- State mutability MUST BE
constant
- IPFS hashes or DAO resolutions
- Core System Parameter Changes
- Stability Fee
jug.ilk.duty
(setIlkStabilityFee)- Comment matches pattern
// Increase ILK-A Stability Fee by X.XX% from X.XX% to X.XX%.
⚠️ Math in sheet action description is off.
- Comment matches pattern
- Autoline Changes
- setIlkAutoLineDebtCeiling
-
ilk
-
line
-
- setIlkAutoLineParameters
-
ilk
-
line
-
gap
-
ttl
-
- setIlkAutoLineDebtCeiling
- Stability Fee
- Offboarding (Lerp
mat
)- 1st Stage Spell Actions
- Remove Ilk from Autoline
- Set Ilks Debt Ceilings to
0
- Cache Ilks
line
to Reduce in the Global Debt Ceiling - Decrease Global Debt Ceiling by Total Amount of Offboarded Ilks
line
Cached
- 1st Stage Spell Actions
- RWA Updates
- Autoline (
line
) + Liquidation Oracle Price Bump (val
)- Enable Autoline
-
ilk
follows format "RWAXXX-A" -
line
(max debt ceiling) -
gap
-
ttl
-
-
bump
RwaLiquidationOracle
with new computed increased price (val
)
❌ Missing!- ensure
val
is set accordingly with autoline max debt ceiling (line
) -
val
should enable DAI to be drawn over the loan period while taking into account the configuredink
amount, interest rate and liquidation ratio (see below)- New
val
is calculated withline * [(1 + duty) ** years] * mat
- rounded up - and makes sense in context of the rate mechanism. Minimum duration is usually in the Exec Doc of the spell with the RWAXXX ilk onboarding. - Comment explaining
val
formula (Debt ceiling * [ (1 + RWA stability fee ) ^ (minimum deal duration in years) ] * liquidation ratio
) is present - Accompanying comment above
bump
line in format// XXM * 1.XX^X * X.XX as a WAD
corresponding to theval
calculation formula (e.g.// 15M * 1.03^2 * 1.00 as a WAD
) is present along with the calculation formula on the line above - IF combining
val
of multiple RWA ilks being combined,val
calculation is done once per ilk and added to make the total, with workings provided in code comments. The existingval
value can be retrieved by callingread()
onPIP_RWAXX
and converting the result into decimal.
- New
- ensure
- Poke
spotter
to pull in the new price
❌ Missing!
- Enable Autoline
- Debt Ceiling (
line
) + Liquidation Oracle Price Bump (val
)- Increase Ilk Debt Ceiling (set DC + increase Global DC)
-
bump
RwaLiquidationOracle
with new computed increased price (val
)
❌ Missing!-
val
should enable DAI to be drawn over the loan period while taking into account the configuredink
amount, interest rate and liquidation ratio (see below)- New
val
is calculated withline * [(1 + duty) ** years] * mat
- rounded up - and makes sense in context of the rate mechanism. Minimum duration is usually in the Exec Doc of the spell with the RWAXXX ilk onboarding. - Comment explaining
val
formula (Debt ceiling * [ (1 + RWA stability fee ) ^ (minimum deal duration in years) ] * liquidation ratio
) is present - Accompanying comment above
bump
line in format// XXM * 1.XX^X * X.XX as a WAD
corresponding to theval
calculation formula (e.g.// 15M * 1.03^2 * 1.00 as a WAD
) is present along with the calculation formula on the line above - IF combining
val
of multiple RWA ilks being combined,val
calculation is done once per ilk and added to make the total, with workings provided in code comments. The existingval
value can be retrieved by callingread()
onPIP_RWAXX
and converting the result into decimal.
- New
-
- Poke
spotter
to pull in the new price
❌ Missing!
- Autoline (
- Tests
- Ensure each spell action has sufficient test coverage
- Non-Scope Defined Parameter Changes - WBTC DC-IAM Changes ✅
testGeneral
- Stability Fee Changes ✅
testGeneral
- Initial RETH-A Offboarding ✅
testGeneral
- Reconfiguring Andromeda RWA015-A ❌ Missing
RwaLiquidationOracle.bump
test - Reconfiguring Clydesdale RWA007-A ❌ Missing
RwaLiquidationOracle.bump
test - USDP-PSM Facilitation Incentives
⚠️ No test coverage. Maybe consider adding it.
- Non-Scope Defined Parameter Changes - WBTC DC-IAM Changes ✅
- Ensure every test function is declared as public if enabled or private if disabled
- Ensure that the
DssExecLib.address
file is not being modified by the spell PR - Check all CI tests are passing as at the latest commit
✅ 8e35e7f - Check all tests are passing locally using
make test
- Ensure that only
ETH_RPC_URL
is being used from env (i.e. nomatch
,block
or similar are active in your env)
- Ensure that only
- Ensure each spell action has sufficient test coverage
Using DssExecLib at: 0x122F6c0Dcd898b4a07310E92c3eAE5D7Ce0c8bb6
[⠃] Compiling...
[⠘] Compiling 6 files with 0.8.16
[⠒] Solc 0.8.16 finished in 1.82s
Compiler run successful!
Running 2 tests for src/test/starknet.t.sol:StarknetTests
[PASS] testStarknet() (gas: 1070878)
[PASS] testStarknetSpell() (gas: 2324)
Test result: ok. 2 passed; 0 failed; 0 skipped; finished in 55.89s
Running 17 tests for src/DssSpell.t.sol:DssSpellTest
[PASS] testAuth() (gas: 52095774)
[PASS] testAuthInSources() (gas: 8107139)
[PASS] testBytecodeMatches() (gas: 2029961)
[PASS] testCastCost() (gas: 911772)
[PASS] testChainlogValues() (gas: 9287776)
[PASS] testChainlogVersionBump() (gas: 4338863)
[PASS] testContractSize() (gas: 8962)
[PASS] testDeployCost() (gas: 2016529)
[PASS] testFailNotScheduled() (gas: 14397)
[PASS] testFailTooEarly() (gas: 13585)
[PASS] testFailTooLate() (gas: 13606)
[PASS] testFailWrongDay() (gas: 13585)
[PASS] testGeneral() (gas: 37783728)
[PASS] testNextCastTime() (gas: 364790)
[PASS] testOnTime() (gas: 907411)
[PASS] testPSMs() (gas: 2219522)
[PASS] testUseEta() (gas: 363541)
Test result: ok. 17 passed; 0 failed; 0 skipped; finished in 1087.21s
Ran 2 test suites: 19 tests passed, 0 failed, 0 skipped (19 total tests)
src/DssSpell.sol
Outdated
// ---------- Reconfiguring Andromeda RWA015-A ---------- | ||
// Forum: https://forum.makerdao.com/t/poll-request-reconfiguring-rwa-allocator-vaults/22159 | ||
// Poll: https://vote.makerdao.com/polling/QmPoLbah | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Dangling whitespace:
src/DssSpell.sol
Outdated
// Set DC-IAM Line (max DC) to 0 (zero). | ||
(,,,uint256 line,) = VatLike(MCD_VAT).ilks("RETH-A"); | ||
DssExecLib.removeIlkFromAutoLine("RETH-A"); | ||
DssExecLib.decreaseIlkDebtCeiling("RETH-A", line / RAD, true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DssExecLib.decreaseIlkDebtCeiling("RETH-A", line / RAD, true); | |
DssExecLib.decreaseIlkDebtCeiling("RETH-A", line / RAD, /* global = */ true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Goerli Executive Spell Review Checklist
Goerli 2023-10-11
Spell Actions (Per Exec Sheet):
- Non-Scope Defined Parameter Changes - WBTC DC-IAM Changes
- Reduce the WBTC-A DC-IAM Target Available Debt from 10 million DAI to 2 million DAI.
- Reduce the WBTC-B DC-IAM Target Available Debt from 5 million DAI to 2 million DAI.
- Reduce the WBTC-C DC-IAM Target Available Debt from 10 million DAI to 2 million DAI.
- Stability Fee Changes
- Increase the ETH-A Stability Fee (SF) by 1.55%, from 3.70% to 5.25%.
- Increase the ETH-B Stability Fee (SF) by 1.55%, from 4.20% to 5.75%.
- Increase the ETH-C Stability Fee (SF) by 1.55%, from 3.45% to 5.00%.
- Increase WBTC-A Stability Fee (SF) by 0.06%, from 5.8% to 5.86%
- Increase WBTC-B Stability Fee (SF) by 0.06%, from 6.30% to 6.36%.
- Increase WBTC-C Stability Fee (SF) by 0.06%, from 5.55% to 5.61%.
- Initial RETH-A Offboarding
- Set rETH-A Debt Ceiling (
line
) to 0 (zero). - Remove RETH-A from
Autoline
.
- Set rETH-A Debt Ceiling (
- Reconfiguring Andromeda RWA015-A
- Set the Maximum Debt Ceiling (line) to 3 billion DAI.
- Reconfiguring Clydesdale RWA007-A
- Reactivate the Debt Ceiling Instant Access Module for this vault type.
- Set the Target Available Debt (gap) to 50 million DAI.
- Set the Ceiling Increase Cooldown (ttl) to 86400 (24 hours).
- Set the Maximum Debt Ceiling (line) to 3 billion DAI.
- SKIP ON GOERLI (comments present) : Set up Governance Facilitator Streams
- JanSky | 2023-10-01 00:00:00 to 2024-09-30 23:59:59 | 504,000.00 DAI | 0xf3F868534FAD48EF5a228Fe78669cf242745a755
- VoteWizard | 2023-10-01 00:00:00 to 2024-09-30 23:59:59 | 504,000.00 DAI | 0x9E72629dF4fcaA2c2F5813FbbDc55064345431b1
- JanSky | 2023-10-01 00:00:00 to 2024-09-30 23:59:59 | 216.00 MKR | 0xf3F868534FAD48EF5a228Fe78669cf242745a755
- VoteWizard | 2023-10-01 00:00:00 to 2024-09-30 23:59:59 | 216.00 MKR | 0x9E72629dF4fcaA2c2F5813FbbDc55064345431b1
- USDP-PSM Facilitation Incentives
- Add dao_resolution parameter: QmWg43PNNGfEyXnTv1qN8dRXFJz5ZchrmZU8qH57Ki6D62
- SKIP ON GOERLI (comments present): BA Labs MKR Distribution
- BA Labs - 175 MKR - 0x5d67d5B1fC7EF4bfF31967bE2D2d7b9323c1521c
- SKIP ON GOERLI (comments present): AVC Member Compensation
- opensky - 20.85 MKR - 0x8e67ee3bbeb1743dc63093af493f67c3c23c6f04
- DAI-Vinci - 12.51 MKR - 0x9ee47F0f82F1A6F45C4E1D25Ce95C321D8C8356a
- IamMeeoh - 20.85 MKR - 0x47f7A5d8D27f259582097E1eE59a07a816982AE9
- ACRE DAOs - 20.85 MKR - 0xBF9226345F601150F64Ea4fEaAE7E40530763cbd
- Harmony - 20.85 MKR - 0xE20A2e231215e9b7Aa308463F1A7490b2ECE55D3
- Res - 20.85 MKR - 0x8c5c8d76372954922400e4654AF7694e158AB784
- seedlatam.eth - 20.85 MKR - 0x0087a081a9b430fd8f688c6ac5dd24421bfb060d
- SKIP ON GOERLI (comments not present, not critical) :Delegate Compensation
- 0xDefensor - 41.67 MKR - 0x9542b441d65B6BF4dDdd3d4D2a66D8dCB9EE07a9
- TRUE NAME - 41.67 MKR - 0x612F7924c367575a0Edf21333D96b15F1B345A5d
- BONAPUBLICA - 41.67 MKR - 0x167c1a762B08D7e78dbF8f24e5C3f1Ab415021D3
- Navigator - 41.67 MKR - 0x11406a9CC2e37425F15f920F494A51133ac93072
- vigilant - 34.5 MKR - 0x2474937cB55500601BCCE9f4cb0A0A72Dc226F61
- Cloaky - 21.06 MKR - 0x869b6d5d8FA7f4FFdaCA4D23FFE0735c5eD1F818
- UPMaker - 13.89 MKR - 0xbB819DF169670DC71A16F58F55956FE642cc6BcD
- PALC - 13.89 MKR - 0x78Deac4F87BD8007b9cb56B8d53889ed5374e83A
- BLUE - 12.78 MKR - 0xb6C09680D822F162449cdFB8248a7D3FC26Ec9Bf
- PBG - 6.48 MKR - 0x8D4df847dB7FfE0B46AF084fE031F7691C6478c2
Development Stage
- Office Hours
- OFF (On Goerli the deployed spell is cast with a pause delay of 60 sec.)
- 30 days spell expiry in constructor (
block.timestamp + 30 days
) - No Exec Doc Hash on Goerli
- Spell Description
- Ensure
description
exactly matches 'Goerli Spell
'
- Ensure
- Local Environment Actions
- Update Foundry by running
foundryup
- Reinstall libraries by running
rm -r lib && git submodule update --init --recursive
Submodule path 'lib/dss-exec-lib': checked out '69b658f35d8618272cd139dfc18c5713caf6b96b' Submodule path 'lib/dss-exec-lib/lib/dss-interfaces': checked out '9bfd7afadd1f8c217ef05850b25556917 86286cb' Submodule path 'lib/dss-exec-lib/lib/forge-std': checked out '0aa99eb8456693c015350c5e6c4f442ebe912f 77' Submodule path 'lib/dss-exec-lib/lib/forge-std/lib/ds-test': checked out 'cd98eff28324bfac652e63a239 a60632a761790b' Submodule path 'lib/dss-test': checked out '7529fa1e043b9195f41549852d9c5bb0714eaa27' Submodule path 'lib/dss-test/lib/dss-interfaces': checked out '9bfd7afadd1f8c217ef05850b255569178628 6cb' Submodule path 'lib/dss-test/lib/forge-std': checked out 'aea0b2685bebc883c09f5554d7fb481e85d0564d' Submodule path 'lib/dss-test/lib/forge-std/lib/ds-test': checked out 'cd98eff28324bfac652e63a239a606 32a761790b'
- Update Foundry by running
- Rate constants used are correct
- Manual check 1: Calculate rates using
make rates pct=<pct>
(e.g. pct=0.75, for 0.75%) - Manual check 2: Compare rates used against IPFS rate list
- Variable name conforms to
X_PT_Y_Z_PCT_RATE
(e.g.ZERO_PT_SEVEN_FIVE_PCT_RATE
for 0.75%,SIX_PCT_RATE
for 6.00%) - Visibility is
internal
- State mutability is
constant
- Manual check 1: Calculate rates using
- Constants Match
- Precision unit constants used match their defined values
-
WAD = 10 ** 18
-
RAY = 10 ** 27
-
RAD = 10 ** 45
- Visibility is
internal
- State mutability is
constant
-
- Math unit constants used match their defined values
-
HUNDRED = 10 ** 2
-
THOUSAND = 10 ** 3
-
MILLION = 10 ** 6
-
BILLION = 10 ** 9
- Visibility is
internal
- State mutability is
constant
- (Non-critical) Ensure they match with config
-
- Precision unit constants used match their defined values
- Address Declaration
-
Address Constants-
Address is not in the ChainLog -
Variable name matches corresponding entry in anaddresses.sol
file -
Address value matches corresponding entry in anaddresses.sol
file -
Visibility isinternal
-
State mutability isconstant
-
- Address Immutables
- Use the DssExecLib Core Address Helpers instead of
getChangelogAddress()
whenever possible (e.g.DssExecLib.vat()
) - Follow pattern
address internal immutable KEY_NAME = DssExecLib.getChangelogAddress(KEY_NAME)
- Variable name matches ChainLog key name
- Exceptions must follow archive patterns (e.g.
MKR
forMCD_GOV
)
- Exceptions must follow archive patterns (e.g.
- Instantiate as
address
type- Exceptions must follow archive patterns (e.g.
GemLike
forMKR
)
- Exceptions must follow archive patterns (e.g.
- Visibility is
internal
- State mutability is
immutable
- Use the DssExecLib Core Address Helpers instead of
-
- String Constants
- IPFS hashes or DAO resolutions
- IPFS hashes and DAO resolutions match the exec doc
- The variable is named
dao_resolutions
-
if multiple dao resolutions are present-
they are located in the same string constant and are comma separated -
The comment above the the variable states:Comma-separated list of DAO resolutions IPFS hashes
-
- Must be TOP LEVEL (or ds pause will reject)
- Name of the variable matches purpose per EXEC DOC
- Visibility is
public
- State mutability MUST BE
constant
- IPFS hashes or DAO resolutions
-
Deployed Contracts (not yet on chainlog or new to chainlog)-
Verified on etherscan -
Optimizations match Repo -
GNU AGPLv3
license -
Constructor args ok (e.g.vat
,dai
,dog
, ...)-
Match ChainLog
-
-
Wards ok (pause proxy relied, deployer denied)-
MCD_ESM
is already relied / being relied in this spell (as approved by GovAlpha) in order to allow de-authing the pause proxy during Emergency Shutdown, viadenyProxy
.
-
-
Matches corresponding github source code (i.e. diffcheck via vscodecode --diff etherscan.sol github.sol
) -
Ensure deployer address is included intoaddresses_deployers.sol
(to keep up to date)
-
- [.] Core System Parameter Changes
- Stability Fee
jug.ilk.duty
(setIlkStabilityFee)- Comment matches pattern
// Increase ILK-A Stability Fee by X.XX% from X.XX% to X.XX%.
- Comment matches pattern
-
Dai Savings Ratepot.dsr
(setDSR)-
Double check thatPCT_RATE
is correct-
Check manually viamake rates pct=<pct>
(e.g. pct=0.75, for 0.75%) -
Compare against IPFS
-
-
-
spotter.ilk.mat
(liquidationRatio) -
dog.ilk.hole
(setIlkMaxLiquidationAmount) -
vat.ilk.dust
(setIlkMinVaultAmount) -
dog.ilk.chop
(liquidationPenalty) -
clip.buf
(startingPriceFactor) -
clipperMom.clip.tolerance
(setLiquidationBreakerPriceTolerance) -
clip.tail
(auctionDuration) -
clip.cusp
(permittedDrop) -
clip.chip
(kprPctReward) -
clip.tip
(kprFlatReward) -
calc.tau
(setLinearDecrease) -
setStairstepExponentialDecrease-
calc.cut
-
calc.step
-
- Stability Fee
- Debt Ceiling Changes
-
vat.ilk.line
changes (per ilk)-
Collateral type (ilk) is not RWAXXX (For RWA refer to the designated section of the checklist) -
setIlkDebtCeiling
orincreaseIlkDebtCeiling
ordecreaseIlkDebtCeiling
-
ilk
-
amount
-
global
-
-
-
vat.Line
changes (Global Line) - Autoline Changes
- setIlkAutoLineDebtCeiling
-
ilk
-
line
-
- setIlkAutoLineParameters
-
ilk
-
line
-
gap
-
ttl
-
- setIlkAutoLineDebtCeiling
-
-
Onboarding (insert relevant checklists inline here) - Offboarding (Lerp
mat
)- 1st Stage Spell Actions
- Remove Ilk from Autoline
- Set Ilks Debt Ceilings to
0
- Cache Ilks
line
to Reduce in the Global Debt Ceiling - Decrease Global Debt Ceiling by Total Amount of Offboarded Ilks
line
Cached
-
2nd Stage Spell Actions-
Set Ilk Liquidation Penaltychop
to0
-
Set Keeper Incentive Flat Ratetip
to0
-
Check IFchip
is required to be adjusted as well -
UseDssExecLib.linearInterpolation
-
name
Format matches "XXX-A Offboarding" -
target
matchesspotter
-
ilk
Format matches "XXX-A" -
what
matchesmat
-
startTime
matchesblock.timestamp
-
start
matches VarCURRENT_XXX_A_MAT
-
end
matches VarTARGET_XXX_A_MAT
(Match Exec Sheet & Risk Computations)-
Check IF Targetmat
Covers All Remaining Vaults CR times Risk Multiplier Factor
-
-
duration
matches Exec Sheet
-
-
- 1st Stage Spell Actions
- RWA Updates
-
doc
(Using the_updateDoc
helper or otherwise)-
init
theRwaLiquidationOracle
to reset thedoc
-
Sanity Checkpip
must be set (not the zero address) -
ilk
follows format "RWAXXX-A" -
val
price ignored (0
) ifinit
has already been called -
doc
new legal document (IPFS HASH) matches Doc (or Forum Post) -
tau
parameter used is the oldtau
value
-
- Autoline (
line
) + Liquidation Oracle Price Bump (val
)- Enable Autoline
-
ilk
follows format "RWAXXX-A" -
line
(max debt ceiling) -
gap
-
ttl
-
-
bump
RwaLiquidationOracle
with new computed increased price (val
)- ensure
val
is set accordingly with autoline max debt ceiling (line
) -
val
should enable DAI to be drawn over the loan period while taking into account the configuredink
amount, interest rate and liquidation ratio (see below)- New
val
is calculated withline * [(1 + duty) ** years] * mat
- rounded up - and makes sense in context of the rate mechanism. Minimum duration is usually in the Exec Doc of the spell with the RWAXXX ilk onboarding. - Comment explaining
val
formula (Debt ceiling * [ (1 + RWA stability fee ) ^ (minimum deal duration in years) ] * liquidation ratio
) is present - Accompanying comment above
bump
line in format// XXM * 1.XX^X * X.XX as a WAD
corresponding to theval
calculation formula (e.g.// 15M * 1.03^2 * 1.00 as a WAD
) is present along with the calculation formula on the line above- SF is zero so should probably replace the formula with the comment like this ❌
- IF combining
val
of multiple RWA ilks being combined,val
calculation is done once per ilk and added to make the total, with workings provided in code comments. The existingval
value can be retrieved by callingread()
onPIP_RWAXX
and converting the result into decimal.
- New
- ensure
- Poke
spotter
to pull in the new price
- Enable Autoline
-
Debt Ceiling (line
) + Liquidation Oracle Price Bump (val
)-
Increase Ilk Debt Ceiling (set DC + increase Global DC) -
bump
RwaLiquidationOracle
with new computed increased price (val
)-
val
should enable DAI to be drawn over the loan period while taking into account the configuredink
amount, interest rate and liquidation ratio (see below)-
Newval
is calculated withline * [(1 + duty) ** years] * mat
- rounded up - and makes sense in context of the rate mechanism. Minimum duration is usually in the Exec Doc of the spell with the RWAXXX ilk onboarding. -
Comment explainingval
formula (Debt ceiling * [ (1 + RWA stability fee ) ^ (minimum deal duration in years) ] * liquidation ratio
) is present -
Accompanying comment abovebump
line in format// XXM * 1.XX^X * X.XX as a WAD
corresponding to theval
calculation formula (e.g.// 15M * 1.03^2 * 1.00 as a WAD
) is present along with the calculation formula on the line above -
IF combiningval
of multiple RWA ilks being combined,val
calculation is done once per ilk and added to make the total, with workings provided in code comments. The existingval
value can be retrieved by callingread()
onPIP_RWAXX
and converting the result into decimal.
-
-
-
Pokespotter
to pull in the new price
-
-
- Payments
- Payments are not crafted or reviewed on Goerli (comments may be present)
-
SubDAO Content-
SubDAO SubProxy spell execution-
SubDAO spell address matches Exec Sheet (comment or otherwise) -
IF SubDAO spell deployer is a smart contract (e.g. multisig or factory)-
Ensure the deployer address is inaddresses_deployers.sol
as an entry
-
-
Executed usingProxyLike(SUBDAO_PROXY).exec(SUBDAO_SPELL, abi.encodeWithSignature("execute()"));
-
Execution is NOT delegate call -
Reviewer Note: Gas cost may be very high as SubDAO spells execute within the maincast
execution. (Also note that low level call gas estimation is not done by our scripts)
-
-
Maker Core (main spell) SubDAO actions (i.e. operate in Pause ProxyDelegateCall
context)-
No SubDAO contract being interacted with is authed on a core contract like vat, etc. (Check comprehensively where the risk is high) -
SubDAO contract licensing and optimizations generally do not matter (except where they pose a security risk) -
SubDAO contracts and all libraries / dependencies are verified (Blocking if not true) -
Upgradable SubDAO contracts-
Any upgradable contracts have thePAUSE_PROXY
as theiradmin
(i.e. the party that can upgrade)-
Any upgradable SubDAO contracts with anadmin
that is notPAUSE_PROXY
are not authed on any core contracts (Blocking)
-
-
-
All SubDAO content addresses (i.e. provided contract addresses or EOAs) present in the Maker Core spell are present in the Exec Sheet and are correct. SubDAO addresses being authed or given any permissions and addresses being called must be confirmed by the SubDAO spell team. -
SubDAO actions match Exec Sheet (only where inline with main spell code) and do not affect core contracts -
Core contract knock-on actions (such as offboarding or setting DC to 0) are present in the Exec Sheet and match the code -
External calls for SubDAO content are NOT delegate call -
Code does not have untoward behavior within the scope of Maker Core Contracts (e.g. up to the SubDAO proxy)
-
-
-
External Contracts Calls (Not SubDAOs, e.g. Starknet)-
Target Contract don't block spell execution -
External call is NOT delegate call -
Target Contract doesn't have permissions on the Vat -
Target Contract doesn't do anything untoward (e.g. interacting with unsafe contracts) -
Contracts deployed viaCREATE2
(e.g. if it looks like a vanity address) do not haveselfdestruct
in their code -
MCD Pause Proxy doesn't give any approvals -
All possible actions of the Target Contract are documented -
Target contract is not upgradable -
Target Contract is included in the ChainLog -
Test Coverage is comprehensive
-
-
ChainLog-
Increment ChainLog version based on update type-
Major -> New Vat (++.0.0) -
Minor -> Core Module (DSS) Update (e.g. Flapper) (0.++.0) -
Patch -> Collateral addition or addition/modification (0.0.++)
-
-
-
addresses_goerli.sol
matches spell code - Ensure every spell variable is declared as public/internal
- Ensure every spell variable is used in the spell (no unused variables)
- RAD not used ❌
- Spell actions match the corresponding Exec Sheet
- Tests
- Ensure each spell action has sufficient test coverage
- Non-Scope defined parameter changes
- SF changes
- RETH-A offboarding stage 1
- Adjustment of RWA007
- Adjustment of RWA015
- Ensure every test function is declared as public if enabled or private if disabled
- Ensure that the
DssExecLib.address
file is not being modified by the spell PR - Check all CI tests are passing as at the latest commit
499b7b5 - Check all tests are passing locally using
make test
- Ensure that only
ETH_RPC_URL
is being used from env (i.e. nomatch
,block
or similar are active in your env)
./scripts/test-dssspell-forge.sh no-match="" match="" block="" Using DssExecLib at: 0x122F6c0Dcd898b4a07310E92c3eAE5D7Ce0c8bb6 [⠘] Compiling... [⠒] Compiling 6 files with 0.8.16 [⠒] Solc 0.8.16 finished in 1.73s Compiler run successful! Running 2 tests for src/test/starknet.t.sol:StarknetTests [PASS] testStarknet() (gas: 1164166) [PASS] testStarknetSpell() (gas: 2324) Test result: ok. 2 passed; 0 failed; 0 skipped; finished in 280.62s Running 19 tests for src/DssSpell.t.sol:DssSpellTest [PASS] testAuth() (gas: 52179062) [PASS] testAuthInSources() (gas: 8190427) [PASS] testBytecodeMatches() (gas: 2284491) [PASS] testCastCost() (gas: 1005060) [PASS] testChainlogValues() (gas: 9381042) [PASS] testChainlogVersionBump() (gas: 4432173) [PASS] testContractSize() (gas: 8984) [PASS] testDeployCost() (gas: 2270357) [PASS] testFailNotScheduled() (gas: 14375) [PASS] testFailTooEarly() (gas: 13607) [PASS] testFailTooLate() (gas: 13606) [PASS] testFailWrongDay() (gas: 13585) [PASS] testGeneral() (gas: 38118126) [PASS] testNextCastTime() (gas: 364790) [PASS] testOnTime() (gas: 1000699) [PASS] testPSMs() (gas: 2287352) [PASS] testUseEta() (gas: 363519) [PASS] test_RWA007_Update() (gas: 1225671) [PASS] test_RWA015_Update() (gas: 1193674) Test result: ok. 19 passed; 0 failed; 0 skipped; finished in 854.06s Ran 2 test suites: 21 tests passed, 0 failed, 0 skipped (21 total tests)
- Ensure that only
- Ensure each spell action has sufficient test coverage
src/DssSpell.sol
Outdated
(,,,uint256 line,) = VatLike(MCD_VAT).ilks("RETH-A"); | ||
DssExecLib.removeIlkFromAutoLine("RETH-A"); | ||
DssExecLib.setValue(MCD_VAT, "RETH-A", "line", 0); | ||
// NOTE: decreasing globalline suniglow level API because of precision loss when using DssExec |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// NOTE: decreasing globalline suniglow level API because of precision loss when using DssExec | |
// NOTE: decreasing global line using the low level API because of precision loss when using DssExecLib |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❌ Test coverage for RWA liquidation is not good.
It is trying to draw 0 after spell being executed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good to deploy
Goerli Executive Spell Review Checklist
Goerli 2023-10-11
Spell Actions (Per Exec Sheet):
- Non-Scope Defined Parameter Changes - WBTC DC-IAM Changes
- Reduce the WBTC-A DC-IAM Target Available Debt (
gap
) from 10 million DAI to 2 million DAI. - Reduce the WBTC-B DC-IAM Target Available Debt (
gap
) from 5 million DAI to 2 million DAI. - Reduce the WBTC-C DC-IAM Target Available Debt (
gap
) from 10 million DAI to 2 million DAI.
- Reduce the WBTC-A DC-IAM Target Available Debt (
- Stability Fee Changes
- Increase the ETH-A Stability Fee (SF) by 1.55%, from 3.70% to 5.25%.
- Increase the ETH-B Stability Fee (SF) by 1.55%, from 4.20% to 5.75%.
- Increase the ETH-C Stability Fee (SF) by 1.55%, from 3.45% to 5.00%.
- Increase WBTC-A Stability Fee (SF) by 0.06%, from 5.8% to 5.86%
- Increase WBTC-B Stability Fee (SF) by 0.06%, from 5.8% to 6.36%
- Increase WBTC-C Stability Fee (SF) by 0.06%, from 5.8% to 5.61%
- Initial RETH-A Offboarding
- Set rETH-A Debt Ceiling (
line
) to 0 (zero). - Remove RETH-A from
Autoline
.
- Set rETH-A Debt Ceiling (
- Reconfiguring Andromeda RWA015-A
- Set the Maximum Debt Ceiling (line) to 3 billion DAI.
- Reconfiguring Clydesdale RWA007-A
- Reactivate the Debt Ceiling Instant Access Module for this vault type.
- Set the Target Available Debt (gap) to 50 million DAI.
- Set the Ceiling Increase Cooldown (ttl) to 86400 (24 hours).
- Set the Maximum Debt Ceiling (line) to 3 billion DAI.
-
Set up Governance Facilitator Streams⚠️ Ignored on Goerli- ~~JanSky | 2023-10-01 00:00:00 to 2024-~~09-30 23:59:59 | 504,000.00 DAI | 0xf3F868534FAD48EF5a228Fe78669cf242745a755
-
VoteWizard | 2023-10-01 00:00:00 to 2024-09-30 23:59:59 | 504,000.00 DAI | 0x9E72629dF4fcaA2c2F5813FbbDc55064345431b1 -
JanSky | 2023-10-01 00:00:00 to 2024-09-30 23:59:59 | 216.00 MKR | 0xf3F868534FAD48EF5a228Fe78669cf242745a755
- USDP-PSM Facilitation Incentives
- DAO Resolution 1: Initial Setup (copy only)
- Add dao_resolution parameter: QmWg43PNNGfEyXnTv1qN8dRXFJz5ZchrmZU8qH57Ki6D62
-
BA Labs MKR Distribution⚠️ Ignored on Goerli-
BA Labs - 175 MKR - 0x5d67d5B1fC7EF4bfF31967bE2D2d7b9323c1521c
-
-
AVC Member Compensation⚠️ Ignored on Goerli-
opensky - 20.85 MKR - 0x8e67ee3bbeb1743dc63093af493f67c3c23c6f04 -
DAI-Vinci - 12.51 MKR - 0x9ee47F0f82F1A6F45C4E1D25Ce95C321D8C8356a -
IamMeeoh - 20.85 MKR - 0x47f7A5d8D27f259582097E1eE59a07a816982AE9 -
ACRE DAOs - 20.85 MKR - 0xBF9226345F601150F64Ea4fEaAE7E40530763cbd -
Harmony - 20.85 MKR - 0xE20A2e231215e9b7Aa308463F1A7490b2ECE55D3 -
Res - 20.85 MKR - 0x8c5c8d76372954922400e4654AF7694e158AB784 -
seedlatam.eth - 20.85 MKR - 0x0087a081a9b430fd8f688c6ac5dd24421bfb060d
-
-
Delegate Compensation⚠️ Ignored on Goerli-
0xDefensor - 41.67 MKR - 0x9542b441d65B6BF4dDdd3d4D2a66D8dCB9EE07a9 -
TRUE NAME - 41.67 MKR - 0x612F7924c367575a0Edf21333D96b15F1B345A5d -
BONAPUBLICA - 41.67 MKR - 0x167c1a762B08D7e78dbF8f24e5C3f1Ab415021D3 -
Navigator - 41.67 MKR - 0x11406a9CC2e37425F15f920F494A51133ac93072 -
vigilant - 34.5 MKR - 0x2474937cB55500601BCCE9f4cb0A0A72Dc226F61 -
Cloaky - 21.06 MKR - 0x869b6d5d8FA7f4FFdaCA4D23FFE0735c5eD1F818 -
UPMaker - 13.89 MKR - 0xbB819DF169670DC71A16F58F55956FE642cc6BcD -
PALC - 13.89 MKR - 0x78Deac4F87BD8007b9cb56B8d53889ed5374e83A -
BLUE - 12.78 MKR - 0xb6C09680D822F162449cdFB8248a7D3FC26Ec9Bf -
PBG - 6.48 MKR - 0x8D4df847dB7FfE0B46AF084fE031F7691C6478c2
-
Development Stage
- Office Hours
- OFF (On Goerli the deployed spell is cast with a pause delay of 60 sec.)
- 30 days spell expiry in constructor (
block.timestamp + 30 days
) - No Exec Doc Hash on Goerli
- Spell Description
- Ensure
description
exactly matches 'Goerli Spell
'
- Ensure
- Local Environment Actions
- Update Foundry by running
foundryup
- Reinstall libraries by running
rm -r lib && git submodule update --init --recursive
Insert checked out submodule paths here
- Library Checks
-
dss-exec-lib
- If submodule upgrades are present make sure
dss-exec-lib
is synced as well - (Non-critical) Submodule hash matches the latest release version (NOTE:
dss-exec-lib
as installed locally will use GitHub code more recent than the 0.0.9 release until the 0.0.10 release)
- If submodule upgrades are present make sure
-
dss-test
-
dss-interfaces
- (Non-critical) Submodule hash matches version used by
dss-test
- (Non-critical) Submodule hash matches version used by
dss-exec-lib
- (Non-critical) Submodule hash matches version used by
-
forge-std
- (Non-critical) Submodule hash matches version used by
dss-test
- (Non-critical) Submodule hash matches version used by
dss-exec-lib
- (Non-critical) Submodule hash matches version used by
-
-
- Update Foundry by running
- Rate constants used are correct
- Manual check 1: Calculate rates using
make rates pct=<pct>
(e.g. pct=0.75, for 0.75%) - Manual check 2: Compare rates used against IPFS rate list
- Variable name conforms to
X_PT_Y_Z_PCT_RATE
(e.g.ZERO_PT_SEVEN_FIVE_PCT_RATE
for 0.75%,SIX_PCT_RATE
for 6.00%) - Visibility is
internal
- State mutability is
constant
- Manual check 1: Calculate rates using
- Constants Match
- Precision unit constants used match their defined values
-
WAD = 10 ** 18
-
RAY = 10 ** 27
-
RAD = 10 ** 45
- Visibility is
internal
- State mutability is
constant
- (Non-critical) Ensure they match with ds-math and the Numerical Ranges
-
- Math unit constants used match their defined values
-
HUNDRED = 10 ** 2
-
THOUSAND = 10 ** 3
-
MILLION = 10 ** 6
-
BILLION = 10 ** 9
- Visibility is
internal
- State mutability is
constant
- (Non-critical) Ensure they match with config
-
- Precision unit constants used match their defined values
- Address Declaration
- Address Constants
- Address is not in the ChainLog
- Variable name matches corresponding entry in an
addresses.sol
file - Address value matches corresponding entry in an
addresses.sol
file - Visibility is
internal
- State mutability is
constant
- Address Immutables
- Use the DssExecLib Core Address Helpers instead of
getChangelogAddress()
whenever possible (e.g.DssExecLib.vat()
) - Follow pattern
address internal immutable KEY_NAME = DssExecLib.getChangelogAddress(KEY_NAME)
- Variable name matches ChainLog key name
- Exceptions must follow archive patterns (e.g.
MKR
forMCD_GOV
)
- Exceptions must follow archive patterns (e.g.
- Instantiate as
address
type- Exceptions must follow archive patterns (e.g.
GemLike
forMKR
)
- Exceptions must follow archive patterns (e.g.
- Visibility is
internal
- State mutability is
immutable
- Use the DssExecLib Core Address Helpers instead of
- Address Constants
- String Constants
- IPFS hashes or DAO resolutions
- IPFS hashes and DAO resolutions match the exec doc
- The variable is named
dao_resolutions
- if multiple dao resolutions are present
- they are located in the same string constant and are comma separated
- The comment above the the variable states:
Comma-separated list of DAO resolutions IPFS hashes
- Must be TOP LEVEL (or ds pause will reject)
- Name of the variable matches purpose per EXEC DOC
- Visibility is
public
- State mutability MUST BE
constant
- IPFS hashes or DAO resolutions
- Deployed Contracts (not yet on chainlog or new to chainlog)
- Verified on etherscan
- Optimizations match Repo
-
GNU AGPLv3
license - Constructor args ok (e.g.
vat
,dai
,dog
, ...)- Match ChainLog
- Wards ok (pause proxy relied, deployer denied)
-
MCD_ESM
is already relied / being relied in this spell (as approved by GovAlpha) in order to allow de-authing the pause proxy during Emergency Shutdown, viadenyProxy
.
-
- Matches corresponding github source code (i.e. diffcheck via vscode
code --diff etherscan.sol github.sol
) - Ensure deployer address is included into
addresses_deployers.sol
(to keep up to date)
- Core System Parameter Changes
- Stability Fee
jug.ilk.duty
(setIlkStabilityFee)- Comment matches pattern
// Increase ILK-A Stability Fee by X.XX% from X.XX% to X.XX%.
- Comment matches pattern
- Dai Savings Rate
pot.dsr
(setDSR)- Double check that
PCT_RATE
is correct- Check manually via
make rates pct=<pct>
(e.g. pct=0.75, for 0.75%) - Compare against IPFS
- Check manually via
- Double check that
-
spotter.ilk.mat
(liquidationRatio) -
dog.ilk.hole
(setIlkMaxLiquidationAmount) -
vat.ilk.dust
(setIlkMinVaultAmount) -
dog.ilk.chop
(liquidationPenalty) -
clip.buf
(startingPriceFactor) -
clipperMom.clip.tolerance
(setLiquidationBreakerPriceTolerance) -
clip.tail
(auctionDuration) -
clip.cusp
(permittedDrop) -
clip.chip
(kprPctReward) -
clip.tip
(kprFlatReward) -
calc.tau
(setLinearDecrease) - setStairstepExponentialDecrease
-
calc.cut
-
calc.step
-
- Stability Fee
- Debt Ceiling Changes
-
vat.ilk.line
changes (per ilk)- Collateral type (ilk) is not RWAXXX (For RWA refer to the designated section of the checklist)
-
setIlkDebtCeiling
orincreaseIlkDebtCeiling
ordecreaseIlkDebtCeiling
-
ilk
-
amount
-
global
-
-
vat.Line
changes (Global Line) - Autoline Changes
- setIlkAutoLineDebtCeiling
-
ilk
-
line
-
- setIlkAutoLineParameters
-
ilk
-
line
-
gap
-
ttl
-
- setIlkAutoLineDebtCeiling
-
- Onboarding (insert relevant checklists inline here)
- Offboarding (Lerp
mat
)- 1st Stage Spell Actions
- Remove Ilk from Autoline
- Set Ilks Debt Ceilings to
0
- Cache Ilks
line
to Reduce in the Global Debt Ceiling - Decrease Global Debt Ceiling by Total Amount of Offboarded Ilks
line
Cached
- 2nd Stage Spell Actions
- Set Ilk Liquidation Penalty
chop
to0
- Set Keeper Incentive Flat Rate
tip
to0
- Check IF
chip
is required to be adjusted as well - Use
DssExecLib.linearInterpolation
-
name
Format matches "XXX-A Offboarding" -
target
matchesspotter
-
ilk
Format matches "XXX-A" -
what
matchesmat
-
startTime
matchesblock.timestamp
-
start
matches VarCURRENT_XXX_A_MAT
-
end
matches VarTARGET_XXX_A_MAT
(Match Exec Sheet & Risk Computations)- Check IF Target
mat
Covers All Remaining Vaults CR times Risk Multiplier Factor
- Check IF Target
-
duration
matches Exec Sheet
-
- Set Ilk Liquidation Penalty
- 1st Stage Spell Actions
- RWA Updates
-
doc
(Using the_updateDoc
helper or otherwise)-
init
theRwaLiquidationOracle
to reset thedoc
- Sanity Check
pip
must be set (not the zero address) -
ilk
follows format "RWAXXX-A" -
val
price ignored (0
) ifinit
has already been called -
doc
new legal document (IPFS HASH) matches Doc (or Forum Post) -
tau
parameter used is the oldtau
value
-
- Autoline (
line
) + Liquidation Oracle Price Bump (val
)- Enable Autoline
-
ilk
follows format "RWAXXX-A" -
line
(max debt ceiling) -
gap
-
ttl
-
-
bump
RwaLiquidationOracle
with new computed increased price (val
)- ensure
val
is set accordingly with autoline max debt ceiling (line
) -
val
should enable DAI to be drawn over the loan period while taking into account the configuredink
amount, interest rate and liquidation ratio (see below)- New
val
is calculated withline * [(1 + duty) ** years] * mat
- rounded up - and makes sense in context of the rate mechanism. Minimum duration is usually in the Exec Doc of the spell with the RWAXXX ilk onboarding. - Comment explaining
val
formula (Debt ceiling * [ (1 + RWA stability fee ) ^ (minimum deal duration in years) ] * liquidation ratio
) is present - Accompanying comment above
bump
line in format// XXM * 1.XX^X * X.XX as a WAD
corresponding to theval
calculation formula (e.g.// 15M * 1.03^2 * 1.00 as a WAD
) is present along with the calculation formula on the line above - IF combining
val
of multiple RWA ilks being combined,val
calculation is done once per ilk and added to make the total, with workings provided in code comments. The existingval
value can be retrieved by callingread()
onPIP_RWAXX
and converting the result into decimal.
- New
- ensure
- Poke
spotter
to pull in the new price
- Enable Autoline
- Debt Ceiling (
line
) + Liquidation Oracle Price Bump (val
)- Increase Ilk Debt Ceiling (set DC + increase Global DC)
-
bump
RwaLiquidationOracle
with new computed increased price (val
)-
val
should enable DAI to be drawn over the loan period while taking into account the configuredink
amount, interest rate and liquidation ratio (see below)- New
val
is calculated withline * [(1 + duty) ** years] * mat
- rounded up - and makes sense in context of the rate mechanism. Minimum duration is usually in the Exec Doc of the spell with the RWAXXX ilk onboarding. - Comment explaining
val
formula (Debt ceiling * [ (1 + RWA stability fee ) ^ (minimum deal duration in years) ] * liquidation ratio
) is present - Accompanying comment above
bump
line in format// XXM * 1.XX^X * X.XX as a WAD
corresponding to theval
calculation formula (e.g.// 15M * 1.03^2 * 1.00 as a WAD
) is present along with the calculation formula on the line above - IF combining
val
of multiple RWA ilks being combined,val
calculation is done once per ilk and added to make the total, with workings provided in code comments. The existingval
value can be retrieved by callingread()
onPIP_RWAXX
and converting the result into decimal.
- New
-
- Poke
spotter
to pull in the new price
-
- Payments
- Payments are not crafted or reviewed on Goerli (comments may be present)
- SubDAO Content
- SubDAO SubProxy spell execution
- SubDAO spell address matches Exec Sheet (comment or otherwise)
- IF SubDAO spell deployer is a smart contract (e.g. multisig or factory)
- Ensure the deployer address is in
addresses_deployers.sol
as an entry
- Ensure the deployer address is in
- Executed using
ProxyLike(SUBDAO_PROXY).exec(SUBDAO_SPELL, abi.encodeWithSignature("execute()"));
- Execution is NOT delegate call
- Reviewer Note: Gas cost may be very high as SubDAO spells execute within the main
cast
execution. (Also note that low level call gas estimation is not done by our scripts)
- Maker Core (main spell) SubDAO actions (i.e. operate in Pause Proxy
DelegateCall
context)- No SubDAO contract being interacted with is authed on a core contract like vat, etc. (Check comprehensively where the risk is high)
- SubDAO contract licensing and optimizations generally do not matter (except where they pose a security risk)
- SubDAO contracts and all libraries / dependencies are verified (Blocking if not true)
- Upgradable SubDAO contracts
- Any upgradable contracts have the
PAUSE_PROXY
as theiradmin
(i.e. the party that can upgrade)- Any upgradable SubDAO contracts with an
admin
that is notPAUSE_PROXY
are not authed on any core contracts (Blocking)
- Any upgradable SubDAO contracts with an
- Any upgradable contracts have the
- All SubDAO content addresses (i.e. provided contract addresses or EOAs) present in the Maker Core spell are present in the Exec Sheet and are correct. SubDAO addresses being authed or given any permissions and addresses being called must be confirmed by the SubDAO spell team.
- SubDAO actions match Exec Sheet (only where inline with main spell code) and do not affect core contracts
- Core contract knock-on actions (such as offboarding or setting DC to 0) are present in the Exec Sheet and match the code
- External calls for SubDAO content are NOT delegate call
- Code does not have untoward behavior within the scope of Maker Core Contracts (e.g. up to the SubDAO proxy)
- SubDAO SubProxy spell execution
- External Contracts Calls (Not SubDAOs, e.g. Starknet)
- Target Contract don't block spell execution
- External call is NOT delegate call
- Target Contract doesn't have permissions on the Vat
- Target Contract doesn't do anything untoward (e.g. interacting with unsafe contracts)
- Contracts deployed via
CREATE2
(e.g. if it looks like a vanity address) do not haveselfdestruct
in their code - MCD Pause Proxy doesn't give any approvals
- All possible actions of the Target Contract are documented
- Target contract is not upgradable
- Target Contract is included in the ChainLog
- Test Coverage is comprehensive
- ChainLog
- Increment ChainLog version based on update type
- Major -> New Vat (++.0.0)
- Minor -> Core Module (DSS) Update (e.g. Flapper) (0.++.0)
- Patch -> Collateral addition or addition/modification (0.0.++)
- Increment ChainLog version based on update type
-
addresses_goerli.sol
matches spell code - Ensure every spell variable is declared as public/internal
- Ensure every spell variable is used in the spell (no unused variables)
- Spell actions match the corresponding Exec Sheet
- Tests
- Ensure each spell action has sufficient test coverage
- Non-Scope Defined Parameter Changes - WBTC DC-IAM Changes
✅testGeneral
- Stability Fee Changes
✅testGeneral
- Initial RETH-A Offboarding
✅testGeneral
- Reconfiguring Andromeda RWA015-A
✅testGeneral
/ :white_check_mark:test_RWA015_Update
- Reconfiguring Clydesdale RWA007-A
✅testGeneral
/ :white_check_mark:test_RWA0007_Update
-
Set up Governance Facilitator Streams⚠️ Ignored on Goerli - USDP-PSM Facilitation Incentives
⚠️ No test coverage, not mandatory. Maybe consider adding it.
- Non-Scope Defined Parameter Changes - WBTC DC-IAM Changes
- Ensure every test function is declared as public if enabled or private if disabled
- Ensure that the
DssExecLib.address
file is not being modified by the spell PR - Check all CI tests are passing as at the latest commit
✅ 5fbcea5 - Check all tests are passing locally using
make test
- Ensure that only
ETH_RPC_URL
is being used from env (i.e. nomatch
,block
or similar are active in your env)
- Ensure that only
- Ensure each spell action has sufficient test coverage
Running 2 tests for src/test/starknet.t.sol:StarknetTests
[PASS] testStarknet() (gas: 1163896)
[PASS] testStarknetSpell() (gas: 2324)
Test result: ok. 2 passed; 0 failed; 0 skipped; finished in 33.12s
Running 19 tests for src/DssSpell.t.sol:DssSpellTest
[PASS] testAuth() (gas: 52178792)
[PASS] testAuthInSources() (gas: 8190157)
[PASS] testBytecodeMatches() (gas: 2289317)
[PASS] testCastCost() (gas: 1004790)
[PASS] testChainlogValues() (gas: 9380772)
[PASS] testChainlogVersionBump() (gas: 4431903)
[PASS] testContractSize() (gas: 8984)
[PASS] testDeployCost() (gas: 2275165)
[PASS] testFailNotScheduled() (gas: 14375)
[PASS] testFailTooEarly() (gas: 13607)
[PASS] testFailTooLate() (gas: 13606)
[PASS] testFailWrongDay() (gas: 13585)
[PASS] testGeneral() (gas: 38122659)
[PASS] testNextCastTime() (gas: 364790)
[PASS] testOnTime() (gas: 1000429)
[PASS] testPSMs() (gas: 2287136)
[PASS] testUseEta() (gas: 363519)
[PASS] test_RWA007_Update() (gas: 1225706)
[PASS] test_RWA015_Update() (gas: 1193749)
Test result: ok. 19 passed; 0 failed; 0 skipped; finished in 1091.67s
Ran 2 test suites: 21 tests passed, 0 failed, 0 skipped (21 total tests)
Good to deploy
Local test rerun: ./scripts/test-dssspell-forge.sh no-match="" match="" block=""
Using DssExecLib at: 0x122F6c0Dcd898b4a07310E92c3eAE5D7Ce0c8bb6
[⠔] Compiling...
No files changed, compilation skipped
Running 2 tests for src/test/starknet.t.sol:StarknetTests
[PASS] testStarknet() (gas: 1163551)
[PASS] testStarknetSpell() (gas: 2324)
Test result: ok. 2 passed; 0 failed; 0 skipped; finished in 261.73s
Running 19 tests for src/DssSpell.t.sol:DssSpellTest
[PASS] testAuth() (gas: 52178447)
[PASS] testAuthInSources() (gas: 8189812)
[PASS] testBytecodeMatches() (gas: 2289317)
[PASS] testCastCost() (gas: 1004445)
[PASS] testChainlogValues() (gas: 9380427)
[PASS] testChainlogVersionBump() (gas: 4431558)
[PASS] testContractSize() (gas: 8984)
[PASS] testDeployCost() (gas: 2275165)
[PASS] testFailNotScheduled() (gas: 14375)
[PASS] testFailTooEarly() (gas: 13607)
[PASS] testFailTooLate() (gas: 13606)
[PASS] testFailWrongDay() (gas: 13585)
[PASS] testGeneral() (gas: 38122314)
[PASS] testNextCastTime() (gas: 364790)
[PASS] testOnTime() (gas: 1000084)
[PASS] testPSMs() (gas: 2286860)
[PASS] testUseEta() (gas: 363519)
[PASS] test_RWA007_Update() (gas: 1253158)
[PASS] test_RWA015_Update() (gas: 1255198)
Test result: ok. 19 passed; 0 failed; 0 skipped; finished in 788.73s
Ran 2 test suites: 21 tests passed, 0 failed, 0 skipped (21 total tests) |
Good to cast Deployed Stage
|
Good to cast. Deployed Stage
Using DssExecLib at: 0x122F6c0Dcd898b4a07310E92c3eAE5D7Ce0c8bb6
[⠒] Compiling...
[⠢] Compiling 4 files with 0.8.16
[⠃] Solc 0.8.16 finished in 1.47s
Compiler run successful!
Running 2 tests for src/test/starknet.t.sol:StarknetTests
[PASS] testStarknet() (gas: 1163896)
[PASS] testStarknetSpell() (gas: 2324)
Test result: ok. 2 passed; 0 failed; 0 skipped; finished in 32.86s
Running 17 tests for src/DssSpell.t.sol:DssSpellTest
[PASS] testBytecodeMatches() (gas: 2289317)
[PASS] testCastCost() (gas: 1004790)
[PASS] testChainlogValues() (gas: 9380772)
[PASS] testChainlogVersionBump() (gas: 4431903)
[PASS] testContractSize() (gas: 8984)
[PASS] testDeployCost() (gas: 2275165)
[PASS] testFailNotScheduled() (gas: 14375)
[PASS] testFailTooEarly() (gas: 13607)
[PASS] testFailTooLate() (gas: 13606)
[PASS] testFailWrongDay() (gas: 13585)
[PASS] testGeneral() (gas: 38124756)
[PASS] testNextCastTime() (gas: 364790)
[PASS] testOnTime() (gas: 1000429)
[PASS] testPSMs() (gas: 2287136)
[PASS] testUseEta() (gas: 363519)
[PASS] test_RWA007_Update() (gas: 1253043)
[PASS] test_RWA015_Update() (gas: 1254968)
Test result: ok. 17 passed; 0 failed; 0 skipped; finished in 358.20s
Ran 2 test suites: 19 tests passed, 0 failed, 0 skipped (19 total tests) |
Cast and Merge Stage
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good to merge 🥇
Cast and Merge Stage
- Spell is Cast
- Check Cast Trace (via EthTx)
- Ensure no reverts are present that block execution
- Inspect low level call reverts if expected
- Ensure all actions are executed and no out-of-gas errors are present
- Ensure no reverts are present that block execution
- Check Cast Trace (via EthTx)
- Ensure that no commits or changes have occurred since the spell was deployed and archived
- Approve spell PR for merge via 'Approve' review option
Description
Contribution Checklist
(PE-<TICKET_NUMBER>)
Checklist
officeHours
modifier override30 days
unless otherwise specified)ETH_GAS_LIMIT="XXX" ETH_GAS_PRICE="YYY" make deploy
Goerli
etherscanmake spell="0x-deployed-spell-address" cast-spell
make archive-spell
ormake date="YYYY-MM-DD" archive-spell
to make an archive directory and copyDssSpell.sol
,DssSpell.t.sol
andDssSpell.t.base.sol
squash and merge
this PR