From 84ea57706ede66adcfbf9f6b5ad8ba1d71a8af3d Mon Sep 17 00:00:00 2001 From: amusingaxl <112016538+amusingaxl@users.noreply.github.com> Date: Wed, 24 Jul 2024 13:29:34 -0300 Subject: [PATCH 1/6] fix: bad precision on `mat` --- spell/psm-checklists.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/spell/psm-checklists.md b/spell/psm-checklists.md index ffe3814..127c075 100644 --- a/spell/psm-checklists.md +++ b/spell/psm-checklists.md @@ -89,14 +89,14 @@ - [ ] `MCD_JUG`: new ilk is initialized - `MCD_SPOT`: - [ ] Sanity check: Dai parity (`par`) current value is 1 (`1 * RAY`) - - [ ] Collateralization ratio (`mat`) is set to 100% (`1 * WAD`) for the ilk - - IF a new `pip` is being used: + - [ ] Collateralization ratio (`mat`) is set to 100% (`1 * RAY`) for the ilk + - [ ] IF a new `pip` is being used: - [ ] `pip` is set for the ilk - [ ] `pip` is a `DSValue` instance - [ ] The value on `pip` is set to 1 (`1 * WAD`) - [ ] `pip` deployer is no longer the `owner` - [ ] `MCD_PAUSE_PROXY` is the `owner` on `pip` - - OTHERWISE when reusing an existing `pip`: + - [ ] OTHERWISE when reusing an existing `pip`: - [ ] `pip` is set for the ilk - [ ] `pip` in the chainlog matches `gem` symbol (i.e. `PIP_USDC` for `USDC`) - [ ] `ILK_REGISTRY`: new ilk is added to the registry @@ -118,7 +118,7 @@ - [ ] `buyGemNoFee` works as expected - [ ] `sellGemNoFee` works as expected - `DssLitePsmMom`: - - Chief (`MCD_ADM`) is set as the `authority` (i.e. `MomLike(MOM).authority() == MCD_ADM`) + - [ ] Chief (`MCD_ADM`) is set as the `authority` (i.e. `MomLike(MOM).authority() == MCD_ADM`) - E2E tests: - [ ] `halt` works as expected - `LitePsmJob`: From 71dbf16443774c7b7c12bd4a09d620e72901b828 Mon Sep 17 00:00:00 2001 From: amusingaxl <112016538+amusingaxl@users.noreply.github.com> Date: Thu, 1 Aug 2024 15:11:34 -0300 Subject: [PATCH 2/6] refactor: reorganize checks --- spell/psm-checklists.md | 105 +++++++++++++++++++++------------------- 1 file changed, 54 insertions(+), 51 deletions(-) diff --git a/spell/psm-checklists.md b/spell/psm-checklists.md index 127c075..3b5092d 100644 --- a/spell/psm-checklists.md +++ b/spell/psm-checklists.md @@ -2,7 +2,8 @@ ## PSM Migration Checklist -- [ ] IF contracts are being on-boarded in the current spell, execute the full [LitePSM On-boarding Checklist](#litepsm-on-boarding-checklist) +- [ ] IF LitePSM MOM is being on-boarded in the current spell, execute the full [LitePSM MOM On-boarding Checklist](#litepsm-mom-on-boarding-checklist) +- [ ] IF LitePSM contracts are being on-boarded in the current spell, execute the full [LitePSM On-boarding Checklist](#litepsm-on-boarding-checklist) - [ ] IF a PSM is deprecated in the migration, execute the full [PSM Off-boarding Checklist](#psm-off-boarding-checklist) - [ ] IF present, max amount of gems to move (`dstWant`) matches the Exec Sheet - [ ] IF present, min amount of gems to keep (`srcKeep`) matches the Exec Sheet @@ -30,10 +31,10 @@ - [ ] `vat.vice()` is unchanged after the spell execution - [ ] `vat.sin(MCD_PAUSE_PROXY)` is unchanged after the spell execution -## LitePSM On-boarding Checklist +## LitePSM MOM On-boarding Checklist - Deployed Contracts - - `DssLitePsm` + - [ ] `DssLitePsmMom` - [ ] Optimizer is **enabled** - [ ] Optimize runs is set to `200` - [ ] Contract has been reviewed by minimum 2 specialized [Active Ecosystem Actors](https://mips.makerdao.com/mips/details/MIP101#2-8-2-active-ecosystem-actors) @@ -44,15 +45,19 @@ - [ ] EITHER code diff check for each individual file - [ ] OR bytecode verification tool such as `forge verify-bytecode` - [ ] Deployed contract matches the code in the [repo](https://github.com/makerdao/dss-lite-psm/) - - Constructor params: - - [ ] ilk is named `LITE-PSM-{TOKEN_SYMBOL}-A` (i.e. `LITE-PSM-USDC-A`) - - [ ] `gem` matches the expected token address - - [ ] `daiJoin` matches `MCD_JOIN_DAI` from the chainlog - - [ ] `pocket` matches the pocket address in the Exec Sheet - - [ ] Deployer no longer has privileged access (`wards(deployer) == 0`) - - [ ] `MCD_PAUSE_PROXY` has been authed (i.e. `require(WardsLike(LITE_PSM).wards(MCD_PAUSE_PROXY) == 1)`) - - [ ] Sanity check: `DssLitePsm` has `type(uint256).max` approval to spend `gem` on behalf of `pocket` - - `DssLitePsmMom` + - [ ] Deployer is no longer the `owner` + - [ ] `MCD_PAUSE_PROXY` is the `owner` of the contract (i.e. `require(MomLike(MOM).owner() == MCD_PAUSE_PROXY`)) +- Initialization: + - [ ] `DssLitePsmMom`: + - [ ] The chief (`MCD_ADM`) is set as the `authority` (i.e. `MomLike(MOM).setAuthority(MCD_ADM)`) +- Test Coverage: + - [ ] `DssLitePsmMom`: + - [ ] The chief (`MCD_ADM`) is set as the `authority` (i.e. `MomLike(MOM).setAuthority(MCD_ADM)`) + +## LitePSM On-boarding Checklist + +- Deployed Contracts + - [ ] `DssLitePsm` - [ ] Optimizer is **enabled** - [ ] Optimize runs is set to `200` - [ ] Contract has been reviewed by minimum 2 specialized [Active Ecosystem Actors](https://mips.makerdao.com/mips/details/MIP101#2-8-2-active-ecosystem-actors) @@ -63,31 +68,35 @@ - [ ] EITHER code diff check for each individual file - [ ] OR bytecode verification tool such as `forge verify-bytecode` - [ ] Deployed contract matches the code in the [repo](https://github.com/makerdao/dss-lite-psm/) - - [ ] Deployer is no longer the `owner` - - [ ] `MCD_PAUSE_PROXY` is the `owner` of the contract (i.e. `require(MomLike(MOM).owner() == MCD_PAUSE_PROXY`)) - - `LitePsmJob` + - Constructor params: + - [ ] ilk is named `LITE-PSM-{TOKEN_SYMBOL}-A` (i.e. `LITE-PSM-USDC-A`) + - [ ] `gem` matches the expected token address + - [ ] `daiJoin` matches `MCD_JOIN_DAI` from the chainlog + - [ ] `pocket` matches the pocket address in the Exec Sheet + - [ ] Deployer no longer has privileged access (`wards(deployer) == 0`) + - [ ] `MCD_PAUSE_PROXY` has been authed (i.e. `require(WardsLike({LITE_PSM}).wards(MCD_PAUSE_PROXY) == 1)`) + - [ ] Sanity check: `DssLitePsm` has `type(uint256).max` approval to spend `gem` on behalf of `pocket` + - [ ] `LitePsmJob` - [ ] Uses the default Solidity version in [`dss-cron`](https://github.com/makerdao/dss-cron) - [ ] Optimizer is **enabled** - [ ] Deployed contract matches the code in the [repo](https://github.com/makerdao/dss-cron) - Constructor params: - [ ] `_sequencer` matches `CRON_SEQUENCER` address from the chainlog - - [ ] `_litePsm` matches `DssLitePsm` address + - [ ] `_litePsm` matches `{LITE_PSM}` address - [ ] `_rushThreshold` matches the Exec Sheet (it might be named as "fill threshold") - [ ] `_gushThreshold` matches the Exec Sheet (it might be named as "trim threshold") - [ ] `_cutThreshold` matches the Exec Sheet (it might be named as "chug threshold") - Initialization - - `DssLitePsm`: + - [ ] `DssLitePsm`: - [ ] `buf` is set to the value specified in the Exec Sheet - [ ] `vow` is set to `MCD_VOW` from the chainlog - - [ ] `MCD_PAUSE_PROXY` is whitelisted to execute swaps with no fees (i.e. `KissLike(LITE_PSM).kiss(MCD_PAUSE_PROXY)`) - - [ ] `DssLitePsmMom` is authed (i.e. `RelyLike(LITE_PSM).rely(MOM)`) - - `DssLitePsmMom`: - - [ ] The chief (`MCD_ADM`) is set as the `authority` (i.e. `MomLike(MOM).setAuthority(MCD_ADM)`) - - `LitePsmJob`: + - [ ] `MCD_PAUSE_PROXY` is whitelisted to execute swaps with no fees (i.e. `KissLike({LITE_PSM}).kiss(MCD_PAUSE_PROXY)`) + - [ ] `DssLitePsmMom` is authed (i.e. `RelyLike({LITE_PSM}).rely(MOM)`) + - [ ] `LitePsmJob`: - [ ] Job is added to `CRON_SEQUENCER` - [ ] `MCD_VAT`: new ilk is initialized - [ ] `MCD_JUG`: new ilk is initialized - - `MCD_SPOT`: + - [ ] `MCD_SPOT`: - [ ] Sanity check: Dai parity (`par`) current value is 1 (`1 * RAY`) - [ ] Collateralization ratio (`mat`) is set to 100% (`1 * RAY`) for the ilk - [ ] IF a new `pip` is being used: @@ -100,52 +109,46 @@ - [ ] `pip` is set for the ilk - [ ] `pip` in the chainlog matches `gem` symbol (i.e. `PIP_USDC` for `USDC`) - [ ] `ILK_REGISTRY`: new ilk is added to the registry - - `CHAINLOG`: + - [ ] `CHAINLOG`: - [ ] `DssLitePsm` is added to the chainlog and `addresses_mainnet.sol` according to the Exec Sheet - [ ] `pocket` is added to the chainlog and `addresses_mainnet.sol` according to the Exec Sheet - [ ] `DssLitePsmMom` is added to the chainlog and `addresses_mainnet.sol` according to the Exec Sheet - [ ] `LitePsmJob` is added to the chainlog and `addresses_mainnet.sol` according to the Exec Sheet - [ ] IF a new `pip` is being added, it is added to the chainlog and `addresses_mainnet.sol` as `PIP_{TOKEN_SYMBOL}` (i.e. `PIP_USDC`) - Test coverage: - - `DssLitePsm`: + - [ ] `DssLitePsm`: - [ ] `vow` is set to `MCD_VOW` - [ ] `buf` matches the Exec Sheet - - [ ] `MCD_PAUSE_PROXY` is whitelisted to execute swaps with no fees (i.e. `KissLike(LITE_PSM).bud(MCD_PAUSE_PROXY) == 1`) - - [ ] `DssLitePsmMom` is authed (i.e. `WardsLike(LITE_PSM).wards(MOM) == 1`) - - E2E tests: + - [ ] `MCD_PAUSE_PROXY` is whitelisted to execute swaps with no fees (i.e. `KissLike({LITE_PSM}).bud(MCD_PAUSE_PROXY) == 1`) + - [ ] `DssLitePsmMom` is authed (i.e. `WardsLike({LITE_PSM}).wards(MOM) == 1`) + - [ ] E2E tests: - [ ] `buyGem` works as expected - [ ] `sellGem` works as expected - [ ] `buyGemNoFee` works as expected - [ ] `sellGemNoFee` works as expected - - `DssLitePsmMom`: - - [ ] Chief (`MCD_ADM`) is set as the `authority` (i.e. `MomLike(MOM).authority() == MCD_ADM`) - - E2E tests: - - [ ] `halt` works as expected - - `LitePsmJob`: + - [ ] `DssLitePsmMom`: + - [ ] E2E tests: + - [ ] `halt` prevents new swaps in `{LITE_PSM}` + - [ ] `LitePsmJob`: - [ ] Job is added to `CRON_SEQUENCER` (i.e.: `SequencerLike(CRON_SEQUENCER).hasJob(LITE_PSM_JOB) == true`) - - [ ] `_sequencer` matches `CRON_SEQUENCER` address from the chainlog - - [ ] `_litePsm` matches `DssLitePsm` address - - [ ] `_rushThreshold` matches the Exec Sheet (it might be named as "fill threshold") - - [ ] `_gushThreshold` matches the Exec Sheet (it might be named as "trim threshold") - - [ ] `_cutThreshold` matches the Exec Sheet (it might be named as "chug threshold") - - E2E tests: - - [ ] `workable` returns the correct value: - - [ ] IF `rush() > 0`, returns `(true, litePsm.fill.selector)` - - [ ] OTHERWISE IF `cut() > 0`, returns `(true, litePsm.chug.selector)` - - [ ] OTHERWISE IF `gush() > 0`, returns `(true, litePsm.trim.selector)` - - [ ] OTHERWISE returns `(false, "")` + - [ ] `sequencer` matches `CRON_SEQUENCER` address from the chainlog + - [ ] `litePsm` matches `{LITE_PSM}` address + - [ ] `rushThreshold` matches the Exec Sheet (it might be named as "fill threshold") + - [ ] `gushThreshold` matches the Exec Sheet (it might be named as "trim threshold") + - [ ] `cutThreshold` matches the Exec Sheet (it might be named as "chug threshold") + - [ ] E2E tests: - [ ] `work` has the desired effect: - - [ ] IF `rush() > 0`, `fill` is called - - [ ] OTHERWISE IF `cut() > 0`, `chug` is called - - [ ] OTHERWISE IF `gush() > 0`, `trim` is called - - [ ] OTHERWISE reverts - - [ ] `MCD_VAT`: `urns[ilk][LITE_PSM].ink` is set to the max value that will not cause an overflow (`int256(type(uint256).max / RAY)`) + - [ ] IF `rush() > _rushThreshold`, `fill` is called + - [ ] OTHERWISE IF `cut() > _cutThreshold`, `chug` is called + - [ ] OTHERWISE IF `gush() > _gushThreshold`, `trim` is called + - [ ] OTHERWISE it reverts + - [ ] `MCD_VAT`: `urns[ilk][{LITE_PSM}].ink` is set to the max value that will not cause an overflow (`int256(type(uint256).max / RAY)`) - [ ] `MCD_JUG`: Stability fee (`duty`) is set to 0% (`1 * RAY`) for the ilk (:information_source: covered in `config.sol`) - - `MCD_SPOT`: + - [ ] `MCD_SPOT`: - [ ] `spotter(DST_ILK).mat` is set to 100% (`1 * RAY`) (:information_source: covered in `config.sol`) - [ ] `spotter(DST_ILK).pip` is set correctly - [ ] `CHAINLOG`: version is bumped: `{x}.{y}.{z+1}` (:information_source: covered in `config.sol`) - - `ILK_REGISTRY`: + - [ ] `ILK_REGISTRY`: - [ ] New ilk is added to the registry - [ ] `name` matches `gem` name - [ ] `symbol` matches `gem` symbol From f8d21e27c5019e9ab7488b0485bef3f81c68be3a Mon Sep 17 00:00:00 2001 From: amusingaxl <112016538+amusingaxl@users.noreply.github.com> Date: Thu, 1 Aug 2024 15:25:00 -0300 Subject: [PATCH 3/6] refactor: normalize hyphenation for "onboarding" and "offboarding" --- spell/psm-checklists.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/spell/psm-checklists.md b/spell/psm-checklists.md index 3b5092d..ec12321 100644 --- a/spell/psm-checklists.md +++ b/spell/psm-checklists.md @@ -2,9 +2,9 @@ ## PSM Migration Checklist -- [ ] IF LitePSM MOM is being on-boarded in the current spell, execute the full [LitePSM MOM On-boarding Checklist](#litepsm-mom-on-boarding-checklist) -- [ ] IF LitePSM contracts are being on-boarded in the current spell, execute the full [LitePSM On-boarding Checklist](#litepsm-on-boarding-checklist) -- [ ] IF a PSM is deprecated in the migration, execute the full [PSM Off-boarding Checklist](#psm-off-boarding-checklist) +- [ ] IF LitePSM MOM is being on-boarded in the current spell, execute the full [LitePSM MOM Onboarding Checklist](#litepsm-mom-onboarding-checklist) +- [ ] IF LitePSM contracts are being on-boarded in the current spell, execute the full [LitePSM Onboarding Checklist](#litepsm-onboarding-checklist) +- [ ] IF a PSM is deprecated in the migration, execute the full [PSM Offboarding Checklist](#psm-offboarding-checklist) - [ ] IF present, max amount of gems to move (`dstWant`) matches the Exec Sheet - [ ] IF present, min amount of gems to keep (`srcKeep`) matches the Exec Sheet - Source PSM: @@ -31,7 +31,7 @@ - [ ] `vat.vice()` is unchanged after the spell execution - [ ] `vat.sin(MCD_PAUSE_PROXY)` is unchanged after the spell execution -## LitePSM MOM On-boarding Checklist +## LitePSM MOM Onboarding Checklist - Deployed Contracts - [ ] `DssLitePsmMom` @@ -54,7 +54,7 @@ - [ ] `DssLitePsmMom`: - [ ] The chief (`MCD_ADM`) is set as the `authority` (i.e. `MomLike(MOM).setAuthority(MCD_ADM)`) -## LitePSM On-boarding Checklist +## LitePSM Onboarding Checklist - Deployed Contracts - [ ] `DssLitePsm` @@ -158,7 +158,7 @@ - [ ] `gemJoin` is set to `address(0)` - [ ] `clip` is set to `address(0)` -## PSM Off-boarding Checklist +## PSM Offboarding Checklist - [ ] ilk is removed from `AutoLine` - [ ] ilk `line` is set to `0` From 7857efcfdd30651d37110b7b1ffd2a87c622b807 Mon Sep 17 00:00:00 2001 From: amusingaxl <112016538+amusingaxl@users.noreply.github.com> Date: Thu, 1 Aug 2024 15:25:42 -0300 Subject: [PATCH 4/6] feat: add checklist items for additional spell dependencies --- spell/spell-reviewer-mainnet-checklist.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/spell/spell-reviewer-mainnet-checklist.md b/spell/spell-reviewer-mainnet-checklist.md index 4668620..c472830 100644 --- a/spell/spell-reviewer-mainnet-checklist.md +++ b/spell/spell-reviewer-mainnet-checklist.md @@ -135,6 +135,11 @@ * [`DssExecLib.setGlobalDebtCeiling(amount)`](https://github.com/makerdao/dss-exec-lib/blob/v0.0.9/src/DssExecLib.sol#L428) * [`DssExecLib.increaseGlobalDebtCeiling(amount)`](https://github.com/makerdao/dss-exec-lib/blob/v0.0.9/src/DssExecLib.sol#L436) * [`DssExecLib.decreaseGlobalDebtCeiling(amount)`](https://github.com/makerdao/dss-exec-lib/blob/v0.0.9/src/DssExecLib.sol#L445C14-L445C39) +* IF additional dependencies (i.e. `./src/dependencies/` directory) are present: + * [ ] IF the dependencies contracts/libraries have been audited + * [ ] FOREACH contract/library ensure its content matches (i.e. diff check) the latest audited version + * [ ] OTHERWISE obtain the permalink to the relevant repository from a trusted party (i.e. Gov Facilitators) + * [ ] FOREACH contract/library ensure its content matches (i.e. diff check) the one from the permalink * IF onboarding is present * [ ] Insert and follow the relevant checklists below: * [Collateral Onboarding](./collateral-onboarding-checklist.md) From afa642a5c53170f5027f3bd8f766c4c3de8e982e Mon Sep 17 00:00:00 2001 From: amusingaxl <112016538+amusingaxl@users.noreply.github.com> Date: Thu, 1 Aug 2024 15:30:23 -0300 Subject: [PATCH 5/6] chore: add missing words to wordslist --- .wordlist.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.wordlist.txt b/.wordlist.txt index 14c8ad7..2fcb95d 100644 --- a/.wordlist.txt +++ b/.wordlist.txt @@ -49,6 +49,7 @@ ExecLib Filable Fileable fileables +FOREACH Getter github goerli @@ -92,6 +93,7 @@ Onboardings OpenZeppelin OSM params +permalink permissioned permissioning permittedDrop From a78751646950cb409f380e8debd76a7d09e85261 Mon Sep 17 00:00:00 2001 From: amusingaxl <112016538+amusingaxl@users.noreply.github.com> Date: Mon, 12 Aug 2024 12:57:28 -0300 Subject: [PATCH 6/6] refactor: address review comments --- spell/psm-checklists.md | 54 +++++++++++++---------- spell/spell-reviewer-mainnet-checklist.md | 6 +-- 2 files changed, 33 insertions(+), 27 deletions(-) diff --git a/spell/psm-checklists.md b/spell/psm-checklists.md index ec12321..cc8f343 100644 --- a/spell/psm-checklists.md +++ b/spell/psm-checklists.md @@ -34,7 +34,7 @@ ## LitePSM MOM Onboarding Checklist - Deployed Contracts - - [ ] `DssLitePsmMom` + - `DssLitePsmMom` - [ ] Optimizer is **enabled** - [ ] Optimize runs is set to `200` - [ ] Contract has been reviewed by minimum 2 specialized [Active Ecosystem Actors](https://mips.makerdao.com/mips/details/MIP101#2-8-2-active-ecosystem-actors) @@ -48,16 +48,16 @@ - [ ] Deployer is no longer the `owner` - [ ] `MCD_PAUSE_PROXY` is the `owner` of the contract (i.e. `require(MomLike(MOM).owner() == MCD_PAUSE_PROXY`)) - Initialization: - - [ ] `DssLitePsmMom`: + - `DssLitePsmMom`: - [ ] The chief (`MCD_ADM`) is set as the `authority` (i.e. `MomLike(MOM).setAuthority(MCD_ADM)`) - Test Coverage: - - [ ] `DssLitePsmMom`: + - `DssLitePsmMom`: - [ ] The chief (`MCD_ADM`) is set as the `authority` (i.e. `MomLike(MOM).setAuthority(MCD_ADM)`) ## LitePSM Onboarding Checklist - Deployed Contracts - - [ ] `DssLitePsm` + - `DssLitePsm` - [ ] Optimizer is **enabled** - [ ] Optimize runs is set to `200` - [ ] Contract has been reviewed by minimum 2 specialized [Active Ecosystem Actors](https://mips.makerdao.com/mips/details/MIP101#2-8-2-active-ecosystem-actors) @@ -76,7 +76,7 @@ - [ ] Deployer no longer has privileged access (`wards(deployer) == 0`) - [ ] `MCD_PAUSE_PROXY` has been authed (i.e. `require(WardsLike({LITE_PSM}).wards(MCD_PAUSE_PROXY) == 1)`) - [ ] Sanity check: `DssLitePsm` has `type(uint256).max` approval to spend `gem` on behalf of `pocket` - - [ ] `LitePsmJob` + - `LitePsmJob` - [ ] Uses the default Solidity version in [`dss-cron`](https://github.com/makerdao/dss-cron) - [ ] Optimizer is **enabled** - [ ] Deployed contract matches the code in the [repo](https://github.com/makerdao/dss-cron) @@ -87,16 +87,18 @@ - [ ] `_gushThreshold` matches the Exec Sheet (it might be named as "trim threshold") - [ ] `_cutThreshold` matches the Exec Sheet (it might be named as "chug threshold") - Initialization - - [ ] `DssLitePsm`: + - `DssLitePsm`: - [ ] `buf` is set to the value specified in the Exec Sheet - [ ] `vow` is set to `MCD_VOW` from the chainlog - [ ] `MCD_PAUSE_PROXY` is whitelisted to execute swaps with no fees (i.e. `KissLike({LITE_PSM}).kiss(MCD_PAUSE_PROXY)`) - [ ] `DssLitePsmMom` is authed (i.e. `RelyLike({LITE_PSM}).rely(MOM)`) - - [ ] `LitePsmJob`: + - `LitePsmJob`: - [ ] Job is added to `CRON_SEQUENCER` - - [ ] `MCD_VAT`: new ilk is initialized - - [ ] `MCD_JUG`: new ilk is initialized - - [ ] `MCD_SPOT`: + - `MCD_VAT`: + - [ ] New ilk is initialized + - `MCD_JUG`: + - [ ] New ilk is initialized + - `MCD_SPOT`: - [ ] Sanity check: Dai parity (`par`) current value is 1 (`1 * RAY`) - [ ] Collateralization ratio (`mat`) is set to 100% (`1 * RAY`) for the ilk - [ ] IF a new `pip` is being used: @@ -108,47 +110,51 @@ - [ ] OTHERWISE when reusing an existing `pip`: - [ ] `pip` is set for the ilk - [ ] `pip` in the chainlog matches `gem` symbol (i.e. `PIP_USDC` for `USDC`) - - [ ] `ILK_REGISTRY`: new ilk is added to the registry - - [ ] `CHAINLOG`: + - `ILK_REGISTRY`: + - [ ] New ilk is added to the registry + - `CHAINLOG`: - [ ] `DssLitePsm` is added to the chainlog and `addresses_mainnet.sol` according to the Exec Sheet - [ ] `pocket` is added to the chainlog and `addresses_mainnet.sol` according to the Exec Sheet - [ ] `DssLitePsmMom` is added to the chainlog and `addresses_mainnet.sol` according to the Exec Sheet - [ ] `LitePsmJob` is added to the chainlog and `addresses_mainnet.sol` according to the Exec Sheet - [ ] IF a new `pip` is being added, it is added to the chainlog and `addresses_mainnet.sol` as `PIP_{TOKEN_SYMBOL}` (i.e. `PIP_USDC`) - Test coverage: - - [ ] `DssLitePsm`: + - `DssLitePsm`: - [ ] `vow` is set to `MCD_VOW` - [ ] `buf` matches the Exec Sheet - [ ] `MCD_PAUSE_PROXY` is whitelisted to execute swaps with no fees (i.e. `KissLike({LITE_PSM}).bud(MCD_PAUSE_PROXY) == 1`) - [ ] `DssLitePsmMom` is authed (i.e. `WardsLike({LITE_PSM}).wards(MOM) == 1`) - - [ ] E2E tests: + - E2E tests: - [ ] `buyGem` works as expected - [ ] `sellGem` works as expected - [ ] `buyGemNoFee` works as expected - [ ] `sellGemNoFee` works as expected - - [ ] `DssLitePsmMom`: - - [ ] E2E tests: + - `DssLitePsmMom`: + - E2E tests: - [ ] `halt` prevents new swaps in `{LITE_PSM}` - - [ ] `LitePsmJob`: + - `LitePsmJob`: - [ ] Job is added to `CRON_SEQUENCER` (i.e.: `SequencerLike(CRON_SEQUENCER).hasJob(LITE_PSM_JOB) == true`) - [ ] `sequencer` matches `CRON_SEQUENCER` address from the chainlog - [ ] `litePsm` matches `{LITE_PSM}` address - [ ] `rushThreshold` matches the Exec Sheet (it might be named as "fill threshold") - [ ] `gushThreshold` matches the Exec Sheet (it might be named as "trim threshold") - [ ] `cutThreshold` matches the Exec Sheet (it might be named as "chug threshold") - - [ ] E2E tests: - - [ ] `work` has the desired effect: + - E2E tests: + - `work` has the desired effect: - [ ] IF `rush() > _rushThreshold`, `fill` is called - [ ] OTHERWISE IF `cut() > _cutThreshold`, `chug` is called - [ ] OTHERWISE IF `gush() > _gushThreshold`, `trim` is called - [ ] OTHERWISE it reverts - - [ ] `MCD_VAT`: `urns[ilk][{LITE_PSM}].ink` is set to the max value that will not cause an overflow (`int256(type(uint256).max / RAY)`) - - [ ] `MCD_JUG`: Stability fee (`duty`) is set to 0% (`1 * RAY`) for the ilk (:information_source: covered in `config.sol`) - - [ ] `MCD_SPOT`: + - `MCD_VAT`: + - [ ] `urns[ilk][{LITE_PSM}].ink` is set to the max value that will not cause an overflow (`int256(type(uint256).max / RAY)`) + - `MCD_JUG`: + - [ ] Stability fee (`duty`) is set to 0% (`1 * RAY`) for the ilk (:information_source: covered in `config.sol`) + - `MCD_SPOT`: - [ ] `spotter(DST_ILK).mat` is set to 100% (`1 * RAY`) (:information_source: covered in `config.sol`) - [ ] `spotter(DST_ILK).pip` is set correctly - - [ ] `CHAINLOG`: version is bumped: `{x}.{y}.{z+1}` (:information_source: covered in `config.sol`) - - [ ] `ILK_REGISTRY`: + - `CHAINLOG`: + - [ ] Version is bumped: `{x}.{y}.{z+1}` (:information_source: covered in `config.sol`) + - `ILK_REGISTRY`: - [ ] New ilk is added to the registry - [ ] `name` matches `gem` name - [ ] `symbol` matches `gem` symbol diff --git a/spell/spell-reviewer-mainnet-checklist.md b/spell/spell-reviewer-mainnet-checklist.md index c472830..4dee663 100644 --- a/spell/spell-reviewer-mainnet-checklist.md +++ b/spell/spell-reviewer-mainnet-checklist.md @@ -137,9 +137,9 @@ * [`DssExecLib.decreaseGlobalDebtCeiling(amount)`](https://github.com/makerdao/dss-exec-lib/blob/v0.0.9/src/DssExecLib.sol#L445C14-L445C39) * IF additional dependencies (i.e. `./src/dependencies/` directory) are present: * [ ] IF the dependencies contracts/libraries have been audited - * [ ] FOREACH contract/library ensure its content matches (i.e. diff check) the latest audited version + * [ ] Each contract/library exactly matches (i.e. diff check) the source code of the latest audited version * [ ] OTHERWISE obtain the permalink to the relevant repository from a trusted party (i.e. Gov Facilitators) - * [ ] FOREACH contract/library ensure its content matches (i.e. diff check) the one from the permalink + * [ ] Each contract/library exactly matches (i.e. diff check) the source code from the permalink * IF onboarding is present * [ ] Insert and follow the relevant checklists below: * [Collateral Onboarding](./collateral-onboarding-checklist.md) @@ -299,7 +299,7 @@ * Minor -> Core Module (DSS) Update (e.g. Flapper) (0.++.0) * Patch -> Collateral addition or addition/modification (0.0.++) * [ ] New addresses are added to the `addresses_mainnet.sol` - * [ ] Changes are tested via `testNewOrUpdatedChainlogValues` + * [ ] Changes are tested via `testChainlogIntegrity` and `testChainlogValues` * [ ] Ensure every spell variable is declared as `public`/`internal` * [ ] Ensure `immutable` visibility is only used when fetching addresses from the `ChainLog` via `DssExecLib.getChangelogAddress(key)` and `constant` is used instead for static addresses * [ ] Fetch addresses as type `address` and wrap with `Like` suffix interfaces inline (when making calls), UNLESS archive patterns permit otherwise (Such as `MKR`)