diff --git a/.assets/380953098cfaf9c52baabfd063712d8e6bcef690.svg b/.assets/380953098cfaf9c52baabfd063712d8e6bcef690.svg new file mode 100644 index 000000000..8cd0062ea --- /dev/null +++ b/.assets/380953098cfaf9c52baabfd063712d8e6bcef690.svg @@ -0,0 +1 @@ + Borrow APR, variableBorrow APR, stableUtilization Rate0%25%50%75%100%0%50%100%Optimal 80%Optimal 80% \ No newline at end of file diff --git a/.assets/541043868751fc5ea1344f681b00906bdf734fdf.svg b/.assets/541043868751fc5ea1344f681b00906bdf734fdf.svg new file mode 100644 index 000000000..58300478c --- /dev/null +++ b/.assets/541043868751fc5ea1344f681b00906bdf734fdf.svg @@ -0,0 +1 @@ + Borrow APR, variableBorrow APR, stableUtilization Rate0%25%50%75%100%0%50%100%Optimal 90%Optimal 90% \ No newline at end of file diff --git a/.assets/64a0110786c519e361963abb7399874664375a85.svg b/.assets/64a0110786c519e361963abb7399874664375a85.svg new file mode 100644 index 000000000..1b4f85f56 --- /dev/null +++ b/.assets/64a0110786c519e361963abb7399874664375a85.svg @@ -0,0 +1 @@ + Borrow APR, variableBorrow APR, stableUtilization Rate0%25%50%75%100%0%50%100%Optimal 90%Optimal 90% \ No newline at end of file diff --git a/.assets/b5cb0fd07fde8594230045982589445fc02ace52.svg b/.assets/b5cb0fd07fde8594230045982589445fc02ace52.svg new file mode 100644 index 000000000..59dc7a873 --- /dev/null +++ b/.assets/b5cb0fd07fde8594230045982589445fc02ace52.svg @@ -0,0 +1 @@ + Borrow APR, variableBorrow APR, stableUtilization Rate0%25%50%75%100%0%200%Optimal 45%Optimal 45% \ No newline at end of file diff --git a/.env.example b/.env.example index 003aef0cf..f9d94d6e9 100644 --- a/.env.example +++ b/.env.example @@ -16,7 +16,7 @@ RPC_HARMONY=https://api.harmony.one RPC_METIS=https://andromeda.metis.io/?owner=1088 RPC_BASE=https://mainnet.base.org RPC_ZKEVM=https://zkevm-rpc.com -RPC_GNOSIS=https://rpc.gnosischain.com +RPC_GNOSIS=https://rpc.ankr.com/gnosis RPC_BNB=https://binance.llamarpc.com # Etherscan api keys for verification & download utils diff --git a/diffs/AaveV3Gnosis_AaveV3GnosisActivation_20231026_before_AaveV3Gnosis_AaveV3GnosisActivation_20231026_after.md b/diffs/AaveV3Gnosis_AaveV3GnosisActivation_20231026_before_AaveV3Gnosis_AaveV3GnosisActivation_20231026_after.md new file mode 100644 index 000000000..c88a71b88 --- /dev/null +++ b/diffs/AaveV3Gnosis_AaveV3GnosisActivation_20231026_before_AaveV3Gnosis_AaveV3GnosisActivation_20231026_after.md @@ -0,0 +1,769 @@ +## Reserve changes + +### Reserve added + +#### WETH ([0x6A023CCd1ff6F2045C3309768eAd9E68F978f6e1](https://blockscout.com/xdai/mainnet/address/0x6A023CCd1ff6F2045C3309768eAd9E68F978f6e1)) + +| description | value | +| --- | --- | +| decimals | 18 | +| isActive | true | +| isFrozen | false | +| supplyCap | 4,000 WETH | +| borrowCap | 3,500 WETH | +| debtCeiling | 0 $ | +| isSiloed | false | +| isFlashloanable | true | +| eModeCategory | 1 | +| oracle | [0xa767f745331D267c7751297D982b050c93985627](https://blockscout.com/xdai/mainnet/address/0xa767f745331D267c7751297D982b050c93985627) | +| oracleDecimals | 8 | +| oracleDescription | ETH / USD | +| oracleLatestAnswer | 1799.74305 | +| usageAsCollateralEnabled | true | +| ltv | 75 % | +| liquidationThreshold | 78 % | +| liquidationBonus | 6 % | +| liquidationProtocolFee | 10 % | +| reserveFactor | 15 % | +| aToken | [0xa818F1B57c201E092C4A2017A91815034326Efd1](https://blockscout.com/xdai/mainnet/address/0xa818F1B57c201E092C4A2017A91815034326Efd1) | +| aTokenImpl | [0x589750BA8aF186cE5B55391B0b7148cAD43a1619](https://blockscout.com/xdai/mainnet/address/0x589750BA8aF186cE5B55391B0b7148cAD43a1619) | +| variableDebtToken | [0x0c0fce05F2314540EcB095bF4D069e5E0ED90fF8](https://blockscout.com/xdai/mainnet/address/0x0c0fce05F2314540EcB095bF4D069e5E0ED90fF8) | +| variableDebtTokenImpl | [0xBeC519531F0E78BcDdB295242fA4EC5251B38574](https://blockscout.com/xdai/mainnet/address/0xBeC519531F0E78BcDdB295242fA4EC5251B38574) | +| stableDebtToken | [0x436D82d905b014926a2375C576500B6fea0D2496](https://blockscout.com/xdai/mainnet/address/0x436D82d905b014926a2375C576500B6fea0D2496) | +| stableDebtTokenImpl | [0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af](https://blockscout.com/xdai/mainnet/address/0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af) | +| borrowingEnabled | true | +| stableBorrowRateEnabled | false | +| isBorrowableInIsolation | false | +| interestRateStrategy | [0xD84d86083010FB683f1e8fA3809ee8DC90A4C4DB](https://blockscout.com/xdai/mainnet/address/0xD84d86083010FB683f1e8fA3809ee8DC90A4C4DB) | +| aTokenName | Aave Gnosis WETH | +| aTokenSymbol | aGnoWETH | +| isPaused | false | +| stableDebtTokenName | Aave Gnosis Stable Debt WETH | +| stableDebtTokenSymbol | stableDebtGnoWETH | +| variableDebtTokenName | Aave Gnosis Variable Debt WETH | +| variableDebtTokenSymbol | variableDebtGnoWETH | +| optimalUsageRatio | 80 % | +| maxExcessUsageRatio | 20 % | +| baseVariableBorrowRate | 0 % | +| variableRateSlope1 | 3.3 % | +| variableRateSlope2 | 80 % | +| baseStableBorrowRate | 5.3 % | +| stableRateSlope1 | 4 % | +| stableRateSlope2 | 80 % | +| optimalStableToTotalDebtRatio | 20 % | +| maxExcessStableToTotalDebtRatio | 80 % | +| interestRate | ![ir](/.assets/380953098cfaf9c52baabfd063712d8e6bcef690.svg) | +| eMode.label | ETH correlated | +| eMode.ltv | 90 % | +| eMode.liquidationThreshold | 93 % | +| eMode.liquidationBonus | 1 % | +| eMode.priceSource | 0x0000000000000000000000000000000000000000 | + + +#### wstETH ([0x6C76971f98945AE98dD7d4DFcA8711ebea946eA6](https://blockscout.com/xdai/mainnet/address/0x6C76971f98945AE98dD7d4DFcA8711ebea946eA6)) + +| description | value | +| --- | --- | +| decimals | 18 | +| isActive | true | +| isFrozen | false | +| supplyCap | 4,000 wstETH | +| borrowCap | 400 wstETH | +| debtCeiling | 0 $ | +| isSiloed | false | +| isFlashloanable | true | +| eModeCategory | 1 | +| oracle | [0xcb0670258e5961CCA85D8F71D29C1167Ef20De99](https://blockscout.com/xdai/mainnet/address/0xcb0670258e5961CCA85D8F71D29C1167Ef20De99) | +| oracleDecimals | 8 | +| oracleDescription | wstETH/ETH/USD | +| oracleLatestAnswer | 2060.26942495 | +| usageAsCollateralEnabled | true | +| ltv | 75 % | +| liquidationThreshold | 78 % | +| liquidationBonus | 6 % | +| liquidationProtocolFee | 10 % | +| reserveFactor | 15 % | +| aToken | [0x23e4E76D01B2002BE436CE8d6044b0aA2f68B68a](https://blockscout.com/xdai/mainnet/address/0x23e4E76D01B2002BE436CE8d6044b0aA2f68B68a) | +| aTokenImpl | [0x589750BA8aF186cE5B55391B0b7148cAD43a1619](https://blockscout.com/xdai/mainnet/address/0x589750BA8aF186cE5B55391B0b7148cAD43a1619) | +| variableDebtToken | [0x9D881f67F20B49243c98f53d2B9E91E39d02Ae09](https://blockscout.com/xdai/mainnet/address/0x9D881f67F20B49243c98f53d2B9E91E39d02Ae09) | +| variableDebtTokenImpl | [0xBeC519531F0E78BcDdB295242fA4EC5251B38574](https://blockscout.com/xdai/mainnet/address/0xBeC519531F0E78BcDdB295242fA4EC5251B38574) | +| stableDebtToken | [0x5CBc43c339F5202D2dcB59583D33cA8498b75031](https://blockscout.com/xdai/mainnet/address/0x5CBc43c339F5202D2dcB59583D33cA8498b75031) | +| stableDebtTokenImpl | [0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af](https://blockscout.com/xdai/mainnet/address/0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af) | +| borrowingEnabled | true | +| stableBorrowRateEnabled | false | +| isBorrowableInIsolation | false | +| interestRateStrategy | [0x9E57695Dab0DCdb42BC220ff1E9eb2e22a31209b](https://blockscout.com/xdai/mainnet/address/0x9E57695Dab0DCdb42BC220ff1E9eb2e22a31209b) | +| aTokenName | Aave Gnosis wstETH | +| aTokenSymbol | aGnowstETH | +| isPaused | false | +| stableDebtTokenName | Aave Gnosis Stable Debt wstETH | +| stableDebtTokenSymbol | stableDebtGnowstETH | +| variableDebtTokenName | Aave Gnosis Variable Debt wstETH | +| variableDebtTokenSymbol | variableDebtGnowstETH | +| optimalUsageRatio | 45 % | +| maxExcessUsageRatio | 55 % | +| baseVariableBorrowRate | 0 % | +| variableRateSlope1 | 7 % | +| variableRateSlope2 | 300 % | +| baseStableBorrowRate | 9 % | +| stableRateSlope1 | 7 % | +| stableRateSlope2 | 300 % | +| optimalStableToTotalDebtRatio | 20 % | +| maxExcessStableToTotalDebtRatio | 80 % | +| interestRate | ![ir](/.assets/b5cb0fd07fde8594230045982589445fc02ace52.svg) | +| eMode.label | ETH correlated | +| eMode.ltv | 90 % | +| eMode.liquidationThreshold | 93 % | +| eMode.liquidationBonus | 1 % | +| eMode.priceSource | 0x0000000000000000000000000000000000000000 | + + +#### GNO ([0x9C58BAcC331c9aa871AFD802DB6379a98e80CEdb](https://blockscout.com/xdai/mainnet/address/0x9C58BAcC331c9aa871AFD802DB6379a98e80CEdb)) + +| description | value | +| --- | --- | +| decimals | 18 | +| isActive | true | +| isFrozen | false | +| supplyCap | 30,000 GNO | +| borrowCap | 0 GNO | +| debtCeiling | 1,000,000 $ | +| isSiloed | false | +| isFlashloanable | true | +| eModeCategory | 0 | +| oracle | [0x22441d81416430A54336aB28765abd31a792Ad37](https://blockscout.com/xdai/mainnet/address/0x22441d81416430A54336aB28765abd31a792Ad37) | +| oracleDecimals | 8 | +| oracleDescription | GNO / USD | +| oracleLatestAnswer | 106.660434 | +| usageAsCollateralEnabled | true | +| ltv | 31 % | +| liquidationThreshold | 36 % | +| liquidationBonus | 10 % | +| liquidationProtocolFee | 10 % | +| reserveFactor | 15 % | +| aToken | [0xA1Fa064A85266E2Ca82DEe5C5CcEC84DF445760e](https://blockscout.com/xdai/mainnet/address/0xA1Fa064A85266E2Ca82DEe5C5CcEC84DF445760e) | +| aTokenImpl | [0x589750BA8aF186cE5B55391B0b7148cAD43a1619](https://blockscout.com/xdai/mainnet/address/0x589750BA8aF186cE5B55391B0b7148cAD43a1619) | +| variableDebtToken | [0xBc59E99198DbA71985A66E1713cC89FFEC53f7FC](https://blockscout.com/xdai/mainnet/address/0xBc59E99198DbA71985A66E1713cC89FFEC53f7FC) | +| variableDebtTokenImpl | [0xBeC519531F0E78BcDdB295242fA4EC5251B38574](https://blockscout.com/xdai/mainnet/address/0xBeC519531F0E78BcDdB295242fA4EC5251B38574) | +| stableDebtToken | [0x1A126F613D7705E59ADb39909b25E1223aDF05dd](https://blockscout.com/xdai/mainnet/address/0x1A126F613D7705E59ADb39909b25E1223aDF05dd) | +| stableDebtTokenImpl | [0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af](https://blockscout.com/xdai/mainnet/address/0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af) | +| borrowingEnabled | false | +| stableBorrowRateEnabled | false | +| isBorrowableInIsolation | false | +| interestRateStrategy | [0x9E57695Dab0DCdb42BC220ff1E9eb2e22a31209b](https://blockscout.com/xdai/mainnet/address/0x9E57695Dab0DCdb42BC220ff1E9eb2e22a31209b) | +| aTokenName | Aave Gnosis GNO | +| aTokenSymbol | aGnoGNO | +| isPaused | false | +| stableDebtTokenName | Aave Gnosis Stable Debt GNO | +| stableDebtTokenSymbol | stableDebtGnoGNO | +| variableDebtTokenName | Aave Gnosis Variable Debt GNO | +| variableDebtTokenSymbol | variableDebtGnoGNO | +| optimalUsageRatio | 45 % | +| maxExcessUsageRatio | 55 % | +| baseVariableBorrowRate | 0 % | +| variableRateSlope1 | 7 % | +| variableRateSlope2 | 300 % | +| baseStableBorrowRate | 9 % | +| stableRateSlope1 | 7 % | +| stableRateSlope2 | 300 % | +| optimalStableToTotalDebtRatio | 20 % | +| maxExcessStableToTotalDebtRatio | 80 % | +| interestRate | ![ir](/.assets/b5cb0fd07fde8594230045982589445fc02ace52.svg) | + + +#### USDC ([0xDDAfbb505ad214D7b80b1f830fcCc89B60fb7A83](https://blockscout.com/xdai/mainnet/address/0xDDAfbb505ad214D7b80b1f830fcCc89B60fb7A83)) + +| description | value | +| --- | --- | +| decimals | 6 | +| isActive | true | +| isFrozen | false | +| supplyCap | 1,000,000 USDC | +| borrowCap | 1,000,000 USDC | +| debtCeiling | 0 $ | +| isSiloed | false | +| isFlashloanable | true | +| eModeCategory | 0 | +| oracle | [0x26C31ac71010aF62E6B486D1132E266D6298857D](https://blockscout.com/xdai/mainnet/address/0x26C31ac71010aF62E6B486D1132E266D6298857D) | +| oracleDecimals | 8 | +| oracleDescription | USDC / USD | +| oracleLatestAnswer | 1.00005376 | +| usageAsCollateralEnabled | true | +| ltv | 77 % | +| liquidationThreshold | 80 % | +| liquidationBonus | 5 % | +| liquidationProtocolFee | 20 % | +| reserveFactor | 10 % | +| aToken | [0xc6B7AcA6DE8a6044E0e32d0c841a89244A10D284](https://blockscout.com/xdai/mainnet/address/0xc6B7AcA6DE8a6044E0e32d0c841a89244A10D284) | +| aTokenImpl | [0x589750BA8aF186cE5B55391B0b7148cAD43a1619](https://blockscout.com/xdai/mainnet/address/0x589750BA8aF186cE5B55391B0b7148cAD43a1619) | +| variableDebtToken | [0x5F6f7B0a87CA3CF3d0b431Ae03EF3305180BFf4d](https://blockscout.com/xdai/mainnet/address/0x5F6f7B0a87CA3CF3d0b431Ae03EF3305180BFf4d) | +| variableDebtTokenImpl | [0xBeC519531F0E78BcDdB295242fA4EC5251B38574](https://blockscout.com/xdai/mainnet/address/0xBeC519531F0E78BcDdB295242fA4EC5251B38574) | +| stableDebtToken | [0x8220133C3a631de3C7A5B679A2417BD61431FEcf](https://blockscout.com/xdai/mainnet/address/0x8220133C3a631de3C7A5B679A2417BD61431FEcf) | +| stableDebtTokenImpl | [0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af](https://blockscout.com/xdai/mainnet/address/0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af) | +| borrowingEnabled | true | +| stableBorrowRateEnabled | false | +| isBorrowableInIsolation | true | +| interestRateStrategy | [0x345f7fcd88207fe060AD03c2656A23A3Ab596479](https://blockscout.com/xdai/mainnet/address/0x345f7fcd88207fe060AD03c2656A23A3Ab596479) | +| aTokenName | Aave Gnosis USDC | +| aTokenSymbol | aGnoUSDC | +| isPaused | false | +| stableDebtTokenName | Aave Gnosis Stable Debt USDC | +| stableDebtTokenSymbol | stableDebtGnoUSDC | +| variableDebtTokenName | Aave Gnosis Variable Debt USDC | +| variableDebtTokenSymbol | variableDebtGnoUSDC | +| optimalUsageRatio | 90 % | +| maxExcessUsageRatio | 10 % | +| baseVariableBorrowRate | 0 % | +| variableRateSlope1 | 5 % | +| variableRateSlope2 | 75 % | +| baseStableBorrowRate | 6 % | +| stableRateSlope1 | 5 % | +| stableRateSlope2 | 75 % | +| optimalStableToTotalDebtRatio | 20 % | +| maxExcessStableToTotalDebtRatio | 80 % | +| interestRate | ![ir](/.assets/541043868751fc5ea1344f681b00906bdf734fdf.svg) | + + +#### sDAI ([0xaf204776c7245bF4147c2612BF6e5972Ee483701](https://blockscout.com/xdai/mainnet/address/0xaf204776c7245bF4147c2612BF6e5972Ee483701)) + +| description | value | +| --- | --- | +| decimals | 18 | +| isActive | true | +| isFrozen | false | +| supplyCap | 1,500,000 sDAI | +| borrowCap | 0 sDAI | +| debtCeiling | 0 $ | +| isSiloed | false | +| isFlashloanable | true | +| eModeCategory | 0 | +| oracle | [0x1D0f881Ce1a646E2f27Dec3c57Fa056cB838BCC2](https://blockscout.com/xdai/mainnet/address/0x1D0f881Ce1a646E2f27Dec3c57Fa056cB838BCC2) | +| oracleDecimals | 8 | +| oracleDescription | sDAI/DAI/USD | +| oracleLatestAnswer | 1.02071584 | +| usageAsCollateralEnabled | true | +| ltv | 77 % | +| liquidationThreshold | 80 % | +| liquidationBonus | 5 % | +| liquidationProtocolFee | 20 % | +| reserveFactor | 10 % | +| aToken | [0x7a5c3860a77a8DC1b225BD46d0fb2ac1C6D191BC](https://blockscout.com/xdai/mainnet/address/0x7a5c3860a77a8DC1b225BD46d0fb2ac1C6D191BC) | +| aTokenImpl | [0x589750BA8aF186cE5B55391B0b7148cAD43a1619](https://blockscout.com/xdai/mainnet/address/0x589750BA8aF186cE5B55391B0b7148cAD43a1619) | +| variableDebtToken | [0x8Fe06E1D8Aff42Bf6812CacF7854A2249a00bED7](https://blockscout.com/xdai/mainnet/address/0x8Fe06E1D8Aff42Bf6812CacF7854A2249a00bED7) | +| variableDebtTokenImpl | [0xBeC519531F0E78BcDdB295242fA4EC5251B38574](https://blockscout.com/xdai/mainnet/address/0xBeC519531F0E78BcDdB295242fA4EC5251B38574) | +| stableDebtToken | [0xa2E0335175Da40b081717FfD394C0E1de738cb9B](https://blockscout.com/xdai/mainnet/address/0xa2E0335175Da40b081717FfD394C0E1de738cb9B) | +| stableDebtTokenImpl | [0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af](https://blockscout.com/xdai/mainnet/address/0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af) | +| borrowingEnabled | false | +| stableBorrowRateEnabled | false | +| isBorrowableInIsolation | false | +| interestRateStrategy | [0x6c3b7e7B8b9609D57C70C3F630228F979EAbb450](https://blockscout.com/xdai/mainnet/address/0x6c3b7e7B8b9609D57C70C3F630228F979EAbb450) | +| aTokenName | Aave Gnosis sDAI | +| aTokenSymbol | aGnosDAI | +| isPaused | false | +| stableDebtTokenName | Aave Gnosis Stable Debt sDAI | +| stableDebtTokenSymbol | stableDebtGnosDAI | +| variableDebtTokenName | Aave Gnosis Variable Debt sDAI | +| variableDebtTokenSymbol | variableDebtGnosDAI | +| optimalUsageRatio | 90 % | +| maxExcessUsageRatio | 10 % | +| baseVariableBorrowRate | 0 % | +| variableRateSlope1 | 4 % | +| variableRateSlope2 | 75 % | +| baseStableBorrowRate | 5 % | +| stableRateSlope1 | 4 % | +| stableRateSlope2 | 75 % | +| optimalStableToTotalDebtRatio | 20 % | +| maxExcessStableToTotalDebtRatio | 80 % | +| interestRate | ![ir](/.assets/64a0110786c519e361963abb7399874664375a85.svg) | + + +#### EURe ([0xcB444e90D8198415266c6a2724b7900fb12FC56E](https://blockscout.com/xdai/mainnet/address/0xcB444e90D8198415266c6a2724b7900fb12FC56E)) + +| description | value | +| --- | --- | +| decimals | 18 | +| isActive | true | +| isFrozen | false | +| supplyCap | 500,000 EURe | +| borrowCap | 500,000 EURe | +| debtCeiling | 0 $ | +| isSiloed | false | +| isFlashloanable | true | +| eModeCategory | 0 | +| oracle | [0xab70BCB260073d036d1660201e9d5405F5829b7a](https://blockscout.com/xdai/mainnet/address/0xab70BCB260073d036d1660201e9d5405F5829b7a) | +| oracleDecimals | 8 | +| oracleDescription | EUR / USD | +| oracleLatestAnswer | 1.0603 | +| usageAsCollateralEnabled | false | +| ltv | 0 % | +| liquidationThreshold | 0 % | +| liquidationBonus | 0 % | +| liquidationProtocolFee | 0 % | +| reserveFactor | 15 % | +| aToken | [0xEdBC7449a9b594CA4E053D9737EC5Dc4CbCcBfb2](https://blockscout.com/xdai/mainnet/address/0xEdBC7449a9b594CA4E053D9737EC5Dc4CbCcBfb2) | +| aTokenImpl | [0x589750BA8aF186cE5B55391B0b7148cAD43a1619](https://blockscout.com/xdai/mainnet/address/0x589750BA8aF186cE5B55391B0b7148cAD43a1619) | +| variableDebtToken | [0xb96404e475f337A7E98e4a541C9b71309BB66c5A](https://blockscout.com/xdai/mainnet/address/0xb96404e475f337A7E98e4a541C9b71309BB66c5A) | +| variableDebtTokenImpl | [0xBeC519531F0E78BcDdB295242fA4EC5251B38574](https://blockscout.com/xdai/mainnet/address/0xBeC519531F0E78BcDdB295242fA4EC5251B38574) | +| stableDebtToken | [0x916E13857FeeD0d982Df148DBe8d8542519aB96e](https://blockscout.com/xdai/mainnet/address/0x916E13857FeeD0d982Df148DBe8d8542519aB96e) | +| stableDebtTokenImpl | [0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af](https://blockscout.com/xdai/mainnet/address/0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af) | +| borrowingEnabled | true | +| stableBorrowRateEnabled | false | +| isBorrowableInIsolation | false | +| interestRateStrategy | [0x6c3b7e7B8b9609D57C70C3F630228F979EAbb450](https://blockscout.com/xdai/mainnet/address/0x6c3b7e7B8b9609D57C70C3F630228F979EAbb450) | +| aTokenName | Aave Gnosis EURe | +| aTokenSymbol | aGnoEURe | +| isPaused | false | +| stableDebtTokenName | Aave Gnosis Stable Debt EURe | +| stableDebtTokenSymbol | stableDebtGnoEURe | +| variableDebtTokenName | Aave Gnosis Variable Debt EURe | +| variableDebtTokenSymbol | variableDebtGnoEURe | +| optimalUsageRatio | 90 % | +| maxExcessUsageRatio | 10 % | +| baseVariableBorrowRate | 0 % | +| variableRateSlope1 | 4 % | +| variableRateSlope2 | 75 % | +| baseStableBorrowRate | 5 % | +| stableRateSlope1 | 4 % | +| stableRateSlope2 | 75 % | +| optimalStableToTotalDebtRatio | 20 % | +| maxExcessStableToTotalDebtRatio | 80 % | +| interestRate | ![ir](/.assets/64a0110786c519e361963abb7399874664375a85.svg) | + + +#### WXDAI ([0xe91D153E0b41518A2Ce8Dd3D7944Fa863463a97d](https://blockscout.com/xdai/mainnet/address/0xe91D153E0b41518A2Ce8Dd3D7944Fa863463a97d)) + +| description | value | +| --- | --- | +| decimals | 18 | +| isActive | true | +| isFrozen | false | +| supplyCap | 1,500,000 WXDAI | +| borrowCap | 1,500,000 WXDAI | +| debtCeiling | 0 $ | +| isSiloed | false | +| isFlashloanable | true | +| eModeCategory | 0 | +| oracle | [0x678df3415fc31947dA4324eC63212874be5a82f8](https://blockscout.com/xdai/mainnet/address/0x678df3415fc31947dA4324eC63212874be5a82f8) | +| oracleDecimals | 8 | +| oracleDescription | DAI / USD | +| oracleLatestAnswer | 1.000059 | +| usageAsCollateralEnabled | true | +| ltv | 77 % | +| liquidationThreshold | 80 % | +| liquidationBonus | 5 % | +| liquidationProtocolFee | 20 % | +| reserveFactor | 10 % | +| aToken | [0xd0Dd6cEF72143E22cCED4867eb0d5F2328715533](https://blockscout.com/xdai/mainnet/address/0xd0Dd6cEF72143E22cCED4867eb0d5F2328715533) | +| aTokenImpl | [0x589750BA8aF186cE5B55391B0b7148cAD43a1619](https://blockscout.com/xdai/mainnet/address/0x589750BA8aF186cE5B55391B0b7148cAD43a1619) | +| variableDebtToken | [0x281963D7471eCdC3A2Bd4503e24e89691cfe420D](https://blockscout.com/xdai/mainnet/address/0x281963D7471eCdC3A2Bd4503e24e89691cfe420D) | +| variableDebtTokenImpl | [0xBeC519531F0E78BcDdB295242fA4EC5251B38574](https://blockscout.com/xdai/mainnet/address/0xBeC519531F0E78BcDdB295242fA4EC5251B38574) | +| stableDebtToken | [0xaC8b1cE0548C69318920C3e0b21Db296d5770D57](https://blockscout.com/xdai/mainnet/address/0xaC8b1cE0548C69318920C3e0b21Db296d5770D57) | +| stableDebtTokenImpl | [0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af](https://blockscout.com/xdai/mainnet/address/0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af) | +| borrowingEnabled | true | +| stableBorrowRateEnabled | false | +| isBorrowableInIsolation | true | +| interestRateStrategy | [0x345f7fcd88207fe060AD03c2656A23A3Ab596479](https://blockscout.com/xdai/mainnet/address/0x345f7fcd88207fe060AD03c2656A23A3Ab596479) | +| aTokenName | Aave Gnosis WXDAI | +| aTokenSymbol | aGnoWXDAI | +| isPaused | false | +| stableDebtTokenName | Aave Gnosis Stable Debt WXDAI | +| stableDebtTokenSymbol | stableDebtGnoWXDAI | +| variableDebtTokenName | Aave Gnosis Variable Debt WXDAI | +| variableDebtTokenSymbol | variableDebtGnoWXDAI | +| optimalUsageRatio | 90 % | +| maxExcessUsageRatio | 10 % | +| baseVariableBorrowRate | 0 % | +| variableRateSlope1 | 5 % | +| variableRateSlope2 | 75 % | +| baseStableBorrowRate | 6 % | +| stableRateSlope1 | 5 % | +| stableRateSlope2 | 75 % | +| optimalStableToTotalDebtRatio | 20 % | +| maxExcessStableToTotalDebtRatio | 80 % | +| interestRate | ![ir](/.assets/541043868751fc5ea1344f681b00906bdf734fdf.svg) | + + +## Raw diff + +```json +{ + "eModes": { + "1": { + "from": null, + "to": { + "eModeCategory": 1, + "label": "ETH correlated", + "liquidationBonus": 10100, + "liquidationThreshold": 9300, + "ltv": 9000, + "priceSource": "0x0000000000000000000000000000000000000000" + } + } + }, + "reserves": { + "0x6A023CCd1ff6F2045C3309768eAd9E68F978f6e1": { + "from": null, + "to": { + "aToken": "0xa818F1B57c201E092C4A2017A91815034326Efd1", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis WETH", + "aTokenSymbol": "aGnoWETH", + "borrowCap": 3500, + "borrowingEnabled": true, + "debtCeiling": 0, + "decimals": 18, + "eModeCategory": 1, + "interestRateStrategy": "0xD84d86083010FB683f1e8fA3809ee8DC90A4C4DB", + "isActive": true, + "isBorrowableInIsolation": false, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 10600, + "liquidationProtocolFee": 1000, + "liquidationThreshold": 7800, + "ltv": 7500, + "oracle": "0xa767f745331D267c7751297D982b050c93985627", + "oracleDecimals": 8, + "oracleDescription": "ETH / USD", + "oracleLatestAnswer": 179974305000, + "reserveFactor": 1500, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0x436D82d905b014926a2375C576500B6fea0D2496", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt WETH", + "stableDebtTokenSymbol": "stableDebtGnoWETH", + "supplyCap": 4000, + "symbol": "WETH", + "underlying": "0x6A023CCd1ff6F2045C3309768eAd9E68F978f6e1", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0x0c0fce05F2314540EcB095bF4D069e5E0ED90fF8", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt WETH", + "variableDebtTokenSymbol": "variableDebtGnoWETH" + } + }, + "0x6C76971f98945AE98dD7d4DFcA8711ebea946eA6": { + "from": null, + "to": { + "aToken": "0x23e4E76D01B2002BE436CE8d6044b0aA2f68B68a", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis wstETH", + "aTokenSymbol": "aGnowstETH", + "borrowCap": 400, + "borrowingEnabled": true, + "debtCeiling": 0, + "decimals": 18, + "eModeCategory": 1, + "interestRateStrategy": "0x9E57695Dab0DCdb42BC220ff1E9eb2e22a31209b", + "isActive": true, + "isBorrowableInIsolation": false, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 10600, + "liquidationProtocolFee": 1000, + "liquidationThreshold": 7800, + "ltv": 7500, + "oracle": "0xcb0670258e5961CCA85D8F71D29C1167Ef20De99", + "oracleDecimals": 8, + "oracleDescription": "wstETH/ETH/USD", + "oracleLatestAnswer": 206026942495, + "reserveFactor": 1500, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0x5CBc43c339F5202D2dcB59583D33cA8498b75031", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt wstETH", + "stableDebtTokenSymbol": "stableDebtGnowstETH", + "supplyCap": 4000, + "symbol": "wstETH", + "underlying": "0x6C76971f98945AE98dD7d4DFcA8711ebea946eA6", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0x9D881f67F20B49243c98f53d2B9E91E39d02Ae09", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt wstETH", + "variableDebtTokenSymbol": "variableDebtGnowstETH" + } + }, + "0x9C58BAcC331c9aa871AFD802DB6379a98e80CEdb": { + "from": null, + "to": { + "aToken": "0xA1Fa064A85266E2Ca82DEe5C5CcEC84DF445760e", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis GNO", + "aTokenSymbol": "aGnoGNO", + "borrowCap": 0, + "borrowingEnabled": false, + "debtCeiling": 100000000, + "decimals": 18, + "eModeCategory": 0, + "interestRateStrategy": "0x9E57695Dab0DCdb42BC220ff1E9eb2e22a31209b", + "isActive": true, + "isBorrowableInIsolation": false, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 11000, + "liquidationProtocolFee": 1000, + "liquidationThreshold": 3600, + "ltv": 3100, + "oracle": "0x22441d81416430A54336aB28765abd31a792Ad37", + "oracleDecimals": 8, + "oracleDescription": "GNO / USD", + "oracleLatestAnswer": 10666043400, + "reserveFactor": 1500, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0x1A126F613D7705E59ADb39909b25E1223aDF05dd", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt GNO", + "stableDebtTokenSymbol": "stableDebtGnoGNO", + "supplyCap": 30000, + "symbol": "GNO", + "underlying": "0x9C58BAcC331c9aa871AFD802DB6379a98e80CEdb", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0xBc59E99198DbA71985A66E1713cC89FFEC53f7FC", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt GNO", + "variableDebtTokenSymbol": "variableDebtGnoGNO" + } + }, + "0xDDAfbb505ad214D7b80b1f830fcCc89B60fb7A83": { + "from": null, + "to": { + "aToken": "0xc6B7AcA6DE8a6044E0e32d0c841a89244A10D284", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis USDC", + "aTokenSymbol": "aGnoUSDC", + "borrowCap": 1000000, + "borrowingEnabled": true, + "debtCeiling": 0, + "decimals": 6, + "eModeCategory": 0, + "interestRateStrategy": "0x345f7fcd88207fe060AD03c2656A23A3Ab596479", + "isActive": true, + "isBorrowableInIsolation": true, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 10500, + "liquidationProtocolFee": 2000, + "liquidationThreshold": 8000, + "ltv": 7700, + "oracle": "0x26C31ac71010aF62E6B486D1132E266D6298857D", + "oracleDecimals": 8, + "oracleDescription": "USDC / USD", + "oracleLatestAnswer": 100005376, + "reserveFactor": 1000, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0x8220133C3a631de3C7A5B679A2417BD61431FEcf", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt USDC", + "stableDebtTokenSymbol": "stableDebtGnoUSDC", + "supplyCap": 1000000, + "symbol": "USDC", + "underlying": "0xDDAfbb505ad214D7b80b1f830fcCc89B60fb7A83", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0x5F6f7B0a87CA3CF3d0b431Ae03EF3305180BFf4d", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt USDC", + "variableDebtTokenSymbol": "variableDebtGnoUSDC" + } + }, + "0xaf204776c7245bF4147c2612BF6e5972Ee483701": { + "from": null, + "to": { + "aToken": "0x7a5c3860a77a8DC1b225BD46d0fb2ac1C6D191BC", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis sDAI", + "aTokenSymbol": "aGnosDAI", + "borrowCap": 0, + "borrowingEnabled": false, + "debtCeiling": 0, + "decimals": 18, + "eModeCategory": 0, + "interestRateStrategy": "0x6c3b7e7B8b9609D57C70C3F630228F979EAbb450", + "isActive": true, + "isBorrowableInIsolation": false, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 10500, + "liquidationProtocolFee": 2000, + "liquidationThreshold": 8000, + "ltv": 7700, + "oracle": "0x1D0f881Ce1a646E2f27Dec3c57Fa056cB838BCC2", + "oracleDecimals": 8, + "oracleDescription": "sDAI/DAI/USD", + "oracleLatestAnswer": 102071584, + "reserveFactor": 1000, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0xa2E0335175Da40b081717FfD394C0E1de738cb9B", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt sDAI", + "stableDebtTokenSymbol": "stableDebtGnosDAI", + "supplyCap": 1500000, + "symbol": "sDAI", + "underlying": "0xaf204776c7245bF4147c2612BF6e5972Ee483701", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0x8Fe06E1D8Aff42Bf6812CacF7854A2249a00bED7", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt sDAI", + "variableDebtTokenSymbol": "variableDebtGnosDAI" + } + }, + "0xcB444e90D8198415266c6a2724b7900fb12FC56E": { + "from": null, + "to": { + "aToken": "0xEdBC7449a9b594CA4E053D9737EC5Dc4CbCcBfb2", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis EURe", + "aTokenSymbol": "aGnoEURe", + "borrowCap": 500000, + "borrowingEnabled": true, + "debtCeiling": 0, + "decimals": 18, + "eModeCategory": 0, + "interestRateStrategy": "0x6c3b7e7B8b9609D57C70C3F630228F979EAbb450", + "isActive": true, + "isBorrowableInIsolation": false, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 0, + "liquidationProtocolFee": 0, + "liquidationThreshold": 0, + "ltv": 0, + "oracle": "0xab70BCB260073d036d1660201e9d5405F5829b7a", + "oracleDecimals": 8, + "oracleDescription": "EUR / USD", + "oracleLatestAnswer": 106030000, + "reserveFactor": 1500, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0x916E13857FeeD0d982Df148DBe8d8542519aB96e", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt EURe", + "stableDebtTokenSymbol": "stableDebtGnoEURe", + "supplyCap": 500000, + "symbol": "EURe", + "underlying": "0xcB444e90D8198415266c6a2724b7900fb12FC56E", + "usageAsCollateralEnabled": false, + "variableDebtToken": "0xb96404e475f337A7E98e4a541C9b71309BB66c5A", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt EURe", + "variableDebtTokenSymbol": "variableDebtGnoEURe" + } + }, + "0xe91D153E0b41518A2Ce8Dd3D7944Fa863463a97d": { + "from": null, + "to": { + "aToken": "0xd0Dd6cEF72143E22cCED4867eb0d5F2328715533", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis WXDAI", + "aTokenSymbol": "aGnoWXDAI", + "borrowCap": 1500000, + "borrowingEnabled": true, + "debtCeiling": 0, + "decimals": 18, + "eModeCategory": 0, + "interestRateStrategy": "0x345f7fcd88207fe060AD03c2656A23A3Ab596479", + "isActive": true, + "isBorrowableInIsolation": true, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 10500, + "liquidationProtocolFee": 2000, + "liquidationThreshold": 8000, + "ltv": 7700, + "oracle": "0x678df3415fc31947dA4324eC63212874be5a82f8", + "oracleDecimals": 8, + "oracleDescription": "DAI / USD", + "oracleLatestAnswer": 100005900, + "reserveFactor": 1000, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0xaC8b1cE0548C69318920C3e0b21Db296d5770D57", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt WXDAI", + "stableDebtTokenSymbol": "stableDebtGnoWXDAI", + "supplyCap": 1500000, + "symbol": "WXDAI", + "underlying": "0xe91D153E0b41518A2Ce8Dd3D7944Fa863463a97d", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0x281963D7471eCdC3A2Bd4503e24e89691cfe420D", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt WXDAI", + "variableDebtTokenSymbol": "variableDebtGnoWXDAI" + } + } + }, + "strategies": { + "0x345f7fcd88207fe060AD03c2656A23A3Ab596479": { + "from": null, + "to": { + "baseStableBorrowRate": "60000000000000000000000000", + "baseVariableBorrowRate": 0, + "maxExcessStableToTotalDebtRatio": "800000000000000000000000000", + "maxExcessUsageRatio": "100000000000000000000000000", + "optimalStableToTotalDebtRatio": "200000000000000000000000000", + "optimalUsageRatio": "900000000000000000000000000", + "stableRateSlope1": "50000000000000000000000000", + "stableRateSlope2": "750000000000000000000000000", + "variableRateSlope1": "50000000000000000000000000", + "variableRateSlope2": "750000000000000000000000000" + } + }, + "0x6c3b7e7B8b9609D57C70C3F630228F979EAbb450": { + "from": null, + "to": { + "baseStableBorrowRate": "50000000000000000000000000", + "baseVariableBorrowRate": 0, + "maxExcessStableToTotalDebtRatio": "800000000000000000000000000", + "maxExcessUsageRatio": "100000000000000000000000000", + "optimalStableToTotalDebtRatio": "200000000000000000000000000", + "optimalUsageRatio": "900000000000000000000000000", + "stableRateSlope1": "40000000000000000000000000", + "stableRateSlope2": "750000000000000000000000000", + "variableRateSlope1": "40000000000000000000000000", + "variableRateSlope2": "750000000000000000000000000" + } + }, + "0x9E57695Dab0DCdb42BC220ff1E9eb2e22a31209b": { + "from": null, + "to": { + "baseStableBorrowRate": "90000000000000000000000000", + "baseVariableBorrowRate": 0, + "maxExcessStableToTotalDebtRatio": "800000000000000000000000000", + "maxExcessUsageRatio": "550000000000000000000000000", + "optimalStableToTotalDebtRatio": "200000000000000000000000000", + "optimalUsageRatio": "450000000000000000000000000", + "stableRateSlope1": "70000000000000000000000000", + "stableRateSlope2": "3000000000000000000000000000", + "variableRateSlope1": "70000000000000000000000000", + "variableRateSlope2": "3000000000000000000000000000" + } + }, + "0xD84d86083010FB683f1e8fA3809ee8DC90A4C4DB": { + "from": null, + "to": { + "baseStableBorrowRate": "53000000000000000000000000", + "baseVariableBorrowRate": 0, + "maxExcessStableToTotalDebtRatio": "800000000000000000000000000", + "maxExcessUsageRatio": "200000000000000000000000000", + "optimalStableToTotalDebtRatio": "200000000000000000000000000", + "optimalUsageRatio": "800000000000000000000000000", + "stableRateSlope1": "40000000000000000000000000", + "stableRateSlope2": "800000000000000000000000000", + "variableRateSlope1": "33000000000000000000000000", + "variableRateSlope2": "800000000000000000000000000" + } + } + } +} +``` \ No newline at end of file diff --git a/foundry.toml b/foundry.toml index b9c42ba97..1a2e02996 100644 --- a/foundry.toml +++ b/foundry.toml @@ -2,6 +2,7 @@ src = 'src' test = 'tests' script = 'scripts' +solc = '0.8.19' out = 'out' libs = ['lib'] remappings = [ diff --git a/generator/utils/importsResolver.ts b/generator/utils/importsResolver.ts index 0d71d8fd6..b23e8c669 100644 --- a/generator/utils/importsResolver.ts +++ b/generator/utils/importsResolver.ts @@ -52,7 +52,7 @@ function findMatch(code: string, needle: string) { } /** - * @dev Returnes the input string prefixed with imports + * @dev Returns the input string prefixed with imports * @param code * @returns */ diff --git a/lib/aave-helpers b/lib/aave-helpers index 963cc7bab..78e58dbd3 160000 --- a/lib/aave-helpers +++ b/lib/aave-helpers @@ -1 +1 @@ -Subproject commit 963cc7bab94078dadbf3668696bdd77f51dc65fe +Subproject commit 78e58dbd37f2d879313587dea0d2cd783aadade3 diff --git a/package.json b/package.json index 1a1f94f7b..0bedd9b5c 100644 --- a/package.json +++ b/package.json @@ -30,7 +30,7 @@ }, "dependencies": { "@bgd-labs/aave-address-book": "^2.8.0", - "@bgd-labs/aave-cli": "0.0.27-454eafdfe0f9813ef73c81bc25457e3efd418c50.0", + "@bgd-labs/aave-cli": "0.0.27-0a01f2a07efe0ec4c875cf479004d20350235f64.0", "@inquirer/prompts": "^3.2.0", "commander": "^11.0.0", "tsx": "^3.13.0", diff --git a/reports/AaveV3Gnosis_AaveV3GnosisActivation_20231026_after.json b/reports/AaveV3Gnosis_AaveV3GnosisActivation_20231026_after.json new file mode 100644 index 000000000..307965ebd --- /dev/null +++ b/reports/AaveV3Gnosis_AaveV3GnosisActivation_20231026_after.json @@ -0,0 +1,355 @@ +{ + "chainId": 100, + "eModes": { + "1": { + "eModeCategory": 1, + "label": "ETH correlated", + "liquidationBonus": 10100, + "liquidationThreshold": 9300, + "ltv": 9000, + "priceSource": "0x0000000000000000000000000000000000000000" + } + }, + "poolConfig": { + "oracle": "0xeb0a051be10228213BAEb449db63719d6742F7c4", + "pool": "0xb50201558B00496A145fE76f7424749556E326D8", + "poolAddressesProvider": "0x36616cf17557639614c1cdDb356b1B83fc0B2132", + "poolConfigurator": "0x7304979ec9E4EaA0273b6A037a31c4e9e5A75D16", + "poolConfiguratorImpl": "0x25Ec457d1778b0E5316e7f38f3c22baF413F1A8C", + "poolImpl": "0xB1532b76D054c9F9E61b25c4d91f69B4133E4671", + "priceOracleSentinel": "0x0000000000000000000000000000000000000000", + "protocolDataProvider": "0x501B4c19dd9C2e06E94dA7b6D5Ed4ddA013EC741" + }, + "reserves": { + "0x6A023CCd1ff6F2045C3309768eAd9E68F978f6e1": { + "aToken": "0xa818F1B57c201E092C4A2017A91815034326Efd1", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis WETH", + "aTokenSymbol": "aGnoWETH", + "borrowCap": 3500, + "borrowingEnabled": true, + "debtCeiling": 0, + "decimals": 18, + "eModeCategory": 1, + "interestRateStrategy": "0xD84d86083010FB683f1e8fA3809ee8DC90A4C4DB", + "isActive": true, + "isBorrowableInIsolation": false, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 10600, + "liquidationProtocolFee": 1000, + "liquidationThreshold": 7800, + "ltv": 7500, + "oracle": "0xa767f745331D267c7751297D982b050c93985627", + "oracleDecimals": 8, + "oracleDescription": "ETH / USD", + "oracleLatestAnswer": 179974305000, + "reserveFactor": 1500, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0x436D82d905b014926a2375C576500B6fea0D2496", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt WETH", + "stableDebtTokenSymbol": "stableDebtGnoWETH", + "supplyCap": 4000, + "symbol": "WETH", + "underlying": "0x6A023CCd1ff6F2045C3309768eAd9E68F978f6e1", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0x0c0fce05F2314540EcB095bF4D069e5E0ED90fF8", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt WETH", + "variableDebtTokenSymbol": "variableDebtGnoWETH" + }, + "0x6C76971f98945AE98dD7d4DFcA8711ebea946eA6": { + "aToken": "0x23e4E76D01B2002BE436CE8d6044b0aA2f68B68a", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis wstETH", + "aTokenSymbol": "aGnowstETH", + "borrowCap": 400, + "borrowingEnabled": true, + "debtCeiling": 0, + "decimals": 18, + "eModeCategory": 1, + "interestRateStrategy": "0x9E57695Dab0DCdb42BC220ff1E9eb2e22a31209b", + "isActive": true, + "isBorrowableInIsolation": false, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 10600, + "liquidationProtocolFee": 1000, + "liquidationThreshold": 7800, + "ltv": 7500, + "oracle": "0xcb0670258e5961CCA85D8F71D29C1167Ef20De99", + "oracleDecimals": 8, + "oracleDescription": "wstETH/ETH/USD", + "oracleLatestAnswer": 206026942495, + "reserveFactor": 1500, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0x5CBc43c339F5202D2dcB59583D33cA8498b75031", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt wstETH", + "stableDebtTokenSymbol": "stableDebtGnowstETH", + "supplyCap": 4000, + "symbol": "wstETH", + "underlying": "0x6C76971f98945AE98dD7d4DFcA8711ebea946eA6", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0x9D881f67F20B49243c98f53d2B9E91E39d02Ae09", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt wstETH", + "variableDebtTokenSymbol": "variableDebtGnowstETH" + }, + "0x9C58BAcC331c9aa871AFD802DB6379a98e80CEdb": { + "aToken": "0xA1Fa064A85266E2Ca82DEe5C5CcEC84DF445760e", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis GNO", + "aTokenSymbol": "aGnoGNO", + "borrowCap": 0, + "borrowingEnabled": false, + "debtCeiling": 100000000, + "decimals": 18, + "eModeCategory": 0, + "interestRateStrategy": "0x9E57695Dab0DCdb42BC220ff1E9eb2e22a31209b", + "isActive": true, + "isBorrowableInIsolation": false, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 11000, + "liquidationProtocolFee": 1000, + "liquidationThreshold": 3600, + "ltv": 3100, + "oracle": "0x22441d81416430A54336aB28765abd31a792Ad37", + "oracleDecimals": 8, + "oracleDescription": "GNO / USD", + "oracleLatestAnswer": 10666043400, + "reserveFactor": 1500, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0x1A126F613D7705E59ADb39909b25E1223aDF05dd", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt GNO", + "stableDebtTokenSymbol": "stableDebtGnoGNO", + "supplyCap": 30000, + "symbol": "GNO", + "underlying": "0x9C58BAcC331c9aa871AFD802DB6379a98e80CEdb", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0xBc59E99198DbA71985A66E1713cC89FFEC53f7FC", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt GNO", + "variableDebtTokenSymbol": "variableDebtGnoGNO" + }, + "0xDDAfbb505ad214D7b80b1f830fcCc89B60fb7A83": { + "aToken": "0xc6B7AcA6DE8a6044E0e32d0c841a89244A10D284", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis USDC", + "aTokenSymbol": "aGnoUSDC", + "borrowCap": 1000000, + "borrowingEnabled": true, + "debtCeiling": 0, + "decimals": 6, + "eModeCategory": 0, + "interestRateStrategy": "0x345f7fcd88207fe060AD03c2656A23A3Ab596479", + "isActive": true, + "isBorrowableInIsolation": true, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 10500, + "liquidationProtocolFee": 2000, + "liquidationThreshold": 8000, + "ltv": 7700, + "oracle": "0x26C31ac71010aF62E6B486D1132E266D6298857D", + "oracleDecimals": 8, + "oracleDescription": "USDC / USD", + "oracleLatestAnswer": 100005376, + "reserveFactor": 1000, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0x8220133C3a631de3C7A5B679A2417BD61431FEcf", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt USDC", + "stableDebtTokenSymbol": "stableDebtGnoUSDC", + "supplyCap": 1000000, + "symbol": "USDC", + "underlying": "0xDDAfbb505ad214D7b80b1f830fcCc89B60fb7A83", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0x5F6f7B0a87CA3CF3d0b431Ae03EF3305180BFf4d", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt USDC", + "variableDebtTokenSymbol": "variableDebtGnoUSDC" + }, + "0xaf204776c7245bF4147c2612BF6e5972Ee483701": { + "aToken": "0x7a5c3860a77a8DC1b225BD46d0fb2ac1C6D191BC", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis sDAI", + "aTokenSymbol": "aGnosDAI", + "borrowCap": 0, + "borrowingEnabled": false, + "debtCeiling": 0, + "decimals": 18, + "eModeCategory": 0, + "interestRateStrategy": "0x6c3b7e7B8b9609D57C70C3F630228F979EAbb450", + "isActive": true, + "isBorrowableInIsolation": false, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 10500, + "liquidationProtocolFee": 2000, + "liquidationThreshold": 8000, + "ltv": 7700, + "oracle": "0x1D0f881Ce1a646E2f27Dec3c57Fa056cB838BCC2", + "oracleDecimals": 8, + "oracleDescription": "sDAI/DAI/USD", + "oracleLatestAnswer": 102071584, + "reserveFactor": 1000, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0xa2E0335175Da40b081717FfD394C0E1de738cb9B", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt sDAI", + "stableDebtTokenSymbol": "stableDebtGnosDAI", + "supplyCap": 1500000, + "symbol": "sDAI", + "underlying": "0xaf204776c7245bF4147c2612BF6e5972Ee483701", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0x8Fe06E1D8Aff42Bf6812CacF7854A2249a00bED7", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt sDAI", + "variableDebtTokenSymbol": "variableDebtGnosDAI" + }, + "0xcB444e90D8198415266c6a2724b7900fb12FC56E": { + "aToken": "0xEdBC7449a9b594CA4E053D9737EC5Dc4CbCcBfb2", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis EURe", + "aTokenSymbol": "aGnoEURe", + "borrowCap": 500000, + "borrowingEnabled": true, + "debtCeiling": 0, + "decimals": 18, + "eModeCategory": 0, + "interestRateStrategy": "0x6c3b7e7B8b9609D57C70C3F630228F979EAbb450", + "isActive": true, + "isBorrowableInIsolation": false, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 0, + "liquidationProtocolFee": 0, + "liquidationThreshold": 0, + "ltv": 0, + "oracle": "0xab70BCB260073d036d1660201e9d5405F5829b7a", + "oracleDecimals": 8, + "oracleDescription": "EUR / USD", + "oracleLatestAnswer": 106030000, + "reserveFactor": 1500, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0x916E13857FeeD0d982Df148DBe8d8542519aB96e", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt EURe", + "stableDebtTokenSymbol": "stableDebtGnoEURe", + "supplyCap": 500000, + "symbol": "EURe", + "underlying": "0xcB444e90D8198415266c6a2724b7900fb12FC56E", + "usageAsCollateralEnabled": false, + "variableDebtToken": "0xb96404e475f337A7E98e4a541C9b71309BB66c5A", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt EURe", + "variableDebtTokenSymbol": "variableDebtGnoEURe" + }, + "0xe91D153E0b41518A2Ce8Dd3D7944Fa863463a97d": { + "aToken": "0xd0Dd6cEF72143E22cCED4867eb0d5F2328715533", + "aTokenImpl": "0x589750BA8aF186cE5B55391B0b7148cAD43a1619", + "aTokenName": "Aave Gnosis WXDAI", + "aTokenSymbol": "aGnoWXDAI", + "borrowCap": 1500000, + "borrowingEnabled": true, + "debtCeiling": 0, + "decimals": 18, + "eModeCategory": 0, + "interestRateStrategy": "0x345f7fcd88207fe060AD03c2656A23A3Ab596479", + "isActive": true, + "isBorrowableInIsolation": true, + "isFlashloanable": true, + "isFrozen": false, + "isPaused": false, + "isSiloed": false, + "liquidationBonus": 10500, + "liquidationProtocolFee": 2000, + "liquidationThreshold": 8000, + "ltv": 7700, + "oracle": "0x678df3415fc31947dA4324eC63212874be5a82f8", + "oracleDecimals": 8, + "oracleDescription": "DAI / USD", + "oracleLatestAnswer": 100005900, + "reserveFactor": 1000, + "stableBorrowRateEnabled": false, + "stableDebtToken": "0xaC8b1cE0548C69318920C3e0b21Db296d5770D57", + "stableDebtTokenImpl": "0x06C35Cfd3FC61eC2aC437f0d08840d5776b945af", + "stableDebtTokenName": "Aave Gnosis Stable Debt WXDAI", + "stableDebtTokenSymbol": "stableDebtGnoWXDAI", + "supplyCap": 1500000, + "symbol": "WXDAI", + "underlying": "0xe91D153E0b41518A2Ce8Dd3D7944Fa863463a97d", + "usageAsCollateralEnabled": true, + "variableDebtToken": "0x281963D7471eCdC3A2Bd4503e24e89691cfe420D", + "variableDebtTokenImpl": "0xBeC519531F0E78BcDdB295242fA4EC5251B38574", + "variableDebtTokenName": "Aave Gnosis Variable Debt WXDAI", + "variableDebtTokenSymbol": "variableDebtGnoWXDAI" + } + }, + "strategies": { + "0x345f7fcd88207fe060AD03c2656A23A3Ab596479": { + "baseStableBorrowRate": 60000000000000000000000000, + "baseVariableBorrowRate": 0, + "maxExcessStableToTotalDebtRatio": 800000000000000000000000000, + "maxExcessUsageRatio": 100000000000000000000000000, + "optimalStableToTotalDebtRatio": 200000000000000000000000000, + "optimalUsageRatio": 900000000000000000000000000, + "stableRateSlope1": 50000000000000000000000000, + "stableRateSlope2": 750000000000000000000000000, + "variableRateSlope1": 50000000000000000000000000, + "variableRateSlope2": 750000000000000000000000000 + }, + "0x6c3b7e7B8b9609D57C70C3F630228F979EAbb450": { + "baseStableBorrowRate": 50000000000000000000000000, + "baseVariableBorrowRate": 0, + "maxExcessStableToTotalDebtRatio": 800000000000000000000000000, + "maxExcessUsageRatio": 100000000000000000000000000, + "optimalStableToTotalDebtRatio": 200000000000000000000000000, + "optimalUsageRatio": 900000000000000000000000000, + "stableRateSlope1": 40000000000000000000000000, + "stableRateSlope2": 750000000000000000000000000, + "variableRateSlope1": 40000000000000000000000000, + "variableRateSlope2": 750000000000000000000000000 + }, + "0x9E57695Dab0DCdb42BC220ff1E9eb2e22a31209b": { + "baseStableBorrowRate": 90000000000000000000000000, + "baseVariableBorrowRate": 0, + "maxExcessStableToTotalDebtRatio": 800000000000000000000000000, + "maxExcessUsageRatio": 550000000000000000000000000, + "optimalStableToTotalDebtRatio": 200000000000000000000000000, + "optimalUsageRatio": 450000000000000000000000000, + "stableRateSlope1": 70000000000000000000000000, + "stableRateSlope2": 3000000000000000000000000000, + "variableRateSlope1": 70000000000000000000000000, + "variableRateSlope2": 3000000000000000000000000000 + }, + "0xD84d86083010FB683f1e8fA3809ee8DC90A4C4DB": { + "baseStableBorrowRate": 53000000000000000000000000, + "baseVariableBorrowRate": 0, + "maxExcessStableToTotalDebtRatio": 800000000000000000000000000, + "maxExcessUsageRatio": 200000000000000000000000000, + "optimalStableToTotalDebtRatio": 200000000000000000000000000, + "optimalUsageRatio": 800000000000000000000000000, + "stableRateSlope1": 40000000000000000000000000, + "stableRateSlope2": 800000000000000000000000000, + "variableRateSlope1": 33000000000000000000000000, + "variableRateSlope2": 800000000000000000000000000 + } + } +} \ No newline at end of file diff --git a/reports/AaveV3Gnosis_AaveV3GnosisActivation_20231026_before.json b/reports/AaveV3Gnosis_AaveV3GnosisActivation_20231026_before.json new file mode 100644 index 000000000..2c2e3e5db --- /dev/null +++ b/reports/AaveV3Gnosis_AaveV3GnosisActivation_20231026_before.json @@ -0,0 +1,16 @@ +{ + "chainId": 100, + "eModes": {}, + "poolConfig": { + "oracle": "0xeb0a051be10228213BAEb449db63719d6742F7c4", + "pool": "0xb50201558B00496A145fE76f7424749556E326D8", + "poolAddressesProvider": "0x36616cf17557639614c1cdDb356b1B83fc0B2132", + "poolConfigurator": "0x7304979ec9E4EaA0273b6A037a31c4e9e5A75D16", + "poolConfiguratorImpl": "0x25Ec457d1778b0E5316e7f38f3c22baF413F1A8C", + "poolImpl": "0xB1532b76D054c9F9E61b25c4d91f69B4133E4671", + "priceOracleSentinel": "0x0000000000000000000000000000000000000000", + "protocolDataProvider": "0x501B4c19dd9C2e06E94dA7b6D5Ed4ddA013EC741" + }, + "reserves": {}, + "strategies": {} +} \ No newline at end of file diff --git a/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3GnosisActivation.md b/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3GnosisActivation.md new file mode 100644 index 000000000..03fc4998a --- /dev/null +++ b/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3GnosisActivation.md @@ -0,0 +1,95 @@ +--- +title: "Aave v3 Gnosis Activation" +author: "BGD Labs @bgdlabs" +discussions: "https://governance.aave.com/t/arfc-aave-v3-deployment-on-gnosischain/14695" +--- + +## Simple Summary + +This proposal allows the Aave governance to activate the Aave V3 Gnosis pool (3.0.2) by completing all the initial setup and listing WETH, wstETH, GNO, USDC, wXDAI, EURe and sDAI as suggested by the service providers (ACI, Gauntlet and Chaos Labs) on the [governance forum](https://governance.aave.com/t/arfc-aave-v3-deployment-on-gnosischain/14695/7). All the Aave Gnosis V3 addresses can be found in the [aave-address-book](https://github.com/bgd-labs/aave-address-book/blob/main/src/AaveV3Gnosis.sol). + +## Motivation + +All the governance procedures for the expansion of Aave v3 to Gnosis have been finished, said: + +- Positive signaling and approval regarding the expansion on the [governance forum](https://governance.aave.com/t/temp-check-aave-v3-deployment-on-gnosischain/14514), [temp check snapshot](https://snapshot.org/#/aave.eth/proposal/0x659d9d54c19fb6b00e1b6061331d3d7d5d5ceab552c76e24dc1a6fe9a15d2c8d), and [final snapshot](https://snapshot.org/#/aave.eth/proposal/0xb62c93a8b3590dc46eed92b223da5fcbbf6b52f1f79a0c2fcd80bbc0afea59d8). +- Positive technical evaluation done by BGD Labs of the Gnosis chain network, as described in the [forum](https://governance.aave.com/t/bgd-aave-gnosischain-infrastructure-technical-evaluation/14915) in detail. +- Positive risk analysis and assets/parameters recommendation by the service providers ACI, Gauntlet and Chaos Labs as commented on the forum. +- Additionally listing sDAI as approved separately on the [forum](https://governance.aave.com/t/arfc-sdai-onboarding-on-aave-v3-gnosis-pool/15111) and [snapshot](https://snapshot.org/#/aave.eth/proposal/0x31703294f1129b579e98f9384fc95ad39e13eafca127f036d0cc20e927d98f56). + +## Specification + +The proposal will do the following: + +- Set risk steward and freezing steward as the risk admin by executing `ACL_MANAGER.addRiskAdmin()`. +- Set the guardian address as the pool admin by executing `ACL_MANAGER.addPoolAdmin()`. + This is following the standard procedure of keeping pool admin on the Aave Guardian during the bootstrap period, for security. +- List the following assets on Aave V3 Gnosis: wETH, wstETH, GNO, USDC, wXDAI, sDAI, EURe. + +The table below illustrates the initial suggested risk parameters for each asset, as passed via the snapshot. + +| | wETH | wstETH | GNO | USDC | wxDAI | EURe | sDAI | +| ---------------------------------- | -------------- | -------------- | --------- | ------- | --------- | --------- | --------- | +| Loan To Value | 75% | 75% | 31% | 77% | 77% | 0% | 77% | +| Liquidation Threshold | 78% | 78% | 36% | 80% | 80% | 0% | 80% | +| Liquidation Protocol Fee | 10% | 10% | 10% | 20% | 20% | 10% | 20% | +| Liquidation Bonus | 6% | 6% | 10% | 5% | 5% | 0% | 5% | +| Reserve Factor | 15% | 15% | 15% | 10% | 10% | 15% | 10% | +| Enable Borrow | Yes | Yes | No | Yes | Yes | Yes | No | +| Enable Collateral | Yes | Yes | Yes | Yes | Yes | No | Yes | +| Supply Cap | 4000 wETH | 4000 wstETH | 30000 GNO | 1M USDC | 1.5M xDAI | 0.5M EURe | 1.5M sDAI | +| Borrow Cap | 3500 wETH | 400 wstETH | 0 GNO | 1M USDC | 1.5M xDAI | 0.5M EURe | 0 sDAI | +| E-mode category | ETH Correlated | ETH Correlated | None | None | None | None | None | +| Isolation Mode | No | No | Yes | No | No | No | No | +| Flashloanable | Yes | Yes | Yes | Yes | Yes | Yes | Yes | +| Siloed Borrowing | No | No | No | No | No | No | No | +| Debt Ceiling | 0 | 0 | $1M | 0 | 0 | 0 | 0 | +| Stable Borrow | No | No | No | No | No | No | No | +| uOptimal | 80% | 45% | 45% | 90% | 90% | 90% | 90% | +| Base Variable Borrow Rate | 0% | 0% | 0% | 0% | 0% | 0% | 0% | +| Variable Rate Slope1 | 3.3% | 7% | 7% | 5% | 5% | 4% | 4% | +| Variable Rate Slope 2 | 80% | 300% | 300% | 75% | 75% | 75% | 75% | +| Stable Rate Slope 1 | 4% | 7% | 7% | 5% | 5% | 4% | 4% | +| Stable Rate Slope 2 | 80% | 300% | 300% | 75% | 75% | 75% | 75% | +| Base Stable Rate Offset | 2% | 2% | 2% | 1% | 1% | 1% | 1% | +| Stable Rate Excess Offset | 8% | 8% | 8% | 8% | 8% | 8% | 8% | +| Optimal Stable To Total Debt Ratio | 20% | 20% | 20% | 20% | 20% | 20% | 20% | + +
+ +**E-Mode:** + +| Category Id | Category Label | Assets included | LT | LTV | Liquidation Bonus | +| ----------- | -------------- | --------------- | --- | --- | ----------------- | +| 1 | ETH Correlated | WETH, wstETH | 93% | 90% | 1% | + +
+ +sDAI adapter: [0x1D0f881Ce1a646E2f27Dec3c57Fa056cB838BCC2](https://gnosisscan.io/address/0x1D0f881Ce1a646E2f27Dec3c57Fa056cB838BCC2) + +wstETH adapter: [0xcb0670258e5961cca85d8f71d29c1167ef20de99](https://gnosisscan.io/address/0xcb0670258e5961cca85d8f71d29c1167ef20de99) + +Risk Steward: [0x33AE1f41546a2e05368Bf789b3d868813c0Ae658](https://gnosisscan.io/address/0x33AE1f41546a2e05368Bf789b3d868813c0Ae658) + +Freezing Steward: [0x3Ceaf9b6CAb92dFe6302D0CC3F1BA880C28d35e5](https://gnosisscan.io/address/0x3Ceaf9b6CAb92dFe6302D0CC3F1BA880C28d35e5) + +## Security + +The proposal execution is simulated within the tests and the resulting pool configuration is tested for correctness. + +The deployed pool and other permissions have been programmatically verified. + +In addition, we have also checked the code diffs of the deployed base contracts with the deployed contracts on Ethereum and other networks. + +As a matter of caution, the `POOL_ADMIN` role will be given for the first weeks to the Aave Guardian multisig. + +## References + +- Implementation: [AaveV3Gnosis](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3Gnosis_AaveV3GnosisActivation_20231026.sol) +- Tests: [AaveV3Gnosis](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3Gnosis_AaveV3GnosisActivation_20231026.t.sol) +- [Snapshot](https://snapshot.org/#/aave.eth/proposal/0xb62c93a8b3590dc46eed92b223da5fcbbf6b52f1f79a0c2fcd80bbc0afea59d8) +- [Discussion](https://governance.aave.com/t/arfc-aave-v3-deployment-on-gnosischain/14695) + +## Copyright + +Copyright and related rights waived via [CC0](https://creativecommons.org/publicdomain/zero/1.0/). diff --git a/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3GnosisActivation_20231026.s.sol b/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3GnosisActivation_20231026.s.sol new file mode 100644 index 000000000..ccdcac92c --- /dev/null +++ b/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3GnosisActivation_20231026.s.sol @@ -0,0 +1,52 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {GovV3Helpers, IPayloadsControllerCore, PayloadsControllerUtils} from 'aave-helpers/GovV3Helpers.sol'; +import {EthereumScript, GnosisScript} from 'aave-helpers/ScriptUtils.sol'; +import {AaveV3Gnosis_AaveV3GnosisActivation_20231026} from './AaveV3Gnosis_AaveV3GnosisActivation_20231026.sol'; + +/** + * @dev Deploy Gnosis + * command: make deploy-ledger contract=src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3GnosisActivation_20231026.s.sol:DeployGnosis chain=gnosis + */ +contract DeployGnosis is GnosisScript { + function run() external broadcast { + // deploy payloads + AaveV3Gnosis_AaveV3GnosisActivation_20231026 payload0 = new AaveV3Gnosis_AaveV3GnosisActivation_20231026(); + + // compose action + IPayloadsControllerCore.ExecutionAction[] + memory actions = new IPayloadsControllerCore.ExecutionAction[](1); + actions[0] = GovV3Helpers.buildAction(address(payload0)); + + // register action at payloadsController + GovV3Helpers.createPayload(actions); + } +} + +/** + * @dev Create Proposal + * command: make deploy-ledger contract=src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3GnosisActivation_20231026.s.sol:CreateProposal chain=mainnet + */ +contract CreateProposal is EthereumScript { + function run() external { + // create payloads + PayloadsControllerUtils.Payload[] memory payloads = new PayloadsControllerUtils.Payload[](1); + + // compose actions for validation + IPayloadsControllerCore.ExecutionAction[] + memory actionsGnosis = new IPayloadsControllerCore.ExecutionAction[](1); + actionsGnosis[0] = GovV3Helpers.buildAction(0x6Cf806CF51749bE514B7055b6fDBe346aee47B7b); + payloads[0] = GovV3Helpers.buildGnosisPayload(vm, actionsGnosis); + + // create proposal + vm.startBroadcast(); + GovV3Helpers.createProposal2_5( + payloads, + GovV3Helpers.ipfsHashFile( + vm, + 'src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3GnosisActivation.md' + ) + ); + } +} diff --git a/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3Gnosis_AaveV3GnosisActivation_20231026.sol b/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3Gnosis_AaveV3GnosisActivation_20231026.sol new file mode 100644 index 000000000..871fb1329 --- /dev/null +++ b/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3Gnosis_AaveV3GnosisActivation_20231026.sol @@ -0,0 +1,295 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {AaveV3Gnosis} from 'aave-address-book/AaveV3Gnosis.sol'; +import {IPool} from 'aave-address-book/AaveV3.sol'; +import {AaveV3PayloadGnosis} from 'aave-helpers/v3-config-engine/AaveV3PayloadGnosis.sol'; +import {EngineFlags} from 'aave-helpers/v3-config-engine/EngineFlags.sol'; +import {IAaveV3ConfigEngine} from 'aave-helpers/v3-config-engine/IAaveV3ConfigEngine.sol'; +import {IV3RateStrategyFactory} from 'aave-helpers/v3-config-engine/IV3RateStrategyFactory.sol'; +import {IERC20} from 'solidity-utils/contracts/oz-common/interfaces/IERC20.sol'; +import {SafeERC20} from 'solidity-utils/contracts/oz-common/SafeERC20.sol'; + +/** + * @title Aave v3 Gnosis Activation + * @author BGD Labs + * - Snapshot: https://snapshot.org/#/aave.eth/proposal/0xb62c93a8b3590dc46eed92b223da5fcbbf6b52f1f79a0c2fcd80bbc0afea59d8 + * - Discussion: https://governance.aave.com/t/arfc-aave-v3-deployment-on-gnosischain/14695 + */ +contract AaveV3Gnosis_AaveV3GnosisActivation_20231026 is AaveV3PayloadGnosis { + using SafeERC20 for IERC20; + + address public constant WETH = 0x6A023CCd1ff6F2045C3309768eAd9E68F978f6e1; + address public constant wstETH = 0x6C76971f98945AE98dD7d4DFcA8711ebea946eA6; + address public constant GNO = 0x9C58BAcC331c9aa871AFD802DB6379a98e80CEdb; + address public constant USDC = 0xDDAfbb505ad214D7b80b1f830fcCc89B60fb7A83; + address public constant WXDAI = 0xe91D153E0b41518A2Ce8Dd3D7944Fa863463a97d; + address public constant EURe = 0xcB444e90D8198415266c6a2724b7900fb12FC56E; + address public constant sDAI = 0xaf204776c7245bF4147c2612BF6e5972Ee483701; + + address public constant GUARDIAN = 0xF163b8698821cefbD33Cf449764d69Ea445cE23D; + address public constant FREEZING_STEWARD = 0x3Ceaf9b6CAb92dFe6302D0CC3F1BA880C28d35e5; + + function _postExecute() internal override { + AaveV3Gnosis.ACL_MANAGER.addPoolAdmin(GUARDIAN); + AaveV3Gnosis.ACL_MANAGER.addRiskAdmin(FREEZING_STEWARD); + AaveV3Gnosis.ACL_MANAGER.addRiskAdmin(AaveV3Gnosis.CAPS_PLUS_RISK_STEWARD); + + _supply(AaveV3Gnosis.POOL, WETH, 0.01 * 1e18, address(AaveV3Gnosis.COLLECTOR)); + _supply(AaveV3Gnosis.POOL, wstETH, 0.01 * 1e18, address(AaveV3Gnosis.COLLECTOR)); + _supply(AaveV3Gnosis.POOL, GNO, 0.1 * 1e18, address(AaveV3Gnosis.COLLECTOR)); + _supply(AaveV3Gnosis.POOL, USDC, 10 * 1e6, address(AaveV3Gnosis.COLLECTOR)); + _supply(AaveV3Gnosis.POOL, WXDAI, 10 * 1e18, address(AaveV3Gnosis.COLLECTOR)); + _supply(AaveV3Gnosis.POOL, EURe, 10 * 1e18, address(AaveV3Gnosis.COLLECTOR)); + _supply(AaveV3Gnosis.POOL, sDAI, 10 * 1e18, address(AaveV3Gnosis.COLLECTOR)); + } + + function eModeCategoriesUpdates() + public + pure + override + returns (IAaveV3ConfigEngine.EModeCategoryUpdate[] memory) + { + IAaveV3ConfigEngine.EModeCategoryUpdate[] + memory eModeUpdates = new IAaveV3ConfigEngine.EModeCategoryUpdate[](1); + + eModeUpdates[0] = IAaveV3ConfigEngine.EModeCategoryUpdate({ + eModeCategory: 1, + ltv: 90_00, + liqThreshold: 93_00, + liqBonus: 1_00, + priceSource: 0x0000000000000000000000000000000000000000, + label: 'ETH correlated' + }); + + return eModeUpdates; + } + + function newListings() public pure override returns (IAaveV3ConfigEngine.Listing[] memory) { + IAaveV3ConfigEngine.Listing[] memory listings = new IAaveV3ConfigEngine.Listing[](7); + + listings[0] = IAaveV3ConfigEngine.Listing({ + asset: WETH, + assetSymbol: 'WETH', + priceFeed: 0xa767f745331D267c7751297D982b050c93985627, + eModeCategory: 1, + enabledToBorrow: EngineFlags.ENABLED, + stableRateModeEnabled: EngineFlags.DISABLED, + borrowableInIsolation: EngineFlags.DISABLED, + withSiloedBorrowing: EngineFlags.DISABLED, + flashloanable: EngineFlags.ENABLED, + ltv: 75_00, + liqThreshold: 78_00, + liqBonus: 6_00, + reserveFactor: 15_00, + supplyCap: 4_000, + borrowCap: 3_500, + debtCeiling: 0, + liqProtocolFee: 10_00, + rateStrategyParams: IV3RateStrategyFactory.RateStrategyParams({ + optimalUsageRatio: _bpsToRay(80_00), + baseVariableBorrowRate: 0, + variableRateSlope1: _bpsToRay(3_30), + variableRateSlope2: _bpsToRay(80_00), + stableRateSlope1: _bpsToRay(4_00), + stableRateSlope2: _bpsToRay(80_00), + baseStableRateOffset: _bpsToRay(2_00), + stableRateExcessOffset: _bpsToRay(8_00), + optimalStableToTotalDebtRatio: _bpsToRay(20_00) + }) + }); + + listings[1] = IAaveV3ConfigEngine.Listing({ + asset: wstETH, + assetSymbol: 'wstETH', + priceFeed: 0xcb0670258e5961CCA85D8F71D29C1167Ef20De99, + eModeCategory: 1, + enabledToBorrow: EngineFlags.ENABLED, + stableRateModeEnabled: EngineFlags.DISABLED, + borrowableInIsolation: EngineFlags.DISABLED, + withSiloedBorrowing: EngineFlags.DISABLED, + flashloanable: EngineFlags.ENABLED, + ltv: 75_00, + liqThreshold: 78_00, + liqBonus: 6_00, + reserveFactor: 15_00, + supplyCap: 4_000, + borrowCap: 400, + debtCeiling: 0, + liqProtocolFee: 10_00, + rateStrategyParams: IV3RateStrategyFactory.RateStrategyParams({ + optimalUsageRatio: _bpsToRay(45_00), + baseVariableBorrowRate: 0, + variableRateSlope1: _bpsToRay(7_00), + variableRateSlope2: _bpsToRay(300_00), + stableRateSlope1: _bpsToRay(7_00), + stableRateSlope2: _bpsToRay(300_00), + baseStableRateOffset: _bpsToRay(2_00), + stableRateExcessOffset: _bpsToRay(8_00), + optimalStableToTotalDebtRatio: _bpsToRay(20_00) + }) + }); + + listings[2] = IAaveV3ConfigEngine.Listing({ + asset: GNO, + assetSymbol: 'GNO', + priceFeed: 0x22441d81416430A54336aB28765abd31a792Ad37, + eModeCategory: 0, + enabledToBorrow: EngineFlags.DISABLED, + stableRateModeEnabled: EngineFlags.DISABLED, + borrowableInIsolation: EngineFlags.DISABLED, + withSiloedBorrowing: EngineFlags.DISABLED, + flashloanable: EngineFlags.ENABLED, + ltv: 31_00, + liqThreshold: 36_00, + liqBonus: 10_00, + reserveFactor: 15_00, + supplyCap: 30_000, + borrowCap: 0, + debtCeiling: 1_000_000, + liqProtocolFee: 10_00, + rateStrategyParams: IV3RateStrategyFactory.RateStrategyParams({ + optimalUsageRatio: _bpsToRay(45_00), + baseVariableBorrowRate: 0, + variableRateSlope1: _bpsToRay(7_00), + variableRateSlope2: _bpsToRay(300_00), + stableRateSlope1: _bpsToRay(7_00), + stableRateSlope2: _bpsToRay(300_00), + baseStableRateOffset: _bpsToRay(2_00), + stableRateExcessOffset: _bpsToRay(8_00), + optimalStableToTotalDebtRatio: _bpsToRay(20_00) + }) + }); + + listings[3] = IAaveV3ConfigEngine.Listing({ + asset: USDC, + assetSymbol: 'USDC', + priceFeed: 0x26C31ac71010aF62E6B486D1132E266D6298857D, + eModeCategory: 0, + enabledToBorrow: EngineFlags.ENABLED, + stableRateModeEnabled: EngineFlags.DISABLED, + borrowableInIsolation: EngineFlags.ENABLED, + withSiloedBorrowing: EngineFlags.DISABLED, + flashloanable: EngineFlags.ENABLED, + ltv: 77_00, + liqThreshold: 80_00, + liqBonus: 5_00, + reserveFactor: 10_00, + supplyCap: 1_000_000, + borrowCap: 1_000_000, + debtCeiling: 0, + liqProtocolFee: 20_00, + rateStrategyParams: IV3RateStrategyFactory.RateStrategyParams({ + optimalUsageRatio: _bpsToRay(90_00), + baseVariableBorrowRate: 0, + variableRateSlope1: _bpsToRay(5_00), + variableRateSlope2: _bpsToRay(75_00), + stableRateSlope1: _bpsToRay(5_00), + stableRateSlope2: _bpsToRay(75_00), + baseStableRateOffset: _bpsToRay(1_00), + stableRateExcessOffset: _bpsToRay(8_00), + optimalStableToTotalDebtRatio: _bpsToRay(20_00) + }) + }); + + listings[4] = IAaveV3ConfigEngine.Listing({ + asset: WXDAI, + assetSymbol: 'WXDAI', + priceFeed: 0x678df3415fc31947dA4324eC63212874be5a82f8, + eModeCategory: 0, + enabledToBorrow: EngineFlags.ENABLED, + stableRateModeEnabled: EngineFlags.DISABLED, + borrowableInIsolation: EngineFlags.ENABLED, + withSiloedBorrowing: EngineFlags.DISABLED, + flashloanable: EngineFlags.ENABLED, + ltv: 77_00, + liqThreshold: 80_00, + liqBonus: 5_00, + reserveFactor: 10_00, + supplyCap: 1_500_000, + borrowCap: 1_500_000, + debtCeiling: 0, + liqProtocolFee: 20_00, + rateStrategyParams: IV3RateStrategyFactory.RateStrategyParams({ + optimalUsageRatio: _bpsToRay(90_00), + baseVariableBorrowRate: 0, + variableRateSlope1: _bpsToRay(5_00), + variableRateSlope2: _bpsToRay(75_00), + stableRateSlope1: _bpsToRay(5_00), + stableRateSlope2: _bpsToRay(75_00), + baseStableRateOffset: _bpsToRay(1_00), + stableRateExcessOffset: _bpsToRay(8_00), + optimalStableToTotalDebtRatio: _bpsToRay(20_00) + }) + }); + + listings[5] = IAaveV3ConfigEngine.Listing({ + asset: EURe, + assetSymbol: 'EURe', + priceFeed: 0xab70BCB260073d036d1660201e9d5405F5829b7a, + eModeCategory: 0, + enabledToBorrow: EngineFlags.ENABLED, + stableRateModeEnabled: EngineFlags.DISABLED, + borrowableInIsolation: EngineFlags.DISABLED, + withSiloedBorrowing: EngineFlags.DISABLED, + flashloanable: EngineFlags.ENABLED, + ltv: 0, + liqThreshold: 0, + liqBonus: 0, + reserveFactor: 15_00, + supplyCap: 500_000, + borrowCap: 500_000, + debtCeiling: 0, + liqProtocolFee: 10_00, + rateStrategyParams: IV3RateStrategyFactory.RateStrategyParams({ + optimalUsageRatio: _bpsToRay(90_00), + baseVariableBorrowRate: 0, + variableRateSlope1: _bpsToRay(4_00), + variableRateSlope2: _bpsToRay(75_00), + stableRateSlope1: _bpsToRay(4_00), + stableRateSlope2: _bpsToRay(75_00), + baseStableRateOffset: _bpsToRay(1_00), + stableRateExcessOffset: _bpsToRay(8_00), + optimalStableToTotalDebtRatio: _bpsToRay(20_00) + }) + }); + + listings[6] = IAaveV3ConfigEngine.Listing({ + asset: sDAI, + assetSymbol: 'sDAI', + priceFeed: 0x1D0f881Ce1a646E2f27Dec3c57Fa056cB838BCC2, + eModeCategory: 0, + enabledToBorrow: EngineFlags.DISABLED, + stableRateModeEnabled: EngineFlags.DISABLED, + borrowableInIsolation: EngineFlags.DISABLED, + withSiloedBorrowing: EngineFlags.DISABLED, + flashloanable: EngineFlags.ENABLED, + ltv: 77_00, + liqThreshold: 80_00, + liqBonus: 5_00, + reserveFactor: 10_00, + supplyCap: 1_500_000, + borrowCap: 0, + debtCeiling: 0, + liqProtocolFee: 20_00, + rateStrategyParams: IV3RateStrategyFactory.RateStrategyParams({ + optimalUsageRatio: _bpsToRay(90_00), + baseVariableBorrowRate: 0, + variableRateSlope1: _bpsToRay(4_00), + variableRateSlope2: _bpsToRay(75_00), + stableRateSlope1: _bpsToRay(4_00), + stableRateSlope2: _bpsToRay(75_00), + baseStableRateOffset: _bpsToRay(1_00), + stableRateExcessOffset: _bpsToRay(8_00), + optimalStableToTotalDebtRatio: _bpsToRay(20_00) + }) + }); + + return listings; + } + + function _supply(IPool pool, address asset, uint256 amount, address onBehalfOf) internal { + IERC20(asset).forceApprove(address(pool), amount); + pool.supply(asset, amount, onBehalfOf, 0); + } +} diff --git a/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3Gnosis_AaveV3GnosisActivation_20231026.t.sol b/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3Gnosis_AaveV3GnosisActivation_20231026.t.sol new file mode 100644 index 000000000..d8318cc00 --- /dev/null +++ b/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/AaveV3Gnosis_AaveV3GnosisActivation_20231026.t.sol @@ -0,0 +1,98 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {GovV3Helpers} from 'aave-helpers/GovV3Helpers.sol'; +import {AaveV3Gnosis} from 'aave-address-book/AaveV3Gnosis.sol'; +import {IERC20} from 'solidity-utils/contracts/oz-common/interfaces/IERC20.sol'; +import {GovernanceV3Gnosis} from 'aave-address-book/GovernanceV3Gnosis.sol'; + +import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase.sol'; +import {AaveV3Gnosis_AaveV3GnosisActivation_20231026} from './AaveV3Gnosis_AaveV3GnosisActivation_20231026.sol'; + +/** + * @dev Test for AaveV3Gnosis_AaveV3GnosisActivation_20231026 + * command: make test-contract filter=AaveV3Gnosis_AaveV3GnosisActivation_20231026 + */ +contract AaveV3Gnosis_AaveV3GnosisActivation_20231026_Test is ProtocolV3TestBase { + AaveV3Gnosis_AaveV3GnosisActivation_20231026 internal proposal; + address constant DEPLOYER = 0x956DE559DFc27678FD69d4f49f485196b50BDD0F; + + function setUp() public { + vm.createSelectFork(vm.rpcUrl('gnosis'), 30721143); + proposal = new AaveV3Gnosis_AaveV3GnosisActivation_20231026(); + } + + /** + * @dev executes the generic test suite including e2e and config snapshots + */ + function test_defaultProposalExecution() public { + defaultTest( + 'AaveV3Gnosis_AaveV3GnosisActivation_20231026', + AaveV3Gnosis.POOL, + address(proposal) + ); + } + + function test_AdminPermissions() public { + GovV3Helpers.executePayload(vm, address(proposal)); + assertTrue(AaveV3Gnosis.ACL_MANAGER.isRiskAdmin(AaveV3Gnosis.CAPS_PLUS_RISK_STEWARD)); + assertTrue(AaveV3Gnosis.ACL_MANAGER.isRiskAdmin(proposal.FREEZING_STEWARD())); + assertTrue(AaveV3Gnosis.ACL_MANAGER.isPoolAdmin(proposal.GUARDIAN())); + } + + function test_collectorHasWETHFunds() public { + GovV3Helpers.executePayload(vm, address(proposal)); + (address aTokenAddress, , ) = AaveV3Gnosis + .AAVE_PROTOCOL_DATA_PROVIDER + .getReserveTokensAddresses(proposal.WETH()); + assertGe(IERC20(aTokenAddress).balanceOf(address(AaveV3Gnosis.COLLECTOR)), 0.01 * 1e18); + } + + function test_collectorHaswstETHFunds() public { + GovV3Helpers.executePayload(vm, address(proposal)); + (address aTokenAddress, , ) = AaveV3Gnosis + .AAVE_PROTOCOL_DATA_PROVIDER + .getReserveTokensAddresses(proposal.wstETH()); + assertGe(IERC20(aTokenAddress).balanceOf(address(AaveV3Gnosis.COLLECTOR)), 0.01 * 1e18); + } + + function test_collectorHasGNOFunds() public { + GovV3Helpers.executePayload(vm, address(proposal)); + (address aTokenAddress, , ) = AaveV3Gnosis + .AAVE_PROTOCOL_DATA_PROVIDER + .getReserveTokensAddresses(proposal.GNO()); + assertGe(IERC20(aTokenAddress).balanceOf(address(AaveV3Gnosis.COLLECTOR)), 0.1 * 1e18); + } + + function test_collectorHasUSDCFunds() public { + GovV3Helpers.executePayload(vm, address(proposal)); + (address aTokenAddress, , ) = AaveV3Gnosis + .AAVE_PROTOCOL_DATA_PROVIDER + .getReserveTokensAddresses(proposal.USDC()); + assertGe(IERC20(aTokenAddress).balanceOf(address(AaveV3Gnosis.COLLECTOR)), 10 * 1e6); + } + + function test_collectorHasWXDAIFunds() public { + GovV3Helpers.executePayload(vm, address(proposal)); + (address aTokenAddress, , ) = AaveV3Gnosis + .AAVE_PROTOCOL_DATA_PROVIDER + .getReserveTokensAddresses(proposal.WXDAI()); + assertGe(IERC20(aTokenAddress).balanceOf(address(AaveV3Gnosis.COLLECTOR)), 10 * 1e18); + } + + function test_collectorHasEUReFunds() public { + GovV3Helpers.executePayload(vm, address(proposal)); + (address aTokenAddress, , ) = AaveV3Gnosis + .AAVE_PROTOCOL_DATA_PROVIDER + .getReserveTokensAddresses(proposal.EURe()); + assertGe(IERC20(aTokenAddress).balanceOf(address(AaveV3Gnosis.COLLECTOR)), 10 * 1e18); + } + + function test_collectorHasSDAIFunds() public { + GovV3Helpers.executePayload(vm, address(proposal)); + (address aTokenAddress, , ) = AaveV3Gnosis + .AAVE_PROTOCOL_DATA_PROVIDER + .getReserveTokensAddresses(proposal.sDAI()); + assertGe(IERC20(aTokenAddress).balanceOf(address(AaveV3Gnosis.COLLECTOR)), 10 * 1e18); + } +} diff --git a/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/config.json b/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/config.json new file mode 100644 index 000000000..3654dc579 --- /dev/null +++ b/src/20231026_AaveV3Gnosis_AaveV3GnosisActivation/config.json @@ -0,0 +1,215 @@ +{ + "rootOptions": { + "pools": [ + "AaveV3Gnosis" + ], + "title": "Aave v3 Gnosis Activation", + "shortName": "AaveV3GnosisActivation", + "date": "20231026", + "author": "BGD Labs", + "discussion": "https://governance.aave.com/t/arfc-aave-v3-deployment-on-gnosischain/14695", + "snapshot": "https://snapshot.org/#/aave.eth/proposal/0xb62c93a8b3590dc46eed92b223da5fcbbf6b52f1f79a0c2fcd80bbc0afea59d8" + }, + "poolOptions": { + "AaveV3Gnosis": { + "configs": { + "EMODES_UPDATES": [ + { + "eModeCategory": "1", + "ltv": "90_00", + "liqThreshold": "93_00", + "liqBonus": "1_00", + "priceSource": "0x0000000000000000000000000000000000000000", + "label": "ETH correlated" + } + ], + "ASSET_LISTING": [ + { + "assetSymbol": "WETH", + "decimals": 18, + "priceFeed": "0xa767f745331D267c7751297D982b050c93985627", + "ltv": "80_50", + "liqThreshold": "83_00", + "liqBonus": "6_00", + "debtCeiling": "0", + "liqProtocolFee": "10_00", + "enabledToBorrow": "EngineFlags.ENABLED", + "flashloanable": "EngineFlags.ENABLED", + "stableRateModeEnabled": "EngineFlags.DISABLED", + "borrowableInIsolation": "EngineFlags.DISABLED", + "withSiloedBorrowing": "EngineFlags.DISABLED", + "reserveFactor": "15_00", + "supplyCap": "4_000_000", + "borrowCap": "3_500_000", + "rateStrategyParams": { + "optimalUtilizationRate": "_bpsToRay(80_00)", + "baseVariableBorrowRate": "_bpsToRay(0_00)", + "variableRateSlope1": "_bpsToRay(3.3)", + "variableRateSlope2": "_bpsToRay(80_00)", + "stableRateSlope1": "_bpsToRay(4_00)", + "stableRateSlope2": "_bpsToRay(80_00)", + "baseStableRateOffset": "_bpsToRay(2_00)", + "stableRateExcessOffset": "_bpsToRay(8_00)", + "optimalStableToTotalDebtRatio": "_bpsToRay(20_00)" + }, + "asset": "0x6A023CCd1ff6F2045C3309768eAd9E68F978f6e1" + }, + { + "assetSymbol": "wstETH", + "decimals": 18, + "priceFeed": "0xcb0670258e5961CCA85D8F71D29C1167Ef20De99", + "ltv": "71_00", + "liqThreshold": "76_00", + "liqBonus": "6_00", + "debtCeiling": "0", + "liqProtocolFee": "10_00", + "enabledToBorrow": "EngineFlags.ENABLED", + "flashloanable": "EngineFlags.ENABLED", + "stableRateModeEnabled": "EngineFlags.DISABLED", + "borrowableInIsolation": "EngineFlags.DISABLED", + "withSiloedBorrowing": "EngineFlags.DISABLED", + "reserveFactor": "15_00", + "supplyCap": "4_000_000", + "borrowCap": "400_000", + "rateStrategyParams": { + "optimalUtilizationRate": "_bpsToRay(45_00)", + "baseVariableBorrowRate": "_bpsToRay(0_00)", + "variableRateSlope1": "_bpsToRay(7_00)", + "variableRateSlope2": "_bpsToRay(300_00)", + "stableRateSlope1": "_bpsToRay(7_00)", + "stableRateSlope2": "_bpsToRay(300_00)", + "baseStableRateOffset": "_bpsToRay(2_00)", + "stableRateExcessOffset": "_bpsToRay(8_00)", + "optimalStableToTotalDebtRatio": "_bpsToRay(20_00)" + }, + "asset": "0x6C76971f98945AE98dD7d4DFcA8711ebea946eA6" + }, + { + "assetSymbol": "GNO", + "decimals": 18, + "priceFeed": "0x22441d81416430A54336aB28765abd31a792Ad37", + "ltv": "31_00", + "liqThreshold": "36_00", + "liqBonus": "10_00", + "debtCeiling": "5_000_000_000", + "liqProtocolFee": "10_00", + "enabledToBorrow": "EngineFlags.DISABLED", + "flashloanable": "EngineFlags.DISABLED", + "stableRateModeEnabled": "EngineFlags.DISABLED", + "borrowableInIsolation": "EngineFlags.DISABLED", + "withSiloedBorrowing": "EngineFlags.DISABLED", + "reserveFactor": "15_00", + "supplyCap": "30_000_000", + "borrowCap": "0", + "rateStrategyParams": { + "optimalUtilizationRate": "_bpsToRay(45_00)", + "baseVariableBorrowRate": "_bpsToRay(0_00)", + "variableRateSlope1": "_bpsToRay(7_00)", + "variableRateSlope2": "_bpsToRay(300_00)", + "stableRateSlope1": "_bpsToRay(7_00)", + "stableRateSlope2": "_bpsToRay(300_00)", + "baseStableRateOffset": "_bpsToRay(2_00)", + "stableRateExcessOffset": "_bpsToRay(8_00)", + "optimalStableToTotalDebtRatio": "_bpsToRay(20_00)" + }, + "asset": "0x9C58BAcC331c9aa871AFD802DB6379a98e80CEdb" + }, + { + "assetSymbol": "USDC", + "decimals": 6, + "priceFeed": "0x26C31ac71010aF62E6B486D1132E266D6298857D", + "ltv": "77_00", + "liqThreshold": "80_00", + "liqBonus": "5_00", + "debtCeiling": "0", + "liqProtocolFee": "20_00", + "enabledToBorrow": "EngineFlags.ENABLED", + "flashloanable": "EngineFlags.ENABLED", + "stableRateModeEnabled": "EngineFlags.DISABLED", + "borrowableInIsolation": "EngineFlags.ENABLED", + "withSiloedBorrowing": "EngineFlags.DISABLED", + "reserveFactor": "10_00", + "supplyCap": "1_000_000_000", + "borrowCap": "1_000_000_000", + "rateStrategyParams": { + "optimalUtilizationRate": "_bpsToRay(90_00)", + "baseVariableBorrowRate": "_bpsToRay(0_00)", + "variableRateSlope1": "_bpsToRay(4_00)", + "variableRateSlope2": "_bpsToRay(75_00)", + "stableRateSlope1": "_bpsToRay(4_00)", + "stableRateSlope2": "_bpsToRay(75_00)", + "baseStableRateOffset": "_bpsToRay(1_00)", + "stableRateExcessOffset": "_bpsToRay(8_00)", + "optimalStableToTotalDebtRatio": "_bpsToRay(20_00)" + }, + "asset": "0xDDAfbb505ad214D7b80b1f830fcCc89B60fb7A83" + }, + { + "assetSymbol": "XDAI", + "decimals": 18, + "priceFeed": "0x678df3415fc31947dA4324eC63212874be5a82f8", + "ltv": "77_00", + "liqThreshold": "80_00", + "liqBonus": "5_00", + "debtCeiling": "0", + "liqProtocolFee": "20_00", + "enabledToBorrow": "EngineFlags.ENABLED", + "flashloanable": "EngineFlags.ENABLED", + "stableRateModeEnabled": "EngineFlags.DISABLED", + "borrowableInIsolation": "EngineFlags.ENABLED", + "withSiloedBorrowing": "EngineFlags.DISABLED", + "reserveFactor": "10_00", + "supplyCap": "1_500_000_000", + "borrowCap": "1_500_000_000", + "rateStrategyParams": { + "optimalUtilizationRate": "_bpsToRay(90_00)", + "baseVariableBorrowRate": "_bpsToRay(0_00)", + "variableRateSlope1": "_bpsToRay(4_00)", + "variableRateSlope2": "_bpsToRay(75_00)", + "stableRateSlope1": "_bpsToRay(4_00)", + "stableRateSlope2": "_bpsToRay(75_00)", + "baseStableRateOffset": "_bpsToRay(1_00)", + "stableRateExcessOffset": "_bpsToRay(8_00)", + "optimalStableToTotalDebtRatio": "_bpsToRay(20_00)" + }, + "asset": "0xe91D153E0b41518A2Ce8Dd3D7944Fa863463a97d" + }, + { + "assetSymbol": "EURe", + "decimals": 18, + "priceFeed": "0xab70BCB260073d036d1660201e9d5405F5829b7a", + "ltv": "0_00", + "liqThreshold": "0_00", + "liqBonus": "0_00", + "debtCeiling": "0", + "liqProtocolFee": "10_00", + "enabledToBorrow": "EngineFlags.ENABLED", + "flashloanable": "EngineFlags.ENABLED", + "stableRateModeEnabled": "EngineFlags.DISABLED", + "borrowableInIsolation": "EngineFlags.DISABLED", + "withSiloedBorrowing": "EngineFlags.DISABLED", + "reserveFactor": "15_00", + "supplyCap": "1_500_000_000", + "borrowCap": "1_500_000_000", + "rateStrategyParams": { + "optimalUtilizationRate": "_bpsToRay(90_00)", + "baseVariableBorrowRate": "_bpsToRay(0_00)", + "variableRateSlope1": "_bpsToRay(4_00)", + "variableRateSlope2": "_bpsToRay(75_00)", + "stableRateSlope1": "_bpsToRay(4_00)", + "stableRateSlope2": "_bpsToRay(75_00)", + "baseStableRateOffset": "_bpsToRay(1_00)", + "stableRateExcessOffset": "_bpsToRay(8_00)", + "optimalStableToTotalDebtRatio": "_bpsToRay(20_00)" + }, + "asset": "0xcB444e90D8198415266c6a2724b7900fb12FC56E" + } + ] + }, + "features": [ + "EMODES_UPDATES", + "ASSET_LISTING" + ] + } + } +} \ No newline at end of file diff --git a/yarn.lock b/yarn.lock index da953e283..e4535fd5f 100644 --- a/yarn.lock +++ b/yarn.lock @@ -44,13 +44,13 @@ resolved "https://registry.yarnpkg.com/@bgd-labs/aave-address-book/-/aave-address-book-2.8.0.tgz#6d4169c5b8e70bc9b847f5173b4ea2ca59f7a21b" integrity sha512-oBcoPtwxnMZ310iYZHLqViuKAy4Q8hvwq6enW33LdqDL5Y+iU7c8TptKl6KdsojxwlluNZ1sahW5PfKNUT0jIQ== -"@bgd-labs/aave-cli@0.0.27-454eafdfe0f9813ef73c81bc25457e3efd418c50.0": - version "0.0.27-454eafdfe0f9813ef73c81bc25457e3efd418c50.0" - resolved "https://registry.yarnpkg.com/@bgd-labs/aave-cli/-/aave-cli-0.0.27-454eafdfe0f9813ef73c81bc25457e3efd418c50.0.tgz#c91e8f2d970a8a2c615dc2ae977d77e0b4cfe41d" - integrity sha512-crIjJpd0oxB6GTrM85K/vUucWKqwkn2l9e4ZHL6fTq6o8os1KowgG/SaLQ0FLZ0K5YNrk2npVYn4Y3p6CzPgDA== +"@bgd-labs/aave-cli@0.0.27-0a01f2a07efe0ec4c875cf479004d20350235f64.0": + version "0.0.27-0a01f2a07efe0ec4c875cf479004d20350235f64.0" + resolved "https://registry.yarnpkg.com/@bgd-labs/aave-cli/-/aave-cli-0.0.27-0a01f2a07efe0ec4c875cf479004d20350235f64.0.tgz#2e3d4de157aae111af294d236536fdca0a51150e" + integrity sha512-7JI0j7JBkXoqmvEneBd0s9GFZuUoiTWFc+vrErWl/xvm3HbyaxO4t3NwpPata5zeVVLO9bBijRGCKJ1ZZwtCwg== dependencies: "@bgd-labs/aave-address-book" "2.7.0" - "@commander-js/extra-typings" "^11.0.0" + "@commander-js/extra-typings" "^11.1.0" "@inquirer/prompts" "^3.2.0" bs58 "^5.0.0" chalk "^4.1.2" @@ -62,13 +62,13 @@ json-bigint "^1.0.0" node-fetch "^2.6.9" object-hash "^3.0.0" - viem "^1.15.1" - zod "^3.22.3" + viem "^1.16.6" + zod "^3.22.4" -"@commander-js/extra-typings@^11.0.0": - version "11.0.0" - resolved "https://registry.yarnpkg.com/@commander-js/extra-typings/-/extra-typings-11.0.0.tgz#eb922a59550454cad1f319d3d33e675e12e92fa0" - integrity sha512-06ol6Kn5gPjFY6v0vWOZ84nQwyqhZdaeZCHYH3vhwewjpOEjniF1KHZxh18887G3poWiJ8qyq5pb6ANuiddfPQ== +"@commander-js/extra-typings@^11.1.0": + version "11.1.0" + resolved "https://registry.yarnpkg.com/@commander-js/extra-typings/-/extra-typings-11.1.0.tgz#dd19fcb8cc6e33ede237fc1b7af96c70833d8f93" + integrity sha512-GuvZ38d23H+7Tz2C9DhzCepivsOsky03s5NI+KCy7ke1FNUvsJ2oO47scQ9YaGGhgjgNW5OYYNSADmbjcSoIhw== "@esbuild/android-arm64@0.18.20": version "0.18.20" @@ -1812,20 +1812,6 @@ varint@^6.0.0: resolved "https://registry.yarnpkg.com/varint/-/varint-6.0.0.tgz#9881eb0ce8feaea6512439d19ddf84bf551661d0" integrity sha512-cXEIW6cfr15lFv563k4GuVuW/fiwjknytD37jIOLSdSWuOI6WnO/oKwmP2FQTU2l01LP8/M5TSAJpzUaGe3uWg== -viem@^1.15.1: - version "1.16.4" - resolved "https://registry.yarnpkg.com/viem/-/viem-1.16.4.tgz#4cb90dd27d13356ea00d21f6fd363bdfe0628c4e" - integrity sha512-T9ziN3EERXz0BtQSS2VJM+P1EJ2W7K7PviobFrmvWCEYmNQ/vJDhfFqGjvq0ZL9LVz9HvevCbenEy8oIdMEZ+w== - dependencies: - "@adraffy/ens-normalize" "1.9.4" - "@noble/curves" "1.2.0" - "@noble/hashes" "1.3.2" - "@scure/bip32" "1.3.2" - "@scure/bip39" "1.2.1" - abitype "0.9.8" - isows "1.0.3" - ws "8.13.0" - viem@^1.16.6: version "1.16.6" resolved "https://registry.yarnpkg.com/viem/-/viem-1.16.6.tgz#78118c9269506a59e2bc4deab13f1646e113d3fc" @@ -1943,7 +1929,7 @@ yocto-queue@^1.0.0: resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-1.0.0.tgz#7f816433fb2cbc511ec8bf7d263c3b58a1a3c251" integrity sha512-9bnSc/HEW2uRy67wc+T8UwauLuPJVn28jb+GtJY16iiKWyvmYJRXVT4UamsAEGQfPohgr2q4Tq0sQbQlxTfi1g== -zod@^3.22.3: +zod@^3.22.4: version "3.22.4" resolved "https://registry.yarnpkg.com/zod/-/zod-3.22.4.tgz#f31c3a9386f61b1f228af56faa9255e845cf3fff" integrity sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==