Skip to content

Commit

Permalink
⛓ Add chain Manta Pacific
Browse files Browse the repository at this point in the history
  • Loading branch information
coccoinomane committed Feb 23, 2024
1 parent 1714803 commit 9e206f9
Show file tree
Hide file tree
Showing 5 changed files with 84 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ w3op = {cmd = "w3op", help = "Run the CLI in dev mode, on Optimism OP chain"}
w3scroll = {cmd = "w3scroll", help = "Run the CLI in dev mode, on Scroll ZK chain"}
w3base = {cmd = "w3base", help = "Run the CLI in dev mode, on Base chain"}
w3zkf = {cmd = "w3zkf", help = "Run the CLI in dev mode, on ZKFair chain"}
w3manta = {cmd = "w3manta", help = "Run the CLI in dev mode, on Manta Pacific chain"}

test = "ape test tests --network ::foundry"
test_verbose = "ape test tests -s --network ::foundry"
Expand Down Expand Up @@ -83,6 +84,7 @@ w3op = "web3cli.main:w3op"
w3scroll = "web3cli.main:w3scroll"
w3base = "web3cli.main:w3base"
w3zkf = "web3cli.main:w3zkf"
w3manta = "web3cli.main:w3manta"

[project.urls]
homepage = "https://github.com/coccoinomane/web3cli"
Expand Down
5 changes: 5 additions & 0 deletions src/web3cli/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -252,3 +252,8 @@ def w3base() -> None:
def w3zkf() -> None:
"""Shorthand command to use ZKFair chain"""
main(lambda a: override_arg(a, "chain", "zkf"))


def w3manta() -> None:
"""Shorthand command to use Manta Pacific chain"""
main(lambda a: override_arg(a, "chain", "manta"))
15 changes: 15 additions & 0 deletions src/web3core/seeds/chain_seeds.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,20 @@
],
}

manta: ChainFields = {
"name": "manta",
"desc": "Manta Pacific Mainnet",
"chain_id": 169,
"coin": "ETH",
"tx_type": 0,
"middlewares": "",
"rpcs": [
{
"url": "https://pacific-rpc.manta.network/http",
}
],
}

"""
_ _ _ _
| | ___ __ __ _ | | __ | |_ __ _ (_) _ _ ___
Expand Down Expand Up @@ -271,6 +285,7 @@
scroll,
base,
zkf,
manta,
# Local
ganache,
anvil,
Expand Down
2 changes: 2 additions & 0 deletions src/web3core/seeds/contract_seeds.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
erat_contract_seeds,
eth_contract_seeds,
gno_contract_seeds,
manta_contract_seeds,
op_contract_seeds,
scroll_contract_seeds,
zkf_contract_seeds,
Expand All @@ -27,4 +28,5 @@
+ scroll_contract_seeds.all
+ base_contract_seeds.all
+ zkf_contract_seeds.all
+ manta_contract_seeds.all
)
60 changes: 60 additions & 0 deletions src/web3core/seeds/contracts/manta_contract_seeds.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
from web3core.models.types import ContractFields

weth: ContractFields = {
"name": "weth",
"desc": "Wrapped ETH",
"type": "weth",
"address": "0x0Dc808adcE2099A9F62AA87D9670745AbA741746",
"chain": "manta",
}

manta: ContractFields = {
"name": "manta",
"desc": "Manta token",
"type": "erc20",
"address": "0x95CeF13441Be50d20cA4558CC0a27B601aC544E5",
"chain": "manta",
}

usdc: ContractFields = {
"name": "usdc",
"desc": "USDC Circle token",
"type": "erc20",
"address": "0xb73603C5d87fA094B7314C74ACE2e64D165016fb",
"chain": "manta",
}

usdt: ContractFields = {
"name": "usdt",
"desc": "USDT Tether token",
"type": "erc20",
"address": "0xf417F5A458eC102B90352F697D6e2Ac3A3d2851f",
"chain": "manta",
}

dai: ContractFields = {
"name": "dai",
"desc": "DAI Maker stablecoin",
"type": "erc20",
"address": "0x1c466b9371f8aBA0D7c458bE10a62192Fcb8Aa71",
"chain": "manta",
}

wbtc: ContractFields = {
"name": "wbtc",
"desc": "Wrapped BTC token",
"type": "erc20",
"address": "0x305E88d809c9DC03179554BFbf85Ac05Ce8F18d6",
"chain": "manta",
}

stone: ContractFields = {
"name": "stone",
"desc": "STONE token Manta",
"type": "erc20",
"address": "0xEc901DA9c68E90798BbBb74c11406A32A70652C3",
"chain": "manta",
}


all = [weth, manta, usdc, usdt, dai, wbtc, stone]

0 comments on commit 9e206f9

Please sign in to comment.