-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: splitting omni-connector into multiple smaller connectors (#48
) * refactor: scratch implementation of refactored version of sdk * refactor: made solana-connector rely on near-connector * chore: removed useless lib.rs files Since we can directly set path for a lib file, then there's no need to create a lib file just to import a module * fix: manually synced with main branch * fix: resolved issues after merge * chore: scratch implementation of bridge-clients * Implement a few near<->evm operations (#52) * feat: added wormhole support Made an abstraction for init&fin transfer as well * chore: bumped spl crates version * feat: support for multiple evm chains * chore: added abstract method for calling `sign_transfer` on NEAR chain * chore: added abstract method for calling `claim_fee` on NEAR chain * chore: added abstract method for calling `sign_claim_fee` on NEAR chain * feat: synced with latest omni-types * feat: added `get_required_storage_deposit` method on NEAR chain * fix: static analysis * feat: added `get_token_id` method on NEAR chain * feat: support multiple OmniAddress variants * feat: added `get_native_token_id` method on NEAR chain * feat: finished abstraction (#54) * feat: finished abstraction * feat: included solana into omni abstraction * feat: made solana's fields optional This can be useful if user won't use full potential of bridge-client, but only some methods which don't require all fields like wormhole or keypair * chore: provided a bit more consistency between different bridge clients * chore: addressed some clippy warnings * chore: updated some crates * chore: decreased attached gas * chore: moved attached gas/deposit to consts --------- Co-authored-by: kiseln <[email protected]> Co-authored-by: Ivan Frolov <[email protected]> Co-authored-by: Ivan Frolov <[email protected]>
- Loading branch information
1 parent
dd5c419
commit a98ba59
Showing
29 changed files
with
3,960 additions
and
2,797 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,57 @@ | ||
/// Mainnet | ||
pub const NEAR_RPC_MAINNET: &str = "https://rpc.mainnet.near.org/"; | ||
pub const ETH_RPC_MAINNET: &str = "https://eth.llamarpc.com"; | ||
pub const ETH_CHAIN_ID_MAINNET: u64 = 1; | ||
pub const TOKEN_LOCKER_ID_MAINNET: &str = "ft-locker.bridge.near"; | ||
pub const BRIDGE_TOKEN_FACTORY_ADDRESS_MAINNET: &str = "0x252e87862A3A720287E7fd527cE6e8d0738427A2"; | ||
pub const NEAR_TOKEN_LOCKER_ID_MAINNET: &str = "omni-locker.near"; | ||
pub const NEAR_LIGHT_CLIENT_ETH_ADDRESS_MAINNET: &str = | ||
"0x3FEFc5A4B1c02f21cBc8D3613643ba0635b9a873"; | ||
|
||
pub const ETH_RPC_MAINNET: &str = "https://eth.llamarpc.com"; | ||
pub const ETH_CHAIN_ID_MAINNET: u64 = 1; | ||
pub const ETH_BRIDGE_TOKEN_FACTORY_ADDRESS_MAINNET: &str = | ||
"0x252e87862A3A720287E7fd527cE6e8d0738427A2"; | ||
pub const ETH_CONNECTOR_ACCOUNT_ID_MAINNET: &str = "aurora"; | ||
pub const ETH_CUSTODIAN_ADDRESS_MAINNET: &str = "0x6BFaD42cFC4EfC96f529D786D643Ff4A8B89FA52"; | ||
pub const FAST_BRIDGE_ACCOUNT_ID_MAINNET: &str = "fast.bridge.near"; | ||
pub const FAST_BRIDGE_ADDRESS_MAINNET: &str = "0xC5E985976d9b521904AD96306356ECA0fE4F3a1f"; | ||
|
||
pub const BASE_RPC_MAINNET: &str = ""; | ||
pub const BASE_CHAIN_ID_MAINNET: u64 = 8453; | ||
pub const BASE_BRIDGE_TOKEN_FACTORY_ADDRESS_MAINNET: &str = ""; | ||
|
||
pub const ARB_RPC_MAINNET: &str = ""; | ||
pub const ARB_CHAIN_ID_MAINNET: u64 = 42161; | ||
pub const ARB_BRIDGE_TOKEN_FACTORY_ADDRESS_MAINNET: &str = ""; | ||
|
||
pub const SOLANA_RPC_MAINNET: &str = "https://api.mainnet-beta.solana.com"; | ||
pub const SOLANA_BRIDGE_ADDRESS_MAINNET: &str = ""; | ||
pub const SOLANA_WORMHOLE_ADDRESS_MAINNET: &str = ""; | ||
|
||
pub const FAST_BRIDGE_ACCOUNT_ID_MAINNET: &str = "fast.bridge.near"; | ||
pub const FAST_BRIDGE_ADDRESS_MAINNET: &str = "0xC5E985976d9b521904AD96306356ECA0fE4F3a1f"; | ||
|
||
/// Testnet | ||
pub const NEAR_RPC_TESTNET: &str = "https://rpc.testnet.near.org/"; | ||
pub const ETH_RPC_TESTNET: &str = "https://ethereum-sepolia.blockpi.network/v1/rpc/public"; | ||
pub const ETH_CHAIN_ID_TESTNET: u64 = 11155111; | ||
pub const TOKEN_LOCKER_ID_TESTNET: &str = "ft-locker.sepolia.testnet"; | ||
pub const BRIDGE_TOKEN_FACTORY_ADDRESS_TESTNET: &str = "0xa9108f7F83Fb661e611991116D526fCa1a9585ab"; | ||
pub const NEAR_TOKEN_LOCKER_ID_TESTNET: &str = "omni-locker.testnet"; | ||
pub const NEAR_LIGHT_CLIENT_ETH_ADDRESS_TESTNET: &str = | ||
"0x202cdf10bfa45a3d2190901373edd864f071d707"; | ||
|
||
pub const ETH_RPC_TESTNET: &str = "https://ethereum-sepolia.blockpi.network/v1/rpc/public"; | ||
pub const ETH_CHAIN_ID_TESTNET: u64 = 11155111; | ||
pub const ETH_BRIDGE_TOKEN_FACTORY_ADDRESS_TESTNET: &str = | ||
"0xa9108f7F83Fb661e611991116D526fCa1a9585ab"; | ||
pub const ETH_CONNECTOR_ACCOUNT_ID_TESTNET: &str = "aurora"; | ||
pub const ETH_CUSTODIAN_ADDRESS_TESTNET: &str = "0xe0320b199863D7f6D5bBa62741aACB312110DEf7"; | ||
pub const FAST_BRIDGE_ACCOUNT_ID_TESTNET: &str = "fastbridge.testnet"; | ||
pub const FAST_BRIDGE_ADDRESS_TESTNET: &str = "0x0B2C4871C9bAD795746C05c1539A8B1f26c26357"; | ||
|
||
pub const BASE_RPC_TESTNET: &str = "https://base-sepolia.blockpi.network/v1/rpc/public"; | ||
pub const BASE_CHAIN_ID_TESTNET: u64 = 84532; | ||
pub const BASE_BRIDGE_TOKEN_FACTORY_ADDRESS_TESTNET: &str = | ||
"0x0C981337fFe39a555d3A40dbb32f21aD0eF33FFA"; | ||
|
||
pub const ARB_RPC_TESTNET: &str = "https://arbitrum-sepolia.blockpi.network/v1/rpc/public"; | ||
pub const ARB_CHAIN_ID_TESTNET: u64 = 421614; | ||
pub const ARB_BRIDGE_TOKEN_FACTORY_ADDRESS_TESTNET: &str = | ||
"0xd565f7CcE0FA1bB8DBe73FCDA281390d545f6200"; | ||
|
||
pub const SOLANA_RPC_TESTNET: &str = "https://api.devnet.solana.com"; | ||
pub const SOLANA_BRIDGE_ADDRESS_TESTNET: &str = ""; | ||
pub const SOLANA_WORMHOLE_ADDRESS_TESTNET: &str = "3u8hJUVTA4jH1wYAyUur7FFZVQ8H635K3tSHHF4ssjQ5"; | ||
|
||
pub const FAST_BRIDGE_ACCOUNT_ID_TESTNET: &str = "fastbridge.testnet"; | ||
pub const FAST_BRIDGE_ADDRESS_TESTNET: &str = "0x0B2C4871C9bAD795746C05c1539A8B1f26c26357"; |
Oops, something went wrong.