diff --git a/.gitignore b/.gitignore index 91dced278b..6e9ddbe72c 100644 --- a/.gitignore +++ b/.gitignore @@ -17,3 +17,5 @@ snapshot.bin *.wasm data runtime/bifrost +parachain-staking +xcm-interface diff --git a/Cargo.lock b/Cargo.lock index 41e3da28e6..c34c6d663f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -59,7 +59,7 @@ dependencies = [ "cipher", "ctr", "ghash", - "subtle", + "subtle 2.4.1", ] [[package]] @@ -99,9 +99,9 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.53" +version = "1.0.55" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94a45b455c14666b85fc40a019e8ab9eb75e3a124e05494f5397122bc9eb06e0" +checksum = "159bb86af3a200e19a068f4224eae4c8bb2d0fa054c7e5d1cacd5cef95e684cd" [[package]] name = "approx" @@ -223,9 +223,9 @@ dependencies = [ [[package]] name = "async-lock" -version = "2.4.0" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6a8ea61bf9947a1007c5cada31e647dbc77b103c679858150003ba697ea798b" +checksum = "e97a171d191782fba31bb902b14ad94e24a68145032b7eedf871ab0bc0d077b6" dependencies = [ "event-listener", ] @@ -374,6 +374,12 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +[[package]] +name = "az" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f771a5d1f5503f7f4279a30f3643d3421ba149848b89ecaaec0ea2acf04a5ac4" + [[package]] name = "backtrace" version = "0.3.64" @@ -419,7 +425,7 @@ dependencies = [ [[package]] name = "beefy-gadget" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "beefy-primitives", "fnv", @@ -448,7 +454,7 @@ dependencies = [ [[package]] name = "beefy-gadget-rpc" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "beefy-gadget", "beefy-primitives", @@ -472,12 +478,12 @@ dependencies = [ [[package]] name = "beefy-merkle-tree" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" [[package]] name = "beefy-primitives" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "scale-info", @@ -495,7 +501,7 @@ dependencies = [ "frame-benchmarking", "frame-support", "frame-system", - "node-primitives", + "node-primitives 0.8.0", "num-bigint 0.4.3", "orml-tokens", "orml-traits", @@ -509,6 +515,14 @@ dependencies = [ "sp-std", ] +[[package]] +name = "bifrost-bancor-runtime-api" +version = "0.8.0" +dependencies = [ + "parity-scale-codec", + "sp-api", +] + [[package]] name = "bifrost-call-switchgear" version = "0.8.0" @@ -516,7 +530,7 @@ dependencies = [ "frame-benchmarking", "frame-support", "frame-system", - "node-primitives", + "node-primitives 0.8.0", "orml-tokens", "orml-traits", "pallet-balances", @@ -542,13 +556,12 @@ dependencies = [ "frame-support", "frame-system", "impl-trait-for-tuples", - "node-primitives", + "node-primitives 0.8.0", "orml-currencies", "orml-tokens", "orml-traits", "pallet-balances", "pallet-transaction-payment", - "pallet-xcm", "parity-scale-codec", "scale-info", "smallvec", @@ -557,9 +570,7 @@ dependencies = [ "sp-io", "sp-runtime", "sp-std", - "xcm", - "xcm-builder", - "xcm-support", + "xcm-interface", "zenlink-protocol", ] @@ -571,7 +582,7 @@ dependencies = [ "jsonrpc-core", "jsonrpc-core-client", "jsonrpc-derive", - "node-primitives", + "node-primitives 0.8.0", "pallet-transaction-payment-rpc-runtime-api", "parity-scale-codec", "sp-api", @@ -585,7 +596,7 @@ dependencies = [ name = "bifrost-flexible-fee-rpc-runtime-api" version = "0.8.0" dependencies = [ - "node-primitives", + "node-primitives 0.8.0", "parity-scale-codec", "sp-api", ] @@ -625,7 +636,7 @@ dependencies = [ "hex-literal", "log", "merkle-distributor", - "node-primitives", + "node-primitives 0.8.0", "orml-currencies", "orml-tokens", "orml-traits", @@ -679,7 +690,7 @@ dependencies = [ "xcm", "xcm-builder", "xcm-executor", - "xcm-support", + "xcm-interface", "zenlink-protocol", "zenlink-protocol-runtime-api", ] @@ -691,7 +702,7 @@ dependencies = [ "frame-benchmarking", "frame-support", "frame-system", - "node-primitives", + "node-primitives 0.8.0", "orml-tokens", "orml-traits", "pallet-collective", @@ -713,7 +724,7 @@ dependencies = [ "frame-support", "frame-system", "log", - "node-primitives", + "node-primitives 0.8.0", "orml-currencies", "orml-tokens", "orml-traits", @@ -733,7 +744,7 @@ dependencies = [ "jsonrpc-core", "jsonrpc-core-client", "jsonrpc-derive", - "node-primitives", + "node-primitives 0.8.0", "parity-scale-codec", "serde", "sp-api", @@ -747,12 +758,34 @@ dependencies = [ name = "bifrost-liquidity-mining-rpc-runtime-api" version = "0.8.0" dependencies = [ - "node-primitives", + "node-primitives 0.8.0", "parity-scale-codec", "sp-api", "sp-std", ] +[[package]] +name = "bifrost-minter-reward" +version = "0.8.0" +dependencies = [ + "bifrost-vtoken-mint", + "fixed", + "frame-benchmarking", + "frame-support", + "frame-system", + "node-primitives 0.8.0", + "orml-currencies", + "orml-tokens", + "orml-traits", + "pallet-balances", + "parity-scale-codec", + "scale-info", + "sp-core", + "sp-io", + "sp-runtime", + "zenlink-protocol", +] + [[package]] name = "bifrost-polkadot-runtime" version = "0.8.0" @@ -776,7 +809,7 @@ dependencies = [ "frame-try-runtime", "hex-literal", "log", - "node-primitives", + "node-primitives 0.8.0", "pallet-aura", "pallet-authorship", "pallet-balances", @@ -821,7 +854,6 @@ dependencies = [ "xcm", "xcm-builder", "xcm-executor", - "xcm-support", ] [[package]] @@ -841,7 +873,7 @@ dependencies = [ "frame-system-rpc-runtime-api", "hex-literal", "log", - "node-primitives", + "node-primitives 0.8.0", "orml-currencies", "orml-tokens", "orml-traits", @@ -876,7 +908,7 @@ dependencies = [ "xcm", "xcm-builder", "xcm-executor", - "xcm-support", + "xcm-interface", "zenlink-protocol", "zenlink-protocol-runtime-api", ] @@ -886,12 +918,11 @@ name = "bifrost-salp" version = "0.8.0" dependencies = [ "bifrost-bancor", - "bifrost-runtime-common", "frame-benchmarking", "frame-support", "frame-system", "log", - "node-primitives", + "node-primitives 0.8.0", "orml-currencies", "orml-tokens", "orml-traits", @@ -899,7 +930,6 @@ dependencies = [ "pallet-collective", "pallet-multisig", "pallet-sudo", - "pallet-xcm", "parity-scale-codec", "scale-info", "smallvec", @@ -908,9 +938,7 @@ dependencies = [ "sp-io", "sp-runtime", "sp-std", - "xcm", - "xcm-builder", - "xcm-support", + "xcm-interface", ] [[package]] @@ -922,7 +950,7 @@ dependencies = [ "frame-support", "frame-system", "log", - "node-primitives", + "node-primitives 0.8.0", "orml-currencies", "orml-tokens", "orml-traits", @@ -946,7 +974,7 @@ dependencies = [ "jsonrpc-core", "jsonrpc-core-client", "jsonrpc-derive", - "node-primitives", + "node-primitives 0.8.0", "parity-scale-codec", "serde", "sp-api", @@ -960,7 +988,7 @@ dependencies = [ name = "bifrost-salp-rpc-runtime-api" version = "0.8.0" dependencies = [ - "node-primitives", + "node-primitives 0.8.0", "parity-scale-codec", "sp-api", ] @@ -972,7 +1000,7 @@ dependencies = [ "frame-benchmarking", "frame-support", "frame-system", - "node-primitives", + "node-primitives 0.8.0", "orml-currencies", "orml-tokens", "orml-traits", @@ -1009,7 +1037,7 @@ dependencies = [ "frame-support", "frame-system", "log", - "node-primitives", + "node-primitives 0.8.0", "orml-tokens", "orml-traits", "parity-scale-codec", @@ -1021,6 +1049,28 @@ dependencies = [ "sp-std", ] +[[package]] +name = "bifrost-vtoken-mint" +version = "0.8.0" +dependencies = [ + "bifrost-minter-reward", + "frame-benchmarking", + "frame-support", + "frame-system", + "node-primitives 0.8.0", + "orml-currencies", + "orml-tokens", + "orml-traits", + "pallet-balances", + "parity-scale-codec", + "scale-info", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std", + "zenlink-protocol", +] + [[package]] name = "bimap" version = "0.6.2" @@ -1404,6 +1454,12 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7" +[[package]] +name = "bytemuck" +version = "1.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "439989e6b8c38d1b6570a384ef1e49c8848128f5a97f3914baef02920842712f" + [[package]] name = "byteorder" version = "1.4.3" @@ -1452,22 +1508,22 @@ dependencies = [ [[package]] name = "cargo_metadata" -version = "0.14.1" +version = "0.14.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba2ae6de944143141f6155a473a6b02f66c7c3f9f47316f802f80204ebfe6e12" +checksum = "4acbb09d9ee8e23699b9634375c72795d095bf268439da88562cf9b501f181fa" dependencies = [ "camino", "cargo-platform", - "semver 1.0.5", + "semver 1.0.6", "serde", "serde_json", ] [[package]] name = "cc" -version = "1.0.72" +version = "1.0.73" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22a9137b95ea06864e018375b72adfb7db6e6f68cfc8df5a04d00288050485ee" +checksum = "2fff2a6927b3bb87f9595d67196a70493f627687a71d87a0d692242c33f58c11" dependencies = [ "jobserver", ] @@ -1667,18 +1723,18 @@ dependencies = [ [[package]] name = "cranelift-bforest" -version = "0.80.0" +version = "0.80.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9516ba6b2ba47b4cbf63b713f75b432fafa0a0e0464ec8381ec76e6efe931ab3" +checksum = "62fc68cdb867b7d27b5f33cd65eb11376dfb41a2d09568a1a2c2bc1dc204f4ef" dependencies = [ "cranelift-entity", ] [[package]] name = "cranelift-codegen" -version = "0.80.0" +version = "0.80.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "489e5d0081f7edff6be12d71282a8bf387b5df64d5592454b75d662397f2d642" +checksum = "31253a44ab62588f8235a996cc9b0636d98a299190069ced9628b8547329b47a" dependencies = [ "cranelift-bforest", "cranelift-codegen-meta", @@ -1693,33 +1749,33 @@ dependencies = [ [[package]] name = "cranelift-codegen-meta" -version = "0.80.0" +version = "0.80.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d36ee1140371bb0f69100e734b30400157a4adf7b86148dee8b0a438763ead48" +checksum = "7a20ab4627d30b702fb1b8a399882726d216b8164d3b3fa6189e3bf901506afe" dependencies = [ "cranelift-codegen-shared", ] [[package]] name = "cranelift-codegen-shared" -version = "0.80.0" +version = "0.80.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "981da52d8f746af1feb96290c83977ff8d41071a7499e991d8abae0d4869f564" +checksum = "6687d9668dacfed4468361f7578d86bded8ca4db978f734d9b631494bebbb5b8" [[package]] name = "cranelift-entity" -version = "0.80.0" +version = "0.80.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2906740053dd3bcf95ce53df0fd9b5649c68ae4bd9adada92b406f059eae461" +checksum = "c77c5d72db97ba2cb36f69037a709edbae0d29cb25503775891e7151c5c874bf" dependencies = [ "serde", ] [[package]] name = "cranelift-frontend" -version = "0.80.0" +version = "0.80.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7cb156de1097f567d46bf57a0cd720a72c3e15e1a2bd8b1041ba2fc894471b7" +checksum = "426dca83f63c7c64ea459eb569aadc5e0c66536c0042ed5d693f91830e8750d0" dependencies = [ "cranelift-codegen", "log", @@ -1729,9 +1785,9 @@ dependencies = [ [[package]] name = "cranelift-native" -version = "0.80.0" +version = "0.80.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "166028ca0343a6ee7bddac0e70084e142b23f99c701bd6f6ea9123afac1a7a46" +checksum = "8007864b5d0c49b026c861a15761785a2871124e401630c03ef1426e6d0d559e" dependencies = [ "cranelift-codegen", "libc", @@ -1740,9 +1796,9 @@ dependencies = [ [[package]] name = "cranelift-wasm" -version = "0.80.0" +version = "0.80.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5012a1cde0c8b3898770b711490d803018ae9bec2d60674ba0e5b2058a874f80" +checksum = "94cf12c071415ba261d897387ae5350c4d83c238376c8c5a96514ecfa2ea66a3" dependencies = [ "cranelift-codegen", "cranelift-entity", @@ -1815,11 +1871,22 @@ checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" [[package]] name = "crypto-common" -version = "0.1.1" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "683d6b536309245c849479fba3da410962a43ed8e51c26b729208ec0ac2798d0" +checksum = "57952ca27b5e3606ff4dd79b0020231aaf9d6aa76dc05fd30137538c50bd3ce8" dependencies = [ "generic-array 0.14.5", + "typenum", +] + +[[package]] +name = "crypto-mac" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4434400df11d95d556bac068ddfedd482915eb18fe8bea89bc80b6e4b1c179e5" +dependencies = [ + "generic-array 0.12.4", + "subtle 1.0.0", ] [[package]] @@ -1829,7 +1896,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b584a330336237c1eecd3e94266efb216c56ed91225d634cb2991c5f3fd1aeab" dependencies = [ "generic-array 0.14.5", - "subtle", + "subtle 2.4.1", ] [[package]] @@ -1839,7 +1906,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b1d1a86f49236c215f271d40892d5fc950490551400b02ef360692c29815c714" dependencies = [ "generic-array 0.14.5", - "subtle", + "subtle 2.4.1", ] [[package]] @@ -2004,7 +2071,7 @@ dependencies = [ "polkadot-node-subsystem", "polkadot-overseer", "polkadot-primitives", - "rand 0.8.4", + "rand 0.8.5", "sc-client-api", "sc-consensus", "sp-api", @@ -2114,12 +2181,25 @@ name = "cumulus-pallet-parachain-system-proc-macro" version = "0.1.0" source = "git+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.16#86f76c5619c64d1300315612695ad4b4fcd0f562" dependencies = [ - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", ] +[[package]] +name = "cumulus-pallet-session-benchmarking" +version = "3.0.0" +source = "git+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.16#86f76c5619c64d1300315612695ad4b4fcd0f562" +dependencies = [ + "frame-support", + "frame-system", + "pallet-session", + "parity-scale-codec", + "sp-runtime", + "sp-std", +] + [[package]] name = "cumulus-pallet-xcm" version = "0.1.0" @@ -2155,6 +2235,23 @@ dependencies = [ "xcm-executor", ] +[[package]] +name = "cumulus-ping" +version = "0.1.0" +source = "git+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.16#86f76c5619c64d1300315612695ad4b4fcd0f562" +dependencies = [ + "cumulus-pallet-xcm", + "cumulus-primitives-core", + "frame-support", + "frame-system", + "parity-scale-codec", + "scale-info", + "serde", + "sp-runtime", + "sp-std", + "xcm", +] + [[package]] name = "cumulus-primitives-core" version = "0.1.0" @@ -2293,7 +2390,7 @@ dependencies = [ "byteorder", "digest 0.8.1", "rand_core 0.5.1", - "subtle", + "subtle 2.4.1", "zeroize", ] @@ -2306,7 +2403,7 @@ dependencies = [ "byteorder", "digest 0.9.0", "rand_core 0.5.1", - "subtle", + "subtle 2.4.1", "zeroize", ] @@ -2380,13 +2477,12 @@ dependencies = [ [[package]] name = "digest" -version = "0.10.1" +version = "0.10.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b697d66081d42af4fba142d56918a3cb21dc8eb63372c6b85d14f44fb9c5979b" +checksum = "f2fb860ca6fafa5552fb6d0e816a69c8e49f0908bf524e30a90d97c85892d506" dependencies = [ "block-buffer 0.10.2", "crypto-common", - "generic-array 0.14.5", ] [[package]] @@ -2689,6 +2785,18 @@ dependencies = [ "scale-info", ] +[[package]] +name = "fixed" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d38004fb072c44da88a322343c7c784bd1ff6f2e3f5b332050de60c5eea3e0e" +dependencies = [ + "az", + "bytemuck", + "half", + "typenum", +] + [[package]] name = "fixed-hash" version = "0.7.0" @@ -2696,7 +2804,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cfcf0ed7fe52a17a03854ec54a9f76d6d84508d1c0e66bc1793301c73fc8493c" dependencies = [ "byteorder", - "rand 0.8.4", + "rand 0.8.5", "rustc-hex", "static_assertions", ] @@ -2729,7 +2837,7 @@ checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" [[package]] name = "fork-tree" version = "3.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", ] @@ -2747,7 +2855,7 @@ dependencies = [ [[package]] name = "frame-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -2768,7 +2876,7 @@ dependencies = [ [[package]] name = "frame-benchmarking-cli" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "Inflector", "chrono", @@ -2794,7 +2902,7 @@ dependencies = [ [[package]] name = "frame-election-provider-support" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -2808,7 +2916,7 @@ dependencies = [ [[package]] name = "frame-executive" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -2836,7 +2944,7 @@ dependencies = [ [[package]] name = "frame-support" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "bitflags", "frame-metadata", @@ -2865,7 +2973,7 @@ dependencies = [ [[package]] name = "frame-support-procedural" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "Inflector", "frame-support-procedural-tools", @@ -2877,10 +2985,10 @@ dependencies = [ [[package]] name = "frame-support-procedural-tools" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support-procedural-tools-derive", - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", @@ -2889,7 +2997,7 @@ dependencies = [ [[package]] name = "frame-support-procedural-tools-derive" version = "3.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "proc-macro2", "quote", @@ -2899,7 +3007,7 @@ dependencies = [ [[package]] name = "frame-system" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "log", @@ -2916,7 +3024,7 @@ dependencies = [ [[package]] name = "frame-system-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -2931,7 +3039,7 @@ dependencies = [ [[package]] name = "frame-system-rpc-runtime-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "sp-api", @@ -2940,7 +3048,7 @@ dependencies = [ [[package]] name = "frame-try-runtime" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "sp-api", @@ -2950,9 +3058,9 @@ dependencies = [ [[package]] name = "fs-err" -version = "2.6.0" +version = "2.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ebd3504ad6116843b8375ad70df74e7bfe83cac77a1f3fe73200c844d43bfe0" +checksum = "5bd79fa345a495d3ae89fb7165fec01c0e72f41821d642dda363a1e97975652e" [[package]] name = "fs-swap" @@ -3241,6 +3349,12 @@ dependencies = [ "tracing", ] +[[package]] +name = "half" +version = "1.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eabb4a44450da02c90444cf74558da904edde8fb4e9035a9a6a4e15445af0bd7" + [[package]] name = "handlebars" version = "4.2.1" @@ -3324,6 +3438,16 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b07f60793ff0a4d9cef0f18e63b5357e06209987153a64648c972c1e5aff336f" +[[package]] +name = "hmac" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5dcb5e64cda4c23119ab41ba960d1e170a774c8e4b9d9e6a9bc18aabf5e59695" +dependencies = [ + "crypto-mac 0.7.0", + "digest 0.8.1", +] + [[package]] name = "hmac" version = "0.8.1" @@ -3344,6 +3468,17 @@ dependencies = [ "digest 0.9.0", ] +[[package]] +name = "hmac-drbg" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6e570451493f10f6581b48cdd530413b63ea9e780f544bfd3bdcaa0d89d1a7b" +dependencies = [ + "digest 0.8.1", + "generic-array 0.12.4", + "hmac 0.7.1", +] + [[package]] name = "hmac-drbg" version = "0.3.0" @@ -3408,9 +3543,9 @@ checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" [[package]] name = "hyper" -version = "0.14.16" +version = "0.14.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7ec3e62bdc98a2f0393a5048e4c30ef659440ea6e0e572965103e72bd836f55" +checksum = "043f0e083e9901b6cc658a77d1eb86f4fc650bbb977a4337dd63192826aa85dd" dependencies = [ "bytes 1.1.0", "futures-channel", @@ -3421,7 +3556,7 @@ dependencies = [ "http-body", "httparse", "httpdate", - "itoa 0.4.8", + "itoa 1.0.1", "pin-project-lite 0.2.8", "socket2 0.4.4", "tokio", @@ -3811,7 +3946,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d802063f7a3c867456955f9d2f15eb3ee0edb5ec9ec2b5526324756759221c0f" dependencies = [ "log", - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", @@ -4049,9 +4184,9 @@ checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" [[package]] name = "libc" -version = "0.2.117" +version = "0.2.119" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e74d72e0f9b65b5b4ca49a346af3976df0f9c61d550727f349ecd559f251a26c" +checksum = "1bf2e165bb3457c8e098ea76f3e3bc9db55f87aa90d52d0e6be741470916aaa4" [[package]] name = "libloading" @@ -4135,7 +4270,7 @@ dependencies = [ "futures-timer", "instant", "lazy_static", - "libsecp256k1", + "libsecp256k1 0.7.0", "log", "multiaddr", "multihash 0.14.0", @@ -4144,7 +4279,7 @@ dependencies = [ "pin-project 1.0.10", "prost", "prost-build", - "rand 0.8.4", + "rand 0.8.5", "ring", "rw-stream-sink", "sha2 0.9.9", @@ -4282,7 +4417,7 @@ dependencies = [ "libp2p-core", "libp2p-swarm", "log", - "rand 0.8.4", + "rand 0.8.5", "smallvec", "socket2 0.4.4", "void", @@ -4334,7 +4469,7 @@ dependencies = [ "log", "prost", "prost-build", - "rand 0.8.4", + "rand 0.8.5", "sha2 0.9.9", "snow", "static_assertions", @@ -4425,7 +4560,7 @@ dependencies = [ "log", "prost", "prost-build", - "rand 0.8.4", + "rand 0.8.5", "sha2 0.9.9", "thiserror", "unsigned-varint 0.7.1", @@ -4564,6 +4699,22 @@ dependencies = [ "libc", ] +[[package]] +name = "libsecp256k1" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fc1e2c808481a63dc6da2074752fdd4336a3c8fcc68b83db6f1fd5224ae7962" +dependencies = [ + "arrayref", + "crunchy", + "digest 0.8.1", + "hmac-drbg 0.2.0", + "rand 0.7.3", + "sha2 0.8.2", + "subtle 2.4.1", + "typenum", +] + [[package]] name = "libsecp256k1" version = "0.7.0" @@ -4573,11 +4724,11 @@ dependencies = [ "arrayref", "base64", "digest 0.9.0", - "hmac-drbg", + "hmac-drbg 0.3.0", "libsecp256k1-core", "libsecp256k1-gen-ecmult", "libsecp256k1-gen-genmult", - "rand 0.8.4", + "rand 0.8.5", "serde", "sha2 0.9.9", "typenum", @@ -4591,7 +4742,7 @@ checksum = "5be9b9bb642d8522a44d533eab56c16c738301965504753b03ad1de3425d5451" dependencies = [ "crunchy", "digest 0.9.0", - "subtle", + "subtle 2.4.1", ] [[package]] @@ -4791,9 +4942,9 @@ dependencies = [ [[package]] name = "memmap2" -version = "0.5.2" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe3179b85e1fd8b14447cbebadb75e45a1002f541b925f0bfec366d56a81c56d" +checksum = "057a3db23999c867821a7a59feb06a578fcb03685e983dff90daf9e7d24ac08f" dependencies = [ "libc", ] @@ -4884,7 +5035,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fd2c2cc134e57461f0898b0e921f0a7819b5e3f3a4335b9aa390ce81a5f36fb9" dependencies = [ "futures 0.3.21", - "rand 0.8.4", + "rand 0.8.5", "thrift", ] @@ -4925,9 +5076,9 @@ dependencies = [ [[package]] name = "mio" -version = "0.7.14" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8067b404fe97c70829f082dec8bcf4f71225d7eaea1d8645349cb76fa06205cc" +checksum = "ba272f85fa0b41fc91872be579b3bbe0f56b792aa361a380eb669469f68dafb2" dependencies = [ "libc", "log", @@ -5040,7 +5191,7 @@ version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "424f6e86263cd5294cbd7f1e95746b95aca0e0d66bff31e5a40d6baa87b4aa99" dependencies = [ - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro-error", "proc-macro2", "quote", @@ -5080,7 +5231,7 @@ dependencies = [ "num-complex", "num-rational 0.4.0", "num-traits", - "rand 0.8.4", + "rand 0.8.5", "rand_distr", "simba", "typenum", @@ -5103,7 +5254,7 @@ version = "0.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "10a8690bf09abf659851e58cd666c3d37ac6af07c2bd7a9e332cfba471715775" dependencies = [ - "rand 0.8.4", + "rand 0.8.5", ] [[package]] @@ -5119,7 +5270,7 @@ dependencies = [ [[package]] name = "node-cli" -version = "0.9.26" +version = "0.9.27" dependencies = [ "cumulus-client-cli", "cumulus-client-service", @@ -5128,7 +5279,7 @@ dependencies = [ "frame-try-runtime", "log", "node-inspect", - "node-primitives", + "node-primitives 0.8.0", "node-service", "parity-scale-codec", "polkadot-cli", @@ -5148,7 +5299,7 @@ dependencies = [ [[package]] name = "node-inspect" version = "0.9.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "derive_more", "parity-scale-codec", @@ -5178,6 +5329,19 @@ dependencies = [ "zenlink-protocol", ] +[[package]] +name = "node-primitives" +version = "2.0.0" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" +dependencies = [ + "frame-system", + "parity-scale-codec", + "scale-info", + "sp-application-crypto", + "sp-core", + "sp-runtime", +] + [[package]] name = "node-rpc" version = "0.8.0" @@ -5189,7 +5353,7 @@ dependencies = [ "bifrost-salp-rpc-api", "bifrost-salp-rpc-runtime-api", "jsonrpc-core", - "node-primitives", + "node-primitives 0.8.0", "pallet-transaction-payment-rpc", "sc-client-api", "sc-rpc", @@ -5231,7 +5395,7 @@ dependencies = [ "hex-literal", "jsonrpc-core", "log", - "node-primitives", + "node-primitives 0.8.0", "node-rpc", "pallet-transaction-payment-rpc", "pallet-transaction-payment-rpc-runtime-api", @@ -5303,9 +5467,9 @@ dependencies = [ [[package]] name = "ntapi" -version = "0.3.6" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f6bb902e437b6d86e03cce10a7e2af662292c5dfef23b65899ea3ac9354ad44" +checksum = "c28774a7fd2fbb4f0babd8237ce554b73af68021b5f695a3cebd6c59bac0980f" dependencies = [ "winapi 0.3.9", ] @@ -5597,10 +5761,41 @@ dependencies = [ "stable_deref_trait", ] +[[package]] +name = "pallet-asset-tx-payment" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" +dependencies = [ + "frame-support", + "frame-system", + "pallet-transaction-payment", + "parity-scale-codec", + "scale-info", + "serde", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std", +] + +[[package]] +name = "pallet-assets" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" +dependencies = [ + "frame-benchmarking", + "frame-support", + "frame-system", + "parity-scale-codec", + "scale-info", + "sp-runtime", + "sp-std", +] + [[package]] name = "pallet-aura" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -5616,7 +5811,7 @@ dependencies = [ [[package]] name = "pallet-authority-discovery" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -5632,7 +5827,7 @@ dependencies = [ [[package]] name = "pallet-authorship" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -5647,7 +5842,7 @@ dependencies = [ [[package]] name = "pallet-babe" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -5671,7 +5866,7 @@ dependencies = [ [[package]] name = "pallet-bags-list" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -5691,7 +5886,7 @@ dependencies = [ [[package]] name = "pallet-balances" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -5706,7 +5901,7 @@ dependencies = [ [[package]] name = "pallet-beefy" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "beefy-primitives", "frame-support", @@ -5722,14 +5917,14 @@ dependencies = [ [[package]] name = "pallet-beefy-mmr" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "beefy-merkle-tree", "beefy-primitives", "frame-support", "frame-system", "hex", - "libsecp256k1", + "libsecp256k1 0.7.0", "log", "pallet-beefy", "pallet-mmr", @@ -5747,7 +5942,7 @@ dependencies = [ [[package]] name = "pallet-bounties" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -5845,7 +6040,7 @@ dependencies = [ [[package]] name = "pallet-collective" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -5862,7 +6057,7 @@ dependencies = [ [[package]] name = "pallet-democracy" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -5878,7 +6073,7 @@ dependencies = [ [[package]] name = "pallet-election-provider-multi-phase" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -5902,7 +6097,7 @@ dependencies = [ [[package]] name = "pallet-elections-phragmen" version = "5.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -5920,7 +6115,7 @@ dependencies = [ [[package]] name = "pallet-gilt" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -5935,7 +6130,7 @@ dependencies = [ [[package]] name = "pallet-grandpa" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -5958,7 +6153,7 @@ dependencies = [ [[package]] name = "pallet-identity" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "enumflags2", "frame-benchmarking", @@ -5974,7 +6169,7 @@ dependencies = [ [[package]] name = "pallet-im-online" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -5994,7 +6189,7 @@ dependencies = [ [[package]] name = "pallet-indices" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6011,7 +6206,7 @@ dependencies = [ [[package]] name = "pallet-membership" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6028,7 +6223,7 @@ dependencies = [ [[package]] name = "pallet-mmr" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "ckb-merkle-mountain-range", "frame-benchmarking", @@ -6046,7 +6241,7 @@ dependencies = [ [[package]] name = "pallet-mmr-primitives" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -6062,7 +6257,7 @@ dependencies = [ [[package]] name = "pallet-mmr-rpc" version = "3.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "jsonrpc-core", "jsonrpc-core-client", @@ -6079,7 +6274,7 @@ dependencies = [ [[package]] name = "pallet-multisig" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6094,7 +6289,7 @@ dependencies = [ [[package]] name = "pallet-nicks" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -6108,7 +6303,7 @@ dependencies = [ [[package]] name = "pallet-offences" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -6125,7 +6320,7 @@ dependencies = [ [[package]] name = "pallet-offences-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -6148,7 +6343,7 @@ dependencies = [ [[package]] name = "pallet-preimage" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6164,7 +6359,7 @@ dependencies = [ [[package]] name = "pallet-proxy" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6179,7 +6374,7 @@ dependencies = [ [[package]] name = "pallet-recovery" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -6193,7 +6388,7 @@ dependencies = [ [[package]] name = "pallet-scheduler" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6209,7 +6404,7 @@ dependencies = [ [[package]] name = "pallet-session" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -6230,7 +6425,7 @@ dependencies = [ [[package]] name = "pallet-session-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6246,7 +6441,7 @@ dependencies = [ [[package]] name = "pallet-society" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -6260,7 +6455,7 @@ dependencies = [ [[package]] name = "pallet-staking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -6283,9 +6478,9 @@ dependencies = [ [[package]] name = "pallet-staking-reward-curve" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", @@ -6294,7 +6489,7 @@ dependencies = [ [[package]] name = "pallet-staking-reward-fn" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "log", "sp-arithmetic", @@ -6303,7 +6498,7 @@ dependencies = [ [[package]] name = "pallet-sudo" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -6317,7 +6512,7 @@ dependencies = [ [[package]] name = "pallet-timestamp" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6335,7 +6530,7 @@ dependencies = [ [[package]] name = "pallet-tips" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6354,7 +6549,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-support", "frame-system", @@ -6371,7 +6566,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment-rpc" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "jsonrpc-core", "jsonrpc-core-client", @@ -6388,7 +6583,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment-rpc-runtime-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "pallet-transaction-payment", "parity-scale-codec", @@ -6399,7 +6594,7 @@ dependencies = [ [[package]] name = "pallet-treasury" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6413,10 +6608,25 @@ dependencies = [ "sp-std", ] +[[package]] +name = "pallet-uniques" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" +dependencies = [ + "frame-benchmarking", + "frame-support", + "frame-system", + "log", + "parity-scale-codec", + "scale-info", + "sp-runtime", + "sp-std", +] + [[package]] name = "pallet-utility" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6432,7 +6642,7 @@ dependencies = [ [[package]] name = "pallet-vesting" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-benchmarking", "frame-support", @@ -6492,11 +6702,38 @@ dependencies = [ "serde", ] +[[package]] +name = "parachains-common" +version = "1.0.0" +source = "git+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.16#86f76c5619c64d1300315612695ad4b4fcd0f562" +dependencies = [ + "frame-executive", + "frame-support", + "frame-system", + "pallet-asset-tx-payment", + "pallet-assets", + "pallet-authorship", + "pallet-balances", + "pallet-collator-selection", + "parity-scale-codec", + "polkadot-primitives", + "polkadot-runtime-common", + "scale-info", + "sp-consensus-aura", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std", + "substrate-wasm-builder", + "xcm", + "xcm-executor", +] + [[package]] name = "parity-db" -version = "0.3.6" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68de01cff53da5574397233383dd7f5c15ee958c348245765ea8cb09f2571e6b" +checksum = "09aa6c5bb8070cf0456d9fc228b3022e900aae9092c48c9c45facf97422efc1d" dependencies = [ "blake2-rfc", "crc32fast", @@ -6507,7 +6744,7 @@ dependencies = [ "lz4", "memmap2 0.2.3", "parking_lot 0.11.2", - "rand 0.8.4", + "rand 0.8.5", "snap", ] @@ -6531,7 +6768,7 @@ version = "2.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1557010476e0595c9b568d16dcfb81b93cdeb157612726f5170d31aa707bed27" dependencies = [ - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", @@ -6881,7 +7118,7 @@ dependencies = [ "polkadot-node-subsystem", "polkadot-node-subsystem-util", "polkadot-primitives", - "rand 0.8.4", + "rand 0.8.5", "sp-core", "sp-keystore", "thiserror", @@ -6902,7 +7139,7 @@ dependencies = [ "polkadot-node-subsystem", "polkadot-node-subsystem-util", "polkadot-primitives", - "rand 0.8.4", + "rand 0.8.5", "sc-network", "thiserror", "tracing", @@ -7042,7 +7279,7 @@ dependencies = [ "polkadot-node-subsystem", "polkadot-node-subsystem-util", "polkadot-primitives", - "rand 0.8.4", + "rand 0.8.5", "rand_chacha 0.3.1", "sc-network", "sp-application-crypto", @@ -7266,7 +7503,7 @@ dependencies = [ "polkadot-node-subsystem", "polkadot-node-subsystem-util", "polkadot-primitives", - "rand 0.8.4", + "rand 0.8.5", "thiserror", "tracing", ] @@ -7287,7 +7524,7 @@ dependencies = [ "polkadot-core-primitives", "polkadot-node-subsystem-util", "polkadot-parachain", - "rand 0.8.4", + "rand 0.8.5", "sc-executor", "sc-executor-common", "sc-executor-wasmtime", @@ -7461,7 +7698,7 @@ dependencies = [ "polkadot-node-subsystem", "polkadot-overseer", "polkadot-primitives", - "rand 0.8.4", + "rand 0.8.5", "sp-application-crypto", "sp-core", "sp-keystore", @@ -7512,7 +7749,7 @@ name = "polkadot-overseer-gen-proc-macro" version = "0.9.16" source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.16#41ab002d7451766324a9f314fee11c9c53314350" dependencies = [ - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", @@ -7707,7 +7944,7 @@ dependencies = [ "frame-support", "frame-system", "impl-trait-for-tuples", - "libsecp256k1", + "libsecp256k1 0.7.0", "log", "pallet-authorship", "pallet-babe", @@ -7789,7 +8026,7 @@ dependencies = [ "parity-scale-codec", "polkadot-primitives", "polkadot-runtime-metrics", - "rand 0.8.4", + "rand 0.8.5", "rand_chacha 0.3.1", "rustc-hex", "scale-info", @@ -8005,9 +8242,9 @@ dependencies = [ [[package]] name = "proc-macro-crate" -version = "1.1.0" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ebace6889caf889b4d3f76becee12e90353f2b8c7d875534a71e5742f8f6f83" +checksum = "9dada8c9981fcf32929c3c0f0cd796a9284aca335565227ed88c83babb1d43dc" dependencies = [ "thiserror", "toml", @@ -8115,9 +8352,9 @@ dependencies = [ [[package]] name = "psm" -version = "0.1.16" +version = "0.1.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd136ff4382c4753fc061cb9e4712ab2af263376b95bbd5bd8cd50c020b78e69" +checksum = "6eca0fa5dd7c4c96e184cec588f0b1db1ee3165e678db21c09793105acb17e6f" dependencies = [ "cc", ] @@ -8170,20 +8407,19 @@ dependencies = [ "libc", "rand_chacha 0.2.2", "rand_core 0.5.1", - "rand_hc 0.2.0", + "rand_hc", "rand_pcg", ] [[package]] name = "rand" -version = "0.8.4" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e7573632e6454cf6b99d7aac4ccca54be06da05aca2ef7423d22d27d4d4bcd8" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" dependencies = [ "libc", "rand_chacha 0.3.1", "rand_core 0.6.3", - "rand_hc 0.3.1", ] [[package]] @@ -8231,7 +8467,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "32cb0b9bc82b0a0876c2dd994a7e7a2683d3e7390ca40e6886785ef0c7e3ee31" dependencies = [ "num-traits", - "rand 0.8.4", + "rand 0.8.5", ] [[package]] @@ -8243,15 +8479,6 @@ dependencies = [ "rand_core 0.5.1", ] -[[package]] -name = "rand_hc" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d51e9f596de227fda2ea6c84607f5558e196eeaf43c986b724ba4fb8fdf497e7" -dependencies = [ - "rand_core 0.6.3", -] - [[package]] name = "rand_pcg" version = "0.2.1" @@ -8402,7 +8629,7 @@ dependencies = [ [[package]] name = "remote-externalities" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "env_logger", "jsonrpsee", @@ -8573,6 +8800,107 @@ dependencies = [ "winapi 0.3.9", ] +[[package]] +name = "runtime-integration-tests" +version = "0.8.0" +dependencies = [ + "bifrost-bancor", + "bifrost-bancor-runtime-api", + "bifrost-flexible-fee", + "bifrost-flexible-fee-rpc-runtime-api", + "bifrost-kusama-runtime", + "bifrost-liquidity-mining", + "bifrost-minter-reward", + "bifrost-polkadot-runtime", + "bifrost-runtime-common", + "bifrost-salp", + "bifrost-salp-rpc-runtime-api", + "bifrost-vesting", + "bifrost-vsbond-auction", + "bifrost-vtoken-mint", + "cumulus-pallet-aura-ext", + "cumulus-pallet-dmp-queue", + "cumulus-pallet-parachain-system", + "cumulus-pallet-xcm", + "cumulus-pallet-xcmp-queue", + "cumulus-primitives-core", + "cumulus-primitives-parachain-inherent", + "cumulus-primitives-timestamp", + "cumulus-primitives-utility", + "cumulus-test-relay-sproof-builder", + "env_logger", + "frame-benchmarking", + "frame-executive", + "frame-support", + "frame-system", + "frame-system-rpc-runtime-api", + "frame-try-runtime", + "hex", + "hex-literal", + "kusama-runtime", + "libsecp256k1 0.3.5", + "log", + "node-primitives 0.8.0", + "node-service", + "orml-currencies", + "orml-tokens", + "orml-traits", + "orml-unknown-tokens", + "orml-xcm-support", + "orml-xtokens", + "pallet-aura", + "pallet-authorship", + "pallet-balances", + "pallet-bounties", + "pallet-collator-selection", + "pallet-collective", + "pallet-democracy", + "pallet-elections-phragmen", + "pallet-indices", + "pallet-membership", + "pallet-multisig", + "pallet-proxy", + "pallet-scheduler", + "pallet-session", + "pallet-sudo", + "pallet-timestamp", + "pallet-tips", + "pallet-transaction-payment", + "pallet-transaction-payment-rpc-runtime-api", + "pallet-treasury", + "pallet-utility", + "pallet-xcm", + "parachain-info", + "parity-scale-codec", + "polkadot-parachain", + "polkadot-primitives", + "polkadot-runtime-parachains", + "serde", + "smallvec", + "sp-api", + "sp-arithmetic", + "sp-block-builder", + "sp-consensus-aura", + "sp-core", + "sp-inherents", + "sp-io", + "sp-offchain", + "sp-runtime", + "sp-session", + "sp-std", + "sp-transaction-pool", + "sp-trie", + "sp-version", + "static_assertions", + "westmint-runtime", + "xcm", + "xcm-builder", + "xcm-emulator", + "xcm-executor", + "zenlink-protocol", + "zenlink-protocol-runtime-api", +] + [[package]] name = "rustc-demangle" version = "0.1.21" @@ -8606,7 +8934,7 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" dependencies = [ - "semver 1.0.5", + "semver 1.0.6", ] [[package]] @@ -8692,7 +9020,7 @@ dependencies = [ [[package]] name = "sc-allocator" version = "4.1.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "log", "sp-core", @@ -8703,7 +9031,7 @@ dependencies = [ [[package]] name = "sc-authority-discovery" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "derive_more", @@ -8730,7 +9058,7 @@ dependencies = [ [[package]] name = "sc-basic-authorship" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "futures 0.3.21", "futures-timer", @@ -8753,7 +9081,7 @@ dependencies = [ [[package]] name = "sc-block-builder" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "sc-client-api", @@ -8769,10 +9097,10 @@ dependencies = [ [[package]] name = "sc-chain-spec" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "impl-trait-for-tuples", - "memmap2 0.5.2", + "memmap2 0.5.3", "parity-scale-codec", "sc-chain-spec-derive", "sc-network", @@ -8786,9 +9114,9 @@ dependencies = [ [[package]] name = "sc-chain-spec-derive" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", @@ -8797,7 +9125,7 @@ dependencies = [ [[package]] name = "sc-cli" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "chrono", "fdlimit", @@ -8835,7 +9163,7 @@ dependencies = [ [[package]] name = "sc-client-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "fnv", "futures 0.3.21", @@ -8863,7 +9191,7 @@ dependencies = [ [[package]] name = "sc-client-db" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "hash-db", "kvdb", @@ -8888,7 +9216,7 @@ dependencies = [ [[package]] name = "sc-consensus" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "futures 0.3.21", @@ -8912,7 +9240,7 @@ dependencies = [ [[package]] name = "sc-consensus-aura" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "derive_more", @@ -8941,7 +9269,7 @@ dependencies = [ [[package]] name = "sc-consensus-babe" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "derive_more", @@ -8984,7 +9312,7 @@ dependencies = [ [[package]] name = "sc-consensus-babe-rpc" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "derive_more", "futures 0.3.21", @@ -9008,7 +9336,7 @@ dependencies = [ [[package]] name = "sc-consensus-epochs" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "fork-tree", "parity-scale-codec", @@ -9021,7 +9349,7 @@ dependencies = [ [[package]] name = "sc-consensus-manual-seal" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "assert_matches", "async-trait", @@ -9057,7 +9385,7 @@ dependencies = [ [[package]] name = "sc-consensus-slots" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "futures 0.3.21", @@ -9082,7 +9410,7 @@ dependencies = [ [[package]] name = "sc-consensus-uncles" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "sc-client-api", "sp-authorship", @@ -9093,10 +9421,10 @@ dependencies = [ [[package]] name = "sc-executor" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "lazy_static", - "libsecp256k1", + "libsecp256k1 0.7.0", "log", "lru 0.6.6", "parity-scale-codec", @@ -9121,7 +9449,7 @@ dependencies = [ [[package]] name = "sc-executor-common" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "derive_more", "environmental", @@ -9139,7 +9467,7 @@ dependencies = [ [[package]] name = "sc-executor-wasmi" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "log", "parity-scale-codec", @@ -9155,7 +9483,7 @@ dependencies = [ [[package]] name = "sc-executor-wasmtime" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "cfg-if 1.0.0", "libc", @@ -9173,7 +9501,7 @@ dependencies = [ [[package]] name = "sc-finality-grandpa" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "derive_more", @@ -9185,7 +9513,7 @@ dependencies = [ "log", "parity-scale-codec", "parking_lot 0.11.2", - "rand 0.8.4", + "rand 0.8.5", "sc-block-builder", "sc-chain-spec", "sc-client-api", @@ -9211,7 +9539,7 @@ dependencies = [ [[package]] name = "sc-finality-grandpa-rpc" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "derive_more", "finality-grandpa", @@ -9235,7 +9563,7 @@ dependencies = [ [[package]] name = "sc-informant" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "ansi_term", "futures 0.3.21", @@ -9252,7 +9580,7 @@ dependencies = [ [[package]] name = "sc-keystore" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "derive_more", @@ -9267,7 +9595,7 @@ dependencies = [ [[package]] name = "sc-network" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-std", "async-trait", @@ -9318,7 +9646,7 @@ dependencies = [ [[package]] name = "sc-network-gossip" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "futures 0.3.21", "futures-timer", @@ -9334,7 +9662,7 @@ dependencies = [ [[package]] name = "sc-offchain" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "bytes 1.1.0", "fnv", @@ -9362,7 +9690,7 @@ dependencies = [ [[package]] name = "sc-peerset" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "futures 0.3.21", "libp2p", @@ -9375,7 +9703,7 @@ dependencies = [ [[package]] name = "sc-proposer-metrics" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "log", "substrate-prometheus-endpoint", @@ -9384,7 +9712,7 @@ dependencies = [ [[package]] name = "sc-rpc" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "futures 0.3.21", "hash-db", @@ -9415,7 +9743,7 @@ dependencies = [ [[package]] name = "sc-rpc-api" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "futures 0.3.21", "jsonrpc-core", @@ -9440,7 +9768,7 @@ dependencies = [ [[package]] name = "sc-rpc-server" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "futures 0.3.21", "jsonrpc-core", @@ -9457,7 +9785,7 @@ dependencies = [ [[package]] name = "sc-service" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "directories", @@ -9521,7 +9849,7 @@ dependencies = [ [[package]] name = "sc-state-db" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "log", "parity-scale-codec", @@ -9535,7 +9863,7 @@ dependencies = [ [[package]] name = "sc-sync-state-rpc" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "jsonrpc-core", "jsonrpc-core-client", @@ -9557,7 +9885,7 @@ dependencies = [ [[package]] name = "sc-telemetry" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "chrono", "futures 0.3.21", @@ -9575,7 +9903,7 @@ dependencies = [ [[package]] name = "sc-tracing" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "ansi_term", "atty", @@ -9606,9 +9934,9 @@ dependencies = [ [[package]] name = "sc-tracing-proc-macro" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", @@ -9617,7 +9945,7 @@ dependencies = [ [[package]] name = "sc-transaction-pool" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "futures 0.3.21", "futures-timer", @@ -9644,7 +9972,7 @@ dependencies = [ [[package]] name = "sc-transaction-pool-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "derive_more", "futures 0.3.21", @@ -9658,7 +9986,7 @@ dependencies = [ [[package]] name = "sc-utils" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "futures 0.3.21", "futures-timer", @@ -9687,7 +10015,7 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "baeb2780690380592f86205aa4ee49815feb2acad8c2f59e6dd207148c3f1fcd" dependencies = [ - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", @@ -9717,7 +10045,7 @@ dependencies = [ "rand 0.7.3", "rand_core 0.5.1", "sha2 0.8.2", - "subtle", + "subtle 2.4.1", "zeroize", ] @@ -9795,9 +10123,9 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.5" +version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0486718e92ec9a68fbed73bb5ef687d71103b142595b406835649bebd33f72c7" +checksum = "a4a3381e03edd24287172047536f20cabde766e2cd3e65e6b00fb3af51c4f38d" dependencies = [ "serde", ] @@ -9900,13 +10228,13 @@ dependencies = [ [[package]] name = "sha2" -version = "0.10.1" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99c3bd8169c58782adad9290a9af5939994036b76187f7b4f0e6de91dbbfc0ec" +checksum = "55deaec60f81eefe3cce0dc50bda92d6d8e88f2a27df7c5033b42afeb1ed2676" dependencies = [ "cfg-if 1.0.0", "cpufeatures 0.2.1", - "digest 0.10.1", + "digest 0.10.3", ] [[package]] @@ -10021,12 +10349,12 @@ dependencies = [ "aes-gcm", "blake2", "chacha20poly1305", - "rand 0.8.4", + "rand 0.8.5", "rand_core 0.6.3", "ring", "rustc_version 0.3.3", "sha2 0.9.9", - "subtle", + "subtle 2.4.1", "x25519-dalek", ] @@ -10063,14 +10391,14 @@ dependencies = [ "futures 0.3.21", "httparse", "log", - "rand 0.8.4", + "rand 0.8.5", "sha-1 0.9.8", ] [[package]] name = "sp-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "hash-db", "log", @@ -10087,10 +10415,10 @@ dependencies = [ [[package]] name = "sp-api-proc-macro" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "blake2-rfc", - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", @@ -10099,7 +10427,7 @@ dependencies = [ [[package]] name = "sp-application-crypto" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "scale-info", @@ -10112,7 +10440,7 @@ dependencies = [ [[package]] name = "sp-arithmetic" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "integer-sqrt", "num-traits", @@ -10127,7 +10455,7 @@ dependencies = [ [[package]] name = "sp-authority-discovery" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "scale-info", @@ -10140,7 +10468,7 @@ dependencies = [ [[package]] name = "sp-authorship" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "parity-scale-codec", @@ -10152,7 +10480,7 @@ dependencies = [ [[package]] name = "sp-block-builder" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "sp-api", @@ -10164,7 +10492,7 @@ dependencies = [ [[package]] name = "sp-blockchain" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "futures 0.3.21", "log", @@ -10182,7 +10510,7 @@ dependencies = [ [[package]] name = "sp-consensus" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "futures 0.3.21", @@ -10201,7 +10529,7 @@ dependencies = [ [[package]] name = "sp-consensus-aura" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "parity-scale-codec", @@ -10219,7 +10547,7 @@ dependencies = [ [[package]] name = "sp-consensus-babe" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "merlin", @@ -10242,7 +10570,7 @@ dependencies = [ [[package]] name = "sp-consensus-slots" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "scale-info", @@ -10254,7 +10582,7 @@ dependencies = [ [[package]] name = "sp-consensus-vrf" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "schnorrkel", @@ -10266,7 +10594,7 @@ dependencies = [ [[package]] name = "sp-core" version = "4.1.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "base58", "bitflags", @@ -10280,7 +10608,7 @@ dependencies = [ "hex", "impl-serde", "lazy_static", - "libsecp256k1", + "libsecp256k1 0.7.0", "log", "merlin", "num-traits", @@ -10294,7 +10622,7 @@ dependencies = [ "schnorrkel", "secrecy", "serde", - "sha2 0.10.1", + "sha2 0.10.2", "sp-core-hashing", "sp-debug-derive", "sp-externalities", @@ -10314,11 +10642,11 @@ dependencies = [ [[package]] name = "sp-core-hashing" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "blake2-rfc", "byteorder", - "sha2 0.10.1", + "sha2 0.10.2", "sp-std", "tiny-keccak", "twox-hash", @@ -10327,7 +10655,7 @@ dependencies = [ [[package]] name = "sp-core-hashing-proc-macro" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "proc-macro2", "quote", @@ -10338,7 +10666,7 @@ dependencies = [ [[package]] name = "sp-database" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "kvdb", "parking_lot 0.11.2", @@ -10347,7 +10675,7 @@ dependencies = [ [[package]] name = "sp-debug-derive" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "proc-macro2", "quote", @@ -10357,7 +10685,7 @@ dependencies = [ [[package]] name = "sp-externalities" version = "0.10.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "environmental", "parity-scale-codec", @@ -10368,7 +10696,7 @@ dependencies = [ [[package]] name = "sp-finality-grandpa" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "finality-grandpa", "log", @@ -10386,7 +10714,7 @@ dependencies = [ [[package]] name = "sp-inherents" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "impl-trait-for-tuples", @@ -10400,11 +10728,11 @@ dependencies = [ [[package]] name = "sp-io" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "futures 0.3.21", "hash-db", - "libsecp256k1", + "libsecp256k1 0.7.0", "log", "parity-scale-codec", "parking_lot 0.11.2", @@ -10424,7 +10752,7 @@ dependencies = [ [[package]] name = "sp-keyring" version = "4.1.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "lazy_static", "sp-core", @@ -10435,7 +10763,7 @@ dependencies = [ [[package]] name = "sp-keystore" version = "0.10.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "derive_more", @@ -10452,7 +10780,7 @@ dependencies = [ [[package]] name = "sp-maybe-compressed-blob" version = "4.1.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "zstd", ] @@ -10460,7 +10788,7 @@ dependencies = [ [[package]] name = "sp-npos-elections" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "scale-info", @@ -10475,9 +10803,9 @@ dependencies = [ [[package]] name = "sp-npos-elections-solution-type" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", @@ -10486,7 +10814,7 @@ dependencies = [ [[package]] name = "sp-offchain" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "sp-api", "sp-core", @@ -10496,7 +10824,7 @@ dependencies = [ [[package]] name = "sp-panic-handler" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "backtrace", "lazy_static", @@ -10506,7 +10834,7 @@ dependencies = [ [[package]] name = "sp-rpc" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "rustc-hash", "serde", @@ -10516,7 +10844,7 @@ dependencies = [ [[package]] name = "sp-runtime" version = "4.1.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "either", "hash256-std-hasher", @@ -10538,7 +10866,7 @@ dependencies = [ [[package]] name = "sp-runtime-interface" version = "4.1.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "impl-trait-for-tuples", "parity-scale-codec", @@ -10555,10 +10883,10 @@ dependencies = [ [[package]] name = "sp-runtime-interface-proc-macro" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "Inflector", - "proc-macro-crate 1.1.0", + "proc-macro-crate 1.1.2", "proc-macro2", "quote", "syn", @@ -10567,7 +10895,7 @@ dependencies = [ [[package]] name = "sp-serializer" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "serde", "serde_json", @@ -10576,7 +10904,7 @@ dependencies = [ [[package]] name = "sp-session" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "scale-info", @@ -10590,7 +10918,7 @@ dependencies = [ [[package]] name = "sp-staking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "scale-info", @@ -10601,7 +10929,7 @@ dependencies = [ [[package]] name = "sp-state-machine" version = "0.10.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "hash-db", "log", @@ -10624,12 +10952,12 @@ dependencies = [ [[package]] name = "sp-std" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" [[package]] name = "sp-storage" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "impl-serde", "parity-scale-codec", @@ -10642,7 +10970,7 @@ dependencies = [ [[package]] name = "sp-tasks" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "log", "sp-core", @@ -10655,7 +10983,7 @@ dependencies = [ [[package]] name = "sp-timestamp" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "futures-timer", @@ -10671,7 +10999,7 @@ dependencies = [ [[package]] name = "sp-tracing" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "sp-std", @@ -10683,7 +11011,7 @@ dependencies = [ [[package]] name = "sp-transaction-pool" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "sp-api", "sp-runtime", @@ -10692,7 +11020,7 @@ dependencies = [ [[package]] name = "sp-transaction-storage-proof" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-trait", "log", @@ -10708,7 +11036,7 @@ dependencies = [ [[package]] name = "sp-trie" version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "hash-db", "memory-db", @@ -10723,7 +11051,7 @@ dependencies = [ [[package]] name = "sp-version" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "impl-serde", "parity-scale-codec", @@ -10740,7 +11068,7 @@ dependencies = [ [[package]] name = "sp-version-proc-macro" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "parity-scale-codec", "proc-macro2", @@ -10751,7 +11079,7 @@ dependencies = [ [[package]] name = "sp-wasm-interface" version = "4.1.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "impl-trait-for-tuples", "log", @@ -10769,9 +11097,9 @@ checksum = "6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042d" [[package]] name = "ss58-registry" -version = "1.12.0" +version = "1.15.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8319f44e20b42e5c11b88b1ad4130c35fe2974665a007b08b02322070177136a" +checksum = "2f9799e6d412271cb2414597581128b03f3285f260ea49f5363d07df6a332b3e" dependencies = [ "Inflector", "proc-macro2", @@ -10828,7 +11156,7 @@ dependencies = [ "lazy_static", "nalgebra", "num-traits", - "rand 0.8.4", + "rand 0.8.5", ] [[package]] @@ -10920,7 +11248,7 @@ dependencies = [ [[package]] name = "substrate-build-script-utils" version = "3.0.0" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "platforms", ] @@ -10928,7 +11256,7 @@ dependencies = [ [[package]] name = "substrate-frame-rpc-system" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "frame-system-rpc-runtime-api", "futures 0.3.21", @@ -10950,7 +11278,7 @@ dependencies = [ [[package]] name = "substrate-prometheus-endpoint" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "async-std", "derive_more", @@ -10964,7 +11292,7 @@ dependencies = [ [[package]] name = "substrate-wasm-builder" version = "5.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "ansi_term", "build-helper", @@ -10976,6 +11304,12 @@ dependencies = [ "wasm-gc-api", ] +[[package]] +name = "subtle" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2d67a5a62ba6e01cb2192ff309324cb4875d0c451d55fe2319433abe7a05a8ee" + [[package]] name = "subtle" version = "2.4.1" @@ -11156,18 +11490,19 @@ checksum = "cda74da7e1a664f795bb1f8a87ec406fb89a02522cf6e50620d016add6dbbf5c" [[package]] name = "tokio" -version = "1.16.1" +version = "1.17.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c27a64b625de6d309e8c57716ba93021dccf1b3b5c97edd6d3dd2d2135afc0a" +checksum = "2af73ac49756f3f7c01172e34a23e5d0216f6c32333757c2c61feb2bbff5a5ee" dependencies = [ "bytes 1.1.0", "libc", "memchr", - "mio 0.7.14", + "mio 0.8.0", "num_cpus", "once_cell", "pin-project-lite 0.2.8", "signal-hook-registry", + "socket2 0.4.4", "tokio-macros", "winapi 0.3.9", ] @@ -11237,9 +11572,9 @@ checksum = "360dfd1d6d30e05fda32ace2c8c70e9c0a9da713275777f5a4dbb8a1893930c6" [[package]] name = "tracing" -version = "0.1.30" +version = "0.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d8d93354fe2a8e50d5953f5ae2e47a3fc2ef03292e7ea46e3cc38f549525fb9" +checksum = "f6c650a8ef0cd2dd93736f033d21cbd1224c5a967aa0c258d00fcf7dafef9b9f" dependencies = [ "cfg-if 1.0.0", "pin-project-lite 0.2.8", @@ -11361,7 +11696,7 @@ dependencies = [ "ipnet", "lazy_static", "log", - "rand 0.8.4", + "rand 0.8.5", "smallvec", "thiserror", "tinyvec", @@ -11396,7 +11731,7 @@ checksum = "59547bce71d9c38b83d9c0e92b6066c4253371f15005def0c30d9657f50c7642" [[package]] name = "try-runtime-cli" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#4aeb95f7f38fcd519e2628f32f79044a8fef99d5" +source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.16#19162e43be45817b44c7d48e50d03f074f60fbf4" dependencies = [ "jsonrpsee", "log", @@ -11431,7 +11766,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4ee73e6e4924fe940354b8d4d98cad5231175d615cd855b758adc658c0aac6a0" dependencies = [ "cfg-if 1.0.0", - "rand 0.8.4", + "rand 0.8.5", "static_assertions", ] @@ -11508,7 +11843,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9f214e8f697e925001e66ec2c6e37a4ef93f0f78c2eed7814394e10c62025b05" dependencies = [ "generic-array 0.14.5", - "subtle", + "subtle 2.4.1", ] [[package]] @@ -11782,9 +12117,9 @@ checksum = "98930446519f63d00a836efdc22f67766ceae8dbcc1571379f2bcabc6b2b9abc" [[package]] name = "wasmtime" -version = "0.33.0" +version = "0.33.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "414be1bc5ca12e755ffd3ff7acc3a6d1979922f8237fc34068b2156cebcc3270" +checksum = "4c9c724da92e39a85d2231d4c2a942c8be295211441dbca581c6c3f3f45a9f00" dependencies = [ "anyhow", "backtrace", @@ -11814,9 +12149,9 @@ dependencies = [ [[package]] name = "wasmtime-cache" -version = "0.33.0" +version = "0.33.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b9b4cd1949206fda9241faf8c460a7d797aa1692594d3dd6bc1cbfa57ee20d0" +checksum = "da4439d99100298344567c0eb6916ad5864e99e54760b8177c427e529077fb30" dependencies = [ "anyhow", "base64", @@ -11834,9 +12169,9 @@ dependencies = [ [[package]] name = "wasmtime-cranelift" -version = "0.33.0" +version = "0.33.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4693d33725773615a4c9957e4aa731af57b27dca579702d1d8ed5750760f1a9" +checksum = "1762765dd69245f00e5d9783b695039e449a7be0f9c5383e4c78465dd6131aeb" dependencies = [ "anyhow", "cranelift-codegen", @@ -11856,9 +12191,9 @@ dependencies = [ [[package]] name = "wasmtime-environ" -version = "0.33.0" +version = "0.33.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b17e47116a078b9770e6fb86cff8b9a660826623cebcfff251b047c8d8993ef" +checksum = "c4468301d95ec71710bb6261382efe27d1296447711645e3dbabaea6e4de3504" dependencies = [ "anyhow", "cranelift-entity", @@ -11876,9 +12211,9 @@ dependencies = [ [[package]] name = "wasmtime-jit" -version = "0.33.0" +version = "0.33.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60ea5b380bdf92e32911400375aeefb900ac9d3f8e350bb6ba555a39315f2ee7" +checksum = "ab0ae6e581ff014b470ec35847ea3c0b4c3ace89a55df5a04c802a11f4574e7d" dependencies = [ "addr2line", "anyhow", @@ -11898,9 +12233,9 @@ dependencies = [ [[package]] name = "wasmtime-runtime" -version = "0.33.0" +version = "0.33.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abc7cd79937edd6e238b337608ebbcaf9c086a8457f01dfd598324f7fa56d81a" +checksum = "6d9c28877ae37a367cda7b52b8887589816152e95dde9b7c80cc686f52761961" dependencies = [ "anyhow", "backtrace", @@ -11913,7 +12248,7 @@ dependencies = [ "mach", "memoffset", "more-asserts", - "rand 0.8.4", + "rand 0.8.5", "region", "rustix", "thiserror", @@ -11923,9 +12258,9 @@ dependencies = [ [[package]] name = "wasmtime-types" -version = "0.33.0" +version = "0.33.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9e5e51a461a2cf2b69e1fc48f325b17d78a8582816e18479e8ead58844b23f8" +checksum = "395726e8f5dd8c57cb0db445627b842343f7e29ed7489467fdf7953ed9d3cd4f" dependencies = [ "cranelift-entity", "serde", @@ -12069,6 +12404,69 @@ dependencies = [ "sp-runtime", ] +[[package]] +name = "westmint-runtime" +version = "1.0.0" +source = "git+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.16#86f76c5619c64d1300315612695ad4b4fcd0f562" +dependencies = [ + "cumulus-pallet-aura-ext", + "cumulus-pallet-dmp-queue", + "cumulus-pallet-parachain-system", + "cumulus-pallet-session-benchmarking", + "cumulus-pallet-xcm", + "cumulus-pallet-xcmp-queue", + "cumulus-ping", + "cumulus-primitives-core", + "cumulus-primitives-timestamp", + "cumulus-primitives-utility", + "frame-executive", + "frame-support", + "frame-system", + "frame-system-rpc-runtime-api", + "log", + "node-primitives 2.0.0", + "pallet-asset-tx-payment", + "pallet-assets", + "pallet-aura", + "pallet-authorship", + "pallet-balances", + "pallet-collator-selection", + "pallet-multisig", + "pallet-proxy", + "pallet-session", + "pallet-timestamp", + "pallet-transaction-payment", + "pallet-transaction-payment-rpc-runtime-api", + "pallet-uniques", + "pallet-utility", + "pallet-xcm", + "parachain-info", + "parachains-common", + "parity-scale-codec", + "polkadot-parachain", + "polkadot-runtime-common", + "scale-info", + "serde", + "smallvec", + "sp-api", + "sp-block-builder", + "sp-consensus-aura", + "sp-core", + "sp-inherents", + "sp-io", + "sp-offchain", + "sp-runtime", + "sp-session", + "sp-std", + "sp-transaction-pool", + "sp-version", + "substrate-wasm-builder", + "westend-runtime-constants", + "xcm", + "xcm-builder", + "xcm-executor", +] + [[package]] name = "which" version = "4.2.4" @@ -12198,6 +12596,30 @@ dependencies = [ "xcm-executor", ] +[[package]] +name = "xcm-emulator" +version = "0.1.0" +source = "git+https://github.com/shaunxw/xcm-simulator?rev=a250ffc998bac4831c5692c591dee7bc13f3aead#a250ffc998bac4831c5692c591dee7bc13f3aead" +dependencies = [ + "cumulus-pallet-dmp-queue", + "cumulus-pallet-parachain-system", + "cumulus-pallet-xcmp-queue", + "cumulus-primitives-core", + "cumulus-primitives-parachain-inherent", + "cumulus-test-relay-sproof-builder", + "frame-support", + "frame-system", + "parachain-info", + "parity-scale-codec", + "paste", + "polkadot-primitives", + "polkadot-runtime-parachains", + "sp-io", + "sp-std", + "xcm", + "xcm-executor", +] + [[package]] name = "xcm-executor" version = "0.9.16" @@ -12217,33 +12639,35 @@ dependencies = [ ] [[package]] -name = "xcm-procedural" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.16#41ab002d7451766324a9f314fee11c9c53314350" -dependencies = [ - "Inflector", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "xcm-support" +name = "xcm-interface" version = "0.8.0" +source = "git+https://github.com/bifrost-finance/xcm-interface?rev=873860a2363186af2527018e89e543379f06772e#873860a2363186af2527018e89e543379f06772e" dependencies = [ - "cumulus-primitives-core", + "frame-benchmarking", "frame-support", "frame-system", - "node-primitives", + "orml-traits", + "pallet-xcm", "parity-scale-codec", - "paste", - "smallvec", + "scale-info", + "sp-core", "sp-io", "sp-runtime", "sp-std", "xcm", ] +[[package]] +name = "xcm-procedural" +version = "0.1.0" +source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.16#41ab002d7451766324a9f314fee11c9c53314350" +dependencies = [ + "Inflector", + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "yamux" version = "0.9.0" @@ -12254,7 +12678,7 @@ dependencies = [ "log", "nohash-hasher", "parking_lot 0.11.2", - "rand 0.8.4", + "rand 0.8.5", "static_assertions", ] @@ -12320,9 +12744,9 @@ dependencies = [ [[package]] name = "zeroize_derive" -version = "1.3.1" +version = "1.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81e8f13fef10b63c06356d65d416b070798ddabcadc10d3ece0c5be9b3c7eddb" +checksum = "3f8f187641dad4f680d25c4bfc4225b418165984179f26ca76ec4fb6441d3a17" dependencies = [ "proc-macro2", "quote", diff --git a/Cargo.toml b/Cargo.toml index 2d2e3cda67..719a782f02 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [workspace] members = [ - #"integration-tests", + "integration-tests", "node/cli", "node/primitives", "node/rpc", @@ -16,7 +16,6 @@ members = [ "pallets/call-switchgear", "runtime/bifrost-kusama", "runtime/bifrost-polkadot", - "xcm-support", ] [profile.dev] @@ -103,4 +102,4 @@ orml-xtokens = { git = "https://github.com/open-web3-stack/open-runtime-module-l orml-unknown-tokens = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "ec9a8d8521ca9b7b800dd36726bba7da7a169b9d" } orml-xcm = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "ec9a8d8521ca9b7b800dd36726bba7da7a169b9d" } orml-xcm-support = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "ec9a8d8521ca9b7b800dd36726bba7da7a169b9d" } - +xcm-interface = { git = "https://github.com/bifrost-finance/xcm-interface", rev = "873860a2363186af2527018e89e543379f06772e"} diff --git a/integration-tests/Cargo.toml b/integration-tests/Cargo.toml index 734f2f08d1..684a8e1b07 100644 --- a/integration-tests/Cargo.toml +++ b/integration-tests/Cargo.toml @@ -93,7 +93,6 @@ bifrost-salp-rpc-runtime-api = { path = "../pallets/salp/rpc/runtime-api", defau bifrost-vsbond-auction = { path = "../pallets/vsbond-auction", default-features = false } bifrost-vtoken-mint = { path = "../pallets/vtoken-mint", default-features = false } pallet-vesting = { package = "bifrost-vesting", path = "../pallets/vesting", default-features = false } -xcm-support = { path = "../xcm-support", default-features = false } bifrost-kusama-runtime = { path = "../runtime/bifrost-kusama", default-features = false } bifrost-polkadot-runtime = { path = "../runtime/bifrost-polkadot", default-features = false } @@ -205,7 +204,6 @@ std = [ "bifrost-salp-rpc-runtime-api/std", "bifrost-vsbond-auction/std", "bifrost-vtoken-mint/std", - "xcm-support/std", "orml-currencies/std", "orml-traits/std", "orml-tokens/std", diff --git a/node/cli/Cargo.toml b/node/cli/Cargo.toml index a96ee4e865..cc582cc3e3 100644 --- a/node/cli/Cargo.toml +++ b/node/cli/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "node-cli" -version = "0.9.26" +version = "0.9.27" authors = ["Liebi Technologies "] description = "Bifrost Parachain Node" build = "build.rs" diff --git a/node/primitives/src/lib.rs b/node/primitives/src/lib.rs index 3bfbb36518..58312fbfe4 100644 --- a/node/primitives/src/lib.rs +++ b/node/primitives/src/lib.rs @@ -31,7 +31,6 @@ mod bridge; pub mod currency; mod salp; pub mod traits; -mod xcm; pub use salp::*; #[cfg(test)] @@ -41,7 +40,6 @@ pub use crate::{ bridge::*, currency::{CurrencyId, TokenSymbol}, traits::*, - xcm::*, }; /// An index to a block. diff --git a/node/primitives/src/xcm.rs b/node/primitives/src/xcm.rs deleted file mode 100644 index 3134779da9..0000000000 --- a/node/primitives/src/xcm.rs +++ /dev/null @@ -1,87 +0,0 @@ -// This file is part of Bifrost. - -// Copyright (C) 2019-2022 Liebi Technologies (UK) Ltd. -// SPDX-License-Identifier: GPL-3.0-or-later WITH Classpath-exception-2.0 - -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -use core::ops::{Add, Mul}; - -use codec::{Decode, Encode}; -use scale_info::TypeInfo; -use sp_std::prelude::*; - -/// The type used to represent the xcmp transfer direction -#[derive(Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Encode, Decode, TypeInfo)] -pub enum TransferOriginType { - FromSelf = 0, - FromRelayChain = 1, - FromSiblingParaChain = 2, -} - -pub struct XcmBaseWeight(u64); - -impl XcmBaseWeight { - pub fn new(x: u64) -> Self { - XcmBaseWeight(x) - } -} - -impl From for XcmBaseWeight { - fn from(u: u64) -> Self { - XcmBaseWeight(u) - } -} - -impl From for u64 { - fn from(x: XcmBaseWeight) -> Self { - x.0.into() - } -} - -impl Add for XcmBaseWeight { - type Output = Self; - fn add(self, other: Self) -> Self::Output { - (self.0 + other.0).into() - } -} - -impl Mul for XcmBaseWeight { - type Output = Self; - - fn mul(self, rhs: u64) -> Self { - XcmBaseWeight::new(self.0 * rhs) - } -} - -/// represent the transact type -#[derive(Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Encode, Decode, TypeInfo)] -pub enum ParachainTransactType { - Xcm = 0, - Proxy = 1, -} - -/// represent the proxy type -#[derive(Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Encode, Decode, TypeInfo)] -pub enum ParachainTransactProxyType { - Primary = 0, - Derived = 1, -} - -/// represent the derived proxy account type -#[repr(u16)] -pub enum ParachainDerivedProxyAccountType { - Salp = 0, - Staking = 1, -} diff --git a/pallets/flexible-fee/Cargo.toml b/pallets/flexible-fee/Cargo.toml index 6d4d2bbc33..5667801308 100644 --- a/pallets/flexible-fee/Cargo.toml +++ b/pallets/flexible-fee/Cargo.toml @@ -27,13 +27,10 @@ sp-core = { git = "https://github.com/paritytech/substrate", branch = "polkadot- sp-io = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.16" } smallvec = "1.4.1" cumulus-primitives-core = { git = "https://github.com/paritytech/cumulus", default-features = false, branch = "polkadot-v0.9.16" } -xcm-builder = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.16" } -pallet-xcm = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.16" } -xcm = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.16"} -xcm-support = { path = "../../xcm-support"} bifrost-salp = { path = "../salp" } bifrost-kusama-runtime = { path = "../../runtime/bifrost-kusama" } bifrost-runtime-common = { path = "../../runtime/common" } +xcm-interface = {version = "*"} [features] default = ["std"] diff --git a/pallets/flexible-fee/src/lib.rs b/pallets/flexible-fee/src/lib.rs index 00447e08f1..dc23858c75 100644 --- a/pallets/flexible-fee/src/lib.rs +++ b/pallets/flexible-fee/src/lib.rs @@ -102,17 +102,15 @@ pub mod pallet { type AltFeeCurrencyExchangeRate: Get<(u32, u32)>; } - pub type CurrencyIdOf = <::MultiCurrency as MultiCurrency< - ::AccountId, - >>::CurrencyId; - pub type PalletBalanceOf = - <::Currency as Currency<::AccountId>>::Balance; - pub type NegativeImbalanceOf = <::Currency as Currency< - ::AccountId, - >>::NegativeImbalance; - pub type PositiveImbalanceOf = <::Currency as Currency< - ::AccountId, - >>::PositiveImbalance; + pub type AccountIdOf = ::AccountId; + pub type CurrencyIdOf = + <::MultiCurrency as MultiCurrency>>::CurrencyId; + pub type PalletBalanceOf = <::Currency as Currency>>::Balance; + pub type NegativeImbalanceOf = + <::Currency as Currency>>::NegativeImbalance; + pub type PositiveImbalanceOf = + <::Currency as Currency>>::PositiveImbalance; + pub type CallOf = ::Call; #[pallet::hooks] @@ -121,7 +119,7 @@ pub mod pallet { #[pallet::event] #[pallet::generate_deposit(pub(super) fn deposit_event)] pub enum Event { - FlexibleFeeExchanged(CurrencyIdOf, u128), // token and amount + FlexibleFeeExchanged(CurrencyIdOf, PalletBalanceOf), // token and amount FixedRateFeeExchanged(CurrencyIdOf, PalletBalanceOf), ExtraFeeDeducted(ExtraFeeName, CurrencyIdOf, PalletBalanceOf), } @@ -383,7 +381,10 @@ impl FeeDealer, CurrencyIdOf> for ) .is_ok() { - Self::deposit_event(Event::FlexibleFeeExchanged(currency_id, amounts[0])); + Self::deposit_event(Event::FlexibleFeeExchanged( + currency_id, + PalletBalanceOf::::saturated_from(amounts[0]), + )); // successfully swap, break iteration break; } diff --git a/pallets/flexible-fee/src/misc_fees.rs b/pallets/flexible-fee/src/misc_fees.rs index a0e8d11a11..b95c250eba 100644 --- a/pallets/flexible-fee/src/misc_fees.rs +++ b/pallets/flexible-fee/src/misc_fees.rs @@ -19,26 +19,22 @@ // The swap pool algorithm implements Balancer protocol // For more details, refer to https://balancer.finance/whitepaper/ -use frame_support::{ - traits::Contains, - weights::{Weight, WeightToFeePolynomial}, -}; +use frame_support::traits::Contains; use node_primitives::ExtraFeeName; use super::*; use crate::Config; -pub struct MiscFeeHandler( - PhantomData<(T, FeeCurrency, WeightToFee, WeightHolder, FeeFilter)>, +pub struct MiscFeeHandler( + PhantomData<(T, FeeCurrency, FeeAmount, FeeFilter)>, ); -impl +impl FeeDeductor, PalletBalanceOf, T::Call> - for MiscFeeHandler + for MiscFeeHandler where FeeCurrency: Get>, - WeightToFee: WeightToFeePolynomial>, - WeightHolder: Get, + FeeAmount: Get>, FeeFilter: Contains>, { fn deduct_fee( @@ -48,7 +44,7 @@ where ) -> Result<(CurrencyIdOf, PalletBalanceOf), DispatchError> { // If this call matches a specific extra-fee call if FeeFilter::contains(call) { - let total_fee = WeightToFee::calc(&WeightHolder::get()); + let total_fee = FeeAmount::get(); let fee_currency = FeeCurrency::get(); ::MultiCurrency::transfer(fee_currency, who, receiver, total_fee)?; diff --git a/pallets/flexible-fee/src/mock.rs b/pallets/flexible-fee/src/mock.rs index 848d78a88b..de5da35268 100644 --- a/pallets/flexible-fee/src/mock.rs +++ b/pallets/flexible-fee/src/mock.rs @@ -20,8 +20,6 @@ use std::convert::TryInto; -// pub use polkadot_parachain::primitives::Id; -pub use cumulus_primitives_core::ParaId; #[cfg(feature = "runtime-benchmarks")] use frame_benchmarking::whitelisted_caller; use frame_support::{ @@ -29,36 +27,26 @@ use frame_support::{ sp_runtime::{DispatchError, DispatchResult}, sp_std::marker::PhantomData, traits::{Contains, Nothing}, - weights::{ - constants::ExtrinsicBaseWeight, IdentityFee, Weight, WeightToFeeCoefficients, - WeightToFeePolynomial, - }, + weights::IdentityFee, PalletId, }; use frame_system as system; use frame_system::EnsureRoot; -use node_primitives::{ - CurrencyId, MessageId, ParachainTransactProxyType, ParachainTransactType, TokenSymbol, - TransferOriginType, XcmBaseWeight, -}; -use orml_traits::{MultiCurrency, XcmTransfer}; -use smallvec::smallvec; +use node_primitives::{CurrencyId, MessageId, ParaId, TokenSymbol}; +use orml_traits::MultiCurrency; use sp_arithmetic::Percent; use sp_core::H256; use sp_runtime::{ generic, testing::Header, traits::{BlakeTwo256, IdentityLookup, UniqueSaturatedInto}, - AccountId32, Perbill, SaturatedConversion, + AccountId32, SaturatedConversion, }; -use sp_std::cell::RefCell; -use xcm::{latest::prelude::*, DoubleEncoded}; -use xcm_support::BifrostXcmExecutor; +use xcm_interface::traits::XcmHelper; use zenlink_protocol::{AssetId as ZenlinkAssetId, LocalAssetHandler, ZenlinkMultiAssets}; use super::*; use crate as flexible_fee; -// use node_primitives::Balance; use crate::{ fee_dealer::FixedCurrencyFeeRate, misc_fees::{ExtraFeeMatcher, MiscFeeHandler, NameGetter}, @@ -124,25 +112,6 @@ impl system::Config for Test { type MaxConsumers = frame_support::traits::ConstU32<16>; } -thread_local! { - static WEIGHT_TO_FEE: RefCell = RefCell::new(1); -} - -pub struct WeightToFee; -impl WeightToFeePolynomial for WeightToFee { - type Balance = Balance; - fn polynomial() -> WeightToFeeCoefficients { - let p = 1_000_000_000_000 / 30_000; // RELAY_CENTS - let q = 10 * Balance::from(ExtrinsicBaseWeight::get()); // ExtrinsicBaseWeight = 125 * 1_000_000_000_000 / 1000 / 1000 = 125_000_000 - smallvec![frame_support::weights::WeightToFeeCoefficient { - degree: 1, - negative: false, - coeff_frac: Perbill::from_rational(p % q, q), - coeff_integer: p / q, - }] - } -} - parameter_types! { pub const TransactionByteFee: Balance = 1; pub const OperationalFeeMultiplier: u8 = 5; @@ -234,7 +203,7 @@ parameter_types! { pub const AlternativeFeeCurrencyId: CurrencyId = CurrencyId::Token(TokenSymbol::KSM); pub const AltFeeCurrencyExchangeRate: (u32, u32) = (1, 100); pub const TreasuryAccount: AccountId32 = TREASURY_ACCOUNT; - pub SalpWeightHolder: XcmBaseWeight = XcmBaseWeight::from(4 * XCM_WEIGHT + ContributionWeight::get()) + u64::pow(2, 24).into(); + pub const SalpContributeFee: Balance = 100_000_000; } impl crate::Config for Test { @@ -251,13 +220,8 @@ impl crate::Config for Test { type OnUnbalanced = (); type WeightInfo = (); type ExtraFeeMatcher = ExtraFeeMatcher; - type MiscFeeHandler = MiscFeeHandler< - Test, - AlternativeFeeCurrencyId, - WeightToFee, - SalpWeightHolder, - ContributeFeeFilter, - >; + type MiscFeeHandler = + MiscFeeHandler; } parameter_types! { @@ -413,45 +377,19 @@ pub(crate) fn new_test_ext() -> sp_io::TestExternalities { // To control the result returned by `MockXcmExecutor` pub(crate) static mut MOCK_XCM_RESULT: (bool, bool) = (true, true); +#[allow(type_alias_bounds)] +pub type AccountIdOf = ::AccountId; + // Mock XcmExecutor pub struct MockXcmExecutor; -impl BifrostXcmExecutor for MockXcmExecutor { - fn transact_weight(_: u64, _: u32) -> u64 { - return 0; - } - - fn transact_id(_data: &[u8]) -> MessageId { - return [0; 32]; - } - - fn ump_transact( - _origin: MultiLocation, - _call: DoubleEncoded<()>, - _weight: u64, - _relayer: bool, - _nonce: u32, - ) -> Result<[u8; 32], XcmError> { +impl XcmHelper, crate::pallet::PalletBalanceOf> for MockXcmExecutor { + fn contribute(_index: ParaId, _value: Balance) -> Result { let result = unsafe { MOCK_XCM_RESULT.0 }; match result { true => Ok([0; 32]), - false => Err(XcmError::Unimplemented), - } - } - - fn ump_transfer_asset( - _origin: MultiLocation, - _dest: MultiLocation, - _amount: u128, - _relay: bool, - _nonce: u32, - ) -> Result { - let result = unsafe { MOCK_XCM_RESULT.1 }; - - match result { - true => Ok([0; 32]), - false => Err(XcmError::Unimplemented), + false => Err(DispatchError::BadOrigin), } } } @@ -467,49 +405,12 @@ parameter_types! { pub const VSBondValidPeriod: BlockNumber = 8u32 as BlockNumber; pub const ReleaseCycle: BlockNumber = 8u32 as BlockNumber; pub const ReleaseRatio: Percent = Percent::from_percent(50); - pub const XcmTransferOrigin: TransferOriginType = TransferOriginType::FromRelayChain; - pub BaseXcmWeight:u64 = 1_000_000_000 as u64; - pub ContributionWeight:u64 = 1_000_000_000 as u64; - pub AddProxyWeight:u64 = 1_000_000_000 as u64; - pub PrimaryAccount: AccountId = ALICE; pub ConfirmMuitiSigAccount: AccountId = ALICE; - pub RelaychainSovereignSubAccount: MultiLocation = MultiLocation::parent(); - pub SalpTransactProxyType: ParachainTransactProxyType = ParachainTransactProxyType::Derived; - pub SalpTransactType: ParachainTransactType = ParachainTransactType::Xcm; pub const RelayCurrencyId: CurrencyId = CurrencyId::Token(TokenSymbol::KSM); - pub const RelayNetwork: NetworkId = NetworkId::Kusama; -} - -pub const XCM_WEIGHT: u64 = 1_000_000_000; - -pub struct MockXTokens; - -impl XcmTransfer for MockXTokens { - fn transfer( - _who: AccountId, - _currency_id: CurrencyId, - _amount: Balance, - _dest: MultiLocation, - _dest_weight: Weight, - ) -> DispatchResult { - Ok(()) - } - - fn transfer_multi_asset( - _who: AccountId, - _asset: MultiAsset, - _dest: MultiLocation, - _dest_weight: Weight, - ) -> DispatchResult { - Ok(()) - } } -use bifrost_runtime_common::r#impl::BifrostAccountIdToMultiLocation; - impl bifrost_salp::Config for Test { type BancorPool = (); - type BifrostXcmExecutor = MockXcmExecutor; type Event = Event; type LeasePeriod = LeasePeriod; type MinContribution = MinContribution; @@ -521,20 +422,9 @@ impl bifrost_salp::Config for Test { type RemoveKeysLimit = RemoveKeysLimit; type SlotLength = SlotLength; type VSBondValidPeriod = VSBondValidPeriod; - type XcmTransferOrigin = XcmTransferOrigin; type WeightInfo = (); - type SelfParaId = SelfParaId; - type BaseXcmWeight = BaseXcmWeight; - type ContributionWeight = ContributionWeight; type EnsureConfirmAsGovernance = EnsureRoot; - type AddProxyWeight = AddProxyWeight; - type XcmTransfer = MockXTokens; - type SovereignSubAccountLocation = RelaychainSovereignSubAccount; - type TransactProxyType = SalpTransactProxyType; - type TransactType = SalpTransactType; - type RelayNetwork = RelayNetwork; - type XcmExecutor = (); - type AccountIdToMultiLocation = BifrostAccountIdToMultiLocation; + type XcmInterface = MockXcmExecutor; } //************** Salp mock end ***************** diff --git a/pallets/flexible-fee/src/tests.rs b/pallets/flexible-fee/src/tests.rs index e5d6621c4c..436adbd9fa 100644 --- a/pallets/flexible-fee/src/tests.rs +++ b/pallets/flexible-fee/src/tests.rs @@ -466,7 +466,7 @@ fn deduct_salp_fee_should_work() { // fee is: 133780717 assert_eq!( ::MultiCurrency::free_balance(CURRENCY_ID_4, &CHARLIE), - 66219283 + 100000000 ); // treasury account has the fee assert_eq!( @@ -474,7 +474,7 @@ fn deduct_salp_fee_should_work() { CURRENCY_ID_4, &::TreasuryAccount::get() ), - 133780717 + 100000000 ); }); } diff --git a/pallets/salp/Cargo.toml b/pallets/salp/Cargo.toml index caaeeb0379..29bacb3efe 100644 --- a/pallets/salp/Cargo.toml +++ b/pallets/salp/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "bifrost-salp" version = "0.8.0" -authors = ["Edwin Wang "] +authors = ["Edwin Wang ","Ron yang"] edition = "2021" [dependencies] @@ -16,12 +16,8 @@ sp-std = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v sp-io = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.16", default-features = false } sp-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.16", default-features = false } sp-arithmetic = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.16", default-features = false } -xcm = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.16", default-features = false } -xcm-support = { path = "../../xcm-support", default-features = false } orml-traits = { version = "0.4.1-dev", default-features = false } -xcm-builder = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.16",default-features = false } -pallet-xcm = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.16",default-features = false } -bifrost-runtime-common = { path = "../../runtime/common",default-features = false } +xcm-interface = { version = "*", default-features = false } [dev-dependencies] pallet-multisig = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.16"} @@ -50,17 +46,11 @@ std = [ "sp-runtime/std", "sp-arithmetic/std", "orml-traits/std", - "xcm/std", - "xcm-builder/std", - "pallet-xcm/std", - "xcm-support/std", - "bifrost-runtime-common/std", + "xcm-interface/std" ] runtime-benchmarks = [ "frame-benchmarking", "sp-runtime/runtime-benchmarks", "frame-system/runtime-benchmarks", - "pallet-xcm/runtime-benchmarks", - "xcm-builder/runtime-benchmarks", ] diff --git a/pallets/salp/src/lib.rs b/pallets/salp/src/lib.rs index cd706fd26e..c586c7337e 100644 --- a/pallets/salp/src/lib.rs +++ b/pallets/salp/src/lib.rs @@ -38,27 +38,6 @@ use node_primitives::{ContributionStatus, TokenInfo, TokenSymbol, TrieIndex}; use orml_traits::MultiCurrency; pub use pallet::*; use scale_info::TypeInfo; -use xcm_support::*; - -macro_rules! use_relay { - ({ $( $code:tt )* }) => { - if T::RelayNetwork::get() == NetworkId::Polkadot { - use polkadot::RelaychainCall; - - $( $code )* - } else if T::RelayNetwork::get() == NetworkId::Kusama { - use kusama::RelaychainCall; - - $( $code )* - } else if T::RelayNetwork::get() == NetworkId::Any { - use rococo::RelaychainCall; - - $( $code )* - } else { - unreachable!() - } - } -} #[allow(type_alias_bounds)] pub type AccountIdOf = ::AccountId; @@ -119,20 +98,16 @@ pub mod pallet { PalletId, }; use frame_system::pallet_prelude::*; - use node_primitives::{ - BancorHandler, CurrencyId, LeasePeriod, MessageId, Nonce, ParaId, - ParachainTransactProxyType, ParachainTransactType, TransferOriginType, - }; - use orml_traits::{currency::TransferAll, MultiCurrency, MultiReservableCurrency, XcmTransfer}; + use node_primitives::{BancorHandler, CurrencyId, LeasePeriod, MessageId, Nonce, ParaId}; + use orml_traits::{currency::TransferAll, MultiCurrency, MultiReservableCurrency}; use sp_arithmetic::Percent; - use sp_runtime::traits::Convert; use sp_std::prelude::*; - use xcm::latest::prelude::*; + use xcm_interface::traits::XcmHelper; use super::*; #[pallet::config] - pub trait Config: frame_system::Config + TypeInfo { + pub trait Config: frame_system::Config { type Event: From> + IsType<::Event>; /// ModuleID for the crowdloan module. An appropriate value could be @@ -179,48 +154,10 @@ pub mod pallet { type EnsureConfirmAsGovernance: EnsureOrigin<::Origin>; - type BifrostXcmExecutor: BifrostXcmExecutor; - - #[pallet::constant] - type XcmTransferOrigin: Get; - - /// Weight information for the extrinsics in this module. type WeightInfo: WeightInfo; - /// Parachain Id - type SelfParaId: Get; - - /// Xcm weight - #[pallet::constant] - type BaseXcmWeight: Get; - - #[pallet::constant] - type ContributionWeight: Get; - - #[pallet::constant] - type AddProxyWeight: Get; - - /// The interface to Cross-chain transfer. - type XcmTransfer: XcmTransfer, BalanceOf, CurrencyId>; - - /// The sovereign sub-account for where the staking currencies are sent to. - #[pallet::constant] - type SovereignSubAccountLocation: Get; - - #[pallet::constant] - type TransactProxyType: Get; - - #[pallet::constant] - type TransactType: Get; - - #[pallet::constant] - type RelayNetwork: Get; - - /// XCM executor. - type XcmExecutor: ExecuteXcm; - - /// Convert `T::AccountId` to `MultiLocation`. - type AccountIdToMultiLocation: Convert, MultiLocation>; + /// The XcmInterface to manage the staking of sub-account on relaychain. + type XcmInterface: XcmHelper, BalanceOf>; } #[pallet::pallet] @@ -261,12 +198,6 @@ pub mod pallet { End(ParaId), Continued(ParaId, LeasePeriod, LeasePeriod), RefundedDissolved(ParaId, LeasePeriod, LeasePeriod), - /// Proxy - ProxyAdded(AccountIdOf), - ProxyRemoved(AccountIdOf), - /// Mint - Minted(AccountIdOf, BalanceOf), - TransferredStatemineMultiAsset(AccountIdOf, BalanceOf), } #[pallet::error] @@ -309,8 +240,6 @@ pub mod pallet { NotEnoughFreeAssetsToRedeem, /// Don't have enough token to redeem by users NotEnoughBalanceInRedeemPool, - ConvertFailure, - XcmExecutionFailed, NotEnoughBalanceInFund, InvalidFundSameSlot, InvalidFundNotExist, @@ -331,7 +260,6 @@ pub mod pallet { /// Tracker for the next nonce index #[pallet::storage] #[pallet::getter(fn current_nonce)] - pub(super) type CurrentNonce = StorageMap<_, Blake2_128Concat, ParaId, Nonce, ValueQuery>; @@ -648,10 +576,7 @@ pub mod pallet { ContributionStatus::Contributing(value), ); - let nonce = Self::next_nonce_index(index)?; - - let message_id = Self::xcm_ump_contribute(origin, index, value, nonce) - .map_err(|_e| Error::::XcmFailed)?; + let message_id = T::XcmInterface::contribute(index, value)?; Self::deposit_event(Event::Contributing(who.clone(), index, value.clone(), message_id)); Ok(()) @@ -1001,69 +926,6 @@ pub mod pallet { Ok(()) } - - /// transfer asset to statemine - #[pallet::weight(T::WeightInfo::contribute())] - pub fn transfer_statemine_assets( - origin: OriginFor, - amount: BalanceOf, - asset_id: u32, - dest: Option>, - ) -> DispatchResult { - use bifrost_runtime_common::constants::parachains; - let who = ensure_signed(origin)?; - let dest = match dest { - Some(account) => account, - None => who, - }; - let origin_location = T::AccountIdToMultiLocation::convert(dest.clone()); - let mut assets = MultiAssets::new(); // VersionedMultiAssets::V1(MultiAssets::new(MultiAsset)) - let amount_128 = - TryInto::::try_into(amount).map_err(|_| Error::::ConvertFailure)?; - let statemine_asset = MultiAsset { - id: AssetId::Concrete(MultiLocation::new( - 1, - Junctions::X3( - Junction::Parachain(parachains::Statemine::ID), - Junction::PalletInstance(parachains::Statemine::PALLET_ID), - Junction::GeneralIndex(asset_id.into()), - ), - )), - fun: Fungibility::Fungible(amount_128), - }; - let dest_weight = 4 * T::BaseXcmWeight::get(); - let fee_asset = MultiAsset { - id: AssetId::Concrete(MultiLocation::new(1, Junctions::Here)), - fun: Fungibility::Fungible(dest_weight.into()), - }; - assets.push(statemine_asset); - assets.push(fee_asset.clone()); - let msg = Xcm(vec![ - WithdrawAsset(assets), - InitiateReserveWithdraw { - assets: All.into(), - reserve: MultiLocation::new(1, Junctions::X1(Junction::Parachain(1000))), - xcm: Xcm(vec![ - BuyExecution { - fees: fee_asset, - weight_limit: WeightLimit::Limited(dest_weight), - }, - DepositAsset { - assets: All.into(), - max_assets: 2, - beneficiary: origin_location.clone(), - }, - ]), - }, - ]); - T::XcmExecutor::execute_xcm_in_credit(origin_location, msg, dest_weight, dest_weight) - .ensure_complete() - .map_err(|_| Error::::XcmExecutionFailed)?; - - Self::deposit_event(Event::::TransferredStatemineMultiAsset(dest, amount)); - - Ok(()) - } } #[pallet::hooks] @@ -1187,13 +1049,6 @@ pub mod pallet { }) } - pub(crate) fn next_nonce_index(index: ParaId) -> Result> { - CurrentNonce::::try_mutate(index, |ni| { - *ni = ni.overflowing_add(1).0; - Ok(*ni) - }) - } - #[allow(non_snake_case)] pub(crate) fn vsAssets( index: ParaId, @@ -1227,30 +1082,6 @@ pub mod pallet { pub(crate) fn set_balance(who: &AccountIdOf, value: BalanceOf) -> DispatchResult { T::MultiCurrency::deposit(T::RelayChainToken::get(), who, value) } - - fn xcm_ump_contribute( - _origin: OriginFor, - index: ParaId, - value: BalanceOf, - nonce: Nonce, - ) -> Result { - use_relay!({ - let contribute_call = - RelaychainCall::Crowdloan::, AccountIdOf, BlockNumberFor>( - ContributeCall::Contribute(Contribution { index, value, signature: None }), - ) - .encode() - .into(); - - T::BifrostXcmExecutor::ump_transact( - MultiLocation::here(), - contribute_call, - T::ContributionWeight::get(), - false, - nonce, - ) - }) - } } } diff --git a/pallets/salp/src/mock.rs b/pallets/salp/src/mock.rs index 73b82e0caa..921ed429b2 100644 --- a/pallets/salp/src/mock.rs +++ b/pallets/salp/src/mock.rs @@ -17,21 +17,19 @@ // along with this program. If not, see . // Ensure we're `no_std` when compiling for Wasm. + +#![cfg(test)] + use frame_support::{ construct_runtime, - dispatch::DispatchResult, + dispatch::DispatchError, parameter_types, traits::{EnsureOrigin, GenesisBuild, Nothing}, - weights::{WeightToFeeCoefficient, WeightToFeeCoefficients, WeightToFeePolynomial}, + weights::Weight, PalletId, }; use frame_system::RawOrigin; -use node_primitives::{ - Amount, Balance, CurrencyId, MessageId, ParachainTransactProxyType, ParachainTransactType, - TokenSymbol, TransferOriginType, -}; -use orml_traits::XcmTransfer; -use smallvec::smallvec; +use node_primitives::{Amount, Balance, CurrencyId, MessageId, ParaId, TokenSymbol}; use sp_arithmetic::Percent; use sp_core::H256; pub use sp_runtime::Perbill; @@ -39,8 +37,7 @@ use sp_runtime::{ generic, traits::{BlakeTwo256, IdentityLookup}, }; -use xcm::{latest::prelude::*, DoubleEncoded}; -use xcm_support::{BifrostXcmExecutor, Weight}; +use xcm_interface::traits::XcmHelper; use crate as salp; use crate::WeightInfo; @@ -202,25 +199,11 @@ parameter_types! { pub const VSBondValidPeriod: BlockNumber = 30 * DAYS; pub const ReleaseCycle: BlockNumber = 1 * DAYS; pub const ReleaseRatio: Percent = Percent::from_percent(50); - pub const XcmTransferOrigin: TransferOriginType = TransferOriginType::FromRelayChain; - pub BaseXcmWeight:u64 = 1_000_000_000 as u64; - pub ContributionWeight:u64 = 1_000_000_000 as u64; - pub AddProxyWeight:u64 = 1_000_000_000 as u64; - pub const SelfParaId: u32 = 2001; - pub PrimaryAccount: AccountId = ALICE; pub ConfirmMuitiSigAccount: AccountId = Multisig::multi_account_id(&vec![ ALICE, BRUCE, CATHI ],2); - pub RelaychainSovereignSubAccount: MultiLocation = MultiLocation::parent(); - pub SalpTransactProxyType: ParachainTransactProxyType = ParachainTransactProxyType::Derived; - pub SalpTransactType: ParachainTransactType = ParachainTransactType::Xcm; - pub const RelayNetwork: NetworkId = NetworkId::Kusama; -} - -parameter_types! { - pub const AnyNetwork: NetworkId = NetworkId::Any; } pub struct EnsureConfirmAsGovernance; @@ -241,47 +224,25 @@ impl EnsureOrigin for EnsureConfirmAsGovernance { } } -pub struct WeightToFee; -impl WeightToFeePolynomial for WeightToFee { - type Balance = Balance; - fn polynomial() -> WeightToFeeCoefficients { - smallvec![WeightToFeeCoefficient { - degree: 1, - negative: false, - coeff_frac: Perbill::from_rational(90u32, 100u32), - coeff_integer: 1, - }] - } -} +// To control the result returned by `MockXcmExecutor` +pub(crate) static mut MOCK_XCM_RESULT: (bool, bool) = (true, true); -pub struct MockXTokens; - -impl XcmTransfer for MockXTokens { - fn transfer( - _who: AccountId, - _currency_id: CurrencyId, - _amount: Balance, - _dest: MultiLocation, - _dest_weight: Weight, - ) -> DispatchResult { - Ok(()) - } +// Mock XcmExecutor +pub struct MockXcmExecutor; + +impl XcmHelper, crate::BalanceOf> for MockXcmExecutor { + fn contribute(_index: ParaId, _value: Balance) -> Result { + let result = unsafe { MOCK_XCM_RESULT.0 }; - fn transfer_multi_asset( - _who: AccountId, - _asset: MultiAsset, - _dest: MultiLocation, - _dest_weight: Weight, - ) -> DispatchResult { - Ok(()) + match result { + true => Ok([0; 32]), + false => Err(DispatchError::BadOrigin), + } } } -use bifrost_runtime_common::r#impl::BifrostAccountIdToMultiLocation; - impl salp::Config for Test { type BancorPool = Bancor; - type BifrostXcmExecutor = MockXcmExecutor; type Event = Event; type LeasePeriod = LeasePeriod; type MinContribution = MinContribution; @@ -293,20 +254,9 @@ impl salp::Config for Test { type RemoveKeysLimit = RemoveKeysLimit; type SlotLength = SlotLength; type VSBondValidPeriod = VSBondValidPeriod; - type XcmTransferOrigin = XcmTransferOrigin; - type WeightInfo = SalpWeightInfo; - type SelfParaId = SelfParaId; - type BaseXcmWeight = BaseXcmWeight; - type ContributionWeight = ContributionWeight; type EnsureConfirmAsGovernance = EnsureConfirmAsGovernance; - type AddProxyWeight = AddProxyWeight; - type XcmTransfer = MockXTokens; - type SovereignSubAccountLocation = RelaychainSovereignSubAccount; - type TransactProxyType = SalpTransactProxyType; - type TransactType = SalpTransactType; - type RelayNetwork = RelayNetwork; - type XcmExecutor = (); - type AccountIdToMultiLocation = BifrostAccountIdToMultiLocation; + type WeightInfo = SalpWeightInfo; + type XcmInterface = MockXcmExecutor; } pub struct SalpWeightInfo; @@ -332,52 +282,6 @@ impl WeightInfo for SalpWeightInfo { } } -// To control the result returned by `MockXcmExecutor` -pub(crate) static mut MOCK_XCM_RESULT: (bool, bool) = (true, true); - -// Mock XcmExecutor -pub struct MockXcmExecutor; - -impl BifrostXcmExecutor for MockXcmExecutor { - fn transact_weight(_: u64, _: u32) -> u64 { - return 0; - } - - fn transact_id(_data: &[u8]) -> MessageId { - return [0; 32]; - } - - fn ump_transact( - _origin: MultiLocation, - _call: DoubleEncoded<()>, - _weight: u64, - _relayer: bool, - _nonce: u32, - ) -> Result<[u8; 32], XcmError> { - let result = unsafe { MOCK_XCM_RESULT.0 }; - - match result { - true => Ok([0; 32]), - false => Err(XcmError::Unimplemented), - } - } - - fn ump_transfer_asset( - _origin: MultiLocation, - _dest: MultiLocation, - _amount: u128, - _relay: bool, - _nonce: u32, - ) -> Result { - let result = unsafe { MOCK_XCM_RESULT.1 }; - - match result { - true => Ok([0; 32]), - false => Err(XcmError::Unimplemented), - } - } -} - pub(crate) fn new_test_ext() -> sp_io::TestExternalities { let mut t = frame_system::GenesisConfig::default().build_storage::().unwrap(); diff --git a/runtime/bifrost-kusama/Cargo.toml b/runtime/bifrost-kusama/Cargo.toml index 87e37b893a..f2d49a2342 100644 --- a/runtime/bifrost-kusama/Cargo.toml +++ b/runtime/bifrost-kusama/Cargo.toml @@ -95,7 +95,6 @@ bifrost-vsbond-auction = { path = "../../pallets/vsbond-auction", default-featur bifrost-token-issuer = { path = "../../pallets/token-issuer", default-features = false } bifrost-lightening-redeem= { path = "../../pallets/lightening-redeem", default-features = false } bifrost-call-switchgear= { path = "../../pallets/call-switchgear", default-features = false } -xcm-support = { path = "../../xcm-support", default-features = false } # orml @@ -110,6 +109,8 @@ orml-xcm-support = { version = "0.4.1-dev", default-features = false } merkle-distributor = {version = "*", default-features = false } zenlink-protocol = { version = "*", default-features = false } zenlink-protocol-runtime-api = { version = "*", default-features = false } +#parachain-staking = { version = "*", default-features = false } +xcm-interface = { version = "*", default-features = false } [build-dependencies] @@ -192,7 +193,8 @@ std = [ "zenlink-protocol/std", "zenlink-protocol-runtime-api/std", "merkle-distributor/std", - "xcm-support/std", + #"parachain-staking/std", + "xcm-interface/std", ] with-tracing = ["frame-executive/with-tracing"] diff --git a/runtime/bifrost-kusama/src/constants.rs b/runtime/bifrost-kusama/src/constants.rs index f6a6a1ae00..bbf082b95a 100644 --- a/runtime/bifrost-kusama/src/constants.rs +++ b/runtime/bifrost-kusama/src/constants.rs @@ -20,7 +20,7 @@ /// Money matters. pub mod currency { - use bifrost_runtime_common::{cent, dollar, milli}; + use bifrost_runtime_common::{cent, milli}; use frame_support::weights::{ constants::{ExtrinsicBaseWeight, WEIGHT_PER_SECOND}, WeightToFeeCoefficient, WeightToFeeCoefficients, WeightToFeePolynomial, @@ -34,21 +34,6 @@ pub mod currency { (bytes as Balance) * 6 * cent(CurrencyId::Native(TokenSymbol::BNC)) } - pub struct KsmWeightToFee; - impl WeightToFeePolynomial for KsmWeightToFee { - type Balance = Balance; - fn polynomial() -> WeightToFeeCoefficients { - let p = ksm_base_tx_fee(); - let q = 10 * Balance::from(ExtrinsicBaseWeight::get()); - smallvec![WeightToFeeCoefficient { - degree: 1, - negative: false, - coeff_frac: Perbill::from_rational(p % q, q), - coeff_integer: p / q, - }] - } - } - pub struct WeightToFee; impl WeightToFeePolynomial for WeightToFee { type Balance = Balance; @@ -65,10 +50,6 @@ pub mod currency { } } - fn ksm_base_tx_fee() -> Balance { - dollar(CurrencyId::Token(TokenSymbol::KSM)) / 10_000 - } - fn base_tx_fee() -> Balance { milli(CurrencyId::Native(TokenSymbol::BNC)) / 3 } diff --git a/runtime/bifrost-kusama/src/lib.rs b/runtime/bifrost-kusama/src/lib.rs index 01702904bc..27027a59c2 100644 --- a/runtime/bifrost-kusama/src/lib.rs +++ b/runtime/bifrost-kusama/src/lib.rs @@ -74,7 +74,7 @@ use bifrost_flexible_fee::{ }; use bifrost_runtime_common::{ cent, - constants::{parachains, time::*}, + constants::time::*, dollar, micro, milli, millicent, prod_or_test, r#impl::{ BifrostAccountIdToMultiLocation, BifrostAssetMatcher, BifrostCurrencyIdConvert, @@ -88,15 +88,13 @@ use constants::currency::*; use cumulus_primitives_core::ParaId as CumulusParaId; use frame_support::{ sp_runtime::traits::Convert, - traits::{EnsureOneOf, LockIdentifier}, + traits::{EnsureOneOf, Get, LockIdentifier}, }; use frame_system::EnsureRoot; use hex_literal::hex; pub use node_primitives::{ traits::CheckSubAccount, AccountId, Amount, Balance, BlockNumber, CurrencyId, ExtraFeeName, - Moment, Nonce, ParaId, ParachainDerivedProxyAccountType, ParachainTransactProxyType, - ParachainTransactType, PoolId, RpcContributionStatus, TokenSymbol, TransferOriginType, - XcmBaseWeight, + Moment, Nonce, ParaId, PoolId, RpcContributionStatus, TokenSymbol, }; // orml imports use orml_currencies::BasicCurrencyAdapter; @@ -117,7 +115,7 @@ use xcm_builder::{ TakeWeightCredit, }; use xcm_executor::{Config, XcmExecutor}; -use xcm_support::{BifrostXcmAdaptor, Get}; +pub use xcm_interface::traits::{parachains, XcmBaseWeight}; // zenlink imports use zenlink_protocol::{ make_x2_location, AssetBalance, AssetId as ZenlinkAssetId, LocalAssetHandler, @@ -138,7 +136,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion { spec_name: create_runtime_str!("bifrost"), impl_name: create_runtime_str!("bifrost"), authoring_version: 1, - spec_version: 926, + spec_version: 927, impl_version: 0, apis: RUNTIME_API_VERSIONS, transaction_version: 1, @@ -1348,7 +1346,7 @@ impl NameGetter for FeeNameGetter { fn get_name(c: &Call) -> ExtraFeeName { match *c { Call::Salp(bifrost_salp::Call::contribute { .. }) => ExtraFeeName::SalpContribute, - Call::Salp(bifrost_salp::Call::transfer_statemine_assets { .. }) => + Call::XcmInterface(xcm_interface::Call::transfer_statemine_assets { .. }) => ExtraFeeName::StatemineTransfer, _ => ExtraFeeName::NoExtraFee, } @@ -1362,7 +1360,7 @@ impl Contains for AggregateExtraFeeFilter { fn contains(c: &Call) -> bool { match *c { Call::Salp(bifrost_salp::Call::contribute { .. }) => true, - Call::Salp(bifrost_salp::Call::transfer_statemine_assets { .. }) => true, + Call::XcmInterface(xcm_interface::Call::transfer_statemine_assets { .. }) => true, _ => false, } } @@ -1382,7 +1380,7 @@ pub struct StatemineTransferFeeFilter; impl Contains for StatemineTransferFeeFilter { fn contains(c: &Call) -> bool { match *c { - Call::Salp(bifrost_salp::Call::transfer_statemine_assets { .. }) => true, + Call::XcmInterface(xcm_interface::Call::transfer_statemine_assets { .. }) => true, _ => false, } } @@ -1390,19 +1388,12 @@ impl Contains for StatemineTransferFeeFilter { parameter_types! { pub const AltFeeCurrencyExchangeRate: (u32, u32) = (1, 100); - pub SalpWeightHolder: XcmBaseWeight = XcmBaseWeight::from(6 * milli(RelayCurrencyId::get()) as u64) + ContributionWeight::get() + u64::pow(2, 24).into(); - pub StatemineTransferWeightHolder: XcmBaseWeight = XcmBaseWeight::from(6 * milli(RelayCurrencyId::get()) as u64); + pub UmpContributeFee: Balance = UmpTransactFee::get(); } pub type MiscFeeHandlers = ( - MiscFeeHandler, - MiscFeeHandler< - Runtime, - RelayCurrencyId, - KsmWeightToFee, - StatemineTransferWeightHolder, - StatemineTransferFeeFilter, - >, + MiscFeeHandler, + MiscFeeHandler, ); impl bifrost_flexible_fee::Config for Runtime { @@ -1440,21 +1431,11 @@ parameter_types! { pub const LeasePeriod: BlockNumber = KUSAMA_LEASE_PERIOD; pub const ReleaseRatio: Percent = Percent::from_percent(50); pub const SlotLength: BlockNumber = 8u32 as BlockNumber; - pub const XcmTransferOrigin: TransferOriginType = TransferOriginType::FromRelayChain; - pub XcmWeight: XcmBaseWeight = RelayXcmBaseWeight::get().into(); - pub ContributionWeight:XcmBaseWeight = RelayXcmBaseWeight::get().into(); - pub AddProxyWeight:XcmBaseWeight = RelayXcmBaseWeight::get().into(); pub ConfirmMuitiSigAccount: AccountId = hex!["e4da05f08e89bf6c43260d96f26fffcfc7deae5b465da08669a9d008e64c2c63"].into(); - pub RelaychainSovereignSubAccount: MultiLocation = create_x2_multilocation(ParachainDerivedProxyAccountType::Salp as u16); - pub SalpTransactType: ParachainTransactType = ParachainTransactType::Xcm; - pub SalpProxyType: ParachainTransactProxyType = ParachainTransactProxyType::Derived; - pub XcmTransactFee: Balance = dollar(RelayCurrencyId::get()) / 10; } impl bifrost_salp::Config for Runtime { type BancorPool = (); - type BifrostXcmExecutor = - BifrostXcmAdaptor; type Event = Event; type LeasePeriod = LeasePeriod; type MinContribution = MinContribution; @@ -1466,21 +1447,10 @@ impl bifrost_salp::Config for Runtime { type RemoveKeysLimit = RemoveKeysLimit; type SlotLength = SlotLength; type VSBondValidPeriod = VSBondValidPeriod; - type XcmTransferOrigin = XcmTransferOrigin; type WeightInfo = (); - type SelfParaId = SelfParaId; - type ContributionWeight = ContributionWeight; - type BaseXcmWeight = XcmWeight; type EnsureConfirmAsGovernance = EnsureOneOf; - type AddProxyWeight = AddProxyWeight; - type XcmTransfer = XTokens; - type SovereignSubAccountLocation = RelaychainSovereignSubAccount; - type TransactProxyType = SalpProxyType; - type TransactType = SalpTransactType; - type RelayNetwork = RelayNetwork; - type XcmExecutor = XcmExecutor; - type AccountIdToMultiLocation = BifrostAccountIdToMultiLocation; + type XcmInterface = XcmInterface; } parameter_types! { @@ -1585,6 +1555,29 @@ impl bifrost_call_switchgear::Config for Runtime { type WeightInfo = (); } +parameter_types! { + pub ParachainAccount: AccountId = ParachainInfo::get().into_account(); + pub ContributionWeight:XcmBaseWeight = RelayXcmBaseWeight::get().into(); + pub UmpTransactFee: Balance = prod_or_test!(milli(RelayCurrencyId::get()),milli(RelayCurrencyId::get()) * 100); + pub StatemineTransferFee: Balance = milli(RelayCurrencyId::get()) * 4; + pub StatemineTransferWeight:XcmBaseWeight = (RelayXcmBaseWeight::get() * 4).into(); +} + +impl xcm_interface::Config for Runtime { + type Event = Event; + type UpdateOrigin = EnsureOneOf; + type MultiCurrency = Currencies; + type RelayNetwork = RelayNetwork; + type RelaychainCurrencyId = RelayCurrencyId; + type ParachainSovereignAccount = ParachainAccount; + type XcmExecutor = XcmExecutor; + type AccountIdToMultiLocation = BifrostAccountIdToMultiLocation; + type StatemineTransferWeight = StatemineTransferWeight; + type StatemineTransferFee = StatemineTransferFee; + type ContributionWeight = ContributionWeight; + type ContributionFee = UmpTransactFee; +} + // Bifrost modules end // zenlink runtime start @@ -1781,6 +1774,7 @@ construct_runtime! { SalpLite: bifrost_salp_lite::{Pallet, Call, Storage, Event, Config} = 111, CallSwitchgear: bifrost_call_switchgear::{Pallet, Storage, Call, Event} = 112, VSBondAuction: bifrost_vsbond_auction::{Pallet, Call, Storage, Event} = 113, + XcmInterface: xcm_interface::{Pallet, Call, Storage, Event} = 117, } } @@ -1826,7 +1820,6 @@ pub type Executive = frame_executive::Executive< frame_system::ChainContext, Runtime, AllPalletsWithSystem, - SchedulerMigrationV3, >; // Migration for scheduler pallet to move from a plain Call to a CallOrHash. diff --git a/runtime/bifrost-polkadot/Cargo.toml b/runtime/bifrost-polkadot/Cargo.toml index 94c6b32dc0..d02e64198e 100644 --- a/runtime/bifrost-polkadot/Cargo.toml +++ b/runtime/bifrost-polkadot/Cargo.toml @@ -82,7 +82,6 @@ xcm-executor = { git = "https://github.com/paritytech/polkadot", branch = "relea # Bifrost pallet-vesting = { package = "bifrost-vesting", path = "../../pallets/vesting", default-features = false } bifrost-runtime-common = { package = "bifrost-runtime-common", path = "../common", default-features = false } -xcm-support = { path = "../../xcm-support", default-features = false } [build-dependencies] substrate-wasm-builder = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.16" } @@ -142,7 +141,6 @@ std = [ "pallet-collator-selection/std", "pallet-session/std", "pallet-vesting/std", - "xcm-support/std", "bifrost-runtime-common/std", "pallet-xcm/std", ] diff --git a/runtime/bifrost-polkadot/src/lib.rs b/runtime/bifrost-polkadot/src/lib.rs index 5fc4f933e0..ad5f6c88ac 100644 --- a/runtime/bifrost-polkadot/src/lib.rs +++ b/runtime/bifrost-polkadot/src/lib.rs @@ -70,9 +70,7 @@ use frame_support::traits::Currency; use frame_system::EnsureRoot; pub use node_primitives::{ traits::CheckSubAccount, AccountId, Amount, Balance, BlockNumber, CurrencyId, ExtraFeeName, - Moment, Nonce, ParaId, ParachainDerivedProxyAccountType, ParachainTransactProxyType, - ParachainTransactType, PoolId, RpcContributionStatus, TokenSymbol, TransferOriginType, - XcmBaseWeight, + Moment, Nonce, ParaId, PoolId, RpcContributionStatus, TokenSymbol, }; use pallet_xcm::XcmPassthrough; // XCM imports diff --git a/runtime/common/Cargo.toml b/runtime/common/Cargo.toml index 794a95ada5..c24cc0e157 100644 --- a/runtime/common/Cargo.toml +++ b/runtime/common/Cargo.toml @@ -64,11 +64,12 @@ pallet-xcm = { git = "https://github.com/paritytech/polkadot", branch = "release orml-currencies = { version = "0.4.1-dev", default-features = false } orml-tokens = { version = "0.4.1-dev", default-features = false } orml-traits = { version = "0.4.1-dev", default-features = false } -xcm-support = { path = "../../xcm-support", default-features = false } zenlink-protocol = { version = "*", default-features = false } zenlink-protocol-runtime-api = { version = "*", default-features = false } +xcm-interface = { version = "*", default-features = false } + [features] default = ["std"] std = [ @@ -112,7 +113,7 @@ std = [ "orml-currencies/std", "orml-traits/std", "orml-tokens/std", - "xcm-support/std", "zenlink-protocol/std", "zenlink-protocol-runtime-api/std", + "xcm-interface/std", ] diff --git a/runtime/common/src/constants.rs b/runtime/common/src/constants.rs index 4fa3339b1a..5b48a3b4db 100644 --- a/runtime/common/src/constants.rs +++ b/runtime/common/src/constants.rs @@ -18,23 +18,6 @@ //! A set of constant values used for all runtimes in common. -#[allow(non_snake_case)] -pub mod parachains { - pub mod karura { - pub const ID: u32 = 2000; - pub const KAR_KEY: &[u8] = &[0, 128]; - pub const KUSD_KEY: &[u8] = &[0, 129]; - } - pub mod Statemine { - pub const ID: u32 = 1000; - pub const PALLET_ID: u8 = 50; - pub const RMRK_ID: u32 = 8; - } - pub mod phala { - pub const ID: u32 = 2004; - } -} - /// Time. pub mod time { use node_primitives::{BlockNumber, Moment}; diff --git a/runtime/common/src/impl.rs b/runtime/common/src/impl.rs index 63494bac4e..200174d9c6 100644 --- a/runtime/common/src/impl.rs +++ b/runtime/common/src/impl.rs @@ -29,8 +29,7 @@ use sp_std::{convert::TryFrom, marker::PhantomData}; use xcm::latest::prelude::*; use xcm_builder::{AccountId32Aliases, NativeAsset, ParentIsDefault, SiblingParachainConvertsVia}; use xcm_executor::traits::{FilterAssetLocation, MatchesFungible}; - -use crate::constants::parachains; +use xcm_interface::traits::parachains; /// ******************************************************************** // Below are for the common utilities for both of Polkadot and Kusama. diff --git a/xcm-support/Cargo.toml b/xcm-support/Cargo.toml deleted file mode 100644 index f26f091143..0000000000 --- a/xcm-support/Cargo.toml +++ /dev/null @@ -1,33 +0,0 @@ -[package] -name = "xcm-support" -description = "Supporting module for XCM integration." -version = "0.8.0" -authors = ["Bifrost Developers"] -edition = "2021" - -[dependencies] -codec = { package = "parity-scale-codec", version = "2.3.0", default-features = false } -paste = "1.0.5" -smallvec = "1.6.1" -sp-std = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.16", default-features = false } -sp-io = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.16", default-features = false } -sp-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.16", default-features = false } -frame-system = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.16", default-features = false } -frame-support = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.16", default-features = false } -xcm = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.16", default-features = false } -cumulus-primitives-core = { git = "https://github.com/paritytech/cumulus", branch = "polkadot-v0.9.16", default-features = false } -node-primitives = { default-features = false, path = "../node/primitives" } - -[features] -default = ["std"] -std = [ - "codec/std", - "sp-std/std", - "sp-io/std", - "sp-runtime/std", - "frame-system/std", - "frame-support/std", - "xcm/std", - "cumulus-primitives-core/std", - "node-primitives/std", -] diff --git a/xcm-support/src/calls.rs b/xcm-support/src/calls.rs deleted file mode 100644 index b951a9da7d..0000000000 --- a/xcm-support/src/calls.rs +++ /dev/null @@ -1,139 +0,0 @@ -// This file is part of Bifrost. - -// Copyright (C) 2019-2022 Liebi Technologies (UK) Ltd. -// SPDX-License-Identifier: GPL-3.0-or-later WITH Classpath-exception-2.0 - -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -use codec::{Decode, Encode}; -use frame_support::{sp_runtime::MultiSignature, RuntimeDebug}; -use node_primitives::ParaId; -use sp_std::vec::Vec; - -#[derive(Encode, Decode, RuntimeDebug)] -pub enum UtilityCall { - #[codec(index = 1)] - AsDerivative(u16, RelayChainCall), - #[codec(index = 2)] - BatchAll(Vec), -} - -#[derive(Encode, Decode, RuntimeDebug)] -pub enum StakingCall { - #[codec(index = 3)] - WithdrawUnbonded(u32), -} - -pub mod rococo { - - pub use crate::calls::*; - - #[derive(Encode, Decode, RuntimeDebug)] - pub enum RelaychainCall { - #[codec(index = 28)] - Crowdloan(ContributeCall), - #[codec(index = 91)] - Proxy(ProxyCall), - } -} - -pub mod kusama { - - pub use crate::calls::*; - - #[derive(Encode, Decode, RuntimeDebug)] - pub enum RelaychainCall { - #[codec(index = 73)] - Crowdloan(ContributeCall), - #[codec(index = 30)] - Proxy(ProxyCall), - } -} - -pub mod polkadot { - - pub use crate::calls::*; - - #[derive(Encode, Decode, RuntimeDebug)] - pub enum RelaychainCall { - #[codec(index = 73)] - Crowdloan(ContributeCall), - #[codec(index = 29)] - Proxy(ProxyCall), - } -} - -#[derive(Encode, Decode, RuntimeDebug)] -pub enum ContributeCall { - #[codec(index = 1)] - Contribute(Contribution), - #[codec(index = 2)] - Withdraw(Withdraw), - #[codec(index = 6)] - AddMemo(AddMemo), -} - -#[derive(PartialEq, Encode, Decode, RuntimeDebug)] -pub struct Contribution { - #[codec(compact)] - pub index: ParaId, - #[codec(compact)] - pub value: BalanceOf, - pub signature: Option, -} - -#[derive(PartialEq, Encode, Decode, RuntimeDebug)] -pub struct Withdraw { - pub who: AccountIdOf, - #[codec(compact)] - pub index: ParaId, -} - -#[derive(PartialEq, Encode, Decode, RuntimeDebug)] -pub struct AddMemo { - pub index: ParaId, - pub memo: Vec, -} - -#[derive(Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Encode, Decode, RuntimeDebug)] -pub enum ProxyType { - Any, - NonTransfer, - Governance, - Staking, - IdentityJudgement, - CancelProxy, -} - -#[derive(Encode, Decode, RuntimeDebug)] -pub enum ProxyCall { - #[codec(index = 1)] - Add(AddProxy), - #[codec(index = 2)] - Remove(RemoveProxy), -} - -#[derive(PartialEq, Encode, Decode, RuntimeDebug)] -pub struct AddProxy { - pub delegate: AccountIdOf, - pub proxy_type: ProxyType, - pub delay: BlockNumberOf, -} - -#[derive(PartialEq, Encode, Decode, RuntimeDebug)] -pub struct RemoveProxy { - pub delegate: AccountIdOf, - pub proxy_type: ProxyType, - pub delay: BlockNumberOf, -} diff --git a/xcm-support/src/lib.rs b/xcm-support/src/lib.rs deleted file mode 100644 index 24964bae9d..0000000000 --- a/xcm-support/src/lib.rs +++ /dev/null @@ -1,156 +0,0 @@ -// This file is part of Bifrost. - -// Copyright (C) 2019-2022 Liebi Technologies (UK) Ltd. -// SPDX-License-Identifier: GPL-3.0-or-later WITH Classpath-exception-2.0 - -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -//! # XCM Support Module. -//! -//! ## Overview -//! -//! The XCM support module provides supporting traits, types and -//! implementations, to support cross-chain message(XCM) integration with ORML -//! modules. - -#![cfg_attr(not(feature = "std"), no_std)] - -use codec::Encode; -pub use frame_support::{traits::Get, weights::Weight}; -pub use paste; -pub use sp_std::{cell::RefCell, marker::PhantomData}; -use sp_std::{prelude::*, vec}; -pub use xcm::VersionedXcm; -use xcm::{latest::prelude::*, DoubleEncoded}; -mod calls; -mod traits; -pub use calls::*; -use cumulus_primitives_core::ParaId; -use frame_support::{sp_runtime::traits::AccountIdConversion, weights::WeightToFeePolynomial}; -pub use node_primitives::XcmBaseWeight; -use node_primitives::{AccountId, MessageId}; -pub use traits::BifrostXcmExecutor; - -/// Asset transaction errors. -#[allow(dead_code)] -enum Error { - /// Failed to match fungible. - FailedToMatchFungible, - /// `MultiLocation` to `AccountId` Conversion failed. - AccountIdConversionFailed, - /// `CurrencyId` conversion failed. - CurrencyIdConversionFailed, -} - -impl From for XcmError { - fn from(e: Error) -> Self { - match e { - Error::FailedToMatchFungible => - XcmError::FailedToTransactAsset("FailedToMatchFungible"), - Error::AccountIdConversionFailed => - XcmError::FailedToTransactAsset("AccountIdConversionFailed"), - Error::CurrencyIdConversionFailed => - XcmError::FailedToTransactAsset("CurrencyIdConversionFailed"), - } - } -} - -pub struct BifrostXcmAdaptor( - PhantomData<(XcmSender, BaseXcmWeight, WeightToFee, SelfParaId, XcmTransactFee)>, -); - -impl< - XcmSender: SendXcm, - BaseXcmWeight: Get, - WeightToFee: WeightToFeePolynomial, - SelfParaId: Get, - XcmTransactFee: Get, - > BifrostXcmExecutor - for BifrostXcmAdaptor -{ - fn transact_weight(weight: u64, nonce: u32) -> u64 { - return weight + 5 * BaseXcmWeight::get() + nonce as u64; - } - - fn transact_id(data: &[u8]) -> MessageId { - return sp_io::hashing::blake2_256(&data[..]); - } - - fn ump_transact( - _origin: MultiLocation, - call: DoubleEncoded<()>, - weight: u64, - _relay: bool, - nonce: u32, - ) -> Result { - let sovereign_account: AccountId = ParaId::from(SelfParaId::get()).into_account(); - - let asset: MultiAsset = MultiAsset { - id: Concrete(MultiLocation::here()), - fun: Fungibility::from(XcmTransactFee::get()), - }; - - let message = Xcm(vec![ - WithdrawAsset(asset.clone().into()), - BuyExecution { fees: asset, weight_limit: Unlimited }, - Transact { - origin_type: OriginKind::SovereignAccount, - require_weight_at_most: weight + nonce as u64, - call, - }, - RefundSurplus, - DepositAsset { - assets: All.into(), - max_assets: 1, - beneficiary: X1(Junction::AccountId32 { - network: NetworkId::Any, - id: sovereign_account.into(), - }) - .into(), - }, - ]); - - let data = VersionedXcm::<()>::from(message.clone()).encode(); - - let id = sp_io::hashing::blake2_256(&data[..]); - - XcmSender::send_xcm(MultiLocation::parent(), message) - .map_err(|_e| XcmError::Unimplemented)?; - - Ok(id) - } - - fn ump_transfer_asset( - _origin: MultiLocation, - dest: MultiLocation, - amount: u128, - _relay: bool, - nonce: u32, - ) -> Result { - let asset = MultiAsset { id: Concrete(MultiLocation::here()), fun: Fungible(amount) }; - let message = Xcm(vec![ - WithdrawAsset(asset.clone().into()), - BuyExecution { fees: asset, weight_limit: Some(nonce as u64).into() }, - DepositAsset { assets: Wild(WildMultiAsset::All), max_assets: 1, beneficiary: dest }, - ]); - - let data = VersionedXcm::<()>::from(message.clone()).encode(); - - let id = Self::transact_id(&data); - - XcmSender::send_xcm(MultiLocation::parent(), message)?; - - Ok(id) - } -} diff --git a/xcm-support/src/traits.rs b/xcm-support/src/traits.rs deleted file mode 100644 index 7512c9cc36..0000000000 --- a/xcm-support/src/traits.rs +++ /dev/null @@ -1,43 +0,0 @@ -// This file is part of Bifrost. - -// Copyright (C) 2019-2022 Liebi Technologies (UK) Ltd. -// SPDX-License-Identifier: GPL-3.0-or-later WITH Classpath-exception-2.0 - -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with this program. If not, see . - -use node_primitives::MessageId; -use xcm::{latest::prelude::*, DoubleEncoded}; - -/// Bifrost Xcm Executor -pub trait BifrostXcmExecutor { - fn transact_weight(weight: u64, nonce: u32) -> u64; - - fn transact_id(data: &[u8]) -> MessageId; - - fn ump_transact( - origin: MultiLocation, - call: DoubleEncoded<()>, - weight: u64, - relay: bool, - nonce: u32, - ) -> Result; - - fn ump_transfer_asset( - origin: MultiLocation, - dest: MultiLocation, - amount: u128, - relay: bool, - nonce: u32, - ) -> Result; -}