diff --git a/Cargo.lock b/Cargo.lock index debd7a66b..a595b03e3 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -639,34 +639,19 @@ name = "bp-message-dispatch" version = "0.1.0" source = "git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4#495a773403e5827bbf9d7b20d97333f673628db9" dependencies = [ - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-runtime", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "parity-scale-codec", "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", ] -[[package]] -name = "bp-messages" -version = "0.1.0" -source = "git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-3#e26d59105acb795161881e49eb14992b8b0c22fa" -dependencies = [ - "bitvec", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-3)", - "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "impl-trait-for-tuples", - "parity-scale-codec", - "serde 1.0.130", - "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", -] - [[package]] name = "bp-messages" version = "0.1.0" source = "git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4#495a773403e5827bbf9d7b20d97333f673628db9" dependencies = [ "bitvec", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-runtime", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "impl-trait-for-tuples", @@ -675,23 +660,6 @@ dependencies = [ "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", ] -[[package]] -name = "bp-runtime" -version = "0.1.0" -source = "git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-3#e26d59105acb795161881e49eb14992b8b0c22fa" -dependencies = [ - "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "hash-db", - "num-traits 0.2.14", - "parity-scale-codec", - "sp-core 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-io 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-state-machine 0.9.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-trie 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", -] - [[package]] name = "bp-runtime" version = "0.1.0" @@ -738,50 +706,14 @@ dependencies = [ "uint 0.8.5", ] -[[package]] -name = "bridge-primitives" -version = "0.11.6" -source = "git+https://github.com/darwinia-network/darwinia.git?branch=bump-deps#db5f7808f496ce757326797a2b794a64669737db" -dependencies = [ - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-runtime-common", - "common-primitives 0.11.6", - "darwinia-fee-market 2.6.10", - "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "pallet-bridge-dispatch", - "sp-api", - "sp-core 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", -] - -[[package]] -name = "bridge-primitives" -version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" -dependencies = [ - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-runtime-common", - "common-primitives 2.7.0", - "darwinia-fee-market 2.7.0", - "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "pallet-bridge-dispatch", - "sp-api", - "sp-core 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", -] - [[package]] name = "bridge-runtime-common" version = "0.1.0" source = "git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4#495a773403e5827bbf9d7b20d97333f673628db9" dependencies = [ "bp-message-dispatch", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", + "bp-runtime", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "hash-db", "pallet-bridge-dispatch", @@ -826,7 +758,7 @@ checksum = "771fe0050b883fcc3ea2359b1a96bcfbc090b7116eae7c3c512c7a083fdf23d3" [[package]] name = "bsc-primitives" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "ethbloom", @@ -1056,33 +988,14 @@ dependencies = [ "winapi", ] -[[package]] -name = "common-primitives" -version = "0.11.6" -source = "git+https://github.com/darwinia-network/darwinia.git?branch=bump-deps#db5f7808f496ce757326797a2b794a64669737db" -dependencies = [ - "parity-scale-codec", - "sp-core 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", -] - -[[package]] -name = "common-primitives" -version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" -dependencies = [ - "sp-core 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", -] - [[package]] name = "common-runtime" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ - "common-primitives 2.7.0", "darwinia-balances 2.7.0", "darwinia-support 2.7.0", + "drml-common-primitives", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "max-encoded-len", @@ -1101,13 +1014,13 @@ version = "0.4.8" dependencies = [ "anyhow", "async-trait", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-primitives 0.11.6", + "bp-messages", + "bp-runtime", "bridge-traits", - "common-primitives 0.11.6", "crab-runtime", - "dp-fee 2.6.10 (git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3)", + "darwinia-bridge-primitives", + "darwinia-common-primitives", + "dp-fee 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "headers-relay", @@ -1128,14 +1041,14 @@ version = "0.4.8" dependencies = [ "anyhow", "async-trait", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-primitives 0.11.6", + "bp-messages", + "bp-runtime", "bridge-traits", - "common-primitives 0.11.6", - "darwinia-bridge-ethereum 2.6.10 (git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3)", + "darwinia-bridge-ethereum 2.6.10", + "darwinia-bridge-primitives", + "darwinia-common-primitives", "darwinia-runtime", - "dp-fee 2.6.10 (git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3)", + "dp-fee 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "headers-relay", @@ -1157,7 +1070,7 @@ dependencies = [ "anyhow", "array-bytes", "async-trait", - "bridge-primitives 0.4.8", + "bridge-primitives", "bridge-traits", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "jsonrpsee-types", @@ -1211,13 +1124,13 @@ version = "0.4.8" dependencies = [ "anyhow", "async-trait", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-primitives 2.7.0", + "bp-messages", + "bp-runtime", "bridge-traits", - "common-primitives 2.7.0", "darwinia-bridge-ethereum 2.7.0", "dp-fee 2.7.0", + "drml-bridge-primitives", + "drml-common-primitives", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "futures-test", @@ -1265,12 +1178,12 @@ version = "0.4.8" dependencies = [ "anyhow", "async-trait", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-primitives 2.7.0", + "bp-messages", + "bp-runtime", "bridge-traits", - "common-primitives 2.7.0", "dp-fee 2.7.0", + "drml-bridge-primitives", + "drml-common-primitives", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "headers-relay", @@ -1424,18 +1337,19 @@ dependencies = [ [[package]] name = "crab-runtime" version = "0.11.6" -source = "git+https://github.com/darwinia-network/darwinia.git?branch=bump-deps#db5f7808f496ce757326797a2b794a64669737db" +source = "git+https://github.com/darwinia-network/darwinia.git?branch=bump-deps#4ea75571cce207c1989f31eeb83fe2a872e30529" dependencies = [ "array-bytes", "bp-message-dispatch", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-primitives 0.11.6", + "bp-messages", + "bp-runtime", "bridge-runtime-common", - "common-primitives 0.11.6", "darwinia-balances 2.6.10", "darwinia-balances-rpc-runtime-api 2.6.10", + "darwinia-bridge-primitives", "darwinia-claims 2.6.10", + "darwinia-common-primitives", + "darwinia-common-runtime", "darwinia-democracy 2.6.10", "darwinia-elections-phragmen 2.6.10", "darwinia-evm 2.6.10", @@ -1445,15 +1359,14 @@ dependencies = [ "darwinia-fee-market-rpc-runtime-api 2.6.10", "darwinia-header-mmr 2.6.10", "darwinia-header-mmr-rpc-runtime-api 2.6.6", - "darwinia-runtime-common", "darwinia-staking 2.6.10", "darwinia-staking-rpc-runtime-api 2.6.10", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "darwinia-vesting 2.6.10", "dp-evm 2.6.10", "dvm-ethereum 2.6.10", "dvm-rpc-runtime-api 2.6.10", - "ethereum-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "ethereum-primitives 2.6.10", "evm", "frame-executive", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -1710,10 +1623,10 @@ dependencies = [ [[package]] name = "darwinia-balances" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "darwinia-balances-rpc-runtime-api 2.6.10", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "log", @@ -1726,7 +1639,7 @@ dependencies = [ [[package]] name = "darwinia-balances" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-balances-rpc-runtime-api 2.7.0", "darwinia-support 2.7.0", @@ -1742,9 +1655,9 @@ dependencies = [ [[package]] name = "darwinia-balances-rpc-runtime-api" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "parity-scale-codec", "serde 1.0.130", "sp-api", @@ -1754,7 +1667,7 @@ dependencies = [ [[package]] name = "darwinia-balances-rpc-runtime-api" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-support 2.7.0", "parity-scale-codec", @@ -1766,7 +1679,7 @@ dependencies = [ [[package]] name = "darwinia-bridge-bsc" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "bsc-primitives", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -1781,15 +1694,15 @@ dependencies = [ [[package]] name = "darwinia-bridge-ethereum" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3#ed73e1a2619107dbe02ce636f174c4570552c946" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "array-bytes", "blake2-rfc", "ckb-merkle-mountain-range", - "darwinia-relay-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3)", - "darwinia-relayer-game 2.6.10 (git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3)", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3)", - "ethereum-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3)", + "darwinia-relay-primitives 2.6.10", + "darwinia-relayer-game 2.6.10", + "darwinia-support 2.6.10", + "ethereum-primitives 2.6.10", "ethereum-types", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -1804,16 +1717,16 @@ dependencies = [ [[package]] name = "darwinia-bridge-ethereum" -version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +version = "2.7.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "blake2-rfc", "ckb-merkle-mountain-range", - "darwinia-relay-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", - "darwinia-relayer-game 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", - "ethereum-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-relay-primitives 2.7.0", + "darwinia-relayer-game 2.7.0", + "darwinia-support 2.7.0", + "ethereum-primitives 2.7.0", "ethereum-types", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -1827,24 +1740,18 @@ dependencies = [ ] [[package]] -name = "darwinia-bridge-ethereum" -version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +name = "darwinia-bridge-primitives" +version = "0.11.6" +source = "git+https://github.com/darwinia-network/darwinia.git?branch=bump-deps#4ea75571cce207c1989f31eeb83fe2a872e30529" dependencies = [ - "array-bytes", - "blake2-rfc", - "ckb-merkle-mountain-range", - "darwinia-relay-primitives 2.7.0", - "darwinia-relayer-game 2.7.0", - "darwinia-support 2.7.0", - "ethereum-primitives 2.7.0", - "ethereum-types", + "bp-messages", + "bp-runtime", + "bridge-runtime-common", + "darwinia-common-primitives", + "darwinia-fee-market 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "parity-scale-codec", - "rlp 0.5.1", - "serde 1.0.130", - "serde_json", + "pallet-bridge-dispatch", + "sp-api", "sp-core 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -1856,7 +1763,7 @@ version = "0.4.8" dependencies = [ "anyhow", "async-recursion", - "bridge-primitives 0.4.8", + "bridge-primitives", "bridge-traits", "colored", "component-state", @@ -1885,10 +1792,10 @@ dependencies = [ [[package]] name = "darwinia-claims" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "array-bytes", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "log", @@ -1903,7 +1810,7 @@ dependencies = [ [[package]] name = "darwinia-claims" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "darwinia-support 2.7.0", @@ -1918,12 +1825,42 @@ dependencies = [ "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", ] +[[package]] +name = "darwinia-common-primitives" +version = "0.11.6" +source = "git+https://github.com/darwinia-network/darwinia.git?branch=bump-deps#4ea75571cce207c1989f31eeb83fe2a872e30529" +dependencies = [ + "parity-scale-codec", + "sp-core 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", + "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", +] + +[[package]] +name = "darwinia-common-runtime" +version = "0.11.6" +source = "git+https://github.com/darwinia-network/darwinia.git?branch=bump-deps#4ea75571cce207c1989f31eeb83fe2a872e30529" +dependencies = [ + "darwinia-balances 2.6.10", + "darwinia-common-primitives", + "darwinia-support 2.6.10", + "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", + "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", + "max-encoded-len", + "pallet-authorship 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", + "pallet-transaction-payment", + "pallet-treasury", + "parity-scale-codec", + "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", + "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", + "static_assertions", +] + [[package]] name = "darwinia-democracy" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "parity-scale-codec", @@ -1936,7 +1873,7 @@ dependencies = [ [[package]] name = "darwinia-democracy" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-support 2.7.0", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -1951,9 +1888,9 @@ dependencies = [ [[package]] name = "darwinia-elections-phragmen" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "log", @@ -1968,7 +1905,7 @@ dependencies = [ [[package]] name = "darwinia-elections-phragmen" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-support 2.7.0", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -1985,11 +1922,11 @@ dependencies = [ [[package]] name = "darwinia-evm" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "array-bytes", "darwinia-balances 2.6.10", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "dp-evm 2.6.10", "evm", "evm-gasometer", @@ -2013,7 +1950,7 @@ dependencies = [ [[package]] name = "darwinia-evm" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "darwinia-balances 2.7.0", @@ -2041,7 +1978,7 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-bridge-ethereum" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-evm 2.7.0", "darwinia-evm-precompile-utils", @@ -2057,10 +1994,10 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-bridge-s2s" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "bp-message-dispatch", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-runtime", "darwinia-evm 2.7.0", "darwinia-evm-precompile-utils", "darwinia-support 2.7.0", @@ -2080,7 +2017,7 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-dispatch" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-evm 2.7.0", "darwinia-support 2.7.0", @@ -2095,7 +2032,7 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-simple" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "dp-evm 2.6.10", "evm", @@ -2107,7 +2044,7 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-simple" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "dp-evm 2.7.0", "evm", @@ -2119,11 +2056,11 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-transfer" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "array-bytes", "darwinia-evm 2.6.10", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "dp-evm 2.6.10", "ethabi 13.0.0", "ethereum-types", @@ -2144,7 +2081,7 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-transfer" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "darwinia-evm 2.7.0", @@ -2169,7 +2106,7 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-utils" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-evm-precompile-utils-macro", "darwinia-support 2.7.0", @@ -2179,7 +2116,7 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-utils-macro" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "evm", "proc-macro2", @@ -2192,13 +2129,13 @@ dependencies = [ [[package]] name = "darwinia-fee-market" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "bitvec", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", - "dp-fee 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "bp-messages", + "bp-runtime", + "darwinia-support 2.6.10", + "dp-fee 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "log", @@ -2215,11 +2152,11 @@ dependencies = [ [[package]] name = "darwinia-fee-market" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "bitvec", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", + "bp-runtime", "darwinia-support 2.7.0", "dp-fee 2.7.0", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -2238,9 +2175,9 @@ dependencies = [ [[package]] name = "darwinia-fee-market-rpc-runtime-api" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", "parity-scale-codec", "serde 1.0.130", "sp-api", @@ -2251,9 +2188,9 @@ dependencies = [ [[package]] name = "darwinia-fee-market-rpc-runtime-api" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", "parity-scale-codec", "serde 1.0.130", "sp-api", @@ -2264,12 +2201,12 @@ dependencies = [ [[package]] name = "darwinia-header-mmr" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "ckb-merkle-mountain-range", "darwinia-header-mmr-rpc-runtime-api 2.6.6", - "darwinia-relay-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-relay-primitives 2.6.10", + "darwinia-support 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "log", @@ -2284,7 +2221,7 @@ dependencies = [ [[package]] name = "darwinia-header-mmr" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "ckb-merkle-mountain-range", "darwinia-header-mmr-rpc-runtime-api 2.7.0", @@ -2304,9 +2241,9 @@ dependencies = [ [[package]] name = "darwinia-header-mmr-rpc-runtime-api" version = "2.6.6" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "parity-scale-codec", "serde 1.0.130", "sp-api", @@ -2317,7 +2254,7 @@ dependencies = [ [[package]] name = "darwinia-header-mmr-rpc-runtime-api" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-support 2.7.0", "parity-scale-codec", @@ -2330,10 +2267,10 @@ dependencies = [ [[package]] name = "darwinia-relay-authorities" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "darwinia-relay-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-relay-primitives 2.6.10", + "darwinia-support 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "log", @@ -2345,7 +2282,7 @@ dependencies = [ [[package]] name = "darwinia-relay-authorities" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-relay-primitives 2.7.0", "darwinia-support 2.7.0", @@ -2360,18 +2297,7 @@ dependencies = [ [[package]] name = "darwinia-relay-primitives" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3#ed73e1a2619107dbe02ce636f174c4570552c946" -dependencies = [ - "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "parity-scale-codec", - "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", -] - -[[package]] -name = "darwinia-relay-primitives" -version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "parity-scale-codec", @@ -2382,24 +2308,9 @@ dependencies = [ [[package]] name = "darwinia-relay-primitives" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" -dependencies = [ - "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "parity-scale-codec", - "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", -] - -[[package]] -name = "darwinia-relayer-game" -version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3#ed73e1a2619107dbe02ce636f174c4570552c946" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ - "darwinia-relay-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3)", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3)", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "log", "parity-scale-codec", "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -2408,10 +2319,10 @@ dependencies = [ [[package]] name = "darwinia-relayer-game" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "darwinia-relay-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-relay-primitives 2.6.10", + "darwinia-support 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "log", @@ -2423,7 +2334,7 @@ dependencies = [ [[package]] name = "darwinia-relayer-game" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-relay-primitives 2.7.0", "darwinia-support 2.7.0", @@ -2438,17 +2349,18 @@ dependencies = [ [[package]] name = "darwinia-runtime" version = "0.11.6" -source = "git+https://github.com/darwinia-network/darwinia.git?branch=bump-deps#db5f7808f496ce757326797a2b794a64669737db" +source = "git+https://github.com/darwinia-network/darwinia.git?branch=bump-deps#4ea75571cce207c1989f31eeb83fe2a872e30529" dependencies = [ "bp-message-dispatch", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-primitives 0.11.6", + "bp-messages", + "bp-runtime", "bridge-runtime-common", - "common-primitives 0.11.6", "darwinia-balances 2.6.10", "darwinia-balances-rpc-runtime-api 2.6.10", - "darwinia-bridge-ethereum 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-bridge-ethereum 2.6.10", + "darwinia-bridge-primitives", + "darwinia-common-primitives", + "darwinia-common-runtime", "darwinia-democracy 2.6.10", "darwinia-elections-phragmen 2.6.10", "darwinia-fee-market 2.6.10", @@ -2456,14 +2368,13 @@ dependencies = [ "darwinia-header-mmr 2.6.10", "darwinia-header-mmr-rpc-runtime-api 2.6.6", "darwinia-relay-authorities 2.6.10", - "darwinia-relay-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", - "darwinia-relayer-game 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", - "darwinia-runtime-common", + "darwinia-relay-primitives 2.6.10", + "darwinia-relayer-game 2.6.10", "darwinia-staking 2.6.10", "darwinia-staking-rpc-runtime-api 2.6.10", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "darwinia-vesting 2.6.10", - "ethereum-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "ethereum-primitives 2.6.10", "frame-executive", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -2523,34 +2434,13 @@ dependencies = [ "to-tron-backing 2.6.10", ] -[[package]] -name = "darwinia-runtime-common" -version = "0.11.6" -source = "git+https://github.com/darwinia-network/darwinia.git?branch=bump-deps#db5f7808f496ce757326797a2b794a64669737db" -dependencies = [ - "common-primitives 0.11.6", - "darwinia-balances 2.6.10", - "darwinia-staking 2.6.10", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", - "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "max-encoded-len", - "pallet-authorship 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "pallet-transaction-payment", - "pallet-treasury", - "parity-scale-codec", - "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "static_assertions", -] - [[package]] name = "darwinia-staking" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "darwinia-staking-rpc-runtime-api 2.6.10", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "frame-election-provider-support", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -2571,7 +2461,7 @@ dependencies = [ [[package]] name = "darwinia-staking" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-staking-rpc-runtime-api 2.7.0", "darwinia-support 2.7.0", @@ -2595,9 +2485,9 @@ dependencies = [ [[package]] name = "darwinia-staking-rpc-runtime-api" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "parity-scale-codec", "serde 1.0.130", "sp-api", @@ -2607,7 +2497,7 @@ dependencies = [ [[package]] name = "darwinia-staking-rpc-runtime-api" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-support 2.7.0", "parity-scale-codec", @@ -2619,34 +2509,12 @@ dependencies = [ [[package]] name = "darwinia-support" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3#ed73e1a2619107dbe02ce636f174c4570552c946" -dependencies = [ - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-3)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-3)", - "ethereum", - "ethereum-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3)", - "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "impl-trait-for-tuples", - "max-encoded-len", - "num-traits 0.2.14", - "parity-scale-codec", - "sha3 0.9.1", - "sp-core 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-io 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", -] - -[[package]] -name = "darwinia-support" -version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", + "bp-runtime", "ethereum", - "ethereum-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "ethereum-primitives 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "impl-trait-for-tuples", @@ -2663,10 +2531,10 @@ dependencies = [ [[package]] name = "darwinia-support" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", + "bp-runtime", "ethereum", "ethereum-primitives 2.7.0", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -2685,9 +2553,9 @@ dependencies = [ [[package]] name = "darwinia-vesting" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "parity-scale-codec", @@ -2698,7 +2566,7 @@ dependencies = [ [[package]] name = "darwinia-vesting" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-support 2.7.0", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -2816,7 +2684,7 @@ checksum = "9ea835d29036a4087793836fa931b08837ad5e957da9e23886b29586fb9b6650" [[package]] name = "dp-asset" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "ethereum-types", "parity-scale-codec", @@ -2827,7 +2695,7 @@ dependencies = [ [[package]] name = "dp-consensus" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "ethereum", "parity-scale-codec", @@ -2841,7 +2709,7 @@ dependencies = [ [[package]] name = "dp-consensus" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "ethereum", "parity-scale-codec", @@ -2855,9 +2723,9 @@ dependencies = [ [[package]] name = "dp-contract" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", "dp-asset", "ethabi 13.0.0", "ethereum-primitives 2.7.0", @@ -2868,7 +2736,7 @@ dependencies = [ [[package]] name = "dp-evm" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "evm", "impl-trait-for-tuples", @@ -2881,7 +2749,7 @@ dependencies = [ [[package]] name = "dp-evm" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "evm", "impl-trait-for-tuples", @@ -2894,21 +2762,9 @@ dependencies = [ [[package]] name = "dp-fee" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3#ed73e1a2619107dbe02ce636f174c4570552c946" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-3)", - "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "parity-scale-codec", - "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", - "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", -] - -[[package]] -name = "dp-fee" -version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" -dependencies = [ - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "parity-scale-codec", "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -2918,9 +2774,9 @@ dependencies = [ [[package]] name = "dp-fee" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "parity-scale-codec", "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -2930,11 +2786,11 @@ dependencies = [ [[package]] name = "dp-s2s" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "bp-message-dispatch", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-runtime", "dp-asset", "dp-contract", "parity-scale-codec", @@ -2946,12 +2802,39 @@ dependencies = [ [[package]] name = "dp-storage" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" [[package]] name = "dp-storage" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" + +[[package]] +name = "drml-bridge-primitives" +version = "2.7.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" +dependencies = [ + "bp-messages", + "bp-runtime", + "bridge-runtime-common", + "darwinia-fee-market 2.7.0", + "drml-common-primitives", + "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", + "pallet-bridge-dispatch", + "sp-api", + "sp-core 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", + "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", + "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", +] + +[[package]] +name = "drml-common-primitives" +version = "2.7.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" +dependencies = [ + "sp-core 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", + "sp-runtime 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", +] [[package]] name = "dtoa" @@ -2962,10 +2845,10 @@ checksum = "56899898ce76aaf4a0f24d914c97ea6ed976d42fec6ad33fcbb0a1103e07b2b0" [[package]] name = "dvm-ethereum" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "darwinia-evm 2.6.10", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "dp-consensus 2.6.10", "dp-evm 2.6.10", "dp-storage 2.6.10", @@ -2991,7 +2874,7 @@ dependencies = [ [[package]] name = "dvm-ethereum" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-evm 2.7.0", "darwinia-support 2.7.0", @@ -3020,10 +2903,10 @@ dependencies = [ [[package]] name = "dvm-rpc-runtime-api" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "darwinia-evm 2.6.10", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "dp-evm 2.6.10", "ethereum", "ethereum-types", @@ -3038,7 +2921,7 @@ dependencies = [ [[package]] name = "dvm-rpc-runtime-api" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-evm 2.7.0", "darwinia-support 2.7.0", @@ -3268,33 +3151,14 @@ dependencies = [ [[package]] name = "ethereum-primitives" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3#ed73e1a2619107dbe02ce636f174c4570552c946" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "array-bytes", "ethash", "ethbloom", "ethereum-types", "keccak-hash", - "merkle-patricia-trie 2.6.10 (git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3)", - "parity-scale-codec", - "rlp 0.5.1", - "rlp-derive", - "serde 1.0.130", - "sp-debug-derive 3.0.0 (registry+https://github.com/rust-lang/crates.io-index)", - "subhasher", -] - -[[package]] -name = "ethereum-primitives" -version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" -dependencies = [ - "array-bytes", - "ethash", - "ethbloom", - "ethereum-types", - "keccak-hash", - "merkle-patricia-trie 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "merkle-patricia-trie 2.6.10", "parity-scale-codec", "rlp 0.5.1", "rlp-derive", @@ -3306,7 +3170,7 @@ dependencies = [ [[package]] name = "ethereum-primitives" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "ethash", @@ -3805,7 +3669,7 @@ dependencies = [ [[package]] name = "from-ethereum-issuing" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "darwinia-bridge-ethereum 2.7.0", @@ -3829,12 +3693,12 @@ dependencies = [ [[package]] name = "from-substrate-issuing" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "bp-message-dispatch", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", + "bp-runtime", "darwinia-evm 2.7.0", "darwinia-support 2.7.0", "dp-asset", @@ -5662,18 +5526,7 @@ checksum = "71d96e3f3c0b6325d8ccd83c33b28acb183edcb6c67938ba104ec546854b0882" [[package]] name = "merkle-patricia-trie" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.6-3#ed73e1a2619107dbe02ce636f174c4570552c946" -dependencies = [ - "hashbrown 0.9.1", - "keccak-hash", - "rlp 0.5.1", - "sp-std 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", -] - -[[package]] -name = "merkle-patricia-trie" -version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "hashbrown 0.9.1", "keccak-hash", @@ -5684,7 +5537,7 @@ dependencies = [ [[package]] name = "merkle-patricia-trie" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "hashbrown 0.9.1", "keccak-hash", @@ -5712,8 +5565,8 @@ dependencies = [ "anyhow", "async-std", "async-trait", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", + "bp-runtime", "futures 0.3.17", "hex", "log", @@ -5798,7 +5651,7 @@ dependencies = [ [[package]] name = "module-transaction-pause" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -6195,7 +6048,7 @@ version = "0.1.0" source = "git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4#495a773403e5827bbf9d7b20d97333f673628db9" dependencies = [ "bp-message-dispatch", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-runtime", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "log", @@ -6211,7 +6064,7 @@ version = "0.1.0" source = "git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4#495a773403e5827bbf9d7b20d97333f673628db9" dependencies = [ "bp-header-chain", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-runtime", "bp-test-utils", "finality-grandpa", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -6233,8 +6086,8 @@ source = "git+https://github.com/darwinia-network/parity-bridges-common.git?tag= dependencies = [ "bitvec", "bp-message-dispatch", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", + "bp-runtime", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "log", @@ -6646,15 +6499,13 @@ dependencies = [ [[package]] name = "pangolin-runtime" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "bp-message-dispatch", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-primitives 2.7.0", + "bp-messages", + "bp-runtime", "bridge-runtime-common", - "common-primitives 2.7.0", "common-runtime", "darwinia-balances 2.7.0", "darwinia-balances-rpc-runtime-api 2.7.0", @@ -6685,6 +6536,8 @@ dependencies = [ "dp-evm 2.7.0", "dp-fee 2.7.0", "dp-s2s", + "drml-bridge-primitives", + "drml-common-primitives", "dvm-ethereum 2.7.0", "dvm-rpc-runtime-api 2.7.0", "ethereum-primitives 2.7.0", @@ -6757,16 +6610,14 @@ dependencies = [ [[package]] name = "pangoro-runtime" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "bp-header-chain", "bp-message-dispatch", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-primitives 2.7.0", + "bp-messages", + "bp-runtime", "bridge-runtime-common", - "common-primitives 2.7.0", "common-runtime", "darwinia-balances 2.7.0", "darwinia-balances-rpc-runtime-api 2.7.0", @@ -6778,6 +6629,8 @@ dependencies = [ "dp-asset", "dp-fee 2.7.0", "dp-s2s", + "drml-bridge-primitives", + "drml-common-primitives", "frame-benchmarking", "frame-election-provider-support", "frame-executive", @@ -7658,7 +7511,7 @@ dependencies = [ "async-std", "async-trait", "bp-header-chain", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-runtime", "finality-relay", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -10174,8 +10027,8 @@ dependencies = [ "async-std", "async-trait", "bp-header-chain", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", + "bp-runtime", "bridge-runtime-common", "finality-grandpa", "finality-relay", @@ -10274,7 +10127,7 @@ name = "support-ethereum" version = "0.4.8" dependencies = [ "anyhow", - "bridge-primitives 0.4.8", + "bridge-primitives", "frame-support 3.0.0 (registry+https://github.com/rust-lang/crates.io-index)", "log", "pallet-im-online 3.0.0 (registry+https://github.com/rust-lang/crates.io-index)", @@ -10305,7 +10158,7 @@ name = "support-proc-macro" version = "0.4.8" dependencies = [ "anyhow", - "bridge-primitives 0.4.8", + "bridge-primitives", "proc-macro2", "proc_macro_roids", "quote", @@ -10395,18 +10248,18 @@ dependencies = [ "anyhow", "async-trait", "bp-header-chain", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-primitives 0.11.6", + "bp-messages", + "bp-runtime", "bridge-runtime-common", "bridge-traits", - "common-primitives 0.11.6", "component-crab-s2s", "component-darwinia-s2s", "component-subscan", "crab-runtime", + "darwinia-bridge-primitives", + "darwinia-common-primitives", + "darwinia-common-runtime", "darwinia-runtime", - "darwinia-runtime-common", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "futures 0.3.17", "futures-timer", @@ -10471,16 +10324,16 @@ dependencies = [ "anyhow", "async-trait", "bp-header-chain", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bridge-primitives 2.7.0", + "bp-messages", + "bp-runtime", "bridge-runtime-common", "bridge-traits", - "common-primitives 2.7.0", "common-runtime", "component-pangolin-s2s", "component-pangoro-s2s", "component-subscan", + "drml-bridge-primitives", + "drml-common-primitives", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "futures 0.3.17", "futures-timer", @@ -10724,13 +10577,13 @@ checksum = "cda74da7e1a664f795bb1f8a87ec406fb89a02522cf6e50620d016add6dbbf5c" [[package]] name = "to-ethereum-backing" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ "array-bytes", - "darwinia-relay-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-relay-primitives 2.6.10", + "darwinia-support 2.6.10", "ethabi 13.0.0", - "ethereum-primitives 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "ethereum-primitives 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "log", @@ -10745,7 +10598,7 @@ dependencies = [ [[package]] name = "to-ethereum-backing" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "darwinia-relay-primitives 2.7.0", @@ -10766,12 +10619,12 @@ dependencies = [ [[package]] name = "to-substrate-backing" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "array-bytes", "bp-message-dispatch", - "bp-messages 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", - "bp-runtime 0.1.0 (git+https://github.com/darwinia-network/parity-bridges-common.git?tag=darwinia-v0.11.6-4)", + "bp-messages", + "bp-runtime", "darwinia-support 2.7.0", "dp-asset", "dp-contract", @@ -10792,9 +10645,9 @@ dependencies = [ [[package]] name = "to-tron-backing" version = "2.6.10" -source = "git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps-darwinia#ac559d47c4fa4dbaf4c807015c4461d7a8464c80" dependencies = [ - "darwinia-support 2.6.10 (git+https://github.com/darwinia-network/darwinia-common?branch=bump-deps-darwinia)", + "darwinia-support 2.6.10", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "frame-system 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", "parity-scale-codec", @@ -10804,7 +10657,7 @@ dependencies = [ [[package]] name = "to-tron-backing" version = "2.7.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#2799b0afede7de6ac67c646fcdd7227d68909e08" +source = "git+https://github.com/darwinia-network/darwinia-common.git?branch=bump-deps#d36cfb35c5d0b57104a0724d3825c04284de92e2" dependencies = [ "darwinia-support 2.7.0", "frame-support 3.0.0 (git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.6-1)", @@ -11107,7 +10960,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1f559b464de2e2bdabcac6a210d12e9b5a5973c251e102c44c585c71d51bd78e" dependencies = [ "cfg-if 1.0.0", - "rand 0.8.4", + "rand 0.3.23", "static_assertions", ] diff --git a/components/client-crab-s2s/Cargo.toml b/components/client-crab-s2s/Cargo.toml index 29793cc3f..727adfbbc 100644 --- a/components/client-crab-s2s/Cargo.toml +++ b/components/client-crab-s2s/Cargo.toml @@ -33,10 +33,10 @@ bp-messages = { git = "https://github.com/darwinia-network/parity-bri bp-runtime = { git = "https://github.com/darwinia-network/parity-bridges-common.git", tag = "darwinia-v0.11.6-4" } ## Bridge dependencies -crab-runtime = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } -common-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } -bridge-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } -dp-fee = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.6-3" } +crab-runtime = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } +darwinia-common-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } +darwinia-bridge-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } +dp-fee = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps-darwinia" } diff --git a/components/client-crab-s2s/src/api.rs b/components/client-crab-s2s/src/api.rs index 2b25548ef..0e54c67df 100644 --- a/components/client-crab-s2s/src/api.rs +++ b/components/client-crab-s2s/src/api.rs @@ -1,8 +1,8 @@ use bp_messages::{LaneId, MessageNonce}; use codec::Encode; -use common_primitives::AccountId; -use common_primitives::Balance; -use common_primitives::BlockNumber; +use darwinia_common_primitives::AccountId; +use darwinia_common_primitives::Balance; +use darwinia_common_primitives::BlockNumber; use dp_fee::{Order, Relayer}; use relay_substrate_client::{ChainBase, Client, TransactionSignScheme, UnsignedTransaction}; use relay_utils::relay_loop::Client as RelayLoopClient; @@ -35,7 +35,7 @@ impl CrabApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -57,7 +57,7 @@ impl CrabApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -73,7 +73,7 @@ impl CrabApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -94,7 +94,7 @@ impl CrabApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -106,14 +106,14 @@ impl CrabApi { /// Return number of the best finalized block. pub async fn best_finalized_header_number( &mut self, - ) -> anyhow::Result { + ) -> anyhow::Result { match self.client.best_finalized_header_number().await { Ok(v) => Ok(v), Err(e) => { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -149,7 +149,7 @@ impl CrabApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -185,7 +185,7 @@ impl CrabApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } diff --git a/components/client-crab-s2s/src/crab.rs b/components/client-crab-s2s/src/crab.rs index 9359fd075..bec964c1a 100644 --- a/components/client-crab-s2s/src/crab.rs +++ b/components/client-crab-s2s/src/crab.rs @@ -11,7 +11,10 @@ use sp_runtime::{generic::SignedPayload, traits::IdentifyAccount}; use std::time::Duration; /// Pangoro header id. -pub type HeaderId = relay_utils::HeaderId; +pub type HeaderId = relay_utils::HeaderId< + darwinia_common_primitives::Hash, + darwinia_common_primitives::BlockNumber, +>; /// Pangoro chain definition. #[derive(Debug, Clone, Copy)] @@ -22,23 +25,24 @@ impl BridgeChain for CrabChain { } impl ChainBase for CrabChain { - type BlockNumber = common_primitives::BlockNumber; - type Hash = common_primitives::Hash; - type Hasher = common_primitives::Hashing; - type Header = common_primitives::Header; - - type AccountId = common_primitives::AccountId; - type Balance = common_primitives::Balance; - type Index = common_primitives::Nonce; - type Signature = common_primitives::Signature; + type BlockNumber = darwinia_common_primitives::BlockNumber; + type Hash = darwinia_common_primitives::Hash; + type Hasher = darwinia_common_primitives::Hashing; + type Header = darwinia_common_primitives::Header; + + type AccountId = darwinia_common_primitives::AccountId; + type Balance = darwinia_common_primitives::Balance; + type Index = darwinia_common_primitives::Nonce; + type Signature = darwinia_common_primitives::Signature; } impl Chain for CrabChain { const NAME: &'static str = "Crab"; const AVERAGE_BLOCK_INTERVAL: Duration = - Duration::from_millis(common_primitives::MILLISECS_PER_BLOCK); - const STORAGE_PROOF_OVERHEAD: u32 = bridge_primitives::EXTRA_STORAGE_PROOF_SIZE; - const MAXIMAL_ENCODED_ACCOUNT_ID_SIZE: u32 = bridge_primitives::MAXIMAL_ENCODED_ACCOUNT_ID_SIZE; + Duration::from_millis(darwinia_common_primitives::MILLISECS_PER_BLOCK); + const STORAGE_PROOF_OVERHEAD: u32 = darwinia_bridge_primitives::EXTRA_STORAGE_PROOF_SIZE; + const MAXIMAL_ENCODED_ACCOUNT_ID_SIZE: u32 = + darwinia_bridge_primitives::MAXIMAL_ENCODED_ACCOUNT_ID_SIZE; type SignedBlock = crab_runtime::SignedBlock; type Call = crab_runtime::Call; @@ -110,7 +114,7 @@ impl TransactionSignScheme for CrabChain { tx.signature .as_ref() .map(|(address, _, _)| { - let account_id: common_primitives::AccountId = + let account_id: darwinia_common_primitives::AccountId = (*signer.public().as_array_ref()).into(); *address == crab_runtime::Address::from(account_id) }) @@ -135,4 +139,4 @@ impl TransactionSignScheme for CrabChain { pub type SigningParams = sp_core::sr25519::Pair; /// Pangoro header type used in headers sync. -pub type SyncHeader = relay_substrate_client::SyncHeader; +pub type SyncHeader = relay_substrate_client::SyncHeader; diff --git a/components/client-crab-s2s/src/feemarket.rs b/components/client-crab-s2s/src/feemarket.rs index 7ddc2b73b..1eef8c071 100644 --- a/components/client-crab-s2s/src/feemarket.rs +++ b/components/client-crab-s2s/src/feemarket.rs @@ -1,6 +1,6 @@ use std::ops::Range; -use common_primitives::AccountId; +use darwinia_common_primitives::AccountId; use messages_relay::message_lane::MessageLane; use messages_relay::message_lane_loop::{ SourceClient as MessageLaneSourceClient, TargetClient as MessageLaneTargetClient, @@ -42,7 +42,7 @@ impl CrabRelayStrategy { let nonce = &reference.nonce; let order = self .api - .order(bridge_primitives::DARWINIA_CRAB_LANE, *nonce) + .order(darwinia_bridge_primitives::DARWINIA_CRAB_LANE, *nonce) .await .map_err(|e| { log::error!("[Pangoro] Failed to query order: {:?}", e); @@ -101,7 +101,7 @@ impl CrabRelayStrategy { let ranges = relayers .iter() .map(|item| item.valid_range.clone()) - .collect::>>(); + .collect::>>(); let mut maximum_timeout = 0; for range in ranges { diff --git a/components/client-darwinia-s2s/Cargo.toml b/components/client-darwinia-s2s/Cargo.toml index 3f0d1bf62..124e75177 100644 --- a/components/client-darwinia-s2s/Cargo.toml +++ b/components/client-darwinia-s2s/Cargo.toml @@ -33,11 +33,11 @@ bp-messages = { git = "https://github.com/darwinia-network/parity-bri bp-runtime = { git = "https://github.com/darwinia-network/parity-bridges-common.git", tag = "darwinia-v0.11.6-4" } ## Bridge dependencies -darwinia-runtime = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } -common-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } -bridge-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } -darwinia-bridge-ethereum = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.6-3" } -dp-fee = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.6-3" } +darwinia-runtime = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } +darwinia-common-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } +darwinia-bridge-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } +darwinia-bridge-ethereum = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps-darwinia" } +dp-fee = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps-darwinia" } diff --git a/components/client-darwinia-s2s/src/api.rs b/components/client-darwinia-s2s/src/api.rs index 072e67ebc..406306b9d 100644 --- a/components/client-darwinia-s2s/src/api.rs +++ b/components/client-darwinia-s2s/src/api.rs @@ -1,8 +1,8 @@ use bp_messages::{LaneId, MessageNonce}; use codec::Encode; -use common_primitives::AccountId; -use common_primitives::Balance; -use common_primitives::BlockNumber; +use darwinia_common_primitives::AccountId; +use darwinia_common_primitives::Balance; +use darwinia_common_primitives::BlockNumber; use dp_fee::{Order, Relayer}; use relay_substrate_client::{ChainBase, Client, TransactionSignScheme, UnsignedTransaction}; use relay_utils::relay_loop::Client as RelayLoopClient; @@ -35,7 +35,7 @@ impl DarwiniaApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -57,7 +57,7 @@ impl DarwiniaApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -73,7 +73,7 @@ impl DarwiniaApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -94,7 +94,7 @@ impl DarwiniaApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -106,14 +106,14 @@ impl DarwiniaApi { /// Return number of the best finalized block. pub async fn best_finalized_header_number( &mut self, - ) -> anyhow::Result { + ) -> anyhow::Result { match self.client.best_finalized_header_number().await { Ok(v) => Ok(v), Err(e) => { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -149,7 +149,7 @@ impl DarwiniaApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -186,7 +186,7 @@ impl DarwiniaApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } diff --git a/components/client-darwinia-s2s/src/darwinia.rs b/components/client-darwinia-s2s/src/darwinia.rs index bf2a3a2b8..f18344af5 100644 --- a/components/client-darwinia-s2s/src/darwinia.rs +++ b/components/client-darwinia-s2s/src/darwinia.rs @@ -10,10 +10,13 @@ use sp_core::{storage::StorageKey, Pair}; use sp_runtime::{generic::SignedPayload, traits::IdentifyAccount}; /// Pangolin header id. -pub type HeaderId = relay_utils::HeaderId; +pub type HeaderId = relay_utils::HeaderId< + darwinia_common_primitives::Hash, + darwinia_common_primitives::BlockNumber, +>; /// Rialto header type used in headers sync. -pub type SyncHeader = relay_substrate_client::SyncHeader; +pub type SyncHeader = relay_substrate_client::SyncHeader; /// Millau chain definition. #[derive(Debug, Clone, Copy)] @@ -24,23 +27,24 @@ impl BridgeChain for DarwiniaChain { } impl ChainBase for DarwiniaChain { - type BlockNumber = common_primitives::BlockNumber; - type Hash = common_primitives::Hash; - type Hasher = common_primitives::Hashing; - type Header = common_primitives::Header; - - type AccountId = common_primitives::AccountId; - type Balance = common_primitives::Balance; - type Index = common_primitives::Nonce; - type Signature = common_primitives::Signature; + type BlockNumber = darwinia_common_primitives::BlockNumber; + type Hash = darwinia_common_primitives::Hash; + type Hasher = darwinia_common_primitives::Hashing; + type Header = darwinia_common_primitives::Header; + + type AccountId = darwinia_common_primitives::AccountId; + type Balance = darwinia_common_primitives::Balance; + type Index = darwinia_common_primitives::Nonce; + type Signature = darwinia_common_primitives::Signature; } impl Chain for DarwiniaChain { const NAME: &'static str = "Darwinia"; const AVERAGE_BLOCK_INTERVAL: Duration = - Duration::from_millis(common_primitives::MILLISECS_PER_BLOCK); - const STORAGE_PROOF_OVERHEAD: u32 = bridge_primitives::EXTRA_STORAGE_PROOF_SIZE; - const MAXIMAL_ENCODED_ACCOUNT_ID_SIZE: u32 = bridge_primitives::MAXIMAL_ENCODED_ACCOUNT_ID_SIZE; + Duration::from_millis(darwinia_common_primitives::MILLISECS_PER_BLOCK); + const STORAGE_PROOF_OVERHEAD: u32 = darwinia_bridge_primitives::EXTRA_STORAGE_PROOF_SIZE; + const MAXIMAL_ENCODED_ACCOUNT_ID_SIZE: u32 = + darwinia_bridge_primitives::MAXIMAL_ENCODED_ACCOUNT_ID_SIZE; type SignedBlock = darwinia_runtime::SignedBlock; type Call = darwinia_runtime::Call; @@ -110,7 +114,7 @@ impl TransactionSignScheme for DarwiniaChain { tx.signature .as_ref() .map(|(address, _, _)| { - let account_id: common_primitives::AccountId = + let account_id: darwinia_common_primitives::AccountId = (*signer.public().as_array_ref()).into(); *address == darwinia_runtime::Address::from(account_id) }) diff --git a/components/client-darwinia-s2s/src/feemarket.rs b/components/client-darwinia-s2s/src/feemarket.rs index b9a7bddee..29d119292 100644 --- a/components/client-darwinia-s2s/src/feemarket.rs +++ b/components/client-darwinia-s2s/src/feemarket.rs @@ -1,6 +1,6 @@ use std::ops::Range; -use common_primitives::AccountId; +use darwinia_common_primitives::AccountId; use messages_relay::message_lane::MessageLane; use messages_relay::message_lane_loop::{ SourceClient as MessageLaneSourceClient, TargetClient as MessageLaneTargetClient, @@ -39,7 +39,7 @@ impl RelayStrategy for DarwiniaRelayStrategy { let nonce = &reference.nonce; let order = self .api - .order(bridge_primitives::DARWINIA_CRAB_LANE, *nonce) + .order(darwinia_bridge_primitives::DARWINIA_CRAB_LANE, *nonce) .await .map_err(|e| { log::error!("Failed to query order: {:?}", e); @@ -94,7 +94,7 @@ impl RelayStrategy for DarwiniaRelayStrategy { let ranges = relayers .iter() .map(|item| item.valid_range.clone()) - .collect::>>(); + .collect::>>(); let mut maximum_timeout = 0; for range in ranges { diff --git a/components/client-pangolin-s2s/Cargo.toml b/components/client-pangolin-s2s/Cargo.toml index 4bdcba28b..0087b1cac 100644 --- a/components/client-pangolin-s2s/Cargo.toml +++ b/components/client-pangolin-s2s/Cargo.toml @@ -34,8 +34,8 @@ bp-runtime = { git = "https://github.com/darwinia-network/parity-bri ## Bridge dependencies pangolin-runtime = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } -common-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } -bridge-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } +drml-common-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } +drml-bridge-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } darwinia-bridge-ethereum = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } dp-fee = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } diff --git a/components/client-pangolin-s2s/src/api.rs b/components/client-pangolin-s2s/src/api.rs index 2b24d48f4..724472e3d 100644 --- a/components/client-pangolin-s2s/src/api.rs +++ b/components/client-pangolin-s2s/src/api.rs @@ -1,16 +1,10 @@ -use std::future::Future; -use std::pin::Pin; - use bp_messages::{LaneId, MessageNonce}; -use bridge_traits::error::StandardError; -use codec::{Decode, Encode}; -use common_primitives::AccountId; -use common_primitives::Balance; -use common_primitives::BlockNumber; +use codec::Encode; use dp_fee::{Order, Relayer}; -use relay_substrate_client::{ - ChainBase, Client, HeaderIdOf, TransactionSignScheme, UnsignedTransaction, -}; +use drml_common_primitives::AccountId; +use drml_common_primitives::Balance; +use drml_common_primitives::BlockNumber; +use relay_substrate_client::{ChainBase, Client, TransactionSignScheme, UnsignedTransaction}; use relay_utils::relay_loop::Client as RelayLoopClient; use relay_utils::MaybeConnectionError; use sp_core::storage::StorageKey; @@ -41,7 +35,7 @@ impl PangolinApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -63,7 +57,7 @@ impl PangolinApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -79,7 +73,7 @@ impl PangolinApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -100,7 +94,7 @@ impl PangolinApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -112,14 +106,14 @@ impl PangolinApi { /// Return number of the best finalized block. pub async fn best_finalized_header_number( &mut self, - ) -> anyhow::Result { + ) -> anyhow::Result { match self.client.best_finalized_header_number().await { Ok(v) => Ok(v), Err(e) => { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -155,7 +149,7 @@ impl PangolinApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -192,7 +186,7 @@ impl PangolinApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } diff --git a/components/client-pangolin-s2s/src/feemarket.rs b/components/client-pangolin-s2s/src/feemarket.rs index 2330ab30f..275480505 100644 --- a/components/client-pangolin-s2s/src/feemarket.rs +++ b/components/client-pangolin-s2s/src/feemarket.rs @@ -1,6 +1,6 @@ use std::ops::Range; -use common_primitives::AccountId; +use drml_common_primitives::AccountId; use messages_relay::message_lane::MessageLane; use messages_relay::message_lane_loop::{ SourceClient as MessageLaneSourceClient, TargetClient as MessageLaneTargetClient, @@ -39,7 +39,7 @@ impl RelayStrategy for PangolinRelayStrategy { let nonce = &reference.nonce; let order = self .api - .order(bridge_primitives::PANGORO_PANGOLIN_LANE, *nonce) + .order(drml_bridge_primitives::PANGORO_PANGOLIN_LANE, *nonce) .await .map_err(|e| { log::error!("Failed to query order: {:?}", e); @@ -94,7 +94,7 @@ impl RelayStrategy for PangolinRelayStrategy { let ranges = relayers .iter() .map(|item| item.valid_range.clone()) - .collect::>>(); + .collect::>>(); let mut maximum_timeout = 0; for range in ranges { diff --git a/components/client-pangolin-s2s/src/pangolin.rs b/components/client-pangolin-s2s/src/pangolin.rs index a5ca133e6..3394074ff 100644 --- a/components/client-pangolin-s2s/src/pangolin.rs +++ b/components/client-pangolin-s2s/src/pangolin.rs @@ -10,10 +10,11 @@ use sp_core::{storage::StorageKey, Pair}; use sp_runtime::{generic::SignedPayload, traits::IdentifyAccount}; /// Pangolin header id. -pub type HeaderId = relay_utils::HeaderId; +pub type HeaderId = + relay_utils::HeaderId; /// Rialto header type used in headers sync. -pub type SyncHeader = relay_substrate_client::SyncHeader; +pub type SyncHeader = relay_substrate_client::SyncHeader; /// Millau chain definition. #[derive(Debug, Clone, Copy)] @@ -24,23 +25,24 @@ impl BridgeChain for PangolinChain { } impl ChainBase for PangolinChain { - type BlockNumber = common_primitives::BlockNumber; - type Hash = common_primitives::Hash; - type Hasher = common_primitives::Hashing; - type Header = common_primitives::Header; - - type AccountId = common_primitives::AccountId; - type Balance = common_primitives::Balance; - type Index = common_primitives::Nonce; - type Signature = common_primitives::Signature; + type BlockNumber = drml_common_primitives::BlockNumber; + type Hash = drml_common_primitives::Hash; + type Hasher = drml_common_primitives::Hashing; + type Header = drml_common_primitives::Header; + + type AccountId = drml_common_primitives::AccountId; + type Balance = drml_common_primitives::Balance; + type Index = drml_common_primitives::Nonce; + type Signature = drml_common_primitives::Signature; } impl Chain for PangolinChain { const NAME: &'static str = "Pangolin"; const AVERAGE_BLOCK_INTERVAL: Duration = - Duration::from_millis(common_primitives::MILLISECS_PER_BLOCK); - const STORAGE_PROOF_OVERHEAD: u32 = bridge_primitives::EXTRA_STORAGE_PROOF_SIZE; - const MAXIMAL_ENCODED_ACCOUNT_ID_SIZE: u32 = bridge_primitives::MAXIMAL_ENCODED_ACCOUNT_ID_SIZE; + Duration::from_millis(drml_common_primitives::MILLISECS_PER_BLOCK); + const STORAGE_PROOF_OVERHEAD: u32 = drml_bridge_primitives::EXTRA_STORAGE_PROOF_SIZE; + const MAXIMAL_ENCODED_ACCOUNT_ID_SIZE: u32 = + drml_bridge_primitives::MAXIMAL_ENCODED_ACCOUNT_ID_SIZE; type SignedBlock = pangolin_runtime::SignedBlock; type Call = pangolin_runtime::Call; @@ -110,7 +112,7 @@ impl TransactionSignScheme for PangolinChain { tx.signature .as_ref() .map(|(address, _, _)| { - let account_id: common_primitives::AccountId = + let account_id: drml_common_primitives::AccountId = (*signer.public().as_array_ref()).into(); *address == pangolin_runtime::Address::from(account_id) }) diff --git a/components/client-pangolin-s2s/tests/client_substrate.rs b/components/client-pangolin-s2s/tests/client_substrate.rs index a890630cc..9083e6743 100644 --- a/components/client-pangolin-s2s/tests/client_substrate.rs +++ b/components/client-pangolin-s2s/tests/client_substrate.rs @@ -5,7 +5,7 @@ fn test_account() { let signer = "//Alice"; let pair = sp_core::sr25519::Pair::from_string(&signer, None).unwrap(); let public = pair.public(); - let account = common_primitives::AccountId::from(public.0); + let account = drml_common_primitives::AccountId::from(public.0); assert_eq!( account.to_string(), "5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY" diff --git a/components/client-pangoro-s2s/Cargo.toml b/components/client-pangoro-s2s/Cargo.toml index ec3764ac6..154aa536c 100644 --- a/components/client-pangoro-s2s/Cargo.toml +++ b/components/client-pangoro-s2s/Cargo.toml @@ -35,8 +35,8 @@ bp-runtime = { git = "https://github.com/darwinia-network/parity-bri ## Bridge dependencies pangoro-runtime = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } -common-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } -bridge-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } +drml-common-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } +drml-bridge-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } dp-fee = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } diff --git a/components/client-pangoro-s2s/src/api.rs b/components/client-pangoro-s2s/src/api.rs index 9f80e9cdd..d0edc1402 100644 --- a/components/client-pangoro-s2s/src/api.rs +++ b/components/client-pangoro-s2s/src/api.rs @@ -1,9 +1,9 @@ use bp_messages::{LaneId, MessageNonce}; use codec::Encode; -use common_primitives::AccountId; -use common_primitives::Balance; -use common_primitives::BlockNumber; use dp_fee::{Order, Relayer}; +use drml_common_primitives::AccountId; +use drml_common_primitives::Balance; +use drml_common_primitives::BlockNumber; use relay_substrate_client::{ChainBase, Client, TransactionSignScheme, UnsignedTransaction}; use relay_utils::relay_loop::Client as RelayLoopClient; use relay_utils::MaybeConnectionError; @@ -35,7 +35,7 @@ impl PangoroApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -57,7 +57,7 @@ impl PangoroApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -73,7 +73,7 @@ impl PangoroApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -94,7 +94,7 @@ impl PangoroApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -106,14 +106,14 @@ impl PangoroApi { /// Return number of the best finalized block. pub async fn best_finalized_header_number( &mut self, - ) -> anyhow::Result { + ) -> anyhow::Result { match self.client.best_finalized_header_number().await { Ok(v) => Ok(v), Err(e) => { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -149,7 +149,7 @@ impl PangoroApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } @@ -185,7 +185,7 @@ impl PangoroApi { if e.is_connection_error() { self.client.reconnect().await?; } - Err(e)? + Err(e.into()) } } } diff --git a/components/client-pangoro-s2s/src/feemarket.rs b/components/client-pangoro-s2s/src/feemarket.rs index 8d9cf15be..fd15f3532 100644 --- a/components/client-pangoro-s2s/src/feemarket.rs +++ b/components/client-pangoro-s2s/src/feemarket.rs @@ -1,6 +1,6 @@ use std::ops::Range; -use common_primitives::AccountId; +use drml_common_primitives::AccountId; use messages_relay::message_lane::MessageLane; use messages_relay::message_lane_loop::{ SourceClient as MessageLaneSourceClient, TargetClient as MessageLaneTargetClient, @@ -42,7 +42,7 @@ impl PangoroRelayStrategy { let nonce = &reference.nonce; let order = self .api - .order(bridge_primitives::PANGORO_PANGOLIN_LANE, *nonce) + .order(drml_bridge_primitives::PANGORO_PANGOLIN_LANE, *nonce) .await .map_err(|e| { log::error!("[Pangoro] Failed to query order: {:?}", e); @@ -101,7 +101,7 @@ impl PangoroRelayStrategy { let ranges = relayers .iter() .map(|item| item.valid_range.clone()) - .collect::>>(); + .collect::>>(); let mut maximum_timeout = 0; for range in ranges { diff --git a/components/client-pangoro-s2s/src/pangoro.rs b/components/client-pangoro-s2s/src/pangoro.rs index 3abb41663..c3d2965e6 100644 --- a/components/client-pangoro-s2s/src/pangoro.rs +++ b/components/client-pangoro-s2s/src/pangoro.rs @@ -11,7 +11,8 @@ use sp_runtime::{generic::SignedPayload, traits::IdentifyAccount}; use std::time::Duration; /// Pangoro header id. -pub type HeaderId = relay_utils::HeaderId; +pub type HeaderId = + relay_utils::HeaderId; /// Pangoro chain definition. #[derive(Debug, Clone, Copy)] @@ -22,23 +23,24 @@ impl BridgeChain for PangoroChain { } impl ChainBase for PangoroChain { - type BlockNumber = common_primitives::BlockNumber; - type Hash = common_primitives::Hash; - type Hasher = common_primitives::Hashing; - type Header = common_primitives::Header; - - type AccountId = common_primitives::AccountId; - type Balance = common_primitives::Balance; - type Index = common_primitives::Nonce; - type Signature = common_primitives::Signature; + type BlockNumber = drml_common_primitives::BlockNumber; + type Hash = drml_common_primitives::Hash; + type Hasher = drml_common_primitives::Hashing; + type Header = drml_common_primitives::Header; + + type AccountId = drml_common_primitives::AccountId; + type Balance = drml_common_primitives::Balance; + type Index = drml_common_primitives::Nonce; + type Signature = drml_common_primitives::Signature; } impl Chain for PangoroChain { const NAME: &'static str = "Pangoro"; const AVERAGE_BLOCK_INTERVAL: Duration = - Duration::from_millis(common_primitives::MILLISECS_PER_BLOCK); - const STORAGE_PROOF_OVERHEAD: u32 = bridge_primitives::EXTRA_STORAGE_PROOF_SIZE; - const MAXIMAL_ENCODED_ACCOUNT_ID_SIZE: u32 = bridge_primitives::MAXIMAL_ENCODED_ACCOUNT_ID_SIZE; + Duration::from_millis(drml_common_primitives::MILLISECS_PER_BLOCK); + const STORAGE_PROOF_OVERHEAD: u32 = drml_bridge_primitives::EXTRA_STORAGE_PROOF_SIZE; + const MAXIMAL_ENCODED_ACCOUNT_ID_SIZE: u32 = + drml_bridge_primitives::MAXIMAL_ENCODED_ACCOUNT_ID_SIZE; type SignedBlock = pangoro_runtime::SignedBlock; type Call = pangoro_runtime::Call; @@ -106,7 +108,7 @@ impl TransactionSignScheme for PangoroChain { tx.signature .as_ref() .map(|(address, _, _)| { - let account_id: common_primitives::AccountId = + let account_id: drml_common_primitives::AccountId = (*signer.public().as_array_ref()).into(); *address == pangoro_runtime::Address::from(account_id) }) @@ -131,4 +133,4 @@ impl TransactionSignScheme for PangoroChain { pub type SigningParams = sp_core::sr25519::Pair; /// Pangoro header type used in headers sync. -pub type SyncHeader = relay_substrate_client::SyncHeader; +pub type SyncHeader = relay_substrate_client::SyncHeader; diff --git a/task/task-darwinia-crab/Cargo.toml b/task/task-darwinia-crab/Cargo.toml index 81375c4bd..5a9857350 100644 --- a/task/task-darwinia-crab/Cargo.toml +++ b/task/task-darwinia-crab/Cargo.toml @@ -64,9 +64,9 @@ component-crab-s2s = { path = "../../components/client-crab-s2s" } component-subscan = { path = "../../components/subscan" } ## darwinia common -bridge-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } -common-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } -darwinia-runtime-common = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } +darwinia-bridge-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } +darwinia-common-primitives = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } +darwinia-common-runtime = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } ## darwinia darwinia-runtime = { git = "https://github.com/darwinia-network/darwinia.git", branch = "bump-deps" } diff --git a/task/task-darwinia-crab/src/chains/crab.rs b/task/task-darwinia-crab/src/chains/crab.rs index 827c5c3cd..d89c0be85 100644 --- a/task/task-darwinia-crab/src/chains/crab.rs +++ b/task/task-darwinia-crab/src/chains/crab.rs @@ -27,33 +27,33 @@ mod s2s_const { impl ChainConst for CrabChainConst { const OUTBOUND_LANE_MESSAGE_DETAILS_METHOD: &'static str = - bridge_primitives::TO_CRAB_MESSAGE_DETAILS_METHOD; + darwinia_bridge_primitives::TO_CRAB_MESSAGE_DETAILS_METHOD; const OUTBOUND_LANE_LATEST_GENERATED_NONCE_METHOD: &'static str = - bridge_primitives::TO_CRAB_LATEST_GENERATED_NONCE_METHOD; + darwinia_bridge_primitives::TO_CRAB_LATEST_GENERATED_NONCE_METHOD; const OUTBOUND_LANE_LATEST_RECEIVED_NONCE_METHOD: &'static str = - bridge_primitives::TO_CRAB_LATEST_RECEIVED_NONCE_METHOD; + darwinia_bridge_primitives::TO_CRAB_LATEST_RECEIVED_NONCE_METHOD; const INBOUND_LANE_LATEST_RECEIVED_NONCE_METHOD: &'static str = - bridge_primitives::FROM_CRAB_LATEST_RECEIVED_NONCE_METHOD; + darwinia_bridge_primitives::FROM_CRAB_LATEST_RECEIVED_NONCE_METHOD; const INBOUND_LANE_LATEST_CONFIRMED_NONCE_METHOD: &'static str = - bridge_primitives::FROM_CRAB_LATEST_CONFIRMED_NONCE_METHOD; + darwinia_bridge_primitives::FROM_CRAB_LATEST_CONFIRMED_NONCE_METHOD; const INBOUND_LANE_UNREWARDED_RELAYERS_STATE: &'static str = - bridge_primitives::FROM_CRAB_UNREWARDED_RELAYERS_STATE; + darwinia_bridge_primitives::FROM_CRAB_UNREWARDED_RELAYERS_STATE; const BEST_FINALIZED_SOURCE_HEADER_ID_AT_TARGET: &'static str = - bridge_primitives::BEST_FINALIZED_CRAB_HEADER_METHOD; + darwinia_bridge_primitives::BEST_FINALIZED_CRAB_HEADER_METHOD; const BEST_FINALIZED_TARGET_HEADER_ID_AT_SOURCE: &'static str = - bridge_primitives::BEST_FINALIZED_CRAB_HEADER_METHOD; + darwinia_bridge_primitives::BEST_FINALIZED_CRAB_HEADER_METHOD; const MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE: MessageNonce = - bridge_primitives::MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE; + darwinia_bridge_primitives::MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE; const MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE: MessageNonce = - bridge_primitives::MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE; + darwinia_bridge_primitives::MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE; const AVERAGE_BLOCK_INTERVAL: Duration = DarwiniaChain::AVERAGE_BLOCK_INTERVAL; - const BRIDGE_CHAIN_ID: ChainId = bridge_primitives::CRAB_CHAIN_ID; + const BRIDGE_CHAIN_ID: ChainId = darwinia_bridge_primitives::CRAB_CHAIN_ID; const MESSAGE_PALLET_NAME_AT_SOURCE: &'static str = - bridge_primitives::WITH_DARWINIA_MESSAGES_PALLET_NAME; + darwinia_bridge_primitives::WITH_DARWINIA_MESSAGES_PALLET_NAME; const MESSAGE_PALLET_NAME_AT_TARGET: &'static str = - bridge_primitives::WITH_CRAB_MESSAGES_PALLET_NAME; + darwinia_bridge_primitives::WITH_CRAB_MESSAGES_PALLET_NAME; const PAY_INBOUND_DISPATCH_FEE_WEIGHT_AT_TARGET_CHAIN: Weight = - bridge_primitives::PAY_INBOUND_DISPATCH_FEE_WEIGHT; + darwinia_bridge_primitives::PAY_INBOUND_DISPATCH_FEE_WEIGHT; type SigningParams = sp_core::sr25519::Pair; } @@ -111,7 +111,7 @@ mod s2s_headers { type TargetChain = DarwiniaChain; - fn transactions_author(&self) -> common_primitives::AccountId { + fn transactions_author(&self) -> darwinia_common_primitives::AccountId { (*self.finality_pipeline.target_sign.public().as_array_ref()).into() } @@ -120,7 +120,7 @@ mod s2s_headers { era: bp_runtime::TransactionEraOf, transaction_nonce: IndexOf, header: component_crab_s2s::SyncHeader, - proof: GrandpaJustification, + proof: GrandpaJustification, ) -> Bytes { let call = darwinia_runtime::BridgeGrandpaCall::< darwinia_runtime::Runtime, @@ -217,7 +217,7 @@ mod s2s_messages { type SourceChain = CrabChain; type TargetChain = DarwiniaChain; - fn source_transactions_author(&self) -> common_primitives::AccountId { + fn source_transactions_author(&self) -> darwinia_common_primitives::AccountId { (*self.message_lane.source_sign.public().as_array_ref()).into() } @@ -248,14 +248,14 @@ mod s2s_messages { TARGET_NAME, SOURCE_NAME, call_weight, - darwinia_runtime_common::max_extrinsic_weight(), + darwinia_common_runtime::max_extrinsic_weight(), transaction.encode().len(), - darwinia_runtime_common::max_extrinsic_size(), + darwinia_common_runtime::max_extrinsic_size(), ); Bytes(transaction.encode()) } - fn target_transactions_author(&self) -> common_primitives::AccountId { + fn target_transactions_author(&self) -> darwinia_common_primitives::AccountId { (*self.message_lane.target_sign.public().as_array_ref()).into() } @@ -298,9 +298,9 @@ mod s2s_messages { SOURCE_NAME, TARGET_NAME, call_weight, - darwinia_runtime_common::max_extrinsic_weight(), + darwinia_common_runtime::max_extrinsic_weight(), transaction.encode().len(), - darwinia_runtime_common::max_extrinsic_size(), + darwinia_common_runtime::max_extrinsic_size(), ); Bytes(transaction.encode()) } @@ -342,13 +342,13 @@ mod s2s_messages { // 2/3 is reserved for proofs and tx overhead let max_messages_size_in_single_batch = - darwinia_runtime_common::max_extrinsic_size() / 3; + darwinia_common_runtime::max_extrinsic_size() / 3; let (max_messages_in_single_batch, max_messages_weight_in_single_batch) = substrate_relay_helper::messages_lane::select_delivery_transaction_limits::< // todo: there can be change to special weight pallet_bridge_messages::weights::RialtoWeight, >( - darwinia_runtime_common::max_extrinsic_weight(), + darwinia_common_runtime::max_extrinsic_weight(), DarwiniaChainConst::MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE, ); diff --git a/task/task-darwinia-crab/src/chains/darwinia.rs b/task/task-darwinia-crab/src/chains/darwinia.rs index c783ece24..76432001d 100644 --- a/task/task-darwinia-crab/src/chains/darwinia.rs +++ b/task/task-darwinia-crab/src/chains/darwinia.rs @@ -26,33 +26,33 @@ mod s2s_const { impl ChainConst for DarwiniaChainConst { const OUTBOUND_LANE_MESSAGE_DETAILS_METHOD: &'static str = - bridge_primitives::TO_DARWINIA_MESSAGE_DETAILS_METHOD; + darwinia_bridge_primitives::TO_DARWINIA_MESSAGE_DETAILS_METHOD; const OUTBOUND_LANE_LATEST_GENERATED_NONCE_METHOD: &'static str = - bridge_primitives::TO_DARWINIA_LATEST_GENERATED_NONCE_METHOD; + darwinia_bridge_primitives::TO_DARWINIA_LATEST_GENERATED_NONCE_METHOD; const OUTBOUND_LANE_LATEST_RECEIVED_NONCE_METHOD: &'static str = - bridge_primitives::TO_DARWINIA_LATEST_RECEIVED_NONCE_METHOD; + darwinia_bridge_primitives::TO_DARWINIA_LATEST_RECEIVED_NONCE_METHOD; const INBOUND_LANE_LATEST_RECEIVED_NONCE_METHOD: &'static str = - bridge_primitives::FROM_DARWINIA_LATEST_RECEIVED_NONCE_METHOD; + darwinia_bridge_primitives::FROM_DARWINIA_LATEST_RECEIVED_NONCE_METHOD; const INBOUND_LANE_LATEST_CONFIRMED_NONCE_METHOD: &'static str = - bridge_primitives::FROM_DARWINIA_LATEST_CONFIRMED_NONCE_METHOD; + darwinia_bridge_primitives::FROM_DARWINIA_LATEST_CONFIRMED_NONCE_METHOD; const INBOUND_LANE_UNREWARDED_RELAYERS_STATE: &'static str = - bridge_primitives::FROM_DARWINIA_UNREWARDED_RELAYERS_STATE; + darwinia_bridge_primitives::FROM_DARWINIA_UNREWARDED_RELAYERS_STATE; const BEST_FINALIZED_SOURCE_HEADER_ID_AT_TARGET: &'static str = - bridge_primitives::BEST_FINALIZED_DARWINIA_HEADER_METHOD; + darwinia_bridge_primitives::BEST_FINALIZED_DARWINIA_HEADER_METHOD; const BEST_FINALIZED_TARGET_HEADER_ID_AT_SOURCE: &'static str = - bridge_primitives::BEST_FINALIZED_DARWINIA_HEADER_METHOD; + darwinia_bridge_primitives::BEST_FINALIZED_DARWINIA_HEADER_METHOD; const MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE: MessageNonce = - bridge_primitives::MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE; + darwinia_bridge_primitives::MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE; const MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE: MessageNonce = - bridge_primitives::MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE; + darwinia_bridge_primitives::MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE; const AVERAGE_BLOCK_INTERVAL: Duration = DarwiniaChain::AVERAGE_BLOCK_INTERVAL; - const BRIDGE_CHAIN_ID: ChainId = bridge_primitives::DARWINIA_CHAIN_ID; + const BRIDGE_CHAIN_ID: ChainId = darwinia_bridge_primitives::DARWINIA_CHAIN_ID; const MESSAGE_PALLET_NAME_AT_SOURCE: &'static str = - bridge_primitives::WITH_CRAB_MESSAGES_PALLET_NAME; + darwinia_bridge_primitives::WITH_CRAB_MESSAGES_PALLET_NAME; const MESSAGE_PALLET_NAME_AT_TARGET: &'static str = - bridge_primitives::WITH_DARWINIA_MESSAGES_PALLET_NAME; + darwinia_bridge_primitives::WITH_DARWINIA_MESSAGES_PALLET_NAME; const PAY_INBOUND_DISPATCH_FEE_WEIGHT_AT_TARGET_CHAIN: Weight = - bridge_primitives::PAY_INBOUND_DISPATCH_FEE_WEIGHT; + darwinia_bridge_primitives::PAY_INBOUND_DISPATCH_FEE_WEIGHT; type SigningParams = sp_core::sr25519::Pair; } @@ -110,7 +110,7 @@ mod s2s_headers { type TargetChain = CrabChain; - fn transactions_author(&self) -> common_primitives::AccountId { + fn transactions_author(&self) -> darwinia_common_primitives::AccountId { (*self.finality_pipeline.target_sign.public().as_array_ref()).into() } @@ -119,7 +119,7 @@ mod s2s_headers { era: bp_runtime::TransactionEraOf, transaction_nonce: IndexOf, header: component_darwinia_s2s::SyncHeader, - proof: GrandpaJustification, + proof: GrandpaJustification, ) -> Bytes { let call = crab_runtime::BridgeGrandpaCall::< crab_runtime::Runtime, @@ -216,7 +216,7 @@ mod s2s_messages { type SourceChain = DarwiniaChain; type TargetChain = CrabChain; - fn source_transactions_author(&self) -> common_primitives::AccountId { + fn source_transactions_author(&self) -> darwinia_common_primitives::AccountId { (*self.message_lane.source_sign.public().as_array_ref()).into() } @@ -247,14 +247,14 @@ mod s2s_messages { TARGET_NAME, SOURCE_NAME, call_weight, - darwinia_runtime_common::max_extrinsic_weight(), + darwinia_common_runtime::max_extrinsic_weight(), transaction.encode().len(), - darwinia_runtime_common::max_extrinsic_size(), + darwinia_common_runtime::max_extrinsic_size(), ); Bytes(transaction.encode()) } - fn target_transactions_author(&self) -> common_primitives::AccountId { + fn target_transactions_author(&self) -> darwinia_common_primitives::AccountId { (*self.message_lane.target_sign.public().as_array_ref()).into() } @@ -297,9 +297,9 @@ mod s2s_messages { SOURCE_NAME, TARGET_NAME, call_weight, - darwinia_runtime_common::max_extrinsic_weight(), + darwinia_common_runtime::max_extrinsic_weight(), transaction.encode().len(), - darwinia_runtime_common::max_extrinsic_size(), + darwinia_common_runtime::max_extrinsic_size(), ); Bytes(transaction.encode()) } @@ -341,13 +341,13 @@ mod s2s_messages { // 2/3 is reserved for proofs and tx overhead let max_messages_size_in_single_batch = - darwinia_runtime_common::max_extrinsic_size() / 3; + darwinia_common_runtime::max_extrinsic_size() / 3; let (max_messages_in_single_batch, max_messages_weight_in_single_batch) = substrate_relay_helper::messages_lane::select_delivery_transaction_limits::< // todo: there can be change to special weight pallet_bridge_messages::weights::RialtoWeight, >( - darwinia_runtime_common::max_extrinsic_weight(), + darwinia_common_runtime::max_extrinsic_weight(), CrabChainConst::MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE, ); diff --git a/task/task-darwinia-crab/src/fee/strategy/common.rs b/task/task-darwinia-crab/src/fee/strategy/common.rs index e4f129d23..d688a4bdb 100644 --- a/task/task-darwinia-crab/src/fee/strategy/common.rs +++ b/task/task-darwinia-crab/src/fee/strategy/common.rs @@ -58,12 +58,6 @@ impl StrategyHelper { } impl StrategyHelper { - pub fn darwinia_api(&self) -> &DarwiniaApi { - &self.darwinia_api - } - pub fn crab_api(&self) -> &CrabApi { - &self.crab_api - } pub fn darwinia_signer(&self) -> &::AccountKeyPair { &self.darwinia_signer } diff --git a/task/task-darwinia-crab/src/fee/strategy/crazy_strategy.rs b/task/task-darwinia-crab/src/fee/strategy/crazy_strategy.rs index 5240427b6..30d2ac246 100644 --- a/task/task-darwinia-crab/src/fee/strategy/crazy_strategy.rs +++ b/task/task-darwinia-crab/src/fee/strategy/crazy_strategy.rs @@ -1,4 +1,4 @@ -use common_primitives::AccountId; +use darwinia_common_primitives::AccountId; use sp_core::Pair; use bridge_traits::bridge::task::BridgeSand; diff --git a/task/task-darwinia-crab/src/fee/strategy/reasonable_strategy.rs b/task/task-darwinia-crab/src/fee/strategy/reasonable_strategy.rs index 88378171c..4fe73ca4b 100644 --- a/task/task-darwinia-crab/src/fee/strategy/reasonable_strategy.rs +++ b/task/task-darwinia-crab/src/fee/strategy/reasonable_strategy.rs @@ -11,8 +11,8 @@ use crate::fee::strategy::common::StrategyHelper; use crate::fee::UpdateFeeStrategy; use crate::task::DarwiniaCrabTask; -const MIN_RELAY_FEE_DARWINIA: u128 = 15 * common_primitives::COIN; -const MIN_RELAY_FEE_CRAB: u128 = 15 * common_primitives::COIN; +const MIN_RELAY_FEE_DARWINIA: u128 = 15 * darwinia_common_primitives::COIN; +const MIN_RELAY_FEE_CRAB: u128 = 15 * darwinia_common_primitives::COIN; #[derive(Clone)] pub struct ReasonableStrategy { @@ -79,8 +79,8 @@ impl ReasonableStrategy { async fn conversion_darwinia_to_crab( &self, - darwinia_currency: common_primitives::Balance, - ) -> anyhow::Result { + darwinia_currency: darwinia_common_primitives::Balance, + ) -> anyhow::Result { let price_darwinia = self._darwinia_open_price().await?; let price_crab = self._crab_open_price().await?; let rate = price_darwinia / price_crab; @@ -90,8 +90,8 @@ impl ReasonableStrategy { } async fn conversion_crab_to_darwinia( &self, - crab_currency: common_primitives::Balance, - ) -> anyhow::Result { + crab_currency: darwinia_common_primitives::Balance, + ) -> anyhow::Result { let price_darwinia = self._darwinia_open_price().await?; let price_crab = self._crab_open_price().await?; let rate = price_crab / price_darwinia; @@ -137,6 +137,8 @@ impl UpdateFeeStrategy for ReasonableStrategy { let expect_fee_darwinia = MIN_RELAY_FEE_DARWINIA + (top100_max_cost_darwinia * 15); let expect_fee_crab = MIN_RELAY_FEE_CRAB + (top100_max_cost_crab * 15); + let crab_signer = self.helper.crab_signer().clone(); + let darwinia_signer = self.helper.darwinia_signer().clone(); log::info!( target: DarwiniaCrabTask::NAME, "[reasonable] Update crab fee: {}", @@ -144,7 +146,7 @@ impl UpdateFeeStrategy for ReasonableStrategy { ); let crab_api = self.helper.crab_api_mut(); crab_api - .update_relay_fee(self.helper.crab_signer().clone(), expect_fee_crab) + .update_relay_fee(crab_signer, expect_fee_crab) .await?; log::info!( @@ -154,7 +156,7 @@ impl UpdateFeeStrategy for ReasonableStrategy { ); let darwinia_api = self.helper.darwinia_api_mut(); darwinia_api - .update_relay_fee(self.helper.darwinia_signer().clone(), expect_fee_darwinia) + .update_relay_fee(darwinia_signer, expect_fee_darwinia) .await?; Ok(()) } diff --git a/task/task-darwinia-crab/src/service/fee.rs b/task/task-darwinia-crab/src/service/fee.rs index d5de626e4..3861294b3 100644 --- a/task/task-darwinia-crab/src/service/fee.rs +++ b/task/task-darwinia-crab/src/service/fee.rs @@ -74,14 +74,14 @@ async fn run_update_fee(config_task: TaskConfig) -> anyhow::Result<()> { if !exists_subscan_config { return Ok(()); } - let strategy = CrazyStrategy::new().await?; + let mut strategy = CrazyStrategy::new().await?; strategy.handle().await } UpdateFeeStrategyType::Reasonable => { if !exists_subscan_config { return Ok(()); } - let strategy = ReasonableStrategy::new().await?; + let mut strategy = ReasonableStrategy::new().await?; strategy.handle().await } } diff --git a/task/task-darwinia-crab/src/service/relay.rs b/task/task-darwinia-crab/src/service/relay.rs index 3cc35d68c..fca24fe30 100644 --- a/task/task-darwinia-crab/src/service/relay.rs +++ b/task/task-darwinia-crab/src/service/relay.rs @@ -1,4 +1,4 @@ -use common_primitives::AccountId; +use darwinia_common_primitives::AccountId; use futures::{FutureExt, TryFutureExt}; use lifeline::{Bus, Lifeline, Receiver, Service, Task}; use relay_substrate_client::{AccountIdOf, Chain, Client, TransactionSignScheme}; @@ -116,7 +116,7 @@ async fn bridge_relay(relay_info: RelayHeadersAndMessagesInfo) -> anyhow::Result if relay_info.create_relayers_fund_accounts { let relayer_fund_acount_id = pallet_bridge_messages::relayer_fund_account_id::< AccountIdOf, - bridge_primitives::AccountIdConverter, + darwinia_bridge_primitives::AccountIdConverter, >(); let relayers_fund_account_balance = darwinia_client .free_native_balance(relayer_fund_acount_id.clone()) @@ -135,7 +135,7 @@ async fn bridge_relay(relay_info: RelayHeadersAndMessagesInfo) -> anyhow::Result let relayer_fund_acount_id = pallet_bridge_messages::relayer_fund_account_id::< AccountIdOf, - bridge_primitives::AccountIdConverter, + darwinia_bridge_primitives::AccountIdConverter, >(); let relayers_fund_account_balance = crab_client .free_native_balance(relayer_fund_acount_id.clone()) @@ -158,7 +158,7 @@ async fn bridge_relay(relay_info: RelayHeadersAndMessagesInfo) -> anyhow::Result crab_client.clone(), pangoro_transactions_mortality, DarwiniaFinalityToCrab::new(crab_client.clone(), pangoro_sign.clone()), - common_primitives::DARWINIA_BLOCKS_PER_SESSION, + darwinia_common_primitives::DARWINIA_BLOCKS_PER_SESSION, relay_info.only_mandatory_headers, ); let crab_to_darwinia_on_demand_headers = OnDemandHeadersRelay::new( @@ -166,7 +166,7 @@ async fn bridge_relay(relay_info: RelayHeadersAndMessagesInfo) -> anyhow::Result darwinia_client.clone(), darwinia_transactions_mortality, CrabFinalityToDarwinia::new(darwinia_client.clone(), darwinia_sign.clone()), - common_primitives::CRAB_BLOCKS_PER_SESSION, + darwinia_common_primitives::CRAB_BLOCKS_PER_SESSION, relay_info.only_mandatory_headers, ); diff --git a/task/task-pangolin-pangoro/Cargo.toml b/task/task-pangolin-pangoro/Cargo.toml index 53ce18948..2bf8604fd 100644 --- a/task/task-pangolin-pangoro/Cargo.toml +++ b/task/task-pangolin-pangoro/Cargo.toml @@ -64,9 +64,9 @@ component-pangoro-s2s = { path = "../../components/client-pangoro-s2s" } component-subscan = { path = "../../components/subscan" } ## darwinia common -common-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } -bridge-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } -common-runtime = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } +drml-common-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } +drml-bridge-primitives = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } +common-runtime = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } ## pangolin pangolin-runtime = { git = "https://github.com/darwinia-network/darwinia-common.git", branch = "bump-deps" } diff --git a/task/task-pangolin-pangoro/src/chains/pangolin.rs b/task/task-pangolin-pangoro/src/chains/pangolin.rs index 2bc0d085b..a9847c27b 100644 --- a/task/task-pangolin-pangoro/src/chains/pangolin.rs +++ b/task/task-pangolin-pangoro/src/chains/pangolin.rs @@ -26,34 +26,34 @@ mod s2s_const { impl ChainConst for PangolinChainConst { const OUTBOUND_LANE_MESSAGE_DETAILS_METHOD: &'static str = - bridge_primitives::TO_PANGOLIN_MESSAGE_DETAILS_METHOD; + drml_bridge_primitives::TO_PANGOLIN_MESSAGE_DETAILS_METHOD; const OUTBOUND_LANE_LATEST_GENERATED_NONCE_METHOD: &'static str = - bridge_primitives::TO_PANGOLIN_LATEST_GENERATED_NONCE_METHOD; + drml_bridge_primitives::TO_PANGOLIN_LATEST_GENERATED_NONCE_METHOD; const OUTBOUND_LANE_LATEST_RECEIVED_NONCE_METHOD: &'static str = - bridge_primitives::TO_PANGOLIN_LATEST_RECEIVED_NONCE_METHOD; + drml_bridge_primitives::TO_PANGOLIN_LATEST_RECEIVED_NONCE_METHOD; const INBOUND_LANE_LATEST_RECEIVED_NONCE_METHOD: &'static str = - bridge_primitives::FROM_PANGOLIN_LATEST_RECEIVED_NONCE_METHOD; + drml_bridge_primitives::FROM_PANGOLIN_LATEST_RECEIVED_NONCE_METHOD; const INBOUND_LANE_LATEST_CONFIRMED_NONCE_METHOD: &'static str = - bridge_primitives::FROM_PANGOLIN_LATEST_CONFIRMED_NONCE_METHOD; + drml_bridge_primitives::FROM_PANGOLIN_LATEST_CONFIRMED_NONCE_METHOD; const INBOUND_LANE_UNREWARDED_RELAYERS_STATE: &'static str = - bridge_primitives::FROM_PANGOLIN_UNREWARDED_RELAYERS_STATE; + drml_bridge_primitives::FROM_PANGOLIN_UNREWARDED_RELAYERS_STATE; const BEST_FINALIZED_SOURCE_HEADER_ID_AT_TARGET: &'static str = - bridge_primitives::BEST_FINALIZED_PANGOLIN_HEADER_METHOD; + drml_bridge_primitives::BEST_FINALIZED_PANGOLIN_HEADER_METHOD; const BEST_FINALIZED_TARGET_HEADER_ID_AT_SOURCE: &'static str = - bridge_primitives::BEST_FINALIZED_PANGOLIN_HEADER_METHOD; + drml_bridge_primitives::BEST_FINALIZED_PANGOLIN_HEADER_METHOD; const MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE: MessageNonce = - bridge_primitives::MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE; + drml_bridge_primitives::MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE; const MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE: MessageNonce = - bridge_primitives::MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE; + drml_bridge_primitives::MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE; const AVERAGE_BLOCK_INTERVAL: Duration = PangolinChain::AVERAGE_BLOCK_INTERVAL; - const BRIDGE_CHAIN_ID: ChainId = bridge_primitives::PANGOLIN_CHAIN_ID; + const BRIDGE_CHAIN_ID: ChainId = drml_bridge_primitives::PANGOLIN_CHAIN_ID; const MESSAGE_PALLET_NAME_AT_SOURCE: &'static str = - bridge_primitives::WITH_PANGORO_MESSAGES_PALLET_NAME; + drml_bridge_primitives::WITH_PANGORO_MESSAGES_PALLET_NAME; const MESSAGE_PALLET_NAME_AT_TARGET: &'static str = - bridge_primitives::WITH_PANGOLIN_MESSAGES_PALLET_NAME; + drml_bridge_primitives::WITH_PANGOLIN_MESSAGES_PALLET_NAME; const PAY_INBOUND_DISPATCH_FEE_WEIGHT_AT_TARGET_CHAIN: Weight = - bridge_primitives::PAY_INBOUND_DISPATCH_FEE_WEIGHT; - type SigningParams = common_primitives::SigningParams; + drml_bridge_primitives::PAY_INBOUND_DISPATCH_FEE_WEIGHT; + type SigningParams = drml_common_primitives::SigningParams; } // === end @@ -110,7 +110,7 @@ mod s2s_headers { type TargetChain = PangoroChain; - fn transactions_author(&self) -> common_primitives::AccountId { + fn transactions_author(&self) -> drml_common_primitives::AccountId { (*self.finality_pipeline.target_sign.public().as_array_ref()).into() } @@ -119,7 +119,7 @@ mod s2s_headers { era: bp_runtime::TransactionEraOf, transaction_nonce: IndexOf, header: component_pangolin_s2s::SyncHeader, - proof: GrandpaJustification, + proof: GrandpaJustification, ) -> Bytes { let call = pangoro_runtime::BridgeGrandpaCall::< pangoro_runtime::Runtime, @@ -216,7 +216,7 @@ mod s2s_messages { type SourceChain = PangolinChain; type TargetChain = PangoroChain; - fn source_transactions_author(&self) -> common_primitives::AccountId { + fn source_transactions_author(&self) -> drml_common_primitives::AccountId { (*self.message_lane.source_sign.public().as_array_ref()).into() } @@ -254,7 +254,7 @@ mod s2s_messages { Bytes(transaction.encode()) } - fn target_transactions_author(&self) -> common_primitives::AccountId { + fn target_transactions_author(&self) -> drml_common_primitives::AccountId { (*self.message_lane.target_sign.public().as_array_ref()).into() } diff --git a/task/task-pangolin-pangoro/src/chains/pangoro.rs b/task/task-pangolin-pangoro/src/chains/pangoro.rs index 34bdcf9cd..5e5936e4f 100644 --- a/task/task-pangolin-pangoro/src/chains/pangoro.rs +++ b/task/task-pangolin-pangoro/src/chains/pangoro.rs @@ -27,34 +27,34 @@ mod s2s_const { impl ChainConst for PangoroChainConst { const OUTBOUND_LANE_MESSAGE_DETAILS_METHOD: &'static str = - bridge_primitives::TO_PANGORO_MESSAGE_DETAILS_METHOD; + drml_bridge_primitives::TO_PANGORO_MESSAGE_DETAILS_METHOD; const OUTBOUND_LANE_LATEST_GENERATED_NONCE_METHOD: &'static str = - bridge_primitives::TO_PANGORO_LATEST_GENERATED_NONCE_METHOD; + drml_bridge_primitives::TO_PANGORO_LATEST_GENERATED_NONCE_METHOD; const OUTBOUND_LANE_LATEST_RECEIVED_NONCE_METHOD: &'static str = - bridge_primitives::TO_PANGORO_LATEST_RECEIVED_NONCE_METHOD; + drml_bridge_primitives::TO_PANGORO_LATEST_RECEIVED_NONCE_METHOD; const INBOUND_LANE_LATEST_RECEIVED_NONCE_METHOD: &'static str = - bridge_primitives::FROM_PANGORO_LATEST_RECEIVED_NONCE_METHOD; + drml_bridge_primitives::FROM_PANGORO_LATEST_RECEIVED_NONCE_METHOD; const INBOUND_LANE_LATEST_CONFIRMED_NONCE_METHOD: &'static str = - bridge_primitives::FROM_PANGORO_LATEST_CONFIRMED_NONCE_METHOD; + drml_bridge_primitives::FROM_PANGORO_LATEST_CONFIRMED_NONCE_METHOD; const INBOUND_LANE_UNREWARDED_RELAYERS_STATE: &'static str = - bridge_primitives::FROM_PANGORO_UNREWARDED_RELAYERS_STATE; + drml_bridge_primitives::FROM_PANGORO_UNREWARDED_RELAYERS_STATE; const BEST_FINALIZED_SOURCE_HEADER_ID_AT_TARGET: &'static str = - bridge_primitives::BEST_FINALIZED_PANGORO_HEADER_METHOD; + drml_bridge_primitives::BEST_FINALIZED_PANGORO_HEADER_METHOD; const BEST_FINALIZED_TARGET_HEADER_ID_AT_SOURCE: &'static str = - bridge_primitives::BEST_FINALIZED_PANGORO_HEADER_METHOD; + drml_bridge_primitives::BEST_FINALIZED_PANGORO_HEADER_METHOD; const MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE: MessageNonce = - bridge_primitives::MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE; + drml_bridge_primitives::MAX_UNREWARDED_RELAYER_ENTRIES_AT_INBOUND_LANE; const MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE: MessageNonce = - bridge_primitives::MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE; + drml_bridge_primitives::MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE; const AVERAGE_BLOCK_INTERVAL: Duration = PangolinChain::AVERAGE_BLOCK_INTERVAL; - const BRIDGE_CHAIN_ID: ChainId = bridge_primitives::PANGORO_CHAIN_ID; + const BRIDGE_CHAIN_ID: ChainId = drml_bridge_primitives::PANGORO_CHAIN_ID; const MESSAGE_PALLET_NAME_AT_SOURCE: &'static str = - bridge_primitives::WITH_PANGOLIN_MESSAGES_PALLET_NAME; + drml_bridge_primitives::WITH_PANGOLIN_MESSAGES_PALLET_NAME; const MESSAGE_PALLET_NAME_AT_TARGET: &'static str = - bridge_primitives::WITH_PANGORO_MESSAGES_PALLET_NAME; + drml_bridge_primitives::WITH_PANGORO_MESSAGES_PALLET_NAME; const PAY_INBOUND_DISPATCH_FEE_WEIGHT_AT_TARGET_CHAIN: Weight = - bridge_primitives::PAY_INBOUND_DISPATCH_FEE_WEIGHT; - type SigningParams = common_primitives::SigningParams; + drml_bridge_primitives::PAY_INBOUND_DISPATCH_FEE_WEIGHT; + type SigningParams = drml_common_primitives::SigningParams; } // === end @@ -111,7 +111,7 @@ mod s2s_headers { type TargetChain = PangolinChain; - fn transactions_author(&self) -> common_primitives::AccountId { + fn transactions_author(&self) -> drml_common_primitives::AccountId { (*self.finality_pipeline.target_sign.public().as_array_ref()).into() } @@ -120,7 +120,7 @@ mod s2s_headers { era: bp_runtime::TransactionEraOf, transaction_nonce: IndexOf, header: component_pangoro_s2s::SyncHeader, - proof: GrandpaJustification, + proof: GrandpaJustification, ) -> Bytes { let call = pangolin_runtime::BridgeGrandpaCall::< pangolin_runtime::Runtime, @@ -217,7 +217,7 @@ mod s2s_messages { type SourceChain = PangoroChain; type TargetChain = PangolinChain; - fn source_transactions_author(&self) -> common_primitives::AccountId { + fn source_transactions_author(&self) -> drml_common_primitives::AccountId { (*self.message_lane.source_sign.public().as_array_ref()).into() } @@ -255,7 +255,7 @@ mod s2s_messages { Bytes(transaction.encode()) } - fn target_transactions_author(&self) -> common_primitives::AccountId { + fn target_transactions_author(&self) -> drml_common_primitives::AccountId { (*self.message_lane.target_sign.public().as_array_ref()).into() } diff --git a/task/task-pangolin-pangoro/src/fee/strategy/common.rs b/task/task-pangolin-pangoro/src/fee/strategy/common.rs index 47850e05a..a7c746f8d 100644 --- a/task/task-pangolin-pangoro/src/fee/strategy/common.rs +++ b/task/task-pangolin-pangoro/src/fee/strategy/common.rs @@ -60,12 +60,6 @@ impl StrategyHelper { } impl StrategyHelper { - pub fn pangolin_api(&self) -> &PangolinApi { - &self.pangolin_api - } - pub fn pangoro_api(&self) -> &PangoroApi { - &self.pangoro_api - } pub fn pangolin_signer(&self) -> &::AccountKeyPair { &self.pangolin_signer } diff --git a/task/task-pangolin-pangoro/src/fee/strategy/crazy_strategy.rs b/task/task-pangolin-pangoro/src/fee/strategy/crazy_strategy.rs index 9dae70161..fa4b11c59 100644 --- a/task/task-pangolin-pangoro/src/fee/strategy/crazy_strategy.rs +++ b/task/task-pangolin-pangoro/src/fee/strategy/crazy_strategy.rs @@ -1,4 +1,4 @@ -use common_primitives::AccountId; +use drml_common_primitives::AccountId; use sp_core::Pair; use bridge_traits::bridge::task::BridgeSand; diff --git a/task/task-pangolin-pangoro/src/fee/strategy/reasonable_strategy.rs b/task/task-pangolin-pangoro/src/fee/strategy/reasonable_strategy.rs index 656d54ac5..d32ae03e4 100644 --- a/task/task-pangolin-pangoro/src/fee/strategy/reasonable_strategy.rs +++ b/task/task-pangolin-pangoro/src/fee/strategy/reasonable_strategy.rs @@ -11,8 +11,8 @@ use crate::fee::strategy::common::StrategyHelper; use crate::fee::UpdateFeeStrategy; use crate::task::PangolinPangoroTask; -const MIN_RELAY_FEE_PANGOLIN: u128 = 15 * common_primitives::COIN; -const MIN_RELAY_FEE_PANGORO: u128 = 15 * common_primitives::COIN; +const MIN_RELAY_FEE_PANGOLIN: u128 = 15 * drml_common_primitives::COIN; +const MIN_RELAY_FEE_PANGORO: u128 = 15 * drml_common_primitives::COIN; #[derive(Clone)] pub struct ReasonableStrategy { @@ -80,8 +80,8 @@ impl ReasonableStrategy { async fn conversion_pangolin_to_pangoro( &self, - pangolin_currency: common_primitives::Balance, - ) -> anyhow::Result { + pangolin_currency: drml_common_primitives::Balance, + ) -> anyhow::Result { let price_pangolin = self._pangolin_open_price().await?; let price_pangoro = self._pangoro_open_price().await?; let rate = price_pangolin / price_pangoro; @@ -91,8 +91,8 @@ impl ReasonableStrategy { } async fn conversion_pangoro_to_pangolin( &self, - pangoro_currency: common_primitives::Balance, - ) -> anyhow::Result { + pangoro_currency: drml_common_primitives::Balance, + ) -> anyhow::Result { let price_pangolin = self._pangolin_open_price().await?; let price_pangoro = self._pangoro_open_price().await?; let rate = price_pangoro / price_pangolin; @@ -145,9 +145,13 @@ impl UpdateFeeStrategy for ReasonableStrategy { "[reasonable] Update pangoro fee: {}", expect_fee_pangoro ); + + let pangoro_signer = self.helper.pangoro_signer().clone(); + let pangolin_signer = self.helper.pangolin_signer().clone(); + let pangoro_api = self.helper.pangoro_api_mut(); pangoro_api - .update_relay_fee(self.helper.pangoro_signer().clone(), expect_fee_pangoro) + .update_relay_fee(pangoro_signer, expect_fee_pangoro) .await?; log::info!( @@ -157,7 +161,7 @@ impl UpdateFeeStrategy for ReasonableStrategy { ); let pangolin_api = self.helper.pangolin_api_mut(); pangolin_api - .update_relay_fee(self.helper.pangolin_signer().clone(), expect_fee_pangolin) + .update_relay_fee(pangolin_signer, expect_fee_pangolin) .await?; Ok(()) } diff --git a/task/task-pangolin-pangoro/src/service/relay.rs b/task/task-pangolin-pangoro/src/service/relay.rs index 65f3d563c..11b20d6b1 100644 --- a/task/task-pangolin-pangoro/src/service/relay.rs +++ b/task/task-pangolin-pangoro/src/service/relay.rs @@ -1,4 +1,4 @@ -use common_primitives::AccountId; +use drml_common_primitives::AccountId; use futures::{FutureExt, TryFutureExt}; use lifeline::{Bus, Lifeline, Receiver, Service, Task}; use relay_substrate_client::{AccountIdOf, Chain, Client, TransactionSignScheme}; @@ -137,7 +137,7 @@ async fn bridge_relay(relay_info: RelayHeadersAndMessagesInfo) -> anyhow::Result if relay_info.create_relayers_fund_accounts { let relayer_fund_acount_id = pallet_bridge_messages::relayer_fund_account_id::< AccountIdOf, - bridge_primitives::AccountIdConverter, + drml_bridge_primitives::AccountIdConverter, >(); let relayers_fund_account_balance = pangolin_client .free_native_balance(relayer_fund_acount_id.clone()) @@ -156,7 +156,7 @@ async fn bridge_relay(relay_info: RelayHeadersAndMessagesInfo) -> anyhow::Result let relayer_fund_acount_id = pallet_bridge_messages::relayer_fund_account_id::< AccountIdOf, - bridge_primitives::AccountIdConverter, + drml_bridge_primitives::AccountIdConverter, >(); let relayers_fund_account_balance = pangoro_client .free_native_balance(relayer_fund_acount_id.clone()) @@ -179,7 +179,7 @@ async fn bridge_relay(relay_info: RelayHeadersAndMessagesInfo) -> anyhow::Result pangoro_client.clone(), pangoro_transactions_mortality, PangolinFinalityToPangoro::new(pangoro_client.clone(), pangoro_sign.clone()), - common_primitives::PANGOLIN_BLOCKS_PER_SESSION, + drml_common_primitives::PANGOLIN_BLOCKS_PER_SESSION, relay_info.only_mandatory_headers, ); let pangoro_to_pangolin_on_demand_headers = OnDemandHeadersRelay::new( @@ -187,7 +187,7 @@ async fn bridge_relay(relay_info: RelayHeadersAndMessagesInfo) -> anyhow::Result pangolin_client.clone(), pangolin_transactions_mortality, PangoroFinalityToPangolin::new(pangolin_client.clone(), pangolin_sign.clone()), - common_primitives::PANGORO_BLOCKS_PER_SESSION, + drml_common_primitives::PANGORO_BLOCKS_PER_SESSION, relay_info.only_mandatory_headers, );