web3-wizzard-lib 0.0.2__py3-none-any.whl → 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- web3_wizzard_lib/core/modules/linea_appeal.py +69 -52
- web3_wizzard_lib/core/modules/stargate/farming.py +1 -1
- web3_wizzard_lib/core/utils/ai_utils.py +45 -0
- web3_wizzard_lib/core/utils/benchmark_utils.py +12 -0
- web3_wizzard_lib/core/utils/module_memory.py +26 -0
- web3_wizzard_lib-0.1.0.data/data/requirements.txt +1 -0
- {web3_wizzard_lib-0.0.2.dist-info → web3_wizzard_lib-0.1.0.dist-info}/METADATA +9 -4
- {web3_wizzard_lib-0.0.2.dist-info → web3_wizzard_lib-0.1.0.dist-info}/RECORD +10 -294
- {web3_wizzard_lib-0.0.2.dist-info → web3_wizzard_lib-0.1.0.dist-info}/WHEEL +1 -1
- core/__init__.py +0 -1
- core/contract/__init__.py +0 -0
- core/contract/aavecontract.py +0 -36
- core/contract/alienswap_contract.py +0 -21
- core/contract/arena_games_contract.py +0 -16
- core/contract/basiliskcontract.py +0 -58
- core/contract/bilinear_contract.py +0 -22
- core/contract/bungee.py +0 -33
- core/contract/coredao_contract.py +0 -35
- core/contract/coredao_from_contract.py +0 -40
- core/contract/dmail_send_mail.py +0 -18
- core/contract/empty_nft.py +0 -18
- core/contract/era_name.py +0 -23
- core/contract/eralendcontract.py +0 -34
- core/contract/eth_scroll_bridge_contract.py +0 -25
- core/contract/frog_war_contract.py +0 -48
- core/contract/horizondex_quoter.py +0 -14
- core/contract/horizondex_router.py +0 -91
- core/contract/imagine_contract.py +0 -18
- core/contract/izumi.py +0 -63
- core/contract/kreatorland_contract.py +0 -21
- core/contract/l0_claim.py +0 -254
- core/contract/l2_telegraph.py +0 -21
- core/contract/layerbank_price.py +0 -18
- core/contract/layerbank_token.py +0 -29
- core/contract/layerbankcontract.py +0 -59
- core/contract/linea_day_2_contract.py +0 -19
- core/contract/linea_day_3_contract.py +0 -55
- core/contract/linea_ens_names_contract.py +0 -55
- core/contract/lineaswaprouter.py +0 -52
- core/contract/maverick_multicall.py +0 -52
- core/contract/mendi_finance_contract.py +0 -11
- core/contract/mendi_token.py +0 -25
- core/contract/merkly_minter.py +0 -47
- core/contract/micro3_contract.py +0 -18
- core/contract/mute_router.py +0 -93
- core/contract/nidum_contract.py +0 -44
- core/contract/nile_contract.py +0 -60
- core/contract/nomis_attest_contract.py +0 -40
- core/contract/nomis_contract.py +0 -40
- core/contract/octomos.py +0 -31
- core/contract/odos.py +0 -104
- core/contract/omnisea.py +0 -29
- core/contract/orbiter_starknet.py +0 -30
- core/contract/pancake_pool.py +0 -19
- core/contract/pancake_quoter.py +0 -20
- core/contract/pancake_router.py +0 -72
- core/contract/rage_claim.py +0 -24
- core/contract/reactor_fusion_contract.py +0 -78
- core/contract/readon_contract.py +0 -19
- core/contract/rubyscore_contract.py +0 -31
- core/contract/satoshi_universe_contract.py +0 -29
- core/contract/scroll_bridge_contract.py +0 -24
- core/contract/scroll_canvas_mint_contract.py +0 -26
- core/contract/scroll_oracle.py +0 -11
- core/contract/snap_contract.py +0 -16
- core/contract/social_scan_contract.py +0 -20
- core/contract/stargate_farming.py +0 -37
- core/contract/stargate_router.py +0 -84
- core/contract/stargate_router_eth.py +0 -41
- core/contract/stargate_token_pool.py +0 -46
- core/contract/stargate_v2_contract.py +0 -36
- core/contract/syncswap_classic_pool.py +0 -15
- core/contract/syncswap_classic_pool_factory.py +0 -15
- core/contract/syncswap_pool.py +0 -25
- core/contract/syncswap_router.py +0 -123
- core/contract/tavaera_id.py +0 -18
- core/contract/tavaera_mint.py +0 -17
- core/contract/townstory_bonus_contract.py +0 -19
- core/contract/townstory_contract.py +0 -21
- core/contract/velocore_lens.py +0 -44
- core/contract/velocore_pool.py +0 -198
- core/contract/velocore_router.py +0 -80
- core/contract/woofi_swap.py +0 -29
- core/contract/xy_finance_contract.py +0 -87
- core/contract/yoddlo_contract.py +0 -19
- core/contract/yuliverse_contract.py +0 -36
- core/contract/zebra_contract.py +0 -68
- core/contract/zerolend_contract.py +0 -34
- core/contract/zerolend_liq_contract.py +0 -20
- core/contract/zkdx_contract.py +0 -40
- core/contract/zkdx_data.py +0 -14
- core/contract/zks.py +0 -24
- core/modules/__init__.py +0 -0
- core/modules/ads_import_proxy.py +0 -52
- core/modules/airdrop_printer.py +0 -80
- core/modules/bank/__init__.py +0 -0
- core/modules/bank/aave.py +0 -25
- core/modules/bank/bank.py +0 -15
- core/modules/bank/bank_module.py +0 -99
- core/modules/bank/basilisk.py +0 -25
- core/modules/bank/eralend.py +0 -25
- core/modules/bank/layerbank.py +0 -116
- core/modules/bank/mendi_finance.py +0 -57
- core/modules/bank/reactorfusion.py +0 -25
- core/modules/bank/zerolend.py +0 -36
- core/modules/bridge/__init__.py +0 -0
- core/modules/bridge/bridge.py +0 -8
- core/modules/bridge/coredao_bridge_sub.py +0 -47
- core/modules/bridge/orbiter_sub.py +0 -112
- core/modules/bridge/scroll_bridge_sub.py +0 -42
- core/modules/bridge/stargate_v2_sub.py +0 -74
- core/modules/bridge_module.py +0 -47
- core/modules/bungee.py +0 -109
- core/modules/cex_sender.py +0 -60
- core/modules/cex_subaccount_transfer.py +0 -34
- core/modules/cex_withdraw.py +0 -91
- core/modules/claimer.py +0 -45
- core/modules/claims/__init__.py +0 -0
- core/modules/claims/layerzero_claimer.py +0 -64
- core/modules/claims/rabby_claimer.py +0 -81
- core/modules/concrete_swap.py +0 -97
- core/modules/coredao_bridge.py +0 -32
- core/modules/coredao_bridge_auto.py +0 -39
- core/modules/debank_checker.py +0 -90
- core/modules/dmail.py +0 -54
- core/modules/erc20_balance.py +0 -42
- core/modules/intract/__init__.py +0 -0
- core/modules/intract/intract_api.py +0 -212
- core/modules/intract/utils.py +0 -81
- core/modules/intract_claim.py +0 -104
- core/modules/layer_2_20.py +0 -65
- core/modules/lending_module.py +0 -134
- core/modules/linea_appeal.py +0 -70
- core/modules/linea_poh_lxp.py +0 -64
- core/modules/liquidity/__init__.py +0 -0
- core/modules/liquidity/nile_pool.py +0 -64
- core/modules/liquidity/pool.py +0 -16
- core/modules/liquidity/syncswap_pool.py +0 -61
- core/modules/liquidity/velocore_pool.py +0 -55
- core/modules/liquidity/zerolend_liquidity.py +0 -26
- core/modules/liquidity_pool.py +0 -60
- core/modules/merkly_refuel.py +0 -87
- core/modules/modules.py +0 -4
- core/modules/nft/__init__.py +0 -0
- core/modules/nft/abbys_world.py +0 -22
- core/modules/nft/acg_worlds.py +0 -25
- core/modules/nft/alienswap_linea.py +0 -22
- core/modules/nft/arena_games.py +0 -22
- core/modules/nft/asmatch.py +0 -22
- core/modules/nft/battlemon.py +0 -25
- core/modules/nft/bilinear.py +0 -22
- core/modules/nft/bitavatar.py +0 -25
- core/modules/nft/culture_satoshi_universe.py +0 -24
- core/modules/nft/efrogs.py +0 -26
- core/modules/nft/empty_nft.py +0 -22
- core/modules/nft/era_domain.py +0 -42
- core/modules/nft/frog_war.py +0 -22
- core/modules/nft/frog_war_bonus.py +0 -22
- core/modules/nft/gamerboom.py +0 -25
- core/modules/nft/gamerboom_bonus.py +0 -26
- core/modules/nft/imagine.py +0 -32
- core/modules/nft/kreatorland_module.py +0 -35
- core/modules/nft/l2_telegraph_module.py +0 -22
- core/modules/nft/layer3_meta.py +0 -25
- core/modules/nft/linea_culture_2_2_linus.py +0 -24
- core/modules/nft/linea_culture_2_3_yooldo.py +0 -24
- core/modules/nft/linea_culture_2_4_frogwar.py +0 -24
- core/modules/nft/linea_culture_2_5_acg.py +0 -25
- core/modules/nft/linea_culture_2_6_ascend_the_end.py +0 -25
- core/modules/nft/linea_culture_3_1_ascend_the_end.py +0 -25
- core/modules/nft/linea_culture_3_2_sending_me.py +0 -25
- core/modules/nft/linea_culture_3_3_townstory.py +0 -25
- core/modules/nft/linea_culture_3_4_daniele.py +0 -25
- core/modules/nft/linea_culture_3_5_demmortal.py +0 -25
- core/modules/nft/linea_culture_3_6_foxy.py +0 -25
- core/modules/nft/linea_culture_4_1_coop_records.py +0 -60
- core/modules/nft/linea_culture_4_2_borja_moskv.py +0 -65
- core/modules/nft/linea_culture_4_2_borja_moskv_approve.py +0 -27
- core/modules/nft/linea_culture_4_3_fruit.py +0 -66
- core/modules/nft/linea_culture_4_4_fruit_crux.py +0 -67
- core/modules/nft/linea_culture_4_5_forbidden_fruit.py +0 -67
- core/modules/nft/linea_culture_4_6_laurent.py +0 -67
- core/modules/nft/linea_culture_day2.py +0 -20
- core/modules/nft/linea_culture_day3.py +0 -20
- core/modules/nft/linea_ens_names.py +0 -107
- core/modules/nft/lucky_cat.py +0 -25
- core/modules/nft/merkly_minter_module.py +0 -22
- core/modules/nft/micro3.py +0 -23
- core/modules/nft/mint_2048.py +0 -28
- core/modules/nft/nft_submodule.py +0 -16
- core/modules/nft/nidum.py +0 -87
- core/modules/nft/nidum_bonus.py +0 -23
- core/modules/nft/nomis.py +0 -64
- core/modules/nft/nomis_attest.py +0 -66
- core/modules/nft/nouns.py +0 -27
- core/modules/nft/octomos.py +0 -32
- core/modules/nft/omnisea.py +0 -33
- core/modules/nft/omnizone.py +0 -25
- core/modules/nft/orbiter_claim.py +0 -87
- core/modules/nft/readon.py +0 -30
- core/modules/nft/rubyscore.py +0 -45
- core/modules/nft/sarubol.py +0 -22
- core/modules/nft/satoshi_universe.py +0 -22
- core/modules/nft/scroll_canvas_attest_year_badge.py +0 -35
- core/modules/nft/scroll_canvas_mint.py +0 -51
- core/modules/nft/sign.py +0 -32
- core/modules/nft/snap.py +0 -25
- core/modules/nft/snap_bonus.py +0 -31
- core/modules/nft/social_scan.py +0 -22
- core/modules/nft/sub_module.py +0 -8
- core/modules/nft/tavaera.py +0 -30
- core/modules/nft/townstory.py +0 -75
- core/modules/nft/townstory_bonus.py +0 -45
- core/modules/nft/trusta_reputation.py +0 -48
- core/modules/nft/trustaa_poh.py +0 -49
- core/modules/nft/uber_poh.py +0 -24
- core/modules/nft/wizards_of_linea.py +0 -26
- core/modules/nft/yoddlo.py +0 -22
- core/modules/nft/yuliverse.py +0 -22
- core/modules/nft/zace.py +0 -25
- core/modules/nft/zks_domain.py +0 -41
- core/modules/nft_minter.py +0 -107
- core/modules/orbiter.py +0 -39
- core/modules/orbiter_checker.py +0 -26
- core/modules/rage.py +0 -54
- core/modules/scroll_bridge.py +0 -45
- core/modules/sell_all.py +0 -51
- core/modules/sleep_module.py +0 -25
- core/modules/smart_contract_deployment.py +0 -37
- core/modules/stargate/__init__.py +0 -0
- core/modules/stargate/auto_bridge.py +0 -91
- core/modules/stargate/bridge.py +0 -38
- core/modules/stargate/bridge_eth.py +0 -59
- core/modules/stargate/bridge_tokens.py +0 -48
- core/modules/stargate/classic_bridge.py +0 -34
- core/modules/stargate/farming.py +0 -163
- core/modules/stargate/l0_data.py +0 -10
- core/modules/stargate/pool.py +0 -74
- core/modules/stargate/stargate_balance_utils.py +0 -25
- core/modules/stargate/stargate_gas_checker.py +0 -68
- core/modules/swap/__init__.py +0 -1
- core/modules/swap/horizondex.py +0 -38
- core/modules/swap/izumi.py +0 -41
- core/modules/swap/lineaswap.py +0 -34
- core/modules/swap/maverick.py +0 -66
- core/modules/swap/mute.py +0 -39
- core/modules/swap/odos.py +0 -58
- core/modules/swap/one_inch.py +0 -58
- core/modules/swap/pancake.py +0 -41
- core/modules/swap/swap_facade.py +0 -10
- core/modules/swap/syncswap.py +0 -62
- core/modules/swap/velocore.py +0 -40
- core/modules/swap/woofi.py +0 -38
- core/modules/swap/xy_finance.py +0 -43
- core/modules/swap/zebra.py +0 -32
- core/modules/warm_up.py +0 -98
- core/modules/wrapping.py +0 -74
- core/modules/zkdx.py +0 -63
- tests/core/__init__.py +0 -0
- tests/core/contracts/__init__.py +0 -0
- tests/core/contracts/test_horizondex_quoter.py +0 -37
- tests/core/contracts/test_uniswap_quoter.py +0 -35
- tests/core/contracts/test_velocore_lens.py +0 -67
- tests/core/contracts/test_velocore_pool.py +0 -57
- tests/core/modules/__init__.py +0 -67
- tests/core/modules/swap/__init__.py +0 -0
- tests/core/modules/swap/test_horizondex.py +0 -37
- tests/core/modules/swap/test_lineaswap.py +0 -28
- tests/core/modules/swap/test_maverick.py +0 -31
- tests/core/modules/swap/test_mute.py +0 -29
- tests/core/modules/swap/test_odos.py +0 -36
- tests/core/modules/swap/test_pancake.py +0 -54
- tests/core/modules/swap/test_syncswap.py +0 -59
- tests/core/modules/swap/test_velocore.py +0 -33
- tests/core/modules/swap/test_woofi.py +0 -22
- tests/core/modules/test_bungee.py +0 -27
- tests/core/modules/test_concrete_swap.py +0 -62
- tests/core/modules/test_dmail.py +0 -41
- tests/core/modules/test_lending.py +0 -122
- tests/core/modules/test_nft.py +0 -32
- tests/core/modules/test_nft_minter.py +0 -30
- tests/core/modules/test_orbiter.py +0 -28
- tests/core/modules/test_sellall.py +0 -27
- tests/core/modules/test_send_to_cex.py +0 -27
- tests/core/modules/test_stargate_auto_bridge.py +0 -32
- tests/core/modules/test_stargate_bridge.py +0 -25
- tests/core/modules/test_stargate_farming.py +0 -108
- tests/core/modules/test_warmup.py +0 -78
- tests/core/modules/test_wrapping.py +0 -68
- tests/core/scenario/__init__.py +0 -0
- tests/core/scenario/module_0_test_config.py +0 -91
- tests/core/test_app.py +0 -19
- tests/core/test_config.py +0 -34
- web3_wizzard_lib/core/modules/modules.py +0 -27
- web3_wizzard_lib/core/modules/nft/sub_module.py +0 -8
- web3_wizzard_lib/core/modules/swap/swap_facade.py +0 -10
- web3_wizzard_lib-0.0.2.data/data/requirements.txt +0 -1
- {web3_wizzard_lib-0.0.2.dist-info → web3_wizzard_lib-0.1.0.dist-info}/top_level.txt +0 -0
core/modules/bank/layerbank.py
DELETED
@@ -1,116 +0,0 @@
|
|
1
|
-
from loguru import logger
|
2
|
-
from sybil_engine.data.contracts import get_contracts_for_chain
|
3
|
-
from sybil_engine.data.tokens import get_tokens_for_chain
|
4
|
-
from sybil_engine.domain.balance.tokens import Erc20Token
|
5
|
-
|
6
|
-
from web3_wizzard_lib.core.contract.layerbank_price import LayerBankPrice
|
7
|
-
from web3_wizzard_lib.core.contract.layerbank_token import LayerBankToken
|
8
|
-
from web3_wizzard_lib.core.contract.layerbankcontract import LayerBankContract
|
9
|
-
from web3_wizzard_lib.core.modules.bank.bank import Bank
|
10
|
-
|
11
|
-
|
12
|
-
class LayerBank(Bank):
|
13
|
-
app_name = 'LAYERBANK'
|
14
|
-
supported_chains = ['LINEA']
|
15
|
-
|
16
|
-
def __init__(self, chain, web3):
|
17
|
-
self.chain = chain
|
18
|
-
self.web3 = web3
|
19
|
-
self.layerbank = LayerBankContract(get_contracts_for_chain(chain)["LAYERBANK"], web3)
|
20
|
-
|
21
|
-
lbwstETH = get_tokens_for_chain(chain)['lbwstETH']
|
22
|
-
self.lbWstETHToken = LayerBankToken(lbwstETH, web3)
|
23
|
-
|
24
|
-
lbETH = get_tokens_for_chain(chain)['lbETH']
|
25
|
-
self.lbETHToken = LayerBankToken(lbETH, web3)
|
26
|
-
|
27
|
-
def supply(self, account, token):
|
28
|
-
token = LayerBankToken(get_tokens_for_chain(self.chain)[token], self.web3)
|
29
|
-
|
30
|
-
erc20_token = Erc20Token(self.chain, token, self.web3)
|
31
|
-
amount = erc20_token.balance(account)
|
32
|
-
|
33
|
-
if 25 * token.one_decimal() <= self.layerbank.account_liquidity_of(account)[0]:
|
34
|
-
logger.info("Already supplied over 25$ worth, skip this step")
|
35
|
-
return
|
36
|
-
|
37
|
-
if erc20_token.allowance(account, token.contract_address) < amount.wei:
|
38
|
-
erc20_token.approve(account, token.contract_address)
|
39
|
-
|
40
|
-
if amount.wei > 0:
|
41
|
-
if token.contract_address not in self.layerbank.market_list_of(account):
|
42
|
-
logger.info("Add support wstETH to LayerBank")
|
43
|
-
self.layerbank.enter_markets(account, token.contract_address)
|
44
|
-
|
45
|
-
logger.info(f"Supply {amount.log_line()}")
|
46
|
-
|
47
|
-
self.layerbank.supply(account, token.contract_address, amount.wei)
|
48
|
-
|
49
|
-
if 25 * token.one_decimal() > self.layerbank.account_liquidity_of(account)[0]:
|
50
|
-
raise Exception(
|
51
|
-
f"Not enough supply for 25$ borrow {self.layerbank.account_liquidity_of(account)[0] / token.one_decimal()}"
|
52
|
-
)
|
53
|
-
|
54
|
-
def borrow(self, account, token):
|
55
|
-
token = LayerBankToken(get_tokens_for_chain(self.chain)[token], self.web3)
|
56
|
-
|
57
|
-
layerbank_price = LayerBankPrice(get_contracts_for_chain(self.chain)["LAYERBANK_PRICE"], self.web3)
|
58
|
-
|
59
|
-
usd_collateral = self.layerbank.account_liquidity_of(account)[0]
|
60
|
-
eth_amount = (usd_collateral / layerbank_price.get_underlying_price(token.contract_address))
|
61
|
-
|
62
|
-
logger.info(f"Borrow {eth_amount} {token.symbol()}")
|
63
|
-
|
64
|
-
borrow_amount = int(
|
65
|
-
eth_amount * token.one_decimal() * token.one_decimal() / token.exchange_rate())
|
66
|
-
|
67
|
-
self.layerbank.borrow(
|
68
|
-
account,
|
69
|
-
token.contract_address,
|
70
|
-
borrow_amount
|
71
|
-
)
|
72
|
-
|
73
|
-
def repay_borrow(self, account, token):
|
74
|
-
token = LayerBankToken(get_tokens_for_chain(self.chain)[token], self.web3)
|
75
|
-
|
76
|
-
layerbank_price = LayerBankPrice(get_contracts_for_chain(self.chain)["LAYERBANK_PRICE"], self.web3)
|
77
|
-
|
78
|
-
borrowed_usdc = self.layerbank.account_liquidity_of(account)[2]
|
79
|
-
lbETHPrice = layerbank_price.get_underlying_price(token.contract_address)
|
80
|
-
ethAmount = int(
|
81
|
-
(
|
82
|
-
borrowed_usdc / lbETHPrice) * token.one_decimal() * token.one_decimal() / token.exchange_rate()
|
83
|
-
)
|
84
|
-
|
85
|
-
if 2 * token.one_decimal() > borrowed_usdc:
|
86
|
-
logger.info("Less than 2$ borrowed, skip")
|
87
|
-
return
|
88
|
-
|
89
|
-
logger.info(f"Repay Borrow {ethAmount / token.one_decimal()}")
|
90
|
-
self.layerbank.repay_borrow(account, token.contract_address, ethAmount)
|
91
|
-
|
92
|
-
def redeem(self, account, amount, token):
|
93
|
-
if token == 'ETH':
|
94
|
-
token = self.lbETHToken
|
95
|
-
elif token == 'wstETH':
|
96
|
-
token = self.lbWstETHToken
|
97
|
-
|
98
|
-
underlying_balance = self.get_deposit_amount(account, token)
|
99
|
-
|
100
|
-
if underlying_balance < 10000:
|
101
|
-
logger.info("Less than 0.001$ supplied, skip")
|
102
|
-
return
|
103
|
-
|
104
|
-
self.layerbank.redeem_token(
|
105
|
-
account,
|
106
|
-
token.contract_address,
|
107
|
-
int(underlying_balance * token.one_decimal() * 0.999 / token.exchange_rate())
|
108
|
-
)
|
109
|
-
|
110
|
-
def get_deposit_amount(self, account, token):
|
111
|
-
if token == 'ETH':
|
112
|
-
token = self.lbETHToken
|
113
|
-
elif token == 'wstETH':
|
114
|
-
token = self.lbWstETHToken
|
115
|
-
|
116
|
-
return token.underlying_balance_of(account)
|
@@ -1,57 +0,0 @@
|
|
1
|
-
from loguru import logger
|
2
|
-
from sybil_engine.data.tokens import get_tokens_for_chain
|
3
|
-
from sybil_engine.domain.balance.tokens import Erc20Token
|
4
|
-
|
5
|
-
from web3_wizzard_lib.core.contract.mendi_token import MendiTokenContract
|
6
|
-
from web3_wizzard_lib.core.modules.bank.bank import Bank
|
7
|
-
|
8
|
-
|
9
|
-
class MendiFinance(Bank):
|
10
|
-
app_name = 'MENDI_FINANCE'
|
11
|
-
supported_chains = ['LINEA']
|
12
|
-
|
13
|
-
def __init__(self, chain, web3):
|
14
|
-
self.chain = chain
|
15
|
-
self.web3 = web3
|
16
|
-
|
17
|
-
def supply(self, account, amount):
|
18
|
-
erc20 = Erc20Token(self.chain, amount.token, self.web3)
|
19
|
-
amount = erc20.balance(account)
|
20
|
-
|
21
|
-
me_token = f'me{amount.token}'
|
22
|
-
mendi_token_address = get_tokens_for_chain(self.chain)[me_token]
|
23
|
-
|
24
|
-
logger.info(f"Mendi supply {amount} {amount.token}")
|
25
|
-
|
26
|
-
if erc20.allowance(account, mendi_token_address) < erc20.balance(account).wei:
|
27
|
-
erc20.approve(account, mendi_token_address)
|
28
|
-
|
29
|
-
mendi = MendiTokenContract(mendi_token_address, self.web3)
|
30
|
-
mendi.mint(account, amount.wei)
|
31
|
-
|
32
|
-
def borrow(self, account, amount):
|
33
|
-
logger.info(f"Mendi borrow {amount.token}")
|
34
|
-
|
35
|
-
def repay_borrow(self, account, amount):
|
36
|
-
logger.info(f"Mendi repay {amount.token}")
|
37
|
-
|
38
|
-
def redeem(self, account, amount):
|
39
|
-
me_token = f'me{amount.token}'
|
40
|
-
mendi_token_address = get_tokens_for_chain(self.chain)[me_token]
|
41
|
-
mendi = MendiTokenContract(mendi_token_address, self.web3)
|
42
|
-
|
43
|
-
redeem_balance = mendi.balance_of(account)
|
44
|
-
|
45
|
-
if redeem_balance > 1000000000:
|
46
|
-
logger.info(f"Mendi reedem {amount. token}")
|
47
|
-
mendi.redeem(account, redeem_balance)
|
48
|
-
else:
|
49
|
-
logger.info(f"Mendi balance is 0")
|
50
|
-
|
51
|
-
def get_deposit_amount(self, account, token):
|
52
|
-
#me_token = f'meweETH'
|
53
|
-
mendi_token_address = get_tokens_for_chain(self.chain)[token]
|
54
|
-
mendi = MendiTokenContract(mendi_token_address, self.web3)
|
55
|
-
|
56
|
-
return mendi.balance_of(account)
|
57
|
-
|
@@ -1,25 +0,0 @@
|
|
1
|
-
from sybil_engine.contract.weth import WETH
|
2
|
-
from sybil_engine.data.networks import get_ids_chain
|
3
|
-
from sybil_engine.data.tokens import get_tokens_for_chain
|
4
|
-
|
5
|
-
from web3_wizzard_lib.core.contract.reactor_fusion_contract import ReactorFusionContract
|
6
|
-
from web3_wizzard_lib.core.modules.bank.bank import Bank
|
7
|
-
|
8
|
-
|
9
|
-
class ReactorFusion(Bank):
|
10
|
-
app_name = 'REACTORFUSION_LANDING'
|
11
|
-
supported_chains = ['ZKSYNC']
|
12
|
-
|
13
|
-
def __init__(self, contract, web3):
|
14
|
-
self.contract = ReactorFusionContract(contract, web3)
|
15
|
-
|
16
|
-
def supply(self, account, amount):
|
17
|
-
self.contract.mint(account, amount.wei)
|
18
|
-
|
19
|
-
def redeem(self, account, withdraw):
|
20
|
-
self.contract.redeem_underlying(account, withdraw.wei)
|
21
|
-
|
22
|
-
def get_deposit_amount(self, account, token):
|
23
|
-
weth_token = get_tokens_for_chain(get_ids_chain()[self.contract.web3.eth.chain_id])['REACTORFUSION_LANDING']
|
24
|
-
|
25
|
-
return WETH(weth_token, self.contract.web3).balance_of(account)
|
core/modules/bank/zerolend.py
DELETED
@@ -1,36 +0,0 @@
|
|
1
|
-
from loguru import logger
|
2
|
-
from sybil_engine.data.contracts import get_contracts_for_chain
|
3
|
-
from sybil_engine.data.tokens import get_tokens_for_chain
|
4
|
-
from sybil_engine.domain.balance.tokens import Erc20Token
|
5
|
-
|
6
|
-
from web3_wizzard_lib.core.contract.zerolend_contract import ZeroLendContract
|
7
|
-
from web3_wizzard_lib.core.modules.bank.bank import Bank
|
8
|
-
|
9
|
-
|
10
|
-
class ZeroLend(Bank):
|
11
|
-
app_name = 'ZEROLEND'
|
12
|
-
supported_chains = ['LINEA']
|
13
|
-
|
14
|
-
def __init__(self, chain, web3):
|
15
|
-
self.chain = chain
|
16
|
-
self.web3 = web3
|
17
|
-
self.contract = ZeroLendContract(get_contracts_for_chain(self.chain)['ZEROLEND_LEND'], self.web3)
|
18
|
-
|
19
|
-
def supply(self, account, amount):
|
20
|
-
logger.info(f"Deposit {amount} to ZEROLEND")
|
21
|
-
|
22
|
-
self.contract.deposit_eth(account, amount.wei)
|
23
|
-
|
24
|
-
def redeem(self, account, amount):
|
25
|
-
erc20_token = Erc20Token('LINEA', get_tokens_for_chain(self.chain)['ZEROLEND_WETH'], self.web3)
|
26
|
-
|
27
|
-
if erc20_token.allowance(account, self.contract.contract_address) < 100:
|
28
|
-
erc20_token.approve(account, self.contract.contract_address)
|
29
|
-
|
30
|
-
self.contract.withdraw_eth(account, amount.wei)
|
31
|
-
|
32
|
-
def get_deposit_amount(self, account, token):
|
33
|
-
erc20_token = Erc20Token('LINEA', get_tokens_for_chain(self.chain)['ZEROLEND_WETH'], self.web3)
|
34
|
-
|
35
|
-
return erc20_token.balance(account)
|
36
|
-
|
core/modules/bridge/__init__.py
DELETED
File without changes
|
core/modules/bridge/bridge.py
DELETED
@@ -1,47 +0,0 @@
|
|
1
|
-
from loguru import logger
|
2
|
-
from sybil_engine.data.contracts import get_contracts_for_chain
|
3
|
-
from sybil_engine.data.networks import get_chain_instance
|
4
|
-
from sybil_engine.domain.balance.balance import NotEnoughERC20Balance
|
5
|
-
from sybil_engine.domain.balance.balance_utils import interval_to_erc20_balance, get_native_balance
|
6
|
-
from sybil_engine.domain.balance.tokens import Erc20Token
|
7
|
-
from sybil_engine.utils.retry import retry
|
8
|
-
from sybil_engine.utils.web3_utils import init_web3
|
9
|
-
|
10
|
-
from web3_wizzard_lib.core.contract.coredao_contract import CoreDaoContract
|
11
|
-
from web3_wizzard_lib.core.contract.coredao_from_contract import CoreDaoFromContract
|
12
|
-
from web3_wizzard_lib.core.modules.bridge.bridge import Bridge
|
13
|
-
|
14
|
-
|
15
|
-
class CoreDaoBridgeSubModule(Bridge):
|
16
|
-
supported_chains = ['POLYGON', 'COREDAO']
|
17
|
-
|
18
|
-
@retry(max_attempts=5, retry_interval={'from': 60 * 15, 'to': 60 * 25})
|
19
|
-
def execute(self, bridge_amount_interval, from_chain, to_chain, token, min_native_balance, account):
|
20
|
-
chain_instance = get_chain_instance(from_chain)
|
21
|
-
web3 = init_web3(chain_instance, account.proxy)
|
22
|
-
|
23
|
-
erc20_token = Erc20Token(from_chain, token, web3)
|
24
|
-
|
25
|
-
amount = interval_to_erc20_balance(bridge_amount_interval, account, token, from_chain, web3)
|
26
|
-
|
27
|
-
logger.info(f"Native balance: {get_native_balance(account, web3, chain_instance)}")
|
28
|
-
logger.info(f"Balance: {erc20_token.balance(account)}")
|
29
|
-
|
30
|
-
logger.info(f"Bridge {from_chain + ' -> ' + to_chain} {amount}")
|
31
|
-
|
32
|
-
if amount.wei == 0:
|
33
|
-
raise NotEnoughERC20Balance(f"Can't swap zero balance")
|
34
|
-
|
35
|
-
coredao_contract = get_contracts_for_chain(from_chain)['COREDAO_BRIDGE']
|
36
|
-
|
37
|
-
if erc20_token.allowance(account, coredao_contract) < amount.wei:
|
38
|
-
erc20_token.approve(account, coredao_contract)
|
39
|
-
|
40
|
-
if from_chain == 'COREDAO':
|
41
|
-
coredao = CoreDaoFromContract(coredao_contract, web3)
|
42
|
-
fee = coredao.estimate_bridge_fee(to_chain)
|
43
|
-
else:
|
44
|
-
coredao = CoreDaoContract(coredao_contract, web3)
|
45
|
-
fee = coredao.estimate_bridge_fee()
|
46
|
-
|
47
|
-
coredao.bridge(account, amount, erc20_token.erc20_contract.contract_address, fee, to_chain)
|
@@ -1,112 +0,0 @@
|
|
1
|
-
import random
|
2
|
-
|
3
|
-
from loguru import logger
|
4
|
-
from sybil_engine.contract.erc20contract import Erc20Contract
|
5
|
-
from sybil_engine.contract.send import Send
|
6
|
-
from sybil_engine.data.contracts import get_contracts_for_chain
|
7
|
-
from sybil_engine.data.networks import get_chain_instance
|
8
|
-
from sybil_engine.data.tokens import get_tokens_for_chain
|
9
|
-
from sybil_engine.domain.balance.balance import NotEnoughNativeBalance
|
10
|
-
from sybil_engine.domain.balance.balance_utils import interval_to_erc20_balance, \
|
11
|
-
interval_to_native_balance, verify_balance
|
12
|
-
from sybil_engine.utils.utils import ConfigurationException
|
13
|
-
from sybil_engine.utils.web3_utils import init_web3
|
14
|
-
|
15
|
-
from web3_wizzard_lib.core.contract.orbiter_starknet import OrbiterStarknet
|
16
|
-
from web3_wizzard_lib.core.modules.bridge.bridge import Bridge
|
17
|
-
|
18
|
-
bridge_codes = {
|
19
|
-
"ETH": 9001,
|
20
|
-
"ARBITRUM": 9002,
|
21
|
-
"POLYGON": 9006,
|
22
|
-
"OPTIMISM": 9007,
|
23
|
-
"BSC": 9015,
|
24
|
-
"ARBITRUM_NOVA": 9016,
|
25
|
-
"ZKSYNC": 9014,
|
26
|
-
"POLYGON_ZK": 9017,
|
27
|
-
"BASE": 9021,
|
28
|
-
"LINEA": 9023,
|
29
|
-
"SCROLL": 9019,
|
30
|
-
#"X_LAYER": 9027, DONT USE
|
31
|
-
"ZORA": 9030,
|
32
|
-
"MANTA": 9031,
|
33
|
-
"ZKFAIR": 9038
|
34
|
-
}
|
35
|
-
|
36
|
-
|
37
|
-
class OrbiterSubModule(Bridge):
|
38
|
-
supported_tokens = ['NATIVE', 'USDC', 'USDT', 'WETH']
|
39
|
-
|
40
|
-
def execute(self, bridge_amount_interval, from_chain, to_chain, token, min_native_balance, account):
|
41
|
-
from_chain_instance = get_chain_instance(from_chain)
|
42
|
-
web3 = init_web3(from_chain_instance, account.proxy)
|
43
|
-
|
44
|
-
if isinstance(to_chain, list):
|
45
|
-
to_chain = random.choice(to_chain)
|
46
|
-
if to_chain not in bridge_codes:
|
47
|
-
raise ConfigurationException(f"{to_chain} not supported in orbiter")
|
48
|
-
|
49
|
-
amount = self.__calculate_bridge_amount(account, bridge_amount_interval, from_chain_instance, to_chain, token,
|
50
|
-
min_native_balance, web3)
|
51
|
-
|
52
|
-
logger.info(f"Bridge {from_chain} –> {to_chain} | {amount}")
|
53
|
-
self.__perform_bridge(account, amount, from_chain, to_chain, token, web3)
|
54
|
-
|
55
|
-
def __perform_bridge(self, account, amount, from_chain, to_chain, token, web3):
|
56
|
-
if token == 'NATIVE':
|
57
|
-
self.__bridge_native(account, amount, from_chain, to_chain, web3)
|
58
|
-
else:
|
59
|
-
self.__bridge_token(account, amount, from_chain, web3)
|
60
|
-
|
61
|
-
def __calculate_bridge_amount(self, account, bridge_amount_interval, from_chain_instance, to_chain, token,
|
62
|
-
min_native_balance, web3):
|
63
|
-
if token == 'NATIVE':
|
64
|
-
native_without_min = verify_balance(min_native_balance, from_chain_instance, account, web3)
|
65
|
-
|
66
|
-
amount = interval_to_native_balance(bridge_amount_interval, account, from_chain_instance['chain'], web3)
|
67
|
-
if amount.wei > native_without_min.wei:
|
68
|
-
if bridge_amount_interval == 'all_balance':
|
69
|
-
amount = native_without_min
|
70
|
-
else:
|
71
|
-
raise NotEnoughNativeBalance(
|
72
|
-
f"The account balance ({native_without_min}) < bridging amount ({amount}).")
|
73
|
-
else:
|
74
|
-
amount = interval_to_erc20_balance(bridge_amount_interval, account, token, from_chain_instance['chain'],
|
75
|
-
web3)
|
76
|
-
if bridge_amount_interval == 'all_balance':
|
77
|
-
amount.wei = amount.wei - 10 ** 5
|
78
|
-
|
79
|
-
amount.wei = self.__adjust_amount_by_bridge_code(amount.wei, to_chain)
|
80
|
-
|
81
|
-
return amount
|
82
|
-
|
83
|
-
def __adjust_amount_by_bridge_code(self, wei_amount, to_chain):
|
84
|
-
bridge_code = bridge_codes.get(to_chain)
|
85
|
-
if not bridge_code:
|
86
|
-
raise ConfigurationException(f"No bridge code found for {to_chain}")
|
87
|
-
return int(f"{wei_amount // 10 ** 4}{bridge_code}")
|
88
|
-
|
89
|
-
def __bridge_native(self, account, amount, from_chain, to_chain, web3):
|
90
|
-
if to_chain == 'STARKNET':
|
91
|
-
if amount.readable() <= 0.0065 or amount.readable() >= 5:
|
92
|
-
raise NotEnoughNativeBalance(f"Limit range amount for starknet 0.0065 – 5 ETH | {amount}")
|
93
|
-
|
94
|
-
if from_chain != 'ZKSYNC':
|
95
|
-
raise ConfigurationException("only ZKSYNC can bridge to STARKNET")
|
96
|
-
|
97
|
-
orbiter_wallet = get_contracts_for_chain(from_chain)['ORBITER_STARKNET']
|
98
|
-
orbiter_starknet = OrbiterStarknet(orbiter_wallet, web3)
|
99
|
-
orbiter_starknet.bridge(account, amount)
|
100
|
-
else:
|
101
|
-
orbiter_wallet = get_contracts_for_chain(from_chain)['ORBITER']
|
102
|
-
send = Send(orbiter_wallet, web3)
|
103
|
-
send.send_to_wallet(account, orbiter_wallet, amount)
|
104
|
-
|
105
|
-
def __bridge_token(self, account, amount, from_chain, web3):
|
106
|
-
contracts = get_contracts_for_chain(from_chain)
|
107
|
-
|
108
|
-
if 'ORBITER_ERC20' not in contracts:
|
109
|
-
raise ConfigurationException(f"ERC20 is not supported for {from_chain}")
|
110
|
-
|
111
|
-
erc20 = Erc20Contract(get_tokens_for_chain(from_chain)[amount.token], web3)
|
112
|
-
erc20.transfer(account, amount, contracts['ORBITER_ERC20'])
|
@@ -1,42 +0,0 @@
|
|
1
|
-
from sybil_engine.utils.utils import ConfigurationException
|
2
|
-
|
3
|
-
from web3_wizzard_lib.core.modules.bridge.bridge import Bridge
|
4
|
-
from sybil_engine.data.contracts import get_contracts_for_chain
|
5
|
-
from sybil_engine.data.networks import get_chain_instance
|
6
|
-
from sybil_engine.domain.balance.balance import NotEnoughNativeBalance
|
7
|
-
from sybil_engine.domain.balance.balance_utils import interval_to_native_balance, verify_balance
|
8
|
-
|
9
|
-
from sybil_engine.utils.web3_utils import init_web3
|
10
|
-
|
11
|
-
from web3_wizzard_lib.core.contract.eth_scroll_bridge_contract import EthScrollBridgeContract
|
12
|
-
from web3_wizzard_lib.core.contract.scroll_bridge_contract import ScrollBridgeContract
|
13
|
-
from web3_wizzard_lib.core.contract.scroll_oracle import ScrollOracle
|
14
|
-
|
15
|
-
class ScrollBridgeSubModule(Bridge):
|
16
|
-
|
17
|
-
def execute(self, bridge_amount_interval, from_chain, to_chain, token, min_native_balance, account):
|
18
|
-
from_chain_instance = get_chain_instance(from_chain)
|
19
|
-
web3 = init_web3(from_chain_instance, account.proxy)
|
20
|
-
native_without_min = verify_balance(min_native_balance, from_chain_instance, account, web3)
|
21
|
-
amount = interval_to_native_balance(bridge_amount_interval, account, from_chain_instance['chain'], web3)
|
22
|
-
if amount.wei > native_without_min.wei:
|
23
|
-
if bridge_amount_interval == 'all_balance':
|
24
|
-
amount = native_without_min
|
25
|
-
else:
|
26
|
-
raise NotEnoughNativeBalance(
|
27
|
-
f"The account balance ({native_without_min}) < bridging amount ({amount}).")
|
28
|
-
if from_chain == 'ETH_MAINNET':
|
29
|
-
contract_oracle = get_contracts_for_chain(from_chain)["SCROLL_ORACLE"]
|
30
|
-
fee = ScrollOracle(contract_oracle, web3).estimateCrossDomainMessageFee()
|
31
|
-
|
32
|
-
scroll_bridge_contract_address = get_contracts_for_chain(from_chain)["SCROLL_BRIDGE"]
|
33
|
-
scroll_bridge = EthScrollBridgeContract(scroll_bridge_contract_address, web3)
|
34
|
-
|
35
|
-
scroll_bridge.sendMessage(account, amount.wei, fee)
|
36
|
-
elif from_chain == 'SCROLL':
|
37
|
-
scroll_bridge_contract_address = get_contracts_for_chain(from_chain)["SCROLL_BRIDGE"]
|
38
|
-
scroll_bridge = ScrollBridgeContract(scroll_bridge_contract_address, web3)
|
39
|
-
|
40
|
-
scroll_bridge.withdraw(account, amount.wei)
|
41
|
-
else:
|
42
|
-
raise ConfigurationException(f"{from_chain} chain is unsupported, only ETH_MAINNET and SCROLL allowed")
|
@@ -1,74 +0,0 @@
|
|
1
|
-
from loguru import logger
|
2
|
-
from sybil_engine.data.contracts import get_contracts_for_chain
|
3
|
-
from sybil_engine.data.networks import get_chain_instance
|
4
|
-
from sybil_engine.domain.balance.balance import NotEnoughNativeBalance
|
5
|
-
from sybil_engine.domain.balance.balance_utils import interval_to_native_balance, verify_balance
|
6
|
-
from sybil_engine.utils.utils import ConfigurationException
|
7
|
-
from sybil_engine.utils.web3_utils import init_web3
|
8
|
-
|
9
|
-
from web3_wizzard_lib.core.contract.stargate_v2_contract import StargateV2Contract
|
10
|
-
from web3_wizzard_lib.core.modules.bridge.bridge import Bridge
|
11
|
-
|
12
|
-
chain_ids = {
|
13
|
-
'LINEA': 30183,
|
14
|
-
'SCROLL': 30214,
|
15
|
-
'OPTIMISM': 30111,
|
16
|
-
'ARBITRUM': 30110,
|
17
|
-
'BASE': 30184
|
18
|
-
}
|
19
|
-
|
20
|
-
|
21
|
-
class StargateV2SubModule(Bridge):
|
22
|
-
supported_tokens = ['NATIVE']
|
23
|
-
|
24
|
-
def execute(self, bridge_amount_interval, from_chain, to_chain, token, min_native_balance, account):
|
25
|
-
if token != 'NATIVE':
|
26
|
-
raise ConfigurationException('Currently only native token bridge is supported by Stargate V2')
|
27
|
-
|
28
|
-
from_chain_instance = get_chain_instance(from_chain)
|
29
|
-
web3 = init_web3(from_chain_instance, account.proxy)
|
30
|
-
stargate_v2_contract = get_contracts_for_chain(from_chain)['STARGATE_V2']
|
31
|
-
|
32
|
-
amount = self.__calculate_bridge_amount(
|
33
|
-
account,
|
34
|
-
bridge_amount_interval,
|
35
|
-
from_chain_instance,
|
36
|
-
min_native_balance,
|
37
|
-
web3
|
38
|
-
)
|
39
|
-
|
40
|
-
logger.info(f"Bridge {from_chain} –> {to_chain} | {amount}")
|
41
|
-
|
42
|
-
send_params = (
|
43
|
-
chain_ids[to_chain],
|
44
|
-
f'0x000000000000000000000000{account.address[2:]}',
|
45
|
-
amount.wei, # amountLD,
|
46
|
-
int(amount.wei * 0.995), # minAmountLd,
|
47
|
-
b'',
|
48
|
-
b'',
|
49
|
-
b'\x01',
|
50
|
-
)
|
51
|
-
|
52
|
-
stargate_v2 = StargateV2Contract(stargate_v2_contract, web3)
|
53
|
-
|
54
|
-
stargate_fee = stargate_v2.quote_send(send_params)
|
55
|
-
|
56
|
-
stargate_v2.send(
|
57
|
-
account,
|
58
|
-
amount.wei + stargate_fee[0],
|
59
|
-
send_params,
|
60
|
-
stargate_fee,
|
61
|
-
account.address
|
62
|
-
)
|
63
|
-
|
64
|
-
def __calculate_bridge_amount(self, account, bridge_amount_interval, from_chain_instance, min_native_balance, web3):
|
65
|
-
native_without_min = verify_balance(min_native_balance, from_chain_instance, account, web3)
|
66
|
-
|
67
|
-
amount = interval_to_native_balance(bridge_amount_interval, account, from_chain_instance['chain'], web3)
|
68
|
-
if amount.wei > native_without_min.wei:
|
69
|
-
if bridge_amount_interval == 'all_balance':
|
70
|
-
amount = native_without_min
|
71
|
-
else:
|
72
|
-
raise NotEnoughNativeBalance(
|
73
|
-
f"The account balance ({native_without_min}) < bridging amount ({amount}).")
|
74
|
-
return amount
|
core/modules/bridge_module.py
DELETED
@@ -1,47 +0,0 @@
|
|
1
|
-
from sybil_engine.module.module import Module
|
2
|
-
from sybil_engine.utils.utils import ConfigurationException
|
3
|
-
from sybil_engine.utils.validation_utils import validate_amount_interval, validate_chain
|
4
|
-
|
5
|
-
from web3_wizzard_lib.core.modules.bridge.coredao_bridge_sub import CoreDaoBridgeSubModule
|
6
|
-
from web3_wizzard_lib.core.modules.bridge.orbiter_sub import OrbiterSubModule
|
7
|
-
from web3_wizzard_lib.core.modules.bridge.scroll_bridge_sub import ScrollBridgeSubModule
|
8
|
-
from web3_wizzard_lib.core.modules.bridge.stargate_v2_sub import StargateV2SubModule
|
9
|
-
|
10
|
-
|
11
|
-
class BridgeModule(Module):
|
12
|
-
module_name = 'BRIDGE'
|
13
|
-
module_config = 'bridge_module'
|
14
|
-
|
15
|
-
supported_tokens = ['NATIVE', 'USDC', 'USDT', 'WETH']
|
16
|
-
|
17
|
-
def execute(self, bridge, bridge_amount_interval, from_chain, to_chain, token, account):
|
18
|
-
if bridge == 'ORBITER':
|
19
|
-
module = OrbiterSubModule()
|
20
|
-
elif bridge == 'STARGATE_V2':
|
21
|
-
module = StargateV2SubModule()
|
22
|
-
elif bridge == 'COREDAO':
|
23
|
-
module = CoreDaoBridgeSubModule()
|
24
|
-
elif bridge == 'SCROLL':
|
25
|
-
module = ScrollBridgeSubModule()
|
26
|
-
else:
|
27
|
-
raise ConfigurationException(f'Bridge {bridge} is not supported')
|
28
|
-
|
29
|
-
module.execute(bridge_amount_interval, from_chain, to_chain, token, self.min_native_balance, account)
|
30
|
-
|
31
|
-
def log(self):
|
32
|
-
return "BRIDGE"
|
33
|
-
|
34
|
-
def parse_params(self, module_params):
|
35
|
-
validate_amount_interval(module_params['bridge_amount_interval'])
|
36
|
-
validate_chain(module_params['from_chain'])
|
37
|
-
|
38
|
-
if 'token' not in module_params:
|
39
|
-
module_params['token'] = 'NATIVE'
|
40
|
-
|
41
|
-
if module_params['token'] not in self.supported_tokens:
|
42
|
-
raise ConfigurationException(
|
43
|
-
f"{module_params['token']} not supported in orbiter. Supported options: {self.supported_tokens}")
|
44
|
-
|
45
|
-
return module_params['bridge'], module_params['bridge_amount_interval'], module_params['from_chain'], \
|
46
|
-
module_params['to_chain'], \
|
47
|
-
module_params['token']
|