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

BIP-436: Allocate BAL Liquidity to Base & Arbitrum axlBAL/BAL pools f… #518

Merged
merged 4 commits into from
Sep 23, 2023
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
65 changes: 65 additions & 0 deletions BIPs/2023-W38/BIP-436A.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
{
"version": "1.0",
"chainId": "1",
"createdAt": 1695236194130,
"meta": {
"name": "Transactions Batch",
"description": "",
"txBuilderVersion": "1.16.2",
"createdFromSafeAddress": "0xc38c5f97B34E175FFd35407fc91a937300E33860",
"createdFromOwnerAddress": "",
"checksum": "0x2fbaa0caea9a000f8a84bdda1024c4f3ee9d8bc52621289798cd2a6fe1e30049"
},
"transactions": [
{
"to": "0x5DbAd78818D4c8958EfF2d5b95b28385A22113Cd",
"value": "0",
"data": null,
"contractMethod": {
"inputs": [
{
"name": "gauge",
"type": "address",
"internalType": "address"
},
{
"name": "gaugeType",
"type": "string",
"internalType": "string"
}
],
"name": "addGauge",
"payable": false
},
"contractInputsValues": {
"gauge": "0x67313e858fB87Cc4b30AD56b6B461D7450738950",
"gaugeType": "Base"
}
},
{
"to": "0x5DbAd78818D4c8958EfF2d5b95b28385A22113Cd",
"value": "0",
"data": null,
"contractMethod": {
"inputs": [
{
"name": "gauge",
"type": "address",
"internalType": "address"
},
{
"name": "gaugeType",
"type": "string",
"internalType": "string"
}
],
"name": "addGauge",
"payable": false
},
"contractInputsValues": {
"gauge": "0x66E9A9d0a35C6a368A66A432AbD9dB4Fb248f212",
"gaugeType": "Arbitrum"
}
}
]
}
16 changes: 16 additions & 0 deletions BIPs/2023-W38/BIP-436A.report.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
File name: BIPs/2023-W38/BIP-436A.json
COMMIT: `60d1c5aefd77768fbdd82335ca7d1db428097e76`
CHAIN(S): `arbitrum, base`
```
+-----------------------+---------------------------------------------------------------------+---------------------------+--------------------------------------------+------------------------------------------------------------+-------------------------------------------------+---------+------------+
| function | pool_id_and_address | symbol_and_info | gauge_address_and_info | tokens | rate_providers | bip | tx_index |
+=======================+=====================================================================+===========================+============================================+============================================================+=================================================+=========+============+
| GaugeAdderV4/addGauge | 0x58f2110b61f97fd6b9200b038d92f17c722a5a3300000000000000000000004f | axlBAL/BAL | 0x67313e858fB87Cc4b30AD56b6B461D7450738950 | "axlBAL(0x11C1879227D463b60db18C17c20aE739aE8E961a)", | "0x0000000000000000000000000000000000000000", | BIP-436 | 0 |
| | pool_address: 0x58F2110B61F97fD6B9200b038d92f17c722A5A33 | fee: 0.05, a-factor: 5000 | Style: L0 sidechain, cap: 100.0% | "BAL(0x4158734D47Fc9692176B5085E0F52ee0Da5d47F1)", | "0x0000000000000000000000000000000000000000", | | |
| | | | | "axlBAL/BAL(0x58F2110B61F97fD6B9200b038d92f17c722A5A33)" | "0x0000000000000000000000000000000000000000" | | |
+-----------------------+---------------------------------------------------------------------+---------------------------+--------------------------------------------+------------------------------------------------------------+-------------------------------------------------+---------+------------+
| GaugeAdderV4/addGauge | 0x3f09c77b19ad8bb527355ec32d5ce98421fec2e30000000000000000000004b2 | axlBAL/BAL | 0x66E9A9d0a35C6a368A66A432AbD9dB4Fb248f212 | "BAL(0x040d1EdC9569d4Bab2D15287Dc5A4F10F56a56B8)", | "0x0000000000000000000000000000000000000000", | BIP-436 | 1 |
| | pool_address: 0x3f09C77B19AD8Bb527355ec32d5ce98421fec2E3 | fee: 0.05, a-factor: 5000 | Style: L0 sidechain, cap: 100.0% | "axlBAL(0x11C1879227D463b60db18C17c20aE739aE8E961a)", | "0x0000000000000000000000000000000000000000", | | |
| | | | | "axlBAL/BAL(0x3f09C77B19AD8Bb527355ec32d5ce98421fec2E3)" | "0x0000000000000000000000000000000000000000" | | |
+-----------------------+---------------------------------------------------------------------+---------------------------+--------------------------------------------+------------------------------------------------------------+-------------------------------------------------+---------+------------+
```
40 changes: 40 additions & 0 deletions BIPs/2023-W38/BIP-436B.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"version": "1.0",
"chainId": "1",
"createdAt": 1695236356608,
"meta": {
"name": "Transactions Batch",
"description": "",
"txBuilderVersion": "1.16.2",
"createdFromSafeAddress": "0x10A19e7eE7d7F8a52822f6817de8ea18204F2e4f",
"createdFromOwnerAddress": "",
"checksum": "0x07a161f638471eb74468f6089e3fba601cb30357e0a2f4331a80df3e97143231"
},
"transactions": [
{
"to": "0xba100000625a3754423978a60c9317c58a424e3D",
"value": "0",
"data": null,
"contractMethod": {
"inputs": [
{
"name": "recipient",
"type": "address",
"internalType": "address"
},
{
"name": "amount",
"type": "uint256",
"internalType": "uint256"
}
],
"name": "transfer",
"payable": false
},
"contractInputsValues": {
"recipient": "0xc38c5f97B34E175FFd35407fc91a937300E33860",
"amount": "40000000000000000000000"
}
}
]
}
10 changes: 10 additions & 0 deletions BIPs/2023-W38/BIP-436B.report.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
File name: BIPs/2023-W38/BIP-436B.json
COMMIT: `60d1c5aefd77768fbdd82335ca7d1db428097e76`
CHAIN(S): `mainnet`
```
+------------+------------------------------------------------+-------------+----------------------------------------+---------+------------+
| function | token_symbol | recipient | amount | bip | tx_index |
+============+================================================+=============+========================================+=========+============+
| transfer | BAL:0xba100000625a3754423978a60c9317c58a424e3D | N/A:None | 40000.0 (RAW: 40000000000000000000000) | BIP-436 | 0 |
+------------+------------------------------------------------+-------------+----------------------------------------+---------+------------+
```
4 changes: 3 additions & 1 deletion action-scripts/brownie/scripts/report_gauges.py
Original file line number Diff line number Diff line change
Expand Up @@ -314,13 +314,15 @@ def _parse_transfer(transaction: dict, **kwargs) -> Optional[dict]:
# Get input values
token = Contract(transaction["to"])
recipient_address = transaction["contractInputsValues"].get("to")
if Web3.isAddress(recipient_address):
recipient_address = Web3.toChecksumAddress(recipient_address)
raw_amount = (
transaction["contractInputsValues"].get("amount")
or transaction["contractInputsValues"].get("value")
)
amount = int(raw_amount) / 10 ** token.decimals() if raw_amount else "N/A"
symbol = token.symbol()
recipient_name = ADDR_BOOK.reversebook.get(Web3.toChecksumAddress(recipient_address), "N/A")
recipient_name = ADDR_BOOK.reversebook.get(recipient_address, "N/A")
return {
"function": "transfer",
"chain": chain_name.replace("-main", "") if chain_name else "mainnet",
Expand Down