Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update cbBTC Supply cap on Ethereum and Base #483

Merged
merged 3 commits into from
Oct 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
## Reserve changes

### Reserves altered

#### cbBTC ([0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf](https://basescan.org/address/0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf))

| description | value before | value after |
| --- | --- | --- |
| supplyCap | 1,600 cbBTC | 5,000 cbBTC |


## Emodes changes

## Raw diff

```json
{
"reserves": {
"0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf": {
"supplyCap": {
"from": 1600,
"to": 5000
}
}
}
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
## Reserve changes

### Reserves altered

#### cbBTC ([0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf](https://etherscan.io/address/0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf))

| description | value before | value after |
| --- | --- | --- |
| supplyCap | 2,400 cbBTC | 10,000 cbBTC |


## Emodes changes

## Raw diff

```json
{
"reserves": {
"0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf": {
"supplyCap": {
"from": 2400,
"to": 10000
}
}
}
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import {AaveV3Base, AaveV3BaseAssets} from 'aave-address-book/AaveV3Base.sol';
import {AaveV3PayloadBase} from 'aave-helpers/src/v3-config-engine/AaveV3PayloadBase.sol';
import {EngineFlags} from 'aave-v3-origin/contracts/extensions/v3-config-engine/EngineFlags.sol';
import {IAaveV3ConfigEngine} from 'aave-v3-origin/contracts/extensions/v3-config-engine/IAaveV3ConfigEngine.sol';
/**
* @title Increase cbBTC Supply Caps
* @author ACI
* - Snapshot: Direct-to-AIP
* - Discussion: https://governance.aave.com/t/arfc-increase-cbbtc-supply-caps-on-aave-v3-ethereum-market-and-base/19304
*/
contract AaveV3Base_IncreaseCbBTCSupplyCaps_20241004 is AaveV3PayloadBase {
function capsUpdates() public pure override returns (IAaveV3ConfigEngine.CapsUpdate[] memory) {
IAaveV3ConfigEngine.CapsUpdate[] memory capsUpdate = new IAaveV3ConfigEngine.CapsUpdate[](1);

capsUpdate[0] = IAaveV3ConfigEngine.CapsUpdate({
asset: AaveV3BaseAssets.cbBTC_UNDERLYING,
supplyCap: 5_000,
borrowCap: EngineFlags.KEEP_CURRENT
});

return capsUpdate;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import {AaveV3Base} from 'aave-address-book/AaveV3Base.sol';

import 'forge-std/Test.sol';
import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/src/ProtocolV3TestBase.sol';
import {AaveV3Base_IncreaseCbBTCSupplyCaps_20241004} from './AaveV3Base_IncreaseCbBTCSupplyCaps_20241004.sol';

/**
* @dev Test for AaveV3Base_IncreaseCbBTCSupplyCaps_20241004
* command: FOUNDRY_PROFILE=base forge test --match-path=src/20241004_Multi_IncreaseCbBTCSupplyCaps/AaveV3Base_IncreaseCbBTCSupplyCaps_20241004.t.sol -vv
*/
contract AaveV3Base_IncreaseCbBTCSupplyCaps_20241004_Test is ProtocolV3TestBase {
AaveV3Base_IncreaseCbBTCSupplyCaps_20241004 internal proposal;

function setUp() public {
vm.createSelectFork(vm.rpcUrl('base'), 20884619);
proposal = new AaveV3Base_IncreaseCbBTCSupplyCaps_20241004();
}

/**
* @dev executes the generic test suite including e2e and config snapshots
*/
function test_defaultProposalExecution() public {
defaultTest('AaveV3Base_IncreaseCbBTCSupplyCaps_20241004', AaveV3Base.POOL, address(proposal));
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import {AaveV3EthereumAssets} from 'aave-address-book/AaveV3Ethereum.sol';
import {AaveV3PayloadEthereum} from 'aave-helpers/src/v3-config-engine/AaveV3PayloadEthereum.sol';
import {EngineFlags} from 'aave-v3-origin/contracts/extensions/v3-config-engine/EngineFlags.sol';
import {IAaveV3ConfigEngine} from 'aave-v3-origin/contracts/extensions/v3-config-engine/IAaveV3ConfigEngine.sol';
/**
* @title Increase cbBTC Supply Caps
* @author ACI
* - Snapshot: Direct AIP
* - Discussion: https://governance.aave.com/t/arfc-increase-cbbtc-supply-caps-on-aave-v3-ethereum-market-and-base/19304
*/
contract AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004 is AaveV3PayloadEthereum {
function capsUpdates() public pure override returns (IAaveV3ConfigEngine.CapsUpdate[] memory) {
IAaveV3ConfigEngine.CapsUpdate[] memory capsUpdate = new IAaveV3ConfigEngine.CapsUpdate[](1);

capsUpdate[0] = IAaveV3ConfigEngine.CapsUpdate({
asset: AaveV3EthereumAssets.cbBTC_UNDERLYING,
supplyCap: 10_000,
borrowCap: EngineFlags.KEEP_CURRENT
});

return capsUpdate;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import {AaveV3Ethereum} from 'aave-address-book/AaveV3Ethereum.sol';

import 'forge-std/Test.sol';
import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/src/ProtocolV3TestBase.sol';
import {AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004} from './AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004.sol';

/**
* @dev Test for AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004
* command: FOUNDRY_PROFILE=mainnet forge test --match-path=src/20241004_Multi_IncreaseCbBTCSupplyCaps/AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004.t.sol -vv
*/
contract AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004_Test is ProtocolV3TestBase {
AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004 internal proposal;

function setUp() public {
vm.createSelectFork(vm.rpcUrl('mainnet'), 20934819);
proposal = new AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004();
}

/**
* @dev executes the generic test suite including e2e and config snapshots
*/
function test_defaultProposalExecution() public {
defaultTest(
'AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004',
AaveV3Ethereum.POOL,
address(proposal)
);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
title: "Increase cbBTC Supply Caps"
author: "ACI"
discussions: "https://governance.aave.com/t/arfc-increase-cbbtc-supply-caps-on-aave-v3-ethereum-market-and-base/19304"
---

## Simple Summary

This proposal aims to increase the supply caps for cbBTC on both the Aave V3 Ethereum Market and BASE. The increase in supply caps will allow for greater utilization of cbBTC within the Aave ecosystem, potentially improving liquidity and capital efficiency.

## Motivation

The current supply caps for cbBTC on Aave V3 Ethereum and BASE markets may be limiting the potential growth and utilization of this asset, as we’ve seen demand and current Supply Caps not being enough to allocate it.

By increasing these caps, we can:

1. Enhance liquidity for cbBTC within the Aave protocol.
2. Provide more opportunities for users to supply and borrow cbBTC.
3. Potentially attract more users and capital to the Aave ecosystem.

## Specification

Ticker: cbBTC (cbBTC)

Mainnet: 0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf

Base: 0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf

We propose to Increase Supply Caps on Mainnet to 10000 cbBTC and to Increase Supply Caps on Base to 5000 cbBTC.

| cbBTC | Ethereum V3 | Base |
| -------------------- | ----------- | ---------- |
| Increase Supply Caps | 10000 cbBTC | 5000 cbBTC |

## References

- Implementation: [AaveV3Ethereum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20241004_Multi_IncreaseCbBTCSupplyCaps/AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004.sol), [AaveV3Base](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20241004_Multi_IncreaseCbBTCSupplyCaps/AaveV3Base_IncreaseCbBTCSupplyCaps_20241004.sol)
- Tests: [AaveV3Ethereum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20241004_Multi_IncreaseCbBTCSupplyCaps/AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004.t.sol), [AaveV3Base](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20241004_Multi_IncreaseCbBTCSupplyCaps/AaveV3Base_IncreaseCbBTCSupplyCaps_20241004.t.sol)
- Snapshot: Direct AIP
- [Discussion](https://governance.aave.com/t/arfc-increase-cbbtc-supply-caps-on-aave-v3-ethereum-market-and-base/19304)

## Copyright

Copyright and related rights waived via [CC0](https://creativecommons.org/publicdomain/zero/1.0/).
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import {GovV3Helpers, IPayloadsControllerCore, PayloadsControllerUtils} from 'aave-helpers/src/GovV3Helpers.sol';
import {GovernanceV3Ethereum} from 'aave-address-book/GovernanceV3Ethereum.sol';
import {EthereumScript, BaseScript} from 'solidity-utils/contracts/utils/ScriptUtils.sol';
import {AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004} from './AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004.sol';
import {AaveV3Base_IncreaseCbBTCSupplyCaps_20241004} from './AaveV3Base_IncreaseCbBTCSupplyCaps_20241004.sol';

/**
* @dev Deploy Ethereum
* deploy-command: make deploy-ledger contract=src/20241004_Multi_IncreaseCbBTCSupplyCaps/IncreaseCbBTCSupplyCaps_20241004.s.sol:DeployEthereum chain=mainnet
* verify-command: FOUNDRY_PROFILE=mainnet npx catapulta-verify -b broadcast/IncreaseCbBTCSupplyCaps_20241004.s.sol/1/run-latest.json
*/
contract DeployEthereum is EthereumScript {
function run() external broadcast {
// deploy payloads
address payload0 = GovV3Helpers.deployDeterministic(
type(AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004).creationCode
);

// compose action
IPayloadsControllerCore.ExecutionAction[]
memory actions = new IPayloadsControllerCore.ExecutionAction[](1);
actions[0] = GovV3Helpers.buildAction(payload0);

// register action at payloadsController
GovV3Helpers.createPayload(actions);
}
}

/**
* @dev Deploy Base
* deploy-command: make deploy-ledger contract=src/20241004_Multi_IncreaseCbBTCSupplyCaps/IncreaseCbBTCSupplyCaps_20241004.s.sol:DeployBase chain=base
* verify-command: FOUNDRY_PROFILE=base npx catapulta-verify -b broadcast/IncreaseCbBTCSupplyCaps_20241004.s.sol/8453/run-latest.json
*/
contract DeployBase is BaseScript {
function run() external broadcast {
// deploy payloads
address payload0 = GovV3Helpers.deployDeterministic(
type(AaveV3Base_IncreaseCbBTCSupplyCaps_20241004).creationCode
);

// compose action
IPayloadsControllerCore.ExecutionAction[]
memory actions = new IPayloadsControllerCore.ExecutionAction[](1);
actions[0] = GovV3Helpers.buildAction(payload0);

// register action at payloadsController
GovV3Helpers.createPayload(actions);
}
}

/**
* @dev Create Proposal
* command: make deploy-ledger contract=src/20241004_Multi_IncreaseCbBTCSupplyCaps/IncreaseCbBTCSupplyCaps_20241004.s.sol:CreateProposal chain=mainnet
*/
contract CreateProposal is EthereumScript {
function run() external {
// create payloads
PayloadsControllerUtils.Payload[] memory payloads = new PayloadsControllerUtils.Payload[](2);

// compose actions for validation
IPayloadsControllerCore.ExecutionAction[]
memory actionsEthereum = new IPayloadsControllerCore.ExecutionAction[](1);
actionsEthereum[0] = GovV3Helpers.buildAction(
type(AaveV3Ethereum_IncreaseCbBTCSupplyCaps_20241004).creationCode
);
payloads[0] = GovV3Helpers.buildMainnetPayload(vm, actionsEthereum);

IPayloadsControllerCore.ExecutionAction[]
memory actionsBase = new IPayloadsControllerCore.ExecutionAction[](1);
actionsBase[0] = GovV3Helpers.buildAction(
type(AaveV3Base_IncreaseCbBTCSupplyCaps_20241004).creationCode
);
payloads[1] = GovV3Helpers.buildBasePayload(vm, actionsBase);

// create proposal
vm.startBroadcast();
GovV3Helpers.createProposal(
vm,
payloads,
GovernanceV3Ethereum.VOTING_PORTAL_ETH_POL,
GovV3Helpers.ipfsHashFile(
vm,
'src/20241004_Multi_IncreaseCbBTCSupplyCaps/IncreaseCbBTCSupplyCaps.md'
)
);
}
}
24 changes: 24 additions & 0 deletions src/20241004_Multi_IncreaseCbBTCSupplyCaps/config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import {ConfigFile} from '../../generator/types';
export const config: ConfigFile = {
rootOptions: {
pools: ['AaveV3Ethereum', 'AaveV3Base'],
title: 'Increase cbBTC Supply Caps',
shortName: 'IncreaseCbBTCSupplyCaps',
date: '20241004',
author: 'ACI',
discussion:
'https://governance.aave.com/t/arfc-increase-cbbtc-supply-caps-on-aave-v3-ethereum-market-and-base/19304',
snapshot: 'Direct AIP',
votingNetwork: 'POLYGON',
},
poolOptions: {
AaveV3Ethereum: {
configs: {CAPS_UPDATE: [{asset: 'cbBTC', supplyCap: '10000', borrowCap: ''}]},
cache: {blockNumber: 20934819},
},
AaveV3Base: {
configs: {CAPS_UPDATE: [{asset: 'cbBTC', supplyCap: '5000', borrowCap: ''}]},
cache: {blockNumber: 20884619},
},
},
};
Loading