Skip to content

Commit

Permalink
Merge branch 'main' of github.com:open-dollar/od-governance-manager i…
Browse files Browse the repository at this point in the history
…nto ChainlinkRelayerWithL2Validity
  • Loading branch information
pi0neerpat committed Jul 6, 2024
2 parents 745446a + 7c5c214 commit 4290192
Show file tree
Hide file tree
Showing 11 changed files with 232 additions and 134 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ Template: [`new-AddCollateral.json`](gov-input/anvil/new-AddCollateral.json)
- delayedOracle: Usually a DelayedOracle that enforces delays to fresh price feeds.
- safetyCRatio: RAY, CRatio used to compute the 'safePrice' - the price used when generating debt in SAFEEngine.
- liquidationCRatio: RAY, CRatio used to compute the 'liquidationPrice' the price used when liquidating SAFEs.
- CollateralAuctionHouseParams: - maximumDiscount: WAD, Maximum discount at which collateral is being sold - minimumBid: WAD, Minimum acceptable bid - minimumDiscount: WAD, Minimum discount at which collateral is being sold - perSecondDiscountUpdateRate: RAY, Rate at which the discount will be updated in an auction.
- CollateralAuctionHouseParams: - maxDiscount: WAD, Maximum discount at which collateral is being sold - minimumBid: WAD, Minimum acceptable bid - minDiscount: WAD, Minimum discount at which collateral is being sold - perSecondDiscountUpdateRate: RAY, Rate at which the discount will be updated in an auction.
This script proposes adding a new collateral to the system (deploys new contracts via the collateral join, collateral auction house factories and it adds the correct authorizations to the needed contracts).

### Modify Parameters
Expand Down
39 changes: 38 additions & 1 deletion gov-input/anvil/new-AddCollateral.json
Original file line number Diff line number Diff line change
@@ -1 +1,38 @@
{"chainid":"31337","description":"add NEWADDed as a collateral type","network":"anvil","newCollateralAddress":"0xa513E6E4b8f2a923D98304ec87F64353C4D5C853","newCollateralType":"NEWADD","proposalType":"AddCollateral","ProtocolToken_Address":"0xc6e7DF5E7b4f2A278906862b61205850344D4e7d","ODGovernor_Address":"0xa85233C63b9Ee964Add6F2cffe00Fd84eb32338f","SAFEEngine_Address":"0x67d269191c92Caf3cD7723F116c85e6E9bf55933","OracleRelayer_Address":"0xE6E340D132b5f46d1e472DebcD681B2aBc16e57E","LiquidationEngine_Address":"0xa82fF9aFd8f496c3d6ac40E2a0F282E47488CFc9","TaxCollector_Address":"0x95401dc811bb5740090279Ba06cfA8fcF6113778","GlobalSettlement_Address":"0x5f3f1dBD7B74C6B46e8c44f98792A1dAf8d69154","SAFEEngineCollateralParams":{"collateralDebtCeiling":"500000000000000000000000000000000000000000000000","collateralDebtFloor":"100000000000000000000000000000000000000000000000"},"TaxCollectorCollateralParams":{"stabilityFee":"1000000000000000000000000000"},"LiquidationEngineCollateralParams":{"liquidationPenalty":"1000000000000000000","liquidationQuantity":"1000000000000000000000000000000000000000000000","newCAHChild":"0xf9b42E09Fd787d6864D6b2Cd8E1350fc93E6683D"},"OracleRelayerCollateralParams":{"delayedOracle":"0xa783CDc72e34a174CCa57a6d9a74904d0Bec05A9","safetyCRatio":"1000000000000000000000000000","liquidationCRatio":"1000000000000000000000000000"},"CollateralAuctionHouseParams":{"maximumDiscount":"1","minimumBid":"2","minimumDiscount":"3","perSecondDiscountUpdateRate":"999998607628240538157433861"}}
{
"chainid": "31337",
"description": "add NEWADDed as a collateral type",
"network": "anvil",
"newCollateralAddress": "0xa513E6E4b8f2a923D98304ec87F64353C4D5C853",
"newCollateralType": "NEWADD",
"proposalType": "AddCollateral",
"ProtocolToken_Address": "0xc6e7DF5E7b4f2A278906862b61205850344D4e7d",
"ODGovernor_Address": "0xa85233C63b9Ee964Add6F2cffe00Fd84eb32338f",
"SAFEEngine_Address": "0x67d269191c92Caf3cD7723F116c85e6E9bf55933",
"OracleRelayer_Address": "0xE6E340D132b5f46d1e472DebcD681B2aBc16e57E",
"LiquidationEngine_Address": "0xa82fF9aFd8f496c3d6ac40E2a0F282E47488CFc9",
"TaxCollector_Address": "0x95401dc811bb5740090279Ba06cfA8fcF6113778",
"GlobalSettlement_Address": "0x5f3f1dBD7B74C6B46e8c44f98792A1dAf8d69154",
"SAFEEngineCollateralParams": {
"collateralDebtCeiling": "500000000000000000000000000000000000000000000000",
"collateralDebtFloor": "100000000000000000000000000000000000000000000000"
},
"TaxCollectorCollateralParams": {
"stabilityFee": "1000000000000000000000000000"
},
"LiquidationEngineCollateralParams": {
"liquidationPenalty": "1000000000000000000",
"liquidationQuantity": "1000000000000000000000000000000000000000000000",
"newCAHChild": "0xf9b42E09Fd787d6864D6b2Cd8E1350fc93E6683D"
},
"OracleRelayerCollateralParams": {
"delayedOracle": "0xa783CDc72e34a174CCa57a6d9a74904d0Bec05A9",
"safetyCRatio": "1000000000000000000000000000",
"liquidationCRatio": "1000000000000000000000000000"
},
"CollateralAuctionHouseParams": {
"maxDiscount": "1",
"minimumBid": "2",
"minDiscount": "3",
"perSecondDiscountUpdateRate": "999998607628240538157433861"
}
}
38 changes: 38 additions & 0 deletions gov-input/mainnet/AddCollateralWETH.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"chainid": "42161",
"description": "Add WETH collateral",
"network": "mainnet",
"newCollateralAddress": "0x82aF49447D8a07e3bd95BD0d56f35241523fBab1",
"newCollateralType": "WETH",
"proposalType": "AddCollateral",
"ProtocolToken_Address": "",
"ODGovernor_Address": "",
"SAFEEngine_Address": "",
"OracleRelayer_Address": "",
"LiquidationEngine_Address": "",
"TaxCollector_Address": "",
"GlobalSettlement_Address": "",
"SAFEEngineCollateralParams": {
"collateralDebtCeiling": "10000000000000000000000000000000000000000000000000000",
"collateralDebtFloor": "200000000000000000000000000000000000000000000000"
},
"TaxCollectorCollateralParams": {
"stabilityFee": "1000000000472114805215157978"
},
"LiquidationEngineCollateralParams": {
"newCAHChild": "0x293b702362918e990Dd5f48a80fB139FeAd64263",
"liquidationPenalty": "1050000000000000000",
"liquidationQuantity": "50000000000000000000000000000000000000000000000000"
},
"OracleRelayerCollateralParams": {
"delayedOracle": "0x562CCE2F4dc383862dC6A926AF10DeFf5fCd172F",
"safetyCRatio": "1200000000000000000000000000",
"liquidationCRatio": "1150000000000000000000000000"
},
"CollateralAuctionHouseParams": {
"maxDiscount": "900000000000000000",
"minimumBid": "100000000000000000000",
"minDiscount": "1000000000000000000",
"perSecondDiscountUpdateRate": "999985752120000000000000000"
}
}
4 changes: 2 additions & 2 deletions gov-input/mainnet/new-AddCollateral.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@
"liquidationCRatio": "1000000000000000000000000000"
},
"CollateralAuctionHouseParams": {
"maximumDiscount": "1",
"maxDiscount": "1",
"minimumBid": "2",
"minimumDiscount": "3",
"minDiscount": "3",
"perSecondDiscountUpdateRate": "999998607628240538157433861"
}
}
74 changes: 37 additions & 37 deletions gov-input/mainnet/new-AddGRT.json
Original file line number Diff line number Diff line change
@@ -1,38 +1,38 @@
{
"chainid": "42161",
"description": "add GRT as a collateral type",
"network": "mainnet",
"newCollateralAddress": "0x9623063377ad1b27544c965ccd7342f7ea7e88c7",
"newCollateralType": "GRT",
"proposalType": "AddCollateral",
"ProtocolToken_Address": "",
"ODGovernor_Address": "",
"SAFEEngine_Address": "",
"OracleRelayer_Address": "",
"LiquidationEngine_Address": "",
"TaxCollector_Address": "",
"GlobalSettlement_Address": "",
"SAFEEngineCollateralParams": {
"collateralDebtCeiling": "TBD",
"collateralDebtFloor": "TBD"
},
"TaxCollectorCollateralParams": {
"stabilityFee": "TBD"
},
"LiquidationEngineCollateralParams": {
"newCAHChild": "",
"liquidationPenalty": "TBD",
"liquidationQuantity": "TBD"
},
"OracleRelayerCollateralParams": {
"delayedOracle": "TBD",
"safetyCRatio": "TBD",
"liquidationCRatio": "TBD"
},
"CollateralAuctionHouseParams": {
"maximumDiscount": "TBD",
"minimumBid": "TBD",
"minimumDiscount": "TBD",
"perSecondDiscountUpdateRate": "999998607628240538157433861"
}
}
"chainid": "42161",
"description": "add GRT as a collateral type",
"network": "mainnet",
"newCollateralAddress": "0x9623063377ad1b27544c965ccd7342f7ea7e88c7",
"newCollateralType": "GRT",
"proposalType": "AddCollateral",
"ProtocolToken_Address": "",
"ODGovernor_Address": "",
"SAFEEngine_Address": "",
"OracleRelayer_Address": "",
"LiquidationEngine_Address": "",
"TaxCollector_Address": "",
"GlobalSettlement_Address": "",
"SAFEEngineCollateralParams": {
"collateralDebtCeiling": "TBD",
"collateralDebtFloor": "TBD"
},
"TaxCollectorCollateralParams": {
"stabilityFee": "TBD"
},
"LiquidationEngineCollateralParams": {
"newCAHChild": "",
"liquidationPenalty": "TBD",
"liquidationQuantity": "TBD"
},
"OracleRelayerCollateralParams": {
"delayedOracle": "TBD",
"safetyCRatio": "TBD",
"liquidationCRatio": "TBD"
},
"CollateralAuctionHouseParams": {
"maxDiscount": "TBD",
"minimumBid": "TBD",
"minDiscount": "TBD",
"perSecondDiscountUpdateRate": "999998607628240538157433861"
}
}
74 changes: 37 additions & 37 deletions gov-input/mainnet/new-AddLINK.json
Original file line number Diff line number Diff line change
@@ -1,38 +1,38 @@
{
"chainid": "42161",
"description": "add LINK as a collateral type",
"network": "mainnet",
"newCollateralAddress": "0xf97f4df75117a78c1A5a0DBb814Af92458539FB4",
"newCollateralType": "LINK",
"proposalType": "AddCollateral",
"ProtocolToken_Address": "",
"ODGovernor_Address": "",
"SAFEEngine_Address": "",
"OracleRelayer_Address": "",
"LiquidationEngine_Address": "",
"TaxCollector_Address": "",
"GlobalSettlement_Address": "",
"SAFEEngineCollateralParams": {
"collateralDebtCeiling": "TBD",
"collateralDebtFloor": "TBD"
},
"TaxCollectorCollateralParams": {
"stabilityFee": "TBD"
},
"LiquidationEngineCollateralParams": {
"newCAHChild": "",
"liquidationPenalty": "TBD",
"liquidationQuantity": "TBD"
},
"OracleRelayerCollateralParams": {
"delayedOracle": "TBD",
"safetyCRatio": "TBD",
"liquidationCRatio": "TBD"
},
"CollateralAuctionHouseParams": {
"maximumDiscount": "TBD",
"minimumBid": "TBD",
"minimumDiscount": "TBD",
"perSecondDiscountUpdateRate": "999998607628240538157433861"
}
}
"chainid": "42161",
"description": "add LINK as a collateral type",
"network": "mainnet",
"newCollateralAddress": "0xf97f4df75117a78c1A5a0DBb814Af92458539FB4",
"newCollateralType": "LINK",
"proposalType": "AddCollateral",
"ProtocolToken_Address": "",
"ODGovernor_Address": "",
"SAFEEngine_Address": "",
"OracleRelayer_Address": "",
"LiquidationEngine_Address": "",
"TaxCollector_Address": "",
"GlobalSettlement_Address": "",
"SAFEEngineCollateralParams": {
"collateralDebtCeiling": "TBD",
"collateralDebtFloor": "TBD"
},
"TaxCollectorCollateralParams": {
"stabilityFee": "TBD"
},
"LiquidationEngineCollateralParams": {
"newCAHChild": "",
"liquidationPenalty": "TBD",
"liquidationQuantity": "TBD"
},
"OracleRelayerCollateralParams": {
"delayedOracle": "TBD",
"safetyCRatio": "TBD",
"liquidationCRatio": "TBD"
},
"CollateralAuctionHouseParams": {
"maxDiscount": "TBD",
"minimumBid": "TBD",
"minDiscount": "TBD",
"perSecondDiscountUpdateRate": "999998607628240538157433861"
}
}
38 changes: 0 additions & 38 deletions gov-input/mainnet/new-AddWETH.json

This file was deleted.

6 changes: 3 additions & 3 deletions gov-input/sepolia/new-AddCollateral.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@
"liquidationCRatio": "7"
},
"CollateralAuctionHouseParams": {
"maximumDiscount": "8",
"maxDiscount": "8",
"minimumBid": "9",
"minimumDiscount": "10",
"minDiscount": "10",
"perSecondDiscountUpdateRate": "11"
}
}
}
70 changes: 70 additions & 0 deletions gov-output/mainnet/add-collateral-34858172.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
{
"CollateralAuctionHouseParams": {
"maxDiscount": "900000000000000000",
"minimumBid": "100000000000000000000",
"minDiscount": "1000000000000000000",
"perSecondDiscountUpdateRate": "999985752120000000000000000"
},
"GlobalSettlement_Address": "0x1c6B7ab018be82ed6b5c63aE82D9f07bb7B231A2",
"LiquidationEngineCollateralParams": {
"newCAHChild": "0x293b702362918e990Dd5f48a80fB139FeAd64263",
"liquidationPenalty": "1050000000000000000",
"liquidationQuantity": "50000000000000000000000000000000000000000000000000"
},
"LiquidationEngine_Address": "0x17e546dDCE2EA8A74Bd667269457A2e80b309965",
"ODGovernor_Address": "0xf704735CE81165261156b41D33AB18a08803B86F",
"OracleRelayerCollateralParams": {
"delayedOracle": "0x562CCE2F4dc383862dC6A926AF10DeFf5fCd172F",
"safetyCRatio": "1200000000000000000000000000",
"liquidationCRatio": "1150000000000000000000000000"
},
"OracleRelayer_Address": "0x7404fc1F3796748FAE17011b57Fad9713185c1d6",
"ProtocolToken_Address": "0x000D636bD52BFc1B3a699165Ef5aa340BEA8939c",
"SAFEEngineCollateralParams": {
"collateralDebtCeiling": "10000000000000000000000000000000000000000000000000000",
"collateralDebtFloor": "200000000000000000000000000000000000000000000000"
},
"SAFEEngine_Address": "0xEff45E8e2353893BD0558bD5892A42786E9142F1",
"TaxCollectorCollateralParams": {
"stabilityFee": "1000000000472114805215157978"
},
"TaxCollector_Address": "0xc93F938A95488a03b976A15B20fAcFD52D087fB2",
"calldatas": [
"0x26e16665574554480000000000000000000000000000000000000000000000000000000000000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab1",
"0x34463c605745544800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000056bc75e2d631000000000000000000000000000000000000000000000000000000de0b6b3a76400000000000000000000000000000000000000000000000000000c7d713b49da00000000000000000000000000000000000000000000033b2b383ec254bdcf6c0000",
"0x34463c60574554480000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000001aba4714957d300d0e549208b31adb1000000000000000000000000000000000000023084f676940b7915149bd08b30d000000000000",
"0x34463c605745544800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000033b2e3ca65dca26e20d5eda",
"0x34463c60574554480000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000060000000000000000000000000293b702362918e990dd5f48a80fb139fead642630000000000000000000000000000000000000000000000000e92596fd6290000000000000000000000000022361d8afcc93343e962029a7edab2000000000000",
"0x34463c60574554480000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000060000000000000000000000000562cce2f4dc383862dc6a926af10deff5fcd172f000000000000000000000000000000000000000003e09de2596099e2b0000000000000000000000000000000000000000000000003b741f8eafc93793e000000",
"0x35b2815300000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000020000000000000000000000000293b702362918e990dd5f48a80fb139fead64263",
"0xd94d420800000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000020000000000000000000000000293b702362918e990dd5f48a80fb139fead64263"
],
"chainid": "42161",
"description": "Add WETH collateral",
"descriptionHash": "0xfd136854ab5ad7612b20257dbb15bbf69f738244d3f9eb544096a2bf7c8f04ef",
"network": "mainnet",
"newCollateralAddress": "0x82aF49447D8a07e3bd95BD0d56f35241523fBab1",
"newCollateralType": "WETH",
"proposalId": 34858172628765133262997362556758347679155114160723424965616922864986482020293,
"proposalType": "AddCollateral",
"targets": [
"0xa83c0f1e9eD8E383919Dde0fC90744ae370EB7B3",
"0x5dc1E86361faC018f24Ae0D1E5eB01D70AB32A82",
"0xEff45E8e2353893BD0558bD5892A42786E9142F1",
"0xc93F938A95488a03b976A15B20fAcFD52D087fB2",
"0x17e546dDCE2EA8A74Bd667269457A2e80b309965",
"0x7404fc1F3796748FAE17011b57Fad9713185c1d6",
"0xEff45E8e2353893BD0558bD5892A42786E9142F1",
"0xEff45E8e2353893BD0558bD5892A42786E9142F1"
],
"values": [
0,
0,
0,
0,
0,
0,
0,
0
]
}
Loading

0 comments on commit 4290192

Please sign in to comment.