diff --git a/.config/lingua.dic b/.config/lingua.dic index ce9ab910aa1af..0ef7f9bef73e1 100644 --- a/.config/lingua.dic +++ b/.config/lingua.dic @@ -68,7 +68,6 @@ MessageNonce MessageNonces MessagePayload MetricsParams -Millau/MS OldHeader OutboundMessages PoA @@ -76,8 +75,6 @@ PoV/MS Pre RLP RPC/MS -Rialto/MS -RialtoParachain/MS Relayer/MS Runtime1 Runtime2 @@ -165,7 +162,6 @@ malus max_value merkle/MS metadata -millau misbehavior/SM misbehaviors multivalidator/SM diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 4b212dba426f3..6c3cf7e16cb88 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -115,18 +115,14 @@ spellcheck: <<: *docker-env <<: *test-refs script: - - cargo spellcheck check --cfg=.config/spellcheck.toml --checkers hunspell -m 1 $(find . -type f -name '*.rs' ! -path "./target/*" ! -path "./bin/millau/runtime/src/weights/*" ! -name 'codegen_runtime.rs' ! -name 'weights.rs') + - cargo spellcheck check --cfg=.config/spellcheck.toml --checkers hunspell -m 1 $(find . -type f -name '*.rs' ! -path "./target/*" ! -name 'codegen_runtime.rs' ! -name 'weights.rs') check: stage: test <<: *docker-env <<: *test-refs script: &check-script - - SKIP_WASM_BUILD=1 time cargo check --locked --verbose --workspace - # Check Rialto benchmarks runtime - - SKIP_WASM_BUILD=1 time cargo check -p rialto-runtime --locked --features runtime-benchmarks --verbose - # Check Millau benchmarks runtime - - SKIP_WASM_BUILD=1 time cargo check -p millau-runtime --locked --features runtime-benchmarks --verbose + - SKIP_WASM_BUILD=1 time cargo check --locked --verbose --workspace --features runtime-benchmarks check-nightly: stage: test @@ -185,19 +181,6 @@ deny-licenses: - echo "___Complete logs can be found in the artifacts___" - cargo deny check licenses 2> licenses.log -benchmarks-test: - stage: test - <<: *docker-env - <<: *nightly-test - script: - - time cargo run --release -p millau-bridge-node --features=runtime-benchmarks -- benchmark pallet --chain=dev --steps=2 --repeat=1 --pallet=pallet_bridge_messages --extrinsic=* --execution=wasm --wasm-execution=Compiled --heap-pages=4096 - - time cargo run --release -p millau-bridge-node --features=runtime-benchmarks -- benchmark pallet --chain=dev --steps=2 --repeat=1 --pallet=pallet_bridge_grandpa --extrinsic=* --execution=wasm --wasm-execution=Compiled --heap-pages=4096 - - time cargo run --release -p millau-bridge-node --features=runtime-benchmarks -- benchmark pallet --chain=dev --steps=2 --repeat=1 --pallet=pallet_bridge_parachains --extrinsic=* --execution=wasm --wasm-execution=Compiled --heap-pages=4096 - - time cargo run --release -p millau-bridge-node --features=runtime-benchmarks -- benchmark pallet --chain=dev --steps=2 --repeat=1 --pallet=pallet_bridge_relayers --extrinsic=* --execution=wasm --wasm-execution=Compiled --heap-pages=4096 - - time cargo run --release -p millau-bridge-node --features=runtime-benchmarks -- benchmark pallet --chain=dev --steps=2 --repeat=1 --pallet=pallet_xcm_bridge_hub_router --extrinsic=* --execution=wasm --wasm-execution=Compiled --heap-pages=4096 - # we may live with failing benchmarks, it is just a signal for us - allow_failure: true - check-rustdoc: stage: test <<: *docker-env @@ -206,7 +189,7 @@ check-rustdoc: SKIP_WASM_BUILD: 1 RUSTDOCFLAGS: "-Dwarnings" script: - - time cargo +nightly doc --workspace --verbose --no-deps --all-features --exclude relay-rialto-parachain-client + - time cargo +nightly doc --workspace --verbose --no-deps --all-features partial-repo-pallets-build-test: stage: test @@ -239,12 +222,6 @@ build: after_script: # Prepare artifacts - mkdir -p ./artifacts - - strip ./target/release/rialto-bridge-node - - mv -v ./target/release/rialto-bridge-node ./artifacts/ - - strip ./target/release/rialto-parachain-collator - - mv -v ./target/release/rialto-parachain-collator ./artifacts/ - - strip ./target/release/millau-bridge-node - - mv -v ./target/release/millau-bridge-node ./artifacts/ - strip ./target/release/substrate-relay - mv -v ./target/release/substrate-relay ./artifacts/ - mv -v ./deployments/local-scripts/bridge-entrypoint.sh ./artifacts/ @@ -292,18 +269,6 @@ build-nightly: --tag "${IMAGE_NAME}:latest" --file "${DOCKERFILE}" . -rialto-bridge-node-build-docker: - stage: publish - <<: *build-image - -rialto-parachain-collator-build-docker: - stage: publish - <<: *build-image - -millau-bridge-node-build-docker: - stage: publish - <<: *build-image - substrate-relay-build-docker: stage: publish <<: *build-image @@ -370,18 +335,6 @@ bridges-common-relay-build-docker: after_script: - env REGISTRY_AUTH_FILE= buildah logout --all -rialto-bridge-node: - stage: publish - <<: *build-push-image - -rialto-parachain-collator: - stage: publish - <<: *build-push-image - -millau-bridge-node: - stage: publish - <<: *build-push-image - substrate-relay: stage: publish <<: *build-push-image @@ -413,21 +366,6 @@ bridges-common-relay: tags: - kubernetes-parity-build -dockerhub-rialto-bridge-node: - extends: .publish-docker-image-description - variables: - SHORT_DESCRIPTION: "rialto-bridge-node" - -dockerhub-rialto-parachain-collator: - extends: .publish-docker-image-description - variables: - SHORT_DESCRIPTION: "rialto-parachain-collator" - -dockerhub-millau-bridge-node: - extends: .publish-docker-image-description - variables: - SHORT_DESCRIPTION: "millau-bridge-node" - dockerhub-substrate-relay: extends: .publish-docker-image-description variables: diff --git a/Cargo.lock b/Cargo.lock index 28afd4b40ed6d..7be87501838df 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -185,12 +185,6 @@ version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" -[[package]] -name = "always-assert" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4436e0292ab1bb631b42973c61205e704475fe8126af845c8d923c0996328127" - [[package]] name = "android-tzdata" version = "0.1.1" @@ -215,54 +209,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "anstream" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ab91ebe16eb252986481c5b62f6098f3b698a45e34b5b98200cf20dd2484a44" -dependencies = [ - "anstyle", - "anstyle-parse", - "anstyle-query", - "anstyle-wincon", - "colorchoice", - "utf8parse", -] - -[[package]] -name = "anstyle" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a30da5c5f2d5e72842e00bcb57657162cdabef0931f40e2deb9b4140440cecd" - -[[package]] -name = "anstyle-parse" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "938874ff5980b03a87c5524b3ae5b59cf99b1d6bc836848df7bc5ada9643c333" -dependencies = [ - "utf8parse", -] - -[[package]] -name = "anstyle-query" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ca11d4be1bab0c8bc8734a9aa7bf4ee8316d462a08c6ac5052f888fef5b494b" -dependencies = [ - "windows-sys 0.48.0", -] - -[[package]] -name = "anstyle-wincon" -version = "3.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0699d10d2f4d628a98ee7b57b289abbc98ff3bad977cb3152709d4bf2330628" -dependencies = [ - "anstyle", - "windows-sys 0.48.0", -] - [[package]] name = "anyhow" version = "1.0.75" @@ -285,19 +231,13 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "df752953c49ce90719c7bf1fc587bc8227aed04732ea0c0f85e5397d7fdbd1a1" dependencies = [ "include_dir", - "itertools 0.10.5", + "itertools", "proc-macro-error", "proc-macro2 1.0.69", "quote 1.0.33", "syn 1.0.109", ] -[[package]] -name = "arbitrary" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2d098ff73c1ca148721f37baad5ea6a465a13f9573aba8641fbbbae8164a54e" - [[package]] name = "arc-swap" version = "1.6.0" @@ -328,7 +268,7 @@ dependencies = [ "ark-std", "derivative", "hashbrown 0.13.2", - "itertools 0.10.5", + "itertools", "num-traits", "zeroize", ] @@ -357,7 +297,7 @@ dependencies = [ "ark-std", "derivative", "digest 0.10.7", - "itertools 0.10.5", + "itertools", "num-bigint", "num-traits", "paste", @@ -582,12 +522,6 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "assert_matches" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b34d609dfbaf33d6889b2b7106d3ca345eacad44200913df5ba02bfd31d2ba9" - [[package]] name = "async-attributes" version = "1.1.2" @@ -772,12 +706,6 @@ version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c59bdb34bc650a32731b31bd8f0829cc15d24a708ee31559e0bb34f2bc320cba" -[[package]] -name = "atomic-take" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8ab6b55fe97976e46f91ddbed8d147d966475dc29b2032757ba47e02376fbc3" - [[package]] name = "atomic-waker" version = "1.1.1" @@ -917,27 +845,6 @@ dependencies = [ "serde", ] -[[package]] -name = "bindgen" -version = "0.65.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cfdf7b466f9a4903edc73f95d6d2bcd5baf8ae620638762244d3f60143643cc5" -dependencies = [ - "bitflags 1.3.2", - "cexpr", - "clang-sys", - "lazy_static", - "lazycell", - "peeking_take_while", - "prettyplease 0.2.10", - "proc-macro2 1.0.69", - "quote 1.0.33", - "regex", - "rustc-hash", - "shlex", - "syn 2.0.38", -] - [[package]] name = "bip39" version = "2.0.0" @@ -1019,31 +926,6 @@ dependencies = [ "constant_time_eq 0.2.6", ] -[[package]] -name = "blake2s_simd" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6637f448b9e61dfadbdcbae9a885fadee1f3eaffb1f8d3c1965d3ade8bdfd44f" -dependencies = [ - "arrayref", - "arrayvec 0.7.4", - "constant_time_eq 0.2.6", -] - -[[package]] -name = "blake3" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "199c42ab6972d92c9f8995f086273d25c42fc0f7b2a1fcefba465c1352d25ba5" -dependencies = [ - "arrayref", - "arrayvec 0.7.4", - "cc", - "cfg-if 1.0.0", - "constant_time_eq 0.3.0", - "digest 0.10.7", -] - [[package]] name = "block-buffer" version = "0.7.3" @@ -1126,20 +1008,11 @@ dependencies = [ "serde", ] -[[package]] -name = "bounded-vec" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68534a48cbf63a4b1323c433cf21238c9ec23711e0df13b08c33e5c2082663ce" -dependencies = [ - "thiserror", -] - [[package]] name = "bp-asset-hub-kusama" version = "0.1.0" dependencies = [ - "bp-xcm-bridge-hub-router 0.1.0", + "bp-xcm-bridge-hub-router", "frame-support", "parity-scale-codec", "scale-info", @@ -1149,7 +1022,7 @@ dependencies = [ name = "bp-asset-hub-polkadot" version = "0.1.0" dependencies = [ - "bp-xcm-bridge-hub-router 0.1.0", + "bp-xcm-bridge-hub-router", "frame-support", "parity-scale-codec", "scale-info", @@ -1160,7 +1033,7 @@ dependencies = [ name = "bp-asset-hub-rococo" version = "0.1.0" dependencies = [ - "bp-xcm-bridge-hub-router 0.1.0", + "bp-xcm-bridge-hub-router", "frame-support", "parity-scale-codec", "scale-info", @@ -1170,7 +1043,7 @@ dependencies = [ name = "bp-asset-hub-westend" version = "0.1.0" dependencies = [ - "bp-xcm-bridge-hub-router 0.1.0", + "bp-xcm-bridge-hub-router", "frame-support", "parity-scale-codec", "scale-info", @@ -1180,7 +1053,7 @@ dependencies = [ name = "bp-asset-hub-wococo" version = "0.1.0" dependencies = [ - "bp-xcm-bridge-hub-router 0.1.0", + "bp-xcm-bridge-hub-router", "frame-support", "parity-scale-codec", "scale-info", @@ -1329,31 +1202,6 @@ dependencies = [ "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] -[[package]] -name = "bp-millau" -version = "0.1.0" -dependencies = [ - "bp-beefy", - "bp-header-chain", - "bp-messages", - "bp-runtime", - "fixed-hash 0.8.0 (git+https://github.com/paritytech/parity-common?branch=master)", - "frame-support", - "frame-system", - "hash256-std-hasher", - "impl-codec", - "impl-serde", - "parity-util-mem", - "scale-info", - "serde", - "sp-api", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-trie", -] - [[package]] name = "bp-parachains" version = "0.1.0" @@ -1432,37 +1280,6 @@ dependencies = [ "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] -[[package]] -name = "bp-rialto" -version = "0.1.0" -dependencies = [ - "bp-header-chain", - "bp-messages", - "bp-runtime", - "frame-support", - "frame-system", - "sp-api", - "sp-core", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "bp-rialto-parachain" -version = "0.1.0" -dependencies = [ - "bp-bridge-hub-cumulus", - "bp-messages", - "bp-polkadot-core", - "bp-runtime", - "frame-support", - "frame-system", - "sp-api", - "sp-core", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - [[package]] name = "bp-rococo" version = "0.1.0" @@ -1552,17 +1369,6 @@ dependencies = [ "sp-runtime", ] -[[package]] -name = "bp-xcm-bridge-hub-router" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-runtime", -] - [[package]] name = "bridge-runtime-common" version = "0.1.0" @@ -1574,7 +1380,7 @@ dependencies = [ "bp-relayers", "bp-runtime", "bp-test-utils", - "bp-xcm-bridge-hub-router 0.1.0", + "bp-xcm-bridge-hub-router", "frame-support", "frame-system", "hash-db", @@ -1624,15 +1430,6 @@ dependencies = [ "serde", ] -[[package]] -name = "build-helper" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bdce191bf3fa4995ce948c8c83b4640a1745457a149e73c6db75b4ffe36aad5f" -dependencies = [ - "semver 0.6.0", -] - [[package]] name = "bumpalo" version = "3.13.0" @@ -1669,17 +1466,6 @@ version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "89b2fd2a0dcf38d7971e2194b6b6eebab45ae01067456a7fd93d5547a61b70be" -[[package]] -name = "bzip2-sys" -version = "0.1.11+1.0.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "736a955f3fa7875102d57c82b8cac37ec45224a07fd32d58f9f7a186b6cd4cdc" -dependencies = [ - "cc", - "libc", - "pkg-config", -] - [[package]] name = "c2-chacha" version = "0.3.3" @@ -1690,38 +1476,6 @@ dependencies = [ "ppv-lite86", ] -[[package]] -name = "camino" -version = "1.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c59e92b5a388f549b863a7bea62612c09f24c8393560709a54558a9abdfb3b9c" -dependencies = [ - "serde", -] - -[[package]] -name = "cargo-platform" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2cfa25e60aea747ec7e1124f238816749faa93759c6ff5b31f1ccdda137f4479" -dependencies = [ - "serde", -] - -[[package]] -name = "cargo_metadata" -version = "0.15.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eee4243f1f26fc7a42710e7439c149e2b10b05472f88090acce52632f231a73a" -dependencies = [ - "camino", - "cargo-platform", - "semver 1.0.18", - "serde", - "serde_json", - "thiserror", -] - [[package]] name = "castaway" version = "0.1.2" @@ -1748,15 +1502,6 @@ dependencies = [ "subtle 2.4.1", ] -[[package]] -name = "cexpr" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fac387a98bb7c37292057cffc56d62ecb629900026402633ae9160df93a8766" -dependencies = [ - "nom", -] - [[package]] name = "cfg-expr" version = "0.15.5" @@ -1778,12 +1523,6 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" -[[package]] -name = "cfg_aliases" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd16c4719339c4530435d38e511904438d07cce7950afa3718a84ac36c10e89e" - [[package]] name = "chacha" version = "0.3.0" @@ -1806,17 +1545,6 @@ dependencies = [ "zeroize", ] -[[package]] -name = "chacha20" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3613f74bd2eac03dad61bd53dbe620703d4371614fe0bc3b9f04dd36fe4e818" -dependencies = [ - "cfg-if 1.0.0", - "cipher 0.4.4", - "cpufeatures", -] - [[package]] name = "chacha20poly1305" version = "0.9.1" @@ -1824,9 +1552,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a18446b09be63d457bbec447509e85f662f32952b035ce892290396bc0b0cff5" dependencies = [ "aead 0.4.3", - "chacha20 0.8.2", + "chacha20", "cipher 0.3.0", - "poly1305 0.7.2", + "poly1305", "zeroize", ] @@ -1845,19 +1573,6 @@ dependencies = [ "windows-targets 0.48.1", ] -[[package]] -name = "cid" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9b68e3193982cd54187d71afdb2a271ad4cf8af157858e9cb911b91321de143" -dependencies = [ - "core2", - "multibase", - "multihash", - "serde", - "unsigned-varint", -] - [[package]] name = "cipher" version = "0.2.5" @@ -1904,17 +1619,6 @@ dependencies = [ "cfg-if 1.0.0", ] -[[package]] -name = "clang-sys" -version = "1.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c688fc74432808e3eb684cae8830a86be1d66a2bd58e1f248ed0960a590baf6f" -dependencies = [ - "glob", - "libc", - "libloading", -] - [[package]] name = "clap" version = "2.34.0" @@ -1931,138 +1635,46 @@ dependencies = [ ] [[package]] -name = "clap" -version = "4.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2275f18819641850fa26c89acc84d465c1bf91ce57bc2748b28c420473352f64" +name = "common" +version = "0.1.0" +source = "git+https://github.com/w3f/ring-proof#edd1e90b847e560bf60fc2e8712235ccfa11a9a9" dependencies = [ - "clap_builder", - "clap_derive", + "ark-ec", + "ark-ff", + "ark-poly", + "ark-serialize", + "ark-std", + "fflonk", + "merlin 3.0.0", + "rand_chacha 0.3.1", ] [[package]] -name = "clap_builder" -version = "4.4.8" +name = "common-path" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07cdf1b148b25c1e1f7a42225e30a0d99a615cd4637eae7365548dd4529b95bc" -dependencies = [ - "anstream", - "anstyle", - "clap_lex", - "strsim 0.10.0", -] +checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" [[package]] -name = "clap_derive" -version = "4.4.7" +name = "concurrent-queue" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf9804afaaf59a91e75b022a30fb7229a7901f60c755489cc61c9b423b836442" +checksum = "62ec6771ecfa0762d24683ee5a32ad78487a3d3afdc0fb8cae19d2c5deb50b7c" dependencies = [ - "heck 0.4.1", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", + "crossbeam-utils", ] [[package]] -name = "clap_lex" -version = "0.6.0" +name = "const-oid" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "702fc72eb24e5a1e48ce58027a675bc24edd52096d5397d4aea7c6dd9eca0bd1" +checksum = "795bc6e66a8e340f075fcf6227e417a2dc976b92b91f3cdc778bb858778b6747" [[package]] -name = "coarsetime" -version = "0.1.23" +name = "const-random" +version = "0.1.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a90d114103adbc625300f346d4d09dfb4ab1c4a8df6868435dd903392ecf4354" -dependencies = [ - "libc", - "once_cell", - "wasi 0.11.0+wasi-snapshot-preview1", - "wasm-bindgen", -] - -[[package]] -name = "codespan-reporting" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3538270d33cc669650c4b093848450d380def10c331d38c768e34cac80576e6e" -dependencies = [ - "termcolor", - "unicode-width", -] - -[[package]] -name = "colorchoice" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acbf1af155f9b9ef647e42cdc158db4b64a1b61f743629225fde6f3e0be2a7c7" - -[[package]] -name = "comfy-table" -version = "7.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ab77dbd8adecaf3f0db40581631b995f312a8a5ae3aa9993188bb8f23d83a5b" -dependencies = [ - "strum 0.24.1", - "strum_macros 0.24.3", - "unicode-width", -] - -[[package]] -name = "common" -version = "0.1.0" -source = "git+https://github.com/w3f/ring-proof#edd1e90b847e560bf60fc2e8712235ccfa11a9a9" -dependencies = [ - "ark-ec", - "ark-ff", - "ark-poly", - "ark-serialize", - "ark-std", - "fflonk", - "merlin 3.0.0", - "rand_chacha 0.3.1", -] - -[[package]] -name = "common-path" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" - -[[package]] -name = "concurrent-queue" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62ec6771ecfa0762d24683ee5a32ad78487a3d3afdc0fb8cae19d2c5deb50b7c" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "console" -version = "0.15.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c926e00cc70edefdc64d3a5ff31cc65bb97a3460097762bd23afb4d8145fccf8" -dependencies = [ - "encode_unicode", - "lazy_static", - "libc", - "unicode-width", - "windows-sys 0.45.0", -] - -[[package]] -name = "const-oid" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "795bc6e66a8e340f075fcf6227e417a2dc976b92b91f3cdc778bb858778b6747" - -[[package]] -name = "const-random" -version = "0.1.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "368a7a772ead6ce7e1de82bfb04c485f3db8ec744f72925af5735e29a22cc18e" +checksum = "368a7a772ead6ce7e1de82bfb04c485f3db8ec744f72925af5735e29a22cc18e" dependencies = [ "const-random-macro", "proc-macro-hack", @@ -2092,12 +1704,6 @@ version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "21a53c0a4d288377e7415b53dcfc3c04da5cdc2cc95c8d5ac178b58f0b861ad6" -[[package]] -name = "constant_time_eq" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7144d30dcf0fafbce74250a3963025d8d52177934239851c917d29f1df280c2" - [[package]] name = "convert_case" version = "0.4.0" @@ -2138,16 +1744,6 @@ dependencies = [ "cfg-if 1.0.0", ] -[[package]] -name = "cpu-time" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9e393a7668fe1fad3075085b86c781883000b4ede868f43627b34a87c8b7ded" -dependencies = [ - "libc", - "winapi", -] - [[package]] name = "cpufeatures" version = "0.2.9" @@ -2248,7 +1844,7 @@ dependencies = [ "cranelift-codegen", "cranelift-entity", "cranelift-frontend", - "itertools 0.10.5", + "itertools", "log", "smallvec", "wasmparser", @@ -2422,658 +2018,385 @@ dependencies = [ ] [[package]] -name = "cumulus-client-cli" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "curl" +version = "0.4.44" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "509bd11746c7ac09ebd19f0b17782eae80aadee26237658a6b4808afb5c11a22" dependencies = [ - "clap 4.4.8", - "parity-scale-codec", - "sc-chain-spec", - "sc-cli", - "sc-client-api", - "sc-service", - "sp-core", - "sp-runtime", - "url", + "curl-sys", + "libc", + "openssl-probe", + "openssl-sys", + "schannel", + "socket2 0.4.9", + "winapi", ] [[package]] -name = "cumulus-client-collator" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "curl-sys" +version = "0.4.63+curl-8.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aeb0fef7046022a1e2ad67a004978f0e3cacb9e3123dc62ce768f92197b771dc" dependencies = [ - "cumulus-client-consensus-common", - "cumulus-client-network", - "cumulus-primitives-core", - "futures", - "parity-scale-codec", - "parking_lot 0.12.1", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-overseer", - "polkadot-primitives", - "sc-client-api", - "sp-api", - "sp-consensus", - "sp-core", - "sp-runtime", - "tracing", + "cc", + "libc", + "libnghttp2-sys", + "libz-sys", + "openssl-sys", + "pkg-config", + "vcpkg", + "winapi", ] [[package]] -name = "cumulus-client-consensus-aura" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "curve25519-dalek" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4a9b85542f99a2dfa2a1b8e192662741c9859a846b296bef1c92ef9b58b5a216" dependencies = [ - "async-trait", - "cumulus-client-collator", - "cumulus-client-consensus-common", - "cumulus-client-consensus-proposer", - "cumulus-primitives-aura", - "cumulus-primitives-core", - "cumulus-primitives-parachain-inherent", - "cumulus-relay-chain-interface", - "futures", - "parity-scale-codec", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-overseer", - "polkadot-primitives", - "sc-client-api", - "sc-consensus", - "sc-consensus-aura", - "sc-consensus-babe", - "sc-consensus-slots", - "sc-telemetry", - "schnellru", - "sp-api", - "sp-application-crypto", - "sp-block-builder", - "sp-blockchain", - "sp-consensus", - "sp-consensus-aura", - "sp-core", - "sp-inherents", - "sp-keystore", - "sp-runtime", - "sp-state-machine", - "sp-timestamp", - "substrate-prometheus-endpoint", - "tracing", + "byteorder", + "digest 0.8.1", + "rand_core 0.5.1", + "subtle 2.4.1", + "zeroize", ] [[package]] -name = "cumulus-client-consensus-common" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "curve25519-dalek" +version = "3.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" dependencies = [ - "async-trait", - "cumulus-client-pov-recovery", - "cumulus-primitives-core", - "cumulus-relay-chain-interface", - "dyn-clone", - "futures", - "log", - "parity-scale-codec", - "polkadot-primitives", - "sc-client-api", - "sc-consensus", - "sc-consensus-babe", - "schnellru", - "sp-blockchain", - "sp-consensus", - "sp-consensus-slots", - "sp-core", - "sp-runtime", - "sp-timestamp", - "sp-trie", - "substrate-prometheus-endpoint", - "tracing", + "byteorder", + "digest 0.9.0", + "rand_core 0.5.1", + "subtle 2.4.1", + "zeroize", ] [[package]] -name = "cumulus-client-consensus-proposer" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "curve25519-dalek" +version = "4.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f711ade317dd348950a9910f81c5947e3d8907ebd2b83f76203ff1807e6a2bc2" dependencies = [ - "anyhow", - "async-trait", - "cumulus-primitives-parachain-inherent", - "sp-consensus", - "sp-inherents", - "sp-runtime", - "sp-state-machine", - "thiserror", + "cfg-if 1.0.0", + "cpufeatures", + "curve25519-dalek-derive", + "digest 0.10.7", + "fiat-crypto", + "platforms", + "rustc_version", + "subtle 2.4.1", + "zeroize", ] [[package]] -name = "cumulus-client-network" +name = "curve25519-dalek-derive" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "83fdaf97f4804dcebfa5862639bc9ce4121e82140bec2a987ac5140294865b5b" dependencies = [ - "async-trait", - "cumulus-relay-chain-interface", - "futures", - "futures-timer", - "parity-scale-codec", - "parking_lot 0.12.1", - "polkadot-node-primitives", - "polkadot-parachain-primitives", - "polkadot-primitives", - "sc-client-api", - "sp-blockchain", - "sp-consensus", - "sp-core", - "sp-runtime", - "sp-state-machine", - "tracing", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 2.0.38", ] [[package]] -name = "cumulus-client-pov-recovery" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "curve25519-dalek-ng" +version = "4.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1c359b7249347e46fb28804470d071c921156ad62b3eef5d34e2ba867533dec8" dependencies = [ - "async-trait", - "cumulus-primitives-core", - "cumulus-relay-chain-interface", - "futures", - "futures-timer", - "parity-scale-codec", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-overseer", - "polkadot-primitives", - "rand 0.8.5", - "sc-client-api", - "sc-consensus", - "sp-consensus", - "sp-maybe-compressed-blob", - "sp-runtime", - "tracing", -] - -[[package]] -name = "cumulus-client-service" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "cumulus-client-cli", - "cumulus-client-collator", - "cumulus-client-consensus-common", - "cumulus-client-network", - "cumulus-client-pov-recovery", - "cumulus-primitives-core", - "cumulus-relay-chain-inprocess-interface", - "cumulus-relay-chain-interface", - "cumulus-relay-chain-minimal-node", - "futures", - "polkadot-primitives", - "sc-client-api", - "sc-consensus", - "sc-network", - "sc-network-sync", - "sc-network-transactions", - "sc-rpc", - "sc-service", - "sc-sysinfo", - "sc-telemetry", - "sc-transaction-pool", - "sc-utils", - "sp-api", - "sp-blockchain", - "sp-consensus", - "sp-core", - "sp-runtime", - "sp-transaction-pool", + "byteorder", + "digest 0.9.0", + "rand_core 0.6.4", + "subtle-ng", + "zeroize", ] [[package]] -name = "cumulus-pallet-aura-ext" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "darling" +version = "0.14.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b750cb3417fd1b327431a470f388520309479ab0bf5e323505daf0290cd3850" dependencies = [ - "cumulus-pallet-parachain-system", - "frame-support", - "frame-system", - "pallet-aura", - "pallet-timestamp", - "parity-scale-codec", - "scale-info", - "sp-application-crypto", - "sp-consensus-aura", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "darling_core 0.14.4", + "darling_macro 0.14.4", ] [[package]] -name = "cumulus-pallet-dmp-queue" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "darling" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0209d94da627ab5605dcccf08bb18afa5009cfbef48d8a8b7d7bdbc79be25c5e" dependencies = [ - "cumulus-primitives-core", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "staging-xcm", + "darling_core 0.20.3", + "darling_macro 0.20.3", ] [[package]] -name = "cumulus-pallet-parachain-system" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "darling_core" +version = "0.14.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "109c1ca6e6b7f82cc233a97004ea8ed7ca123a9af07a8230878fcfda9b158bf0" dependencies = [ - "bytes", - "cumulus-pallet-parachain-system-proc-macro", - "cumulus-primitives-core", - "cumulus-primitives-parachain-inherent", - "environmental", - "frame-support", - "frame-system", - "impl-trait-for-tuples", - "log", - "parity-scale-codec", - "polkadot-parachain-primitives", - "scale-info", - "sp-core", - "sp-externalities", - "sp-inherents", - "sp-io", - "sp-runtime", - "sp-state-machine", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-trie", - "sp-version", - "staging-xcm", - "trie-db", + "fnv", + "ident_case", + "proc-macro2 1.0.69", + "quote 1.0.33", + "strsim 0.10.0", + "syn 1.0.109", ] [[package]] -name = "cumulus-pallet-parachain-system-proc-macro" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "darling_core" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "177e3443818124b357d8e76f53be906d60937f0d3a90773a664fa63fa253e621" dependencies = [ - "proc-macro-crate", + "fnv", + "ident_case", "proc-macro2 1.0.69", "quote 1.0.33", + "strsim 0.10.0", "syn 2.0.38", ] [[package]] -name = "cumulus-pallet-xcm" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "darling_macro" +version = "0.14.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4aab4dbc9f7611d8b55048a3a16d2d010c2c8334e46304b40ac1cc14bf3b48e" dependencies = [ - "cumulus-primitives-core", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "staging-xcm", + "darling_core 0.14.4", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "cumulus-pallet-xcmp-queue" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "darling_macro" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5" dependencies = [ - "bp-xcm-bridge-hub-router 0.1.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "cumulus-primitives-core", - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "polkadot-runtime-common", - "rand_chacha 0.3.1", - "scale-info", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "staging-xcm", - "staging-xcm-executor", + "darling_core 0.20.3", + "quote 1.0.33", + "syn 2.0.38", ] [[package]] -name = "cumulus-primitives-aura" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "data-encoding" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2e66c9d817f1720209181c316d28635c050fa304f9c79e47a520882661b7308" + +[[package]] +name = "data-encoding-macro" +version = "0.1.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c904b33cc60130e1aeea4956ab803d08a3f4a0ca82d64ed757afac3891f2bb99" dependencies = [ - "parity-scale-codec", - "polkadot-core-primitives", - "polkadot-primitives", - "sp-api", - "sp-consensus-aura", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "data-encoding", + "data-encoding-macro-internal", ] [[package]] -name = "cumulus-primitives-core" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "data-encoding-macro-internal" +version = "0.1.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fdf3fce3ce863539ec1d7fd1b6dcc3c645663376b43ed376bbf887733e4f772" dependencies = [ - "parity-scale-codec", - "polkadot-core-primitives", - "polkadot-parachain-primitives", - "polkadot-primitives", - "scale-info", - "sp-api", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-trie", - "staging-xcm", + "data-encoding", + "syn 1.0.109", ] [[package]] -name = "cumulus-primitives-parachain-inherent" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "der" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1a467a65c5e759bce6e65eaf91cc29f466cdc57cb65777bd646872a8a1fd4de" dependencies = [ - "async-trait", - "cumulus-primitives-core", - "cumulus-relay-chain-interface", - "cumulus-test-relay-sproof-builder", - "parity-scale-codec", - "sc-client-api", - "scale-info", - "sp-api", - "sp-core", - "sp-inherents", - "sp-runtime", - "sp-state-machine", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-storage", - "sp-trie", - "tracing", + "const-oid", + "pem-rfc7468", + "zeroize", ] [[package]] -name = "cumulus-primitives-timestamp" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "der" +version = "0.7.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c7ed52955ce76b1554f509074bb357d3fb8ac9b51288a65a3fd480d1dfba946" dependencies = [ - "cumulus-primitives-core", - "futures", - "parity-scale-codec", - "sp-inherents", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-timestamp", + "const-oid", + "zeroize", ] [[package]] -name = "cumulus-relay-chain-inprocess-interface" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "der-parser" +version = "7.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe398ac75057914d7d07307bf67dc7f3f574a26783b4fc7805a20ffa9f506e82" dependencies = [ - "async-trait", - "cumulus-primitives-core", - "cumulus-relay-chain-interface", - "futures", - "futures-timer", - "polkadot-cli", - "polkadot-service", - "sc-cli", - "sc-client-api", - "sc-sysinfo", - "sc-telemetry", - "sc-tracing", - "sp-api", - "sp-consensus", - "sp-core", - "sp-runtime", - "sp-state-machine", + "asn1-rs 0.3.1", + "displaydoc", + "nom", + "num-bigint", + "num-traits", + "rusticata-macros", ] [[package]] -name = "cumulus-relay-chain-interface" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "der-parser" +version = "8.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dbd676fbbab537128ef0278adb5576cf363cff6aa22a7b24effe97347cfab61e" dependencies = [ - "async-trait", - "cumulus-primitives-core", - "futures", - "jsonrpsee-core 0.16.2", - "parity-scale-codec", - "polkadot-overseer", - "sc-client-api", - "sp-api", - "sp-blockchain", - "sp-state-machine", - "thiserror", + "asn1-rs 0.5.2", + "displaydoc", + "nom", + "num-bigint", + "num-traits", + "rusticata-macros", ] [[package]] -name = "cumulus-relay-chain-minimal-node" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "deranged" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f32d04922c60427da6f9fef14d042d9edddef64cb9d4ce0d64d0685fbeb1fd3" dependencies = [ - "array-bytes 6.1.0", - "async-trait", - "cumulus-primitives-core", - "cumulus-relay-chain-interface", - "cumulus-relay-chain-rpc-interface", - "futures", - "polkadot-availability-recovery", - "polkadot-collator-protocol", - "polkadot-core-primitives", - "polkadot-network-bridge", - "polkadot-node-collation-generation", - "polkadot-node-core-runtime-api", - "polkadot-node-network-protocol", - "polkadot-node-subsystem-util", - "polkadot-overseer", - "polkadot-primitives", - "sc-authority-discovery", - "sc-network", - "sc-network-common", - "sc-service", - "sc-tracing", - "sc-utils", - "schnellru", - "sp-api", - "sp-consensus", - "sp-consensus-babe", - "sp-runtime", - "tracing", + "powerfmt", ] [[package]] -name = "cumulus-relay-chain-rpc-interface" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "derivative" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" dependencies = [ - "async-trait", - "cumulus-primitives-core", - "cumulus-relay-chain-interface", - "either", - "futures", - "futures-timer", - "jsonrpsee 0.16.2", - "parity-scale-codec", - "pin-project", - "polkadot-overseer", - "rand 0.8.5", - "sc-client-api", - "sc-rpc-api", - "sc-service", - "schnellru", - "serde", - "serde_json", - "smoldot 0.11.0", - "smoldot-light 0.9.0", - "sp-api", - "sp-authority-discovery", - "sp-consensus-babe", - "sp-core", - "sp-runtime", - "sp-state-machine", - "sp-storage", - "thiserror", - "tokio", - "tokio-util", - "tracing", - "url", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "cumulus-test-relay-sproof-builder" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "derive-syn-parse" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e79116f119dd1dba1abf1f3405f03b9b0e79a27a3883864bfebded8a3dc768cd" dependencies = [ - "cumulus-primitives-core", - "parity-scale-codec", - "polkadot-primitives", - "sp-runtime", - "sp-state-machine", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-trie", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "curl" -version = "0.4.44" +name = "derive_builder" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "509bd11746c7ac09ebd19f0b17782eae80aadee26237658a6b4808afb5c11a22" +checksum = "d07adf7be193b71cc36b193d0f5fe60b918a3a9db4dad0449f57bcfd519704a3" dependencies = [ - "curl-sys", - "libc", - "openssl-probe", - "openssl-sys", - "schannel", - "socket2 0.4.9", - "winapi", + "derive_builder_macro", ] [[package]] -name = "curl-sys" -version = "0.4.63+curl-8.1.2" +name = "derive_builder_core" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aeb0fef7046022a1e2ad67a004978f0e3cacb9e3123dc62ce768f92197b771dc" +checksum = "1f91d4cfa921f1c05904dc3c57b4a32c38aed3340cce209f3a6fd1478babafc4" dependencies = [ - "cc", - "libc", - "libnghttp2-sys", - "libz-sys", - "openssl-sys", - "pkg-config", - "vcpkg", - "winapi", + "darling 0.14.4", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "curve25519-dalek" -version = "2.1.3" +name = "derive_builder_macro" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4a9b85542f99a2dfa2a1b8e192662741c9859a846b296bef1c92ef9b58b5a216" +checksum = "8f0314b72bed045f3a68671b3c86328386762c93f82d98c65c3cb5e5f573dd68" dependencies = [ - "byteorder", - "digest 0.8.1", - "rand_core 0.5.1", - "subtle 2.4.1", - "zeroize", + "derive_builder_core", + "syn 1.0.109", ] [[package]] -name = "curve25519-dalek" -version = "3.2.0" +name = "derive_more" +version = "0.99.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" +checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.5.1", - "subtle 2.4.1", - "zeroize", + "convert_case", + "proc-macro2 1.0.69", + "quote 1.0.33", + "rustc_version", + "syn 1.0.109", ] [[package]] -name = "curve25519-dalek" -version = "4.0.0" +name = "difflib" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f711ade317dd348950a9910f81c5947e3d8907ebd2b83f76203ff1807e6a2bc2" -dependencies = [ - "cfg-if 1.0.0", - "cpufeatures", - "curve25519-dalek-derive", - "digest 0.10.7", - "fiat-crypto", - "platforms", - "rustc_version", - "subtle 2.4.1", - "zeroize", -] +checksum = "6184e33543162437515c2e2b48714794e37845ec9851711914eec9d308f6ebe8" [[package]] -name = "curve25519-dalek-derive" -version = "0.1.0" +name = "digest" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83fdaf97f4804dcebfa5862639bc9ce4121e82140bec2a987ac5140294865b5b" +checksum = "f3d0c8c8752312f9713efd397ff63acb9f85585afbf179282e720e7704954dd5" dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", + "generic-array 0.12.4", ] [[package]] -name = "curve25519-dalek-ng" -version = "4.1.1" +name = "digest" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c359b7249347e46fb28804470d071c921156ad62b3eef5d34e2ba867533dec8" +checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.6.4", - "subtle-ng", - "zeroize", + "generic-array 0.14.7", ] [[package]] -name = "cxx" -version = "1.0.101" +name = "digest" +version = "0.10.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5032837c1384de3708043de9d4e97bb91290faca6c16529a28aa340592a78166" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" dependencies = [ - "cc", - "cxxbridge-flags", - "cxxbridge-macro", - "link-cplusplus", + "block-buffer 0.10.4", + "const-oid", + "crypto-common", + "subtle 2.4.1", ] [[package]] -name = "cxx-build" -version = "1.0.101" +name = "directories-next" +version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51368b3d0dbf356e10fcbfd455a038503a105ee556f7ee79b6bb8c53a7247456" +checksum = "339ee130d97a610ea5a5872d2bbb130fdf68884ff09d3028b81bec8a1ac23bbc" dependencies = [ - "cc", - "codespan-reporting", - "once_cell", - "proc-macro2 1.0.69", - "quote 1.0.33", - "scratch", - "syn 2.0.38", + "cfg-if 1.0.0", + "dirs-sys-next", ] [[package]] -name = "cxxbridge-flags" -version = "1.0.101" +name = "dirs-sys-next" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d9062157072e4aafc8e56ceaf8325ce850c5ae37578c852a0d4de2cecdded13" +checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d" +dependencies = [ + "libc", + "redox_users", + "winapi", +] [[package]] -name = "cxxbridge-macro" -version = "1.0.101" +name = "displaydoc" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf01e8a540f5a4e0f284595834f81cf88572f244b768f051724537afa99a2545" +checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" dependencies = [ "proc-macro2 1.0.69", "quote 1.0.33", @@ -3081,3158 +2404,3081 @@ dependencies = [ ] [[package]] -name = "darling" -version = "0.14.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b750cb3417fd1b327431a470f388520309479ab0bf5e323505daf0290cd3850" +name = "dleq_vrf" +version = "0.0.2" +source = "git+https://github.com/w3f/ring-vrf?rev=4b09416#4b09416fd23383ec436ddac127d58c7b7cd392c6" dependencies = [ - "darling_core 0.14.4", - "darling_macro 0.14.4", + "ark-ec", + "ark-ff", + "ark-scale", + "ark-secret-scalar", + "ark-serialize", + "ark-std", + "ark-transcript", + "arrayvec 0.7.4", + "rand_core 0.6.4", + "zeroize", ] [[package]] -name = "darling" -version = "0.20.3" +name = "docify" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0209d94da627ab5605dcccf08bb18afa5009cfbef48d8a8b7d7bdbc79be25c5e" +checksum = "76ee528c501ddd15d5181997e9518e59024844eac44fd1e40cb20ddb2a8562fa" dependencies = [ - "darling_core 0.20.3", - "darling_macro 0.20.3", + "docify_macros", ] [[package]] -name = "darling_core" -version = "0.14.4" +name = "docify_macros" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "109c1ca6e6b7f82cc233a97004ea8ed7ca123a9af07a8230878fcfda9b158bf0" +checksum = "0ca01728ab2679c464242eca99f94e2ce0514b52ac9ad950e2ed03fca991231c" dependencies = [ - "fnv", - "ident_case", + "common-path", + "derive-syn-parse", + "once_cell", "proc-macro2 1.0.69", "quote 1.0.33", - "strsim 0.10.0", - "syn 1.0.109", + "regex", + "syn 2.0.38", + "termcolor", + "toml 0.7.6", + "walkdir", ] [[package]] -name = "darling_core" -version = "0.20.3" +name = "downcast" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "177e3443818124b357d8e76f53be906d60937f0d3a90773a664fa63fa253e621" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2 1.0.69", - "quote 1.0.33", - "strsim 0.10.0", - "syn 2.0.38", -] +checksum = "1435fa1053d8b2fbbe9be7e97eca7f33d37b28409959813daefc1446a14247f1" [[package]] -name = "darling_macro" -version = "0.14.4" +name = "downcast-rs" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4aab4dbc9f7611d8b55048a3a16d2d010c2c8334e46304b40ac1cc14bf3b48e" -dependencies = [ - "darling_core 0.14.4", - "quote 1.0.33", - "syn 1.0.109", -] - -[[package]] -name = "darling_macro" -version = "0.20.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5" -dependencies = [ - "darling_core 0.20.3", - "quote 1.0.33", - "syn 2.0.38", -] +checksum = "9ea835d29036a4087793836fa931b08837ad5e957da9e23886b29586fb9b6650" [[package]] -name = "data-encoding" -version = "2.4.0" +name = "dtoa" +version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2e66c9d817f1720209181c316d28635c050fa304f9c79e47a520882661b7308" +checksum = "dcbb2bf8e87535c23f7a8a321e364ce21462d0ff10cb6407820e8e96dfff6653" [[package]] -name = "data-encoding-macro" -version = "0.1.13" +name = "dyn-clonable" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c904b33cc60130e1aeea4956ab803d08a3f4a0ca82d64ed757afac3891f2bb99" +checksum = "4e9232f0e607a262ceb9bd5141a3dfb3e4db6994b31989bbfd845878cba59fd4" dependencies = [ - "data-encoding", - "data-encoding-macro-internal", + "dyn-clonable-impl", + "dyn-clone", ] [[package]] -name = "data-encoding-macro-internal" -version = "0.1.11" +name = "dyn-clonable-impl" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fdf3fce3ce863539ec1d7fd1b6dcc3c645663376b43ed376bbf887733e4f772" +checksum = "558e40ea573c374cf53507fd240b7ee2f5477df7cfebdb97323ec61c719399c5" dependencies = [ - "data-encoding", + "proc-macro2 1.0.69", + "quote 1.0.33", "syn 1.0.109", ] [[package]] -name = "der" -version = "0.6.1" +name = "dyn-clone" +version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1a467a65c5e759bce6e65eaf91cc29f466cdc57cb65777bd646872a8a1fd4de" -dependencies = [ - "const-oid", - "pem-rfc7468", - "zeroize", -] +checksum = "304e6508efa593091e97a9abbc10f90aa7ca635b6d2784feff3c89d41dd12272" [[package]] -name = "der" -version = "0.7.7" +name = "ecdsa" +version = "0.14.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c7ed52955ce76b1554f509074bb357d3fb8ac9b51288a65a3fd480d1dfba946" +checksum = "413301934810f597c1d19ca71c8710e99a3f1ba28a0d2ebc01551a2daeea3c5c" dependencies = [ - "const-oid", - "zeroize", + "der 0.6.1", + "elliptic-curve 0.12.3", + "rfc6979 0.3.1", + "signature 1.6.4", ] [[package]] -name = "der-parser" -version = "7.0.0" +name = "ecdsa" +version = "0.16.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe398ac75057914d7d07307bf67dc7f3f574a26783b4fc7805a20ffa9f506e82" +checksum = "0997c976637b606099b9985693efa3581e84e41f5c11ba5255f88711058ad428" dependencies = [ - "asn1-rs 0.3.1", - "displaydoc", - "nom", - "num-bigint", - "num-traits", - "rusticata-macros", + "der 0.7.7", + "digest 0.10.7", + "elliptic-curve 0.13.5", + "rfc6979 0.4.0", + "signature 2.1.0", + "spki 0.7.2", ] [[package]] -name = "der-parser" -version = "8.2.0" +name = "ed25519" +version = "2.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbd676fbbab537128ef0278adb5576cf363cff6aa22a7b24effe97347cfab61e" +checksum = "60f6d271ca33075c88028be6f04d502853d63a5ece419d269c15315d4fc1cf1d" dependencies = [ - "asn1-rs 0.5.2", - "displaydoc", - "nom", - "num-bigint", - "num-traits", - "rusticata-macros", + "pkcs8 0.10.2", + "signature 2.1.0", ] [[package]] -name = "deranged" -version = "0.3.9" +name = "ed25519-dalek" +version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f32d04922c60427da6f9fef14d042d9edddef64cb9d4ce0d64d0685fbeb1fd3" +checksum = "7277392b266383ef8396db7fdeb1e77b6c52fed775f5df15bb24f35b72156980" dependencies = [ - "powerfmt", + "curve25519-dalek 4.0.0", + "ed25519", + "rand_core 0.6.4", + "serde", + "sha2 0.10.7", + "zeroize", ] [[package]] -name = "derivative" -version = "2.2.0" +name = "ed25519-zebra" +version = "3.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" +checksum = "7c24f403d068ad0b359e577a77f92392118be3f3c927538f2bb544a5ecd828c6" dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", + "curve25519-dalek 3.2.0", + "hashbrown 0.12.3", + "hex", + "rand_core 0.6.4", + "sha2 0.9.9", + "zeroize", ] [[package]] -name = "derive-syn-parse" -version = "0.1.5" +name = "either" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e79116f119dd1dba1abf1f3405f03b9b0e79a27a3883864bfebded8a3dc768cd" -dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", -] +checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" [[package]] -name = "derive_builder" -version = "0.11.2" +name = "elliptic-curve" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d07adf7be193b71cc36b193d0f5fe60b918a3a9db4dad0449f57bcfd519704a3" +checksum = "e7bb888ab5300a19b8e5bceef25ac745ad065f3c9f7efc6de1b91958110891d3" dependencies = [ - "derive_builder_macro", + "base16ct 0.1.1", + "crypto-bigint 0.4.9", + "der 0.6.1", + "digest 0.10.7", + "ff 0.12.1", + "generic-array 0.14.7", + "group 0.12.1", + "hkdf", + "pem-rfc7468", + "pkcs8 0.9.0", + "rand_core 0.6.4", + "sec1 0.3.0", + "subtle 2.4.1", + "zeroize", ] [[package]] -name = "derive_builder_core" -version = "0.11.2" +name = "elliptic-curve" +version = "0.13.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f91d4cfa921f1c05904dc3c57b4a32c38aed3340cce209f3a6fd1478babafc4" +checksum = "968405c8fdc9b3bf4df0a6638858cc0b52462836ab6b1c87377785dd09cf1c0b" dependencies = [ - "darling 0.14.4", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", + "base16ct 0.2.0", + "crypto-bigint 0.5.2", + "digest 0.10.7", + "ff 0.13.0", + "generic-array 0.14.7", + "group 0.13.0", + "pkcs8 0.10.2", + "rand_core 0.6.4", + "sec1 0.7.3", + "subtle 2.4.1", + "zeroize", ] [[package]] -name = "derive_builder_macro" -version = "0.11.2" +name = "encoding_rs" +version = "0.8.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f0314b72bed045f3a68671b3c86328386762c93f82d98c65c3cb5e5f573dd68" +checksum = "071a31f4ee85403370b58aca746f01041ede6f0da2730960ad001edc2b71b394" dependencies = [ - "derive_builder_core", - "syn 1.0.109", + "cfg-if 1.0.0", ] [[package]] -name = "derive_more" -version = "0.99.17" +name = "enum-as-inner" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" +checksum = "c9720bba047d567ffc8a3cba48bf19126600e249ab7f128e9233e6376976a116" dependencies = [ - "convert_case", + "heck 0.4.1", "proc-macro2 1.0.69", "quote 1.0.33", - "rustc_version", "syn 1.0.109", ] [[package]] -name = "difflib" -version = "0.4.0" +name = "env_logger" +version = "0.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6184e33543162437515c2e2b48714794e37845ec9851711914eec9d308f6ebe8" +checksum = "95b3f3e67048839cb0d0781f445682a35113da7121f7c949db0e2be96a4fbece" +dependencies = [ + "humantime", + "is-terminal", + "log", + "regex", + "termcolor", +] [[package]] -name = "digest" -version = "0.8.1" +name = "environmental" +version = "1.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3d0c8c8752312f9713efd397ff63acb9f85585afbf179282e720e7704954dd5" -dependencies = [ - "generic-array 0.12.4", -] +checksum = "e48c92028aaa870e83d51c64e5d4e0b6981b360c522198c23959f219a4e1b15b" [[package]] -name = "digest" -version = "0.9.0" +name = "equivalent" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + +[[package]] +name = "equivocation-detector" +version = "0.1.0" dependencies = [ - "generic-array 0.14.7", + "async-std", + "async-trait", + "bp-header-chain", + "finality-relay", + "frame-support", + "futures", + "log", + "num-traits", + "relay-utils", ] [[package]] -name = "digest" -version = "0.10.7" +name = "errno" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +checksum = "4bcfec3a70f97c962c307b2d2c56e358cf1d00b558d74262b5f929ee8cc7e73a" dependencies = [ - "block-buffer 0.10.4", - "const-oid", - "crypto-common", - "subtle 2.4.1", + "errno-dragonfly", + "libc", + "windows-sys 0.48.0", ] [[package]] -name = "directories" -version = "5.0.1" +name = "errno-dragonfly" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a49173b84e034382284f27f1af4dcbbd231ffa358c0fe316541a7337f376a35" +checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" dependencies = [ - "dirs-sys", + "cc", + "libc", ] [[package]] -name = "directories-next" -version = "2.0.0" +name = "ethbloom" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "339ee130d97a610ea5a5872d2bbb130fdf68884ff09d3028b81bec8a1ac23bbc" +checksum = "c22d4b5885b6aa2fe5e8b9329fb8d232bf739e434e6b87347c63bdd00c120f60" dependencies = [ - "cfg-if 1.0.0", - "dirs-sys-next", + "crunchy", + "fixed-hash", + "impl-rlp", + "impl-serde", + "tiny-keccak", ] [[package]] -name = "dirs-sys" -version = "0.4.1" +name = "ethereum-types" +version = "0.14.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "520f05a5cbd335fae5a99ff7a6ab8627577660ee5cfd6a94a6a929b52ff0321c" +checksum = "02d215cbf040552efcbe99a38372fe80ab9d00268e20012b79fcd0f073edd8ee" dependencies = [ - "libc", - "option-ext", - "redox_users", - "windows-sys 0.48.0", + "ethbloom", + "fixed-hash", + "impl-rlp", + "impl-serde", + "primitive-types", + "uint", ] [[package]] -name = "dirs-sys-next" -version = "0.1.2" +name = "event-listener" +version = "2.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d" -dependencies = [ - "libc", - "redox_users", - "winapi", -] +checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" [[package]] -name = "displaydoc" -version = "0.2.4" +name = "expander" +version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" +checksum = "5f86a749cf851891866c10515ef6c299b5c69661465e9c3bbe7e07a2b77fb0f7" dependencies = [ + "blake2 0.10.6", + "fs-err", "proc-macro2 1.0.69", "quote 1.0.33", "syn 2.0.38", ] [[package]] -name = "dleq_vrf" -version = "0.0.2" -source = "git+https://github.com/w3f/ring-vrf?rev=4b09416#4b09416fd23383ec436ddac127d58c7b7cd392c6" -dependencies = [ - "ark-ec", - "ark-ff", - "ark-scale", - "ark-secret-scalar", - "ark-serialize", - "ark-std", - "ark-transcript", - "arrayvec 0.7.4", - "rand_core 0.6.4", - "zeroize", -] +name = "fake-simd" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e88a8acf291dafb59c2d96e8f59828f3838bb1a70398823ade51a84de6a6deed" [[package]] -name = "docify" -version = "0.2.4" +name = "fallible-iterator" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76ee528c501ddd15d5181997e9518e59024844eac44fd1e40cb20ddb2a8562fa" -dependencies = [ - "docify_macros", -] +checksum = "4443176a9f2c162692bd3d352d745ef9413eec5782a80d8fd6f8a1ac692a07f7" [[package]] -name = "docify_macros" -version = "0.2.4" +name = "fastrand" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ca01728ab2679c464242eca99f94e2ce0514b52ac9ad950e2ed03fca991231c" +checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" dependencies = [ - "common-path", - "derive-syn-parse", - "once_cell", - "proc-macro2 1.0.69", - "quote 1.0.33", - "regex", - "syn 2.0.38", - "termcolor", - "toml 0.7.6", - "walkdir", + "instant", ] [[package]] -name = "downcast" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1435fa1053d8b2fbbe9be7e97eca7f33d37b28409959813daefc1446a14247f1" - -[[package]] -name = "downcast-rs" -version = "1.2.0" +name = "fastrand" +version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ea835d29036a4087793836fa931b08837ad5e957da9e23886b29586fb9b6650" +checksum = "6999dc1837253364c2ebb0704ba97994bd874e8f195d665c50b7548f6ea92764" [[package]] -name = "dtoa" -version = "1.0.9" +name = "ff" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcbb2bf8e87535c23f7a8a321e364ce21462d0ff10cb6407820e8e96dfff6653" +checksum = "d013fc25338cc558c5c2cfbad646908fb23591e2404481826742b651c9af7160" +dependencies = [ + "rand_core 0.6.4", + "subtle 2.4.1", +] [[package]] -name = "dyn-clonable" -version = "0.9.0" +name = "ff" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e9232f0e607a262ceb9bd5141a3dfb3e4db6994b31989bbfd845878cba59fd4" +checksum = "ded41244b729663b1e574f1b4fb731469f69f79c17667b5d776b16cda0479449" dependencies = [ - "dyn-clonable-impl", - "dyn-clone", + "rand_core 0.6.4", + "subtle 2.4.1", ] [[package]] -name = "dyn-clonable-impl" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "558e40ea573c374cf53507fd240b7ee2f5477df7cfebdb97323ec61c719399c5" +name = "fflonk" +version = "0.1.0" +source = "git+https://github.com/w3f/fflonk#26a5045b24e169cffc1f9328ca83d71061145c40" dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", + "ark-ec", + "ark-ff", + "ark-poly", + "ark-serialize", + "ark-std", + "merlin 3.0.0", ] [[package]] -name = "dyn-clone" -version = "1.0.12" +name = "fiat-crypto" +version = "0.1.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "304e6508efa593091e97a9abbc10f90aa7ca635b6d2784feff3c89d41dd12272" +checksum = "e825f6987101665dea6ec934c09ec6d721de7bc1bf92248e1d5810c8cd636b77" [[package]] -name = "ecdsa" -version = "0.14.8" +name = "file-per-thread-logger" +version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "413301934810f597c1d19ca71c8710e99a3f1ba28a0d2ebc01551a2daeea3c5c" +checksum = "84f2e425d9790201ba4af4630191feac6dcc98765b118d4d18e91d23c2353866" dependencies = [ - "der 0.6.1", - "elliptic-curve 0.12.3", - "rfc6979 0.3.1", - "signature 1.6.4", + "env_logger", + "log", ] [[package]] -name = "ecdsa" -version = "0.16.7" +name = "finality-grandpa" +version = "0.16.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0997c976637b606099b9985693efa3581e84e41f5c11ba5255f88711058ad428" +checksum = "36530797b9bf31cd4ff126dcfee8170f86b00cfdcea3269d73133cc0415945c3" dependencies = [ - "der 0.7.7", - "digest 0.10.7", - "elliptic-curve 0.13.5", - "rfc6979 0.4.0", - "signature 2.1.0", - "spki 0.7.2", + "either", + "futures", + "futures-timer", + "log", + "num-traits", + "parity-scale-codec", + "parking_lot 0.12.1", + "scale-info", ] [[package]] -name = "ed25519" -version = "2.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60f6d271ca33075c88028be6f04d502853d63a5ece419d269c15315d4fc1cf1d" +name = "finality-relay" +version = "0.1.0" dependencies = [ - "pkcs8 0.10.2", - "signature 2.1.0", + "async-std", + "async-trait", + "backoff", + "bp-header-chain", + "futures", + "log", + "num-traits", + "parking_lot 0.12.1", + "relay-utils", ] [[package]] -name = "ed25519-dalek" -version = "2.0.0" +name = "fixed-hash" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7277392b266383ef8396db7fdeb1e77b6c52fed775f5df15bb24f35b72156980" +checksum = "835c052cb0c08c1acf6ffd71c022172e18723949c8282f2b9f27efbc51e64534" dependencies = [ - "curve25519-dalek 4.0.0", - "ed25519", - "rand_core 0.6.4", - "serde", - "sha2 0.10.7", - "zeroize", + "byteorder", + "rand 0.8.5", + "rustc-hex", + "static_assertions", ] [[package]] -name = "ed25519-zebra" -version = "3.1.0" +name = "fixedbitset" +version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c24f403d068ad0b359e577a77f92392118be3f3c927538f2bb544a5ecd828c6" +checksum = "0ce7134b9999ecaf8bcd65542e436736ef32ddca1b3e06094cb6ec5755203b80" + +[[package]] +name = "flate2" +version = "1.0.26" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b9429470923de8e8cbd4d2dc513535400b4b3fef0319fb5c4e1f520a7bef743" dependencies = [ - "curve25519-dalek 3.2.0", - "hashbrown 0.12.3", - "hex", - "rand_core 0.6.4", - "sha2 0.9.9", - "zeroize", + "crc32fast", + "libz-sys", + "miniz_oxide", ] [[package]] -name = "ed25519-zebra" -version = "4.0.2" +name = "float-cmp" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e83e509bcd060ca4b54b72bde5bb306cb2088cb01e14797ebae90a24f70f5f7" +checksum = "98de4bbd547a563b716d8dfa9aad1cb19bfab00f4fa09a6a4ed21dbcf44ce9c4" dependencies = [ - "curve25519-dalek 4.0.0", - "ed25519", - "hashbrown 0.14.0", - "hex", - "rand_core 0.6.4", - "sha2 0.10.7", - "zeroize", + "num-traits", ] [[package]] -name = "either" -version = "1.9.0" +name = "fnv" +version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" [[package]] -name = "elliptic-curve" -version = "0.12.3" +name = "form_urlencoded" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7bb888ab5300a19b8e5bceef25ac745ad065f3c9f7efc6de1b91958110891d3" +checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652" dependencies = [ - "base16ct 0.1.1", - "crypto-bigint 0.4.9", - "der 0.6.1", - "digest 0.10.7", - "ff 0.12.1", - "generic-array 0.14.7", - "group 0.12.1", - "hkdf", - "pem-rfc7468", - "pkcs8 0.9.0", - "rand_core 0.6.4", - "sec1 0.3.0", - "subtle 2.4.1", - "zeroize", + "percent-encoding", ] [[package]] -name = "elliptic-curve" -version = "0.13.5" +name = "fragile" +version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "968405c8fdc9b3bf4df0a6638858cc0b52462836ab6b1c87377785dd09cf1c0b" -dependencies = [ - "base16ct 0.2.0", - "crypto-bigint 0.5.2", - "digest 0.10.7", - "ff 0.13.0", - "generic-array 0.14.7", - "group 0.13.0", - "pkcs8 0.10.2", - "rand_core 0.6.4", - "sec1 0.7.3", - "subtle 2.4.1", - "zeroize", -] +checksum = "6c2141d6d6c8512188a7891b4b01590a45f6dac67afb4f255c4124dbb86d4eaa" [[package]] -name = "encode_unicode" -version = "0.3.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a357d28ed41a50f9c765dbfe56cbc04a64e53e5fc58ba79fbc34c10ef3df831f" +name = "frame-benchmarking" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +dependencies = [ + "frame-support", + "frame-support-procedural", + "frame-system", + "linregress", + "log", + "parity-scale-codec", + "paste", + "scale-info", + "serde", + "sp-api", + "sp-application-crypto", + "sp-core", + "sp-io", + "sp-runtime", + "sp-runtime-interface", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-storage", + "static_assertions", +] [[package]] -name = "encoding_rs" -version = "0.8.32" +name = "frame-metadata" +version = "15.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071a31f4ee85403370b58aca746f01041ede6f0da2730960ad001edc2b71b394" +checksum = "878babb0b136e731cc77ec2fd883ff02745ff21e6fb662729953d44923df009c" dependencies = [ "cfg-if 1.0.0", + "parity-scale-codec", + "scale-info", ] [[package]] -name = "enum-as-inner" -version = "0.5.1" +name = "frame-metadata" +version = "16.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9720bba047d567ffc8a3cba48bf19126600e249ab7f128e9233e6376976a116" +checksum = "87cf1549fba25a6fcac22785b61698317d958e96cac72a59102ea45b9ae64692" dependencies = [ - "heck 0.4.1", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", + "cfg-if 1.0.0", + "parity-scale-codec", + "scale-info", + "serde", ] [[package]] -name = "enumflags2" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c041f5090df68b32bcd905365fd51769c8b9d553fe87fde0b683534f10c01bd2" +name = "frame-support" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "enumflags2_derive", + "aquamarine", + "bitflags 1.3.2", + "docify", + "environmental", + "frame-metadata 16.0.0", + "frame-support-procedural", + "impl-trait-for-tuples", + "k256", + "log", + "macro_magic", + "parity-scale-codec", + "paste", + "scale-info", + "serde", + "serde_json", + "smallvec", + "sp-api", + "sp-arithmetic", + "sp-core", + "sp-core-hashing-proc-macro", + "sp-debug-derive", + "sp-genesis-builder", + "sp-inherents", + "sp-io", + "sp-metadata-ir", + "sp-runtime", + "sp-staking", + "sp-state-machine", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-tracing", + "sp-weights", + "static_assertions", + "tt-call", ] [[package]] -name = "enumflags2_derive" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e9a1f9f7d83e59740248a6e14ecf93929ade55027844dfcea78beafccc15745" +name = "frame-support-procedural" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ + "Inflector", + "cfg-expr", + "derive-syn-parse", + "expander", + "frame-support-procedural-tools", + "itertools", + "macro_magic", + "proc-macro-warning", "proc-macro2 1.0.69", "quote 1.0.33", + "sp-core-hashing 9.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", "syn 2.0.38", ] [[package]] -name = "enumn" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2ad8cef1d801a4686bfd8919f0b30eac4c8e48968c437a6405ded4fb5272d2b" +name = "frame-support-procedural-tools" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ + "frame-support-procedural-tools-derive", + "proc-macro-crate", "proc-macro2 1.0.69", "quote 1.0.33", "syn 2.0.38", ] [[package]] -name = "env_logger" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95b3f3e67048839cb0d0781f445682a35113da7121f7c949db0e2be96a4fbece" +name = "frame-support-procedural-tools-derive" +version = "3.0.0" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "humantime", - "is-terminal", - "log", - "regex", - "termcolor", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 2.0.38", ] [[package]] -name = "environmental" -version = "1.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e48c92028aaa870e83d51c64e5d4e0b6981b360c522198c23959f219a4e1b15b" - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "equivocation-detector" -version = "0.1.0" +name = "frame-system" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "async-std", - "async-trait", - "bp-header-chain", - "finality-relay", + "cfg-if 1.0.0", "frame-support", - "futures", "log", - "num-traits", - "relay-utils", + "parity-scale-codec", + "scale-info", + "serde", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-version", + "sp-weights", ] [[package]] -name = "errno" -version = "0.3.1" +name = "fs-err" +version = "2.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bcfec3a70f97c962c307b2d2c56e358cf1d00b558d74262b5f929ee8cc7e73a" -dependencies = [ - "errno-dragonfly", - "libc", - "windows-sys 0.48.0", -] +checksum = "0845fa252299212f0389d64ba26f34fa32cfe41588355f21ed507c59a0f64541" [[package]] -name = "errno-dragonfly" -version = "0.1.2" +name = "funty" +version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" -dependencies = [ - "cc", - "libc", -] +checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" [[package]] -name = "ethbloom" -version = "0.13.0" +name = "futures" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c22d4b5885b6aa2fe5e8b9329fb8d232bf739e434e6b87347c63bdd00c120f60" +checksum = "da0290714b38af9b4a7b094b8a37086d1b4e61f2df9122c3cad2577669145335" dependencies = [ - "crunchy", - "fixed-hash 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)", - "impl-rlp", - "impl-serde", - "tiny-keccak", + "futures-channel", + "futures-core", + "futures-executor", + "futures-io", + "futures-sink", + "futures-task", + "futures-util", ] [[package]] -name = "ethereum-types" -version = "0.14.1" +name = "futures-channel" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02d215cbf040552efcbe99a38372fe80ab9d00268e20012b79fcd0f073edd8ee" +checksum = "ff4dd66668b557604244583e3e1e1eada8c5c2e96a6d0d6653ede395b78bbacb" dependencies = [ - "ethbloom", - "fixed-hash 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)", - "impl-rlp", - "impl-serde", - "primitive-types", - "uint", + "futures-core", + "futures-sink", ] [[package]] -name = "event-listener" -version = "2.5.3" +name = "futures-core" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" +checksum = "eb1d22c66e66d9d72e1758f0bd7d4fd0bee04cad842ee34587d68c07e45d088c" [[package]] -name = "exit-future" -version = "0.2.0" +name = "futures-executor" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e43f2f1833d64e33f15592464d6fdd70f349dda7b1a53088eb83cd94014008c5" +checksum = "0f4fb8693db0cf099eadcca0efe2a5a22e4550f98ed16aba6c48700da29597bc" dependencies = [ - "futures", + "futures-core", + "futures-task", + "futures-util", + "num_cpus", ] [[package]] -name = "expander" -version = "0.0.4" +name = "futures-io" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a718c0675c555c5f976fff4ea9e2c150fa06cefa201cadef87cfbf9324075881" -dependencies = [ - "blake3", - "fs-err", - "proc-macro2 1.0.69", - "quote 1.0.33", -] +checksum = "8bf34a163b5c4c52d0478a4d757da8fb65cabef42ba90515efee0f6f9fa45aaa" [[package]] -name = "expander" -version = "2.0.0" +name = "futures-lite" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f86a749cf851891866c10515ef6c299b5c69661465e9c3bbe7e07a2b77fb0f7" +checksum = "49a9d51ce47660b1e808d3c990b4709f2f415d928835a17dfd16991515c46bce" +dependencies = [ + "fastrand 1.9.0", + "futures-core", + "futures-io", + "memchr", + "parking", + "pin-project-lite 0.2.12", + "waker-fn", +] + +[[package]] +name = "futures-macro" +version = "0.3.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53b153fd91e4b0147f4aced87be237c98248656bb01050b96bf3ee89220a8ddb" dependencies = [ - "blake2 0.10.6", - "fs-err", "proc-macro2 1.0.69", "quote 1.0.33", "syn 2.0.38", ] [[package]] -name = "fake-simd" -version = "0.1.2" +name = "futures-rustls" +version = "0.22.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e88a8acf291dafb59c2d96e8f59828f3838bb1a70398823ade51a84de6a6deed" +checksum = "d2411eed028cdf8c8034eaf21f9915f956b6c3abec4d4c7949ee67f0721127bd" +dependencies = [ + "futures-io", + "rustls 0.20.8", + "webpki 0.22.2", +] [[package]] -name = "fallible-iterator" -version = "0.2.0" +name = "futures-sink" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4443176a9f2c162692bd3d352d745ef9413eec5782a80d8fd6f8a1ac692a07f7" +checksum = "e36d3378ee38c2a36ad710c5d30c2911d752cb941c00c72dbabfb786a7970817" [[package]] -name = "fastrand" -version = "1.9.0" +name = "futures-task" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" -dependencies = [ - "instant", -] +checksum = "efd193069b0ddadc69c46389b740bbccdd97203899b48d09c5f7969591d6bae2" [[package]] -name = "fastrand" -version = "2.0.0" +name = "futures-timer" +version = "3.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6999dc1837253364c2ebb0704ba97994bd874e8f195d665c50b7548f6ea92764" +checksum = "e64b03909df88034c26dc1547e8970b91f98bdb65165d6a4e9110d94263dbb2c" [[package]] -name = "fatality" -version = "0.0.6" +name = "futures-util" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ad875162843b0d046276327afe0136e9ed3a23d5a754210fb6f1f33610d39ab" +checksum = "a19526d624e703a3179b3d322efec918b6246ea0fa51d41124525f00f1cc8104" dependencies = [ - "fatality-proc-macro", - "thiserror", + "futures-channel", + "futures-core", + "futures-io", + "futures-macro", + "futures-sink", + "futures-task", + "memchr", + "pin-project-lite 0.2.12", + "pin-utils", + "slab", ] [[package]] -name = "fatality-proc-macro" -version = "0.0.6" +name = "fxhash" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5aa1e3ae159e592ad222dc90c5acbad632b527779ba88486abe92782ab268bd" +checksum = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c" dependencies = [ - "expander 0.0.4", - "indexmap 1.9.3", - "proc-macro-crate", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", - "thiserror", + "byteorder", ] [[package]] -name = "fdlimit" -version = "0.2.1" +name = "generic-array" +version = "0.12.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c4c9e43643f5a3be4ca5b67d26b98031ff9db6806c3440ae32e02e3ceac3f1b" +checksum = "ffdf9f34f1447443d37393cc6c2b8313aebddcd96906caf34e54c68d8e57d7bd" dependencies = [ - "libc", + "typenum", ] [[package]] -name = "ff" -version = "0.12.1" +name = "generic-array" +version = "0.14.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d013fc25338cc558c5c2cfbad646908fb23591e2404481826742b651c9af7160" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" dependencies = [ - "rand_core 0.6.4", - "subtle 2.4.1", + "typenum", + "version_check", + "zeroize", ] [[package]] -name = "ff" -version = "0.13.0" +name = "getrandom" +version = "0.1.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ded41244b729663b1e574f1b4fb731469f69f79c17667b5d776b16cda0479449" +checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" dependencies = [ - "rand_core 0.6.4", - "subtle 2.4.1", + "cfg-if 1.0.0", + "libc", + "wasi 0.9.0+wasi-snapshot-preview1", ] [[package]] -name = "fflonk" -version = "0.1.0" -source = "git+https://github.com/w3f/fflonk#26a5045b24e169cffc1f9328ca83d71061145c40" +name = "getrandom" +version = "0.2.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" dependencies = [ - "ark-ec", - "ark-ff", - "ark-poly", - "ark-serialize", - "ark-std", - "merlin 3.0.0", + "cfg-if 1.0.0", + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", ] [[package]] -name = "fiat-crypto" -version = "0.1.20" +name = "ghash" +version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e825f6987101665dea6ec934c09ec6d721de7bc1bf92248e1d5810c8cd636b77" +checksum = "1583cc1656d7839fd3732b80cf4f38850336cdb9b8ded1cd399ca62958de3c99" +dependencies = [ + "opaque-debug 0.3.0", + "polyval 0.5.3", +] [[package]] -name = "file-per-thread-logger" -version = "0.1.6" +name = "ghash" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84f2e425d9790201ba4af4630191feac6dcc98765b118d4d18e91d23c2353866" +checksum = "d930750de5717d2dd0b8c0d42c076c0e884c81a73e6cab859bbd2339c71e3e40" dependencies = [ - "env_logger", - "log", + "opaque-debug 0.3.0", + "polyval 0.6.1", ] [[package]] -name = "filetime" -version = "0.2.21" +name = "gimli" +version = "0.27.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cbc844cecaee9d4443931972e1289c8ff485cb4cc2767cb03ca139ed6885153" +checksum = "b6c80984affa11d98d1b88b66ac8853f143217b399d3c74116778ff8fdb4ed2e" dependencies = [ - "cfg-if 1.0.0", - "libc", - "redox_syscall 0.2.16", - "windows-sys 0.48.0", + "fallible-iterator", + "indexmap 1.9.3", + "stable_deref_trait", ] [[package]] -name = "finality-grandpa" -version = "0.16.2" +name = "globset" +version = "0.4.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "36530797b9bf31cd4ff126dcfee8170f86b00cfdcea3269d73133cc0415945c3" +checksum = "1391ab1f92ffcc08911957149833e682aa3fe252b9f45f966d2ef972274c97df" dependencies = [ - "either", - "futures", - "futures-timer", + "aho-corasick", + "bstr", + "fnv", "log", - "num-traits", - "parity-scale-codec", - "parking_lot 0.12.1", - "scale-info", + "regex", ] [[package]] -name = "finality-relay" -version = "0.1.0" +name = "gloo-timers" +version = "0.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b995a66bb87bebce9a0f4a95aed01daca4872c050bfcb21653361c03bc35e5c" dependencies = [ - "async-std", - "async-trait", - "backoff", - "bp-header-chain", - "futures", - "log", - "num-traits", - "parking_lot 0.12.1", - "relay-utils", + "futures-channel", + "futures-core", + "js-sys", + "wasm-bindgen", ] [[package]] -name = "fixed-hash" -version = "0.8.0" +name = "group" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "835c052cb0c08c1acf6ffd71c022172e18723949c8282f2b9f27efbc51e64534" +checksum = "5dfbfb3a6cfbd390d5c9564ab283a0349b9b9fcd46a706c1eb10e0db70bfbac7" dependencies = [ - "byteorder", - "rand 0.8.5", - "rustc-hex", - "static_assertions", + "ff 0.12.1", + "rand_core 0.6.4", + "subtle 2.4.1", ] [[package]] -name = "fixed-hash" -version = "0.8.0" -source = "git+https://github.com/paritytech/parity-common?branch=master#b4e1516a95c7e7c0bde66d03dbea6f388e7c5fec" +name = "group" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" dependencies = [ - "byteorder", - "rand 0.8.5", - "rustc-hex", - "static_assertions", + "ff 0.13.0", + "rand_core 0.6.4", + "subtle 2.4.1", ] [[package]] -name = "fixedbitset" -version = "0.4.2" +name = "h2" +version = "0.3.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ce7134b9999ecaf8bcd65542e436736ef32ddca1b3e06094cb6ec5755203b80" +checksum = "97ec8491ebaf99c8eaa73058b045fe58073cd6be7f596ac993ced0b0a0c01049" +dependencies = [ + "bytes", + "fnv", + "futures-core", + "futures-sink", + "futures-util", + "http", + "indexmap 1.9.3", + "slab", + "tokio", + "tokio-util", + "tracing", +] [[package]] -name = "flate2" -version = "1.0.26" +name = "hash-db" +version = "0.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b9429470923de8e8cbd4d2dc513535400b4b3fef0319fb5c4e1f520a7bef743" -dependencies = [ - "crc32fast", - "libz-sys", - "miniz_oxide", -] +checksum = "8e7d7786361d7425ae2fe4f9e407eb0efaa0840f5212d109cc018c40c35c6ab4" [[package]] -name = "float-cmp" -version = "0.9.0" +name = "hash256-std-hasher" +version = "0.15.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98de4bbd547a563b716d8dfa9aad1cb19bfab00f4fa09a6a4ed21dbcf44ce9c4" +checksum = "92c171d55b98633f4ed3860808f004099b36c1cc29c42cfc53aa8591b21efcf2" dependencies = [ - "num-traits", + "crunchy", ] [[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "fork-tree" -version = "3.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "hashbrown" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" dependencies = [ - "parity-scale-codec", + "ahash 0.7.6", ] [[package]] -name = "form_urlencoded" -version = "1.2.0" +name = "hashbrown" +version = "0.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652" +checksum = "43a3c133739dddd0d2990f9a4bdf8eb4b21ef50e4851ca85ab661199821d510e" dependencies = [ - "percent-encoding", + "ahash 0.8.3", ] [[package]] -name = "fragile" -version = "2.0.0" +name = "hashbrown" +version = "0.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c2141d6d6c8512188a7891b4b01590a45f6dac67afb4f255c4124dbb86d4eaa" - -[[package]] -name = "frame-benchmarking" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +checksum = "2c6201b9ff9fd90a5a3bac2e56a830d0caa509576f0e503818ee82c181b3437a" dependencies = [ - "frame-support", - "frame-support-procedural", - "frame-system", - "linregress", - "log", - "parity-scale-codec", - "paste", - "scale-info", + "ahash 0.8.3", + "allocator-api2", "serde", - "sp-api", - "sp-application-crypto", - "sp-core", - "sp-io", - "sp-runtime", - "sp-runtime-interface", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-storage", - "static_assertions", ] [[package]] -name = "frame-benchmarking-cli" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "hashlink" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8094feaf31ff591f651a2664fb9cfd92bba7a60ce3197265e9482ebe753c8f7" dependencies = [ - "Inflector", - "array-bytes 6.1.0", - "chrono", - "clap 4.4.8", - "comfy-table", - "frame-benchmarking", - "frame-support", - "frame-system", - "gethostname", - "handlebars", - "itertools 0.10.5", - "lazy_static", - "linked-hash-map", - "log", - "parity-scale-codec", - "rand 0.8.5", - "rand_pcg", - "sc-block-builder", - "sc-cli", - "sc-client-api", - "sc-client-db", - "sc-executor", - "sc-service", - "sc-sysinfo", - "serde", - "serde_json", - "sp-api", - "sp-blockchain", - "sp-core", - "sp-database", - "sp-externalities", - "sp-inherents", - "sp-io", - "sp-keystore", - "sp-runtime", - "sp-state-machine", - "sp-storage", - "sp-trie", - "sp-wasm-interface", - "thiserror", - "thousands", + "hashbrown 0.14.0", ] [[package]] -name = "frame-election-provider-solution-type" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "heck" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" dependencies = [ - "proc-macro-crate", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", + "unicode-segmentation", ] [[package]] -name = "frame-election-provider-support" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-election-provider-solution-type", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-arithmetic", - "sp-core", - "sp-npos-elections", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] +name = "heck" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" [[package]] -name = "frame-executive" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "hermit-abi" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" dependencies = [ - "frame-support", - "frame-system", - "frame-try-runtime", - "log", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-tracing", + "libc", ] [[package]] -name = "frame-metadata" -version = "15.1.0" +name = "hermit-abi" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "878babb0b136e731cc77ec2fd883ff02745ff21e6fb662729953d44923df009c" -dependencies = [ - "cfg-if 1.0.0", - "parity-scale-codec", - "scale-info", -] +checksum = "443144c8cdadd93ebf52ddb4056d257f5b52c04d3c804e657d19eb73fc33668b" [[package]] -name = "frame-metadata" -version = "16.0.0" +name = "hex" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cf1549fba25a6fcac22785b61698317d958e96cac72a59102ea45b9ae64692" -dependencies = [ - "cfg-if 1.0.0", - "parity-scale-codec", - "scale-info", - "serde", -] +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" [[package]] -name = "frame-remote-externalities" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "indicatif", - "jsonrpsee 0.16.2", - "log", - "parity-scale-codec", - "serde", - "sp-core", - "sp-io", - "sp-runtime", - "sp-state-machine", - "spinners", - "substrate-rpc-client", - "tokio", - "tokio-retry", -] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] -name = "frame-support" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "hkdf" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "791a029f6b9fc27657f6f188ec6e5e43f6911f6f878e0dc5501396e09809d437" dependencies = [ - "aquamarine", - "bitflags 1.3.2", - "docify", - "environmental", - "frame-metadata 16.0.0", - "frame-support-procedural", - "impl-trait-for-tuples", - "k256", - "log", - "macro_magic", - "parity-scale-codec", - "paste", - "scale-info", - "serde", - "serde_json", - "smallvec", - "sp-api", - "sp-arithmetic", - "sp-core", - "sp-core-hashing-proc-macro", - "sp-debug-derive", - "sp-genesis-builder", - "sp-inherents", - "sp-io", - "sp-metadata-ir", - "sp-runtime", - "sp-staking", - "sp-state-machine", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-tracing", - "sp-weights", - "static_assertions", - "tt-call", + "hmac 0.12.1", ] [[package]] -name = "frame-support-procedural" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "hmac" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "126888268dcc288495a26bf004b38c5fdbb31682f992c84ceb046a1f0fe38840" dependencies = [ - "Inflector", - "cfg-expr", - "derive-syn-parse", - "expander 2.0.0", - "frame-support-procedural-tools", - "itertools 0.10.5", - "macro_magic", - "proc-macro-warning", - "proc-macro2 1.0.69", - "quote 1.0.33", - "sp-core-hashing 9.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "syn 2.0.38", + "crypto-mac 0.8.0", + "digest 0.9.0", ] [[package]] -name = "frame-support-procedural-tools" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "hmac" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2a2a2320eb7ec0ebe8da8f744d7812d9fc4cb4d09344ac01898dbcb6a20ae69b" dependencies = [ - "frame-support-procedural-tools-derive", - "proc-macro-crate", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", + "crypto-mac 0.11.1", + "digest 0.9.0", ] [[package]] -name = "frame-support-procedural-tools-derive" -version = "3.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "hmac" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", + "digest 0.10.7", ] [[package]] -name = "frame-system" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "hmac-drbg" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "17ea0a1394df5b6574da6e0c1ade9e78868c9fb0a4e5ef4428e32da4676b85b1" dependencies = [ - "cfg-if 1.0.0", - "frame-support", - "log", - "parity-scale-codec", - "scale-info", - "serde", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-version", - "sp-weights", + "digest 0.9.0", + "generic-array 0.14.7", + "hmac 0.8.1", ] [[package]] -name = "frame-system-benchmarking" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "hostname" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c731c3e10504cc8ed35cfe2f1db4c9274c3d35fa486e3b31df46f068ef3e867" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "libc", + "match_cfg", + "winapi", ] [[package]] -name = "frame-system-rpc-runtime-api" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "http" +version = "0.2.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" dependencies = [ - "parity-scale-codec", - "sp-api", + "bytes", + "fnv", + "itoa", ] [[package]] -name = "frame-try-runtime" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "http-body" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" dependencies = [ - "frame-support", - "parity-scale-codec", - "sp-api", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "bytes", + "http", + "pin-project-lite 0.2.12", ] [[package]] -name = "fs-err" -version = "2.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0845fa252299212f0389d64ba26f34fa32cfe41588355f21ed507c59a0f64541" - -[[package]] -name = "fs2" -version = "0.4.3" +name = "httparse" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9564fc758e15025b46aa6643b1b77d047d1a56a1aea6e01002ac0c7026876213" -dependencies = [ - "libc", - "winapi", -] +checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" [[package]] -name = "fs4" -version = "0.6.6" +name = "httpdate" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2eeb4ed9e12f43b7fa0baae3f9cdda28352770132ef2e09a23760c29cae8bd47" -dependencies = [ - "rustix 0.38.21", - "windows-sys 0.48.0", -] +checksum = "c4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421" [[package]] -name = "funty" -version = "2.0.0" +name = "humantime" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" +checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" [[package]] -name = "futures" -version = "0.3.29" +name = "hyper" +version = "0.14.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da0290714b38af9b4a7b094b8a37086d1b4e61f2df9122c3cad2577669145335" +checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" dependencies = [ + "bytes", "futures-channel", "futures-core", - "futures-executor", - "futures-io", - "futures-sink", - "futures-task", "futures-util", + "h2", + "http", + "http-body", + "httparse", + "httpdate", + "itoa", + "pin-project-lite 0.2.12", + "socket2 0.4.9", + "tokio", + "tower-service", + "tracing", + "want", ] [[package]] -name = "futures-channel" -version = "0.3.29" +name = "hyper-rustls" +version = "0.24.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff4dd66668b557604244583e3e1e1eada8c5c2e96a6d0d6653ede395b78bbacb" +checksum = "8d78e1e73ec14cf7375674f74d7dde185c8206fd9dea6fb6295e8a98098aaa97" dependencies = [ - "futures-core", - "futures-sink", + "futures-util", + "http", + "hyper", + "log", + "rustls 0.21.5", + "rustls-native-certs", + "tokio", + "tokio-rustls", ] [[package]] -name = "futures-core" -version = "0.3.29" +name = "iana-time-zone" +version = "0.1.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb1d22c66e66d9d72e1758f0bd7d4fd0bee04cad842ee34587d68c07e45d088c" +checksum = "2fad5b825842d2b38bd206f3e81d6957625fd7f0a361e345c30e01a0ae2dd613" +dependencies = [ + "android_system_properties", + "core-foundation-sys", + "iana-time-zone-haiku", + "js-sys", + "wasm-bindgen", + "windows 0.48.0", +] [[package]] -name = "futures-executor" -version = "0.3.29" +name = "iana-time-zone-haiku" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f4fb8693db0cf099eadcca0efe2a5a22e4550f98ed16aba6c48700da29597bc" +checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" dependencies = [ - "futures-core", - "futures-task", - "futures-util", - "num_cpus", + "cc", ] [[package]] -name = "futures-io" -version = "0.3.29" +name = "ident_case" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8bf34a163b5c4c52d0478a4d757da8fb65cabef42ba90515efee0f6f9fa45aaa" +checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" [[package]] -name = "futures-lite" -version = "1.13.0" +name = "idna" +version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49a9d51ce47660b1e808d3c990b4709f2f415d928835a17dfd16991515c46bce" +checksum = "418a0a6fab821475f634efe3ccc45c013f742efe03d853e8d3355d5cb850ecf8" dependencies = [ - "fastrand 1.9.0", - "futures-core", - "futures-io", - "memchr", - "parking", - "pin-project-lite 0.2.12", - "waker-fn", + "matches", + "unicode-bidi", + "unicode-normalization", ] [[package]] -name = "futures-macro" -version = "0.3.29" +name = "idna" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53b153fd91e4b0147f4aced87be237c98248656bb01050b96bf3ee89220a8ddb" +checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c" dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", + "unicode-bidi", + "unicode-normalization", ] [[package]] -name = "futures-rustls" -version = "0.22.2" +name = "if-addrs" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2411eed028cdf8c8034eaf21f9915f956b6c3abec4d4c7949ee67f0721127bd" +checksum = "cbc0fa01ffc752e9dbc72818cdb072cd028b86be5e09dd04c5a643704fe101a9" dependencies = [ - "futures-io", - "rustls 0.20.8", - "webpki 0.22.2", + "libc", + "winapi", ] [[package]] -name = "futures-sink" -version = "0.3.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e36d3378ee38c2a36ad710c5d30c2911d752cb941c00c72dbabfb786a7970817" - -[[package]] -name = "futures-task" -version = "0.3.29" +name = "if-watch" +version = "3.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "efd193069b0ddadc69c46389b740bbccdd97203899b48d09c5f7969591d6bae2" +checksum = "a9465340214b296cd17a0009acdb890d6160010b8adf8f78a00d0d7ab270f79f" +dependencies = [ + "async-io", + "core-foundation", + "fnv", + "futures", + "if-addrs", + "ipnet", + "log", + "rtnetlink", + "system-configuration", + "tokio", + "windows 0.34.0", +] [[package]] -name = "futures-timer" -version = "3.0.2" +name = "impl-codec" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e64b03909df88034c26dc1547e8970b91f98bdb65165d6a4e9110d94263dbb2c" +checksum = "ba6a270039626615617f3f36d15fc827041df3b78c439da2cadfa47455a77f2f" +dependencies = [ + "parity-scale-codec", +] [[package]] -name = "futures-util" -version = "0.3.29" +name = "impl-rlp" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a19526d624e703a3179b3d322efec918b6246ea0fa51d41124525f00f1cc8104" +checksum = "f28220f89297a075ddc7245cd538076ee98b01f2a9c23a53a4f1105d5a322808" dependencies = [ - "futures-channel", - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite 0.2.12", - "pin-utils", - "slab", + "rlp", ] [[package]] -name = "fxhash" -version = "0.2.1" +name = "impl-serde" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c" +checksum = "ebc88fc67028ae3db0c853baa36269d398d5f45b6982f95549ff5def78c935cd" dependencies = [ - "byteorder", + "serde", ] [[package]] -name = "generic-array" -version = "0.12.4" +name = "impl-trait-for-tuples" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffdf9f34f1447443d37393cc6c2b8313aebddcd96906caf34e54c68d8e57d7bd" +checksum = "11d7a9f6330b71fea57921c9b61c47ee6e84f72d394754eff6163ae67e7395eb" dependencies = [ - "typenum", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "generic-array" -version = "0.14.7" +name = "include_dir" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +checksum = "18762faeff7122e89e0857b02f7ce6fcc0d101d5e9ad2ad7846cc01d61b7f19e" dependencies = [ - "typenum", - "version_check", - "zeroize", + "include_dir_macros", ] [[package]] -name = "gethostname" -version = "0.2.3" +name = "include_dir_macros" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1ebd34e35c46e00bb73e81363248d627782724609fe1b6396f553f68fe3862e" +checksum = "b139284b5cf57ecfa712bcc66950bb635b31aff41c188e8a4cfc758eca374a3f" dependencies = [ - "libc", - "winapi", + "proc-macro2 1.0.69", + "quote 1.0.33", ] [[package]] -name = "getrandom" -version = "0.1.16" +name = "indexmap" +version = "1.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" +checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" dependencies = [ - "cfg-if 1.0.0", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", + "autocfg", + "hashbrown 0.12.3", + "serde", ] [[package]] -name = "getrandom" -version = "0.2.10" +name = "indexmap" +version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" +checksum = "d5477fe2230a79769d8dc68e0eabf5437907c0457a5614a9e8dddb67f65eb65d" dependencies = [ - "cfg-if 1.0.0", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", + "equivalent", + "hashbrown 0.14.0", ] [[package]] -name = "ghash" -version = "0.4.4" +name = "indexmap-nostd" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1583cc1656d7839fd3732b80cf4f38850336cdb9b8ded1cd399ca62958de3c99" -dependencies = [ - "opaque-debug 0.3.0", - "polyval 0.5.3", -] +checksum = "8e04e2fd2b8188ea827b32ef11de88377086d690286ab35747ef7f9bf3ccb590" [[package]] -name = "ghash" -version = "0.5.0" +name = "inout" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d930750de5717d2dd0b8c0d42c076c0e884c81a73e6cab859bbd2339c71e3e40" +checksum = "a0c10553d664a4d0bcff9f4215d0aac67a639cc68ef660840afe309b807bc9f5" dependencies = [ - "opaque-debug 0.3.0", - "polyval 0.6.1", + "generic-array 0.14.7", ] [[package]] -name = "gimli" -version = "0.27.3" +name = "instant" +version = "0.1.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6c80984affa11d98d1b88b66ac8853f143217b399d3c74116778ff8fdb4ed2e" +checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" dependencies = [ - "fallible-iterator", - "indexmap 1.9.3", - "stable_deref_trait", + "cfg-if 1.0.0", ] [[package]] -name = "glob" -version = "0.3.1" +name = "integer-sqrt" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" +checksum = "276ec31bcb4a9ee45f58bec6f9ec700ae4cf4f4f8f2fa7e06cb406bd5ffdd770" +dependencies = [ + "num-traits", +] [[package]] -name = "globset" -version = "0.4.11" +name = "interceptor" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1391ab1f92ffcc08911957149833e682aa3fe252b9f45f966d2ef972274c97df" +checksum = "1e8a11ae2da61704edada656798b61c94b35ecac2c58eb955156987d5e6be90b" dependencies = [ - "aho-corasick", - "bstr", - "fnv", + "async-trait", + "bytes", "log", - "regex", + "rand 0.8.5", + "rtcp", + "rtp", + "thiserror", + "tokio", + "waitgroup", + "webrtc-srtp", + "webrtc-util", ] [[package]] -name = "gloo-timers" -version = "0.2.6" +name = "intx" +version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b995a66bb87bebce9a0f4a95aed01daca4872c050bfcb21653361c03bc35e5c" +checksum = "f6f38a50a899dc47a6d0ed5508e7f601a2e34c3a85303514b5d137f3c10a0c75" + +[[package]] +name = "io-lifetimes" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" dependencies = [ - "futures-channel", - "futures-core", - "js-sys", - "wasm-bindgen", + "hermit-abi 0.3.2", + "libc", + "windows-sys 0.48.0", ] [[package]] -name = "group" -version = "0.12.1" +name = "ip_network" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dfbfb3a6cfbd390d5c9564ab283a0349b9b9fcd46a706c1eb10e0db70bfbac7" +checksum = "aa2f047c0a98b2f299aa5d6d7088443570faae494e9ae1305e48be000c9e0eb1" + +[[package]] +name = "ipconfig" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b58db92f96b720de98181bbbe63c831e87005ab460c1bf306eb2622b4707997f" dependencies = [ - "ff 0.12.1", - "rand_core 0.6.4", - "subtle 2.4.1", + "socket2 0.5.5", + "widestring", + "windows-sys 0.48.0", + "winreg", ] [[package]] -name = "group" -version = "0.13.0" +name = "ipnet" +version = "2.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" +checksum = "28b29a3cd74f0f4598934efe3aeba42bae0eb4680554128851ebbecb02af14e6" + +[[package]] +name = "is-terminal" +version = "0.4.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb0889898416213fab133e1d33a0e5858a48177452750691bde3666d0fdbaf8b" dependencies = [ - "ff 0.13.0", - "rand_core 0.6.4", - "subtle 2.4.1", + "hermit-abi 0.3.2", + "rustix 0.38.21", + "windows-sys 0.48.0", ] [[package]] -name = "h2" -version = "0.3.20" +name = "isahc" +version = "1.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97ec8491ebaf99c8eaa73058b045fe58073cd6be7f596ac993ced0b0a0c01049" +checksum = "334e04b4d781f436dc315cb1e7515bd96826426345d498149e4bde36b67f8ee9" dependencies = [ - "bytes", - "fnv", - "futures-core", - "futures-sink", - "futures-util", + "async-channel", + "castaway", + "crossbeam-utils", + "curl", + "curl-sys", + "encoding_rs", + "event-listener", + "futures-lite", "http", - "indexmap 1.9.3", + "log", + "mime", + "once_cell", + "polling", "slab", - "tokio", - "tokio-util", + "sluice", "tracing", + "tracing-futures", + "url", + "waker-fn", ] [[package]] -name = "handlebars" -version = "4.3.7" +name = "itertools" +version = "0.10.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83c3372087601b532857d332f5957cbae686da52bb7810bf038c3e3c3cc2fa0d" +checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" dependencies = [ - "log", - "pest", - "pest_derive", - "serde", - "serde_json", - "thiserror", + "either", ] [[package]] -name = "hash-db" -version = "0.16.0" +name = "itoa" +version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e7d7786361d7425ae2fe4f9e407eb0efaa0840f5212d109cc018c40c35c6ab4" +checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" [[package]] -name = "hash256-std-hasher" -version = "0.15.2" +name = "jobserver" +version = "0.1.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92c171d55b98633f4ed3860808f004099b36c1cc29c42cfc53aa8591b21efcf2" +checksum = "936cfd212a0155903bcbc060e316fb6cc7cbf2e1907329391ebadc1fe0ce77c2" dependencies = [ - "crunchy", + "libc", ] [[package]] -name = "hashbrown" -version = "0.12.3" +name = "js-sys" +version = "0.3.64" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" +checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" dependencies = [ - "ahash 0.7.6", + "wasm-bindgen", ] [[package]] -name = "hashbrown" -version = "0.13.2" +name = "jsonpath_lib" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43a3c133739dddd0d2990f9a4bdf8eb4b21ef50e4851ca85ab661199821d510e" +checksum = "eaa63191d68230cccb81c5aa23abd53ed64d83337cacbb25a7b8c7979523774f" dependencies = [ - "ahash 0.8.3", + "log", + "serde", + "serde_json", ] [[package]] -name = "hashbrown" -version = "0.14.0" +name = "jsonrpsee" +version = "0.16.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c6201b9ff9fd90a5a3bac2e56a830d0caa509576f0e503818ee82c181b3437a" +checksum = "7d291e3a5818a2384645fd9756362e6d89cf0541b0b916fa7702ea4a9833608e" dependencies = [ - "ahash 0.8.3", - "allocator-api2", - "serde", + "jsonrpsee-core 0.16.2", + "jsonrpsee-proc-macros 0.16.2", + "jsonrpsee-server", + "jsonrpsee-types 0.16.2", + "tracing", ] [[package]] -name = "hashlink" -version = "0.8.4" +name = "jsonrpsee" +version = "0.17.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8094feaf31ff591f651a2664fb9cfd92bba7a60ce3197265e9482ebe753c8f7" +checksum = "8b971ce0f6cd1521ede485afc564b95b2c8e7079b9da41d4273bd9b55140a55d" dependencies = [ - "hashbrown 0.14.0", -] - + "jsonrpsee-core 0.17.1", + "jsonrpsee-proc-macros 0.17.1", + "jsonrpsee-types 0.17.1", + "jsonrpsee-ws-client", + "tracing", +] + [[package]] -name = "heck" -version = "0.3.3" +name = "jsonrpsee" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" +checksum = "9ad9b31183a8bcbe843e32ca8554ad2936633548d95a7bb6a8e14c767dea6b05" dependencies = [ - "unicode-segmentation", + "jsonrpsee-client-transport 0.20.1", + "jsonrpsee-core 0.20.1", + "jsonrpsee-http-client", + "jsonrpsee-types 0.20.1", ] [[package]] -name = "heck" -version = "0.4.1" +name = "jsonrpsee-client-transport" +version = "0.17.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" +checksum = "7ca00d975eda834826b04ad57d4e690c67439bb51b02eb0f8b7e4c30fcef8ab9" +dependencies = [ + "futures-util", + "http", + "jsonrpsee-core 0.17.1", + "pin-project", + "rustls-native-certs", + "soketto", + "thiserror", + "tokio", + "tokio-rustls", + "tokio-util", + "tracing", +] [[package]] -name = "hermit-abi" -version = "0.1.19" +name = "jsonrpsee-client-transport" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" +checksum = "97f2743cad51cc86b0dbfe316309eeb87a9d96a3d7f4dd7a99767c4b5f065335" dependencies = [ - "libc", + "futures-util", + "http", + "jsonrpsee-core 0.20.1", + "pin-project", + "rustls-native-certs", + "soketto", + "thiserror", + "tokio", + "tokio-rustls", + "tokio-util", + "tracing", + "url", ] [[package]] -name = "hermit-abi" -version = "0.3.2" +name = "jsonrpsee-core" +version = "0.16.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "443144c8cdadd93ebf52ddb4056d257f5b52c04d3c804e657d19eb73fc33668b" +checksum = "a4e70b4439a751a5de7dd5ed55eacff78ebf4ffe0fc009cb1ebb11417f5b536b" +dependencies = [ + "anyhow", + "arrayvec 0.7.4", + "async-trait", + "beef", + "futures-channel", + "futures-util", + "globset", + "hyper", + "jsonrpsee-types 0.16.2", + "parking_lot 0.12.1", + "rand 0.8.5", + "rustc-hash", + "serde", + "serde_json", + "soketto", + "thiserror", + "tokio", + "tracing", +] [[package]] -name = "hex" -version = "0.4.3" +name = "jsonrpsee-core" +version = "0.17.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" +checksum = "b83cca7a5a7899eed8b2935d5f755c8c4052ad66ab5b328bd34ac2b3ffd3515f" +dependencies = [ + "anyhow", + "async-lock", + "async-trait", + "beef", + "futures-timer", + "futures-util", + "jsonrpsee-types 0.17.1", + "rustc-hash", + "serde", + "serde_json", + "thiserror", + "tokio", + "tokio-stream", + "tracing", +] [[package]] -name = "hex-literal" -version = "0.4.1" +name = "jsonrpsee-core" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" +checksum = "35dc957af59ce98373bcdde0c1698060ca6c2d2e9ae357b459c7158b6df33330" +dependencies = [ + "anyhow", + "async-lock", + "async-trait", + "beef", + "futures-timer", + "futures-util", + "hyper", + "jsonrpsee-types 0.20.1", + "rustc-hash", + "serde", + "serde_json", + "thiserror", + "tokio", + "tracing", +] [[package]] -name = "hkdf" -version = "0.12.3" +name = "jsonrpsee-http-client" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "791a029f6b9fc27657f6f188ec6e5e43f6911f6f878e0dc5501396e09809d437" +checksum = "0dd865d0072764cb937b0110a92b5f53e995f7101cb346beca03d93a2dea79de" dependencies = [ - "hmac 0.12.1", + "async-trait", + "hyper", + "hyper-rustls", + "jsonrpsee-core 0.20.1", + "jsonrpsee-types 0.20.1", + "serde", + "serde_json", + "thiserror", + "tokio", + "tower", + "tracing", + "url", ] [[package]] -name = "hmac" -version = "0.8.1" +name = "jsonrpsee-proc-macros" +version = "0.16.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "126888268dcc288495a26bf004b38c5fdbb31682f992c84ceb046a1f0fe38840" +checksum = "baa6da1e4199c10d7b1d0a6e5e8bd8e55f351163b6f4b3cbb044672a69bd4c1c" dependencies = [ - "crypto-mac 0.8.0", - "digest 0.9.0", + "heck 0.4.1", + "proc-macro-crate", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "hmac" -version = "0.11.0" +name = "jsonrpsee-proc-macros" +version = "0.17.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a2a2320eb7ec0ebe8da8f744d7812d9fc4cb4d09344ac01898dbcb6a20ae69b" +checksum = "d814a21d9a819f8de1a41b819a263ffd68e4bb5f043d936db1c49b54684bde0a" dependencies = [ - "crypto-mac 0.11.1", - "digest 0.9.0", + "heck 0.4.1", + "proc-macro-crate", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "hmac" -version = "0.12.1" +name = "jsonrpsee-server" +version = "0.16.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" +checksum = "1fb69dad85df79527c019659a992498d03f8495390496da2f07e6c24c2b356fc" dependencies = [ - "digest 0.10.7", + "futures-channel", + "futures-util", + "http", + "hyper", + "jsonrpsee-core 0.16.2", + "jsonrpsee-types 0.16.2", + "serde", + "serde_json", + "soketto", + "tokio", + "tokio-stream", + "tokio-util", + "tower", + "tracing", ] [[package]] -name = "hmac-drbg" -version = "0.3.0" +name = "jsonrpsee-types" +version = "0.16.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17ea0a1394df5b6574da6e0c1ade9e78868c9fb0a4e5ef4428e32da4676b85b1" +checksum = "5bd522fe1ce3702fd94812965d7bb7a3364b1c9aba743944c5a00529aae80f8c" dependencies = [ - "digest 0.9.0", - "generic-array 0.14.7", - "hmac 0.8.1", + "anyhow", + "beef", + "serde", + "serde_json", + "thiserror", + "tracing", ] [[package]] -name = "honggfuzz" -version = "0.5.55" +name = "jsonrpsee-types" +version = "0.17.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "848e9c511092e0daa0a35a63e8e6e475a3e8f870741448b9f6028d69b142f18e" +checksum = "dd301ccc3e08718393432d1961539d78c4580dcca86014dfe6769c308b2c08b2" dependencies = [ - "arbitrary", - "lazy_static", - "memmap2", - "rustc_version", + "anyhow", + "beef", + "serde", + "serde_json", + "thiserror", + "tracing", ] [[package]] -name = "hostname" -version = "0.3.1" +name = "jsonrpsee-types" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c731c3e10504cc8ed35cfe2f1db4c9274c3d35fa486e3b31df46f068ef3e867" +checksum = "fa9e25aec855b2a7d3ed90fded6c41e8c3fb72b63f071e1be3f0004eba19b625" dependencies = [ - "libc", - "match_cfg", - "winapi", + "anyhow", + "beef", + "serde", + "serde_json", + "thiserror", + "tracing", ] [[package]] -name = "http" -version = "0.2.9" +name = "jsonrpsee-ws-client" +version = "0.17.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" +checksum = "89a69852133d549b07cb37ff2d0ec540eae0d20abb75ae923f5d39bc7536d987" dependencies = [ - "bytes", - "fnv", - "itoa", + "http", + "jsonrpsee-client-transport 0.17.1", + "jsonrpsee-core 0.17.1", + "jsonrpsee-types 0.17.1", ] [[package]] -name = "http-body" -version = "0.4.5" +name = "k256" +version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" +checksum = "cadb76004ed8e97623117f3df85b17aaa6626ab0b0831e6573f104df16cd1bcc" dependencies = [ - "bytes", - "http", - "pin-project-lite 0.2.12", + "cfg-if 1.0.0", + "ecdsa 0.16.7", + "elliptic-curve 0.13.5", + "once_cell", + "sha2 0.10.7", ] [[package]] -name = "http-range-header" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bfe8eed0a9285ef776bb792479ea3834e8b94e13d615c2f66d03dd50a435a29" - -[[package]] -name = "httparse" -version = "1.8.0" +name = "keccak" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" +checksum = "8f6d5ed8676d904364de097082f4e7d240b571b67989ced0240f08b7f966f940" +dependencies = [ + "cpufeatures", +] [[package]] -name = "httpdate" -version = "1.0.2" +name = "keystream" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421" +checksum = "c33070833c9ee02266356de0c43f723152bd38bd96ddf52c82b3af10c9138b28" [[package]] -name = "humantime" -version = "2.1.0" +name = "kv-log-macro" +version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" +checksum = "0de8b303297635ad57c9f5059fd9cee7a47f8e8daa09df0fcd07dd39fb22977f" +dependencies = [ + "log", +] [[package]] -name = "hyper" -version = "0.14.27" +name = "kvdb" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" +checksum = "e7d770dcb02bf6835887c3a979b5107a04ff4bbde97a5f0928d27404a155add9" dependencies = [ - "bytes", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "httpdate", - "itoa", - "pin-project-lite 0.2.12", - "socket2 0.4.9", - "tokio", - "tower-service", - "tracing", - "want", + "smallvec", ] [[package]] -name = "hyper-rustls" -version = "0.23.2" +name = "lazy_static" +version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1788965e61b367cd03a62950836d5cd41560c3577d90e40e0819373194d1661c" -dependencies = [ - "http", - "hyper", - "log", - "rustls 0.20.8", - "rustls-native-certs", - "tokio", - "tokio-rustls 0.23.4", - "webpki-roots", -] +checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" [[package]] -name = "hyper-rustls" -version = "0.24.1" +name = "libc" +version = "0.2.149" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d78e1e73ec14cf7375674f74d7dde185c8206fd9dea6fb6295e8a98098aaa97" -dependencies = [ - "futures-util", - "http", - "hyper", - "log", - "rustls 0.21.5", - "rustls-native-certs", - "tokio", - "tokio-rustls 0.24.1", -] +checksum = "a08173bc88b7955d1b3145aa561539096c421ac8debde8cbc3612ec635fee29b" [[package]] -name = "iana-time-zone" -version = "0.1.57" +name = "libm" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fad5b825842d2b38bd206f3e81d6957625fd7f0a361e345c30e01a0ae2dd613" -dependencies = [ - "android_system_properties", - "core-foundation-sys", - "iana-time-zone-haiku", - "js-sys", - "wasm-bindgen", - "windows 0.48.0", -] +checksum = "f7012b1bbb0719e1097c47611d3898568c546d597c2e74d66f6087edd5233ff4" [[package]] -name = "iana-time-zone-haiku" -version = "0.1.2" +name = "libnghttp2-sys" +version = "0.1.7+1.45.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" +checksum = "57ed28aba195b38d5ff02b9170cbff627e336a20925e43b4945390401c5dc93f" dependencies = [ "cc", + "libc", ] [[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - -[[package]] -name = "idna" -version = "0.2.3" +name = "libp2p" +version = "0.51.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "418a0a6fab821475f634efe3ccc45c013f742efe03d853e8d3355d5cb850ecf8" +checksum = "f210d259724eae82005b5c48078619b7745edb7b76de370b03f8ba59ea103097" dependencies = [ - "matches", - "unicode-bidi", - "unicode-normalization", + "bytes", + "futures", + "futures-timer", + "getrandom 0.2.10", + "instant", + "libp2p-allow-block-list", + "libp2p-connection-limits", + "libp2p-core", + "libp2p-dns", + "libp2p-identify", + "libp2p-identity", + "libp2p-kad", + "libp2p-mdns", + "libp2p-metrics", + "libp2p-noise", + "libp2p-ping", + "libp2p-quic", + "libp2p-request-response", + "libp2p-swarm", + "libp2p-tcp", + "libp2p-wasm-ext", + "libp2p-webrtc", + "libp2p-websocket", + "libp2p-yamux", + "multiaddr", + "pin-project", ] [[package]] -name = "idna" -version = "0.4.0" +name = "libp2p-allow-block-list" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c" +checksum = "510daa05efbc25184458db837f6f9a5143888f1caa742426d92e1833ddd38a50" dependencies = [ - "unicode-bidi", - "unicode-normalization", + "libp2p-core", + "libp2p-identity", + "libp2p-swarm", + "void", ] [[package]] -name = "if-addrs" -version = "0.7.0" +name = "libp2p-connection-limits" +version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbc0fa01ffc752e9dbc72818cdb072cd028b86be5e09dd04c5a643704fe101a9" +checksum = "4caa33f1d26ed664c4fe2cca81a08c8e07d4c1c04f2f4ac7655c2dd85467fda0" dependencies = [ - "libc", - "winapi", + "libp2p-core", + "libp2p-identity", + "libp2p-swarm", + "void", ] [[package]] -name = "if-watch" -version = "3.0.1" +name = "libp2p-core" +version = "0.39.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9465340214b296cd17a0009acdb890d6160010b8adf8f78a00d0d7ab270f79f" +checksum = "3c1df63c0b582aa434fb09b2d86897fa2b419ffeccf934b36f87fcedc8e835c2" dependencies = [ - "async-io", - "core-foundation", + "either", "fnv", "futures", - "if-addrs", - "ipnet", + "futures-timer", + "instant", + "libp2p-identity", "log", - "rtnetlink", - "system-configuration", - "tokio", - "windows 0.34.0", + "multiaddr", + "multihash", + "multistream-select", + "once_cell", + "parking_lot 0.12.1", + "pin-project", + "quick-protobuf", + "rand 0.8.5", + "rw-stream-sink", + "smallvec", + "thiserror", + "unsigned-varint", + "void", ] [[package]] -name = "impl-codec" -version = "0.6.0" +name = "libp2p-dns" +version = "0.39.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba6a270039626615617f3f36d15fc827041df3b78c439da2cadfa47455a77f2f" +checksum = "146ff7034daae62077c415c2376b8057368042df6ab95f5432ad5e88568b1554" dependencies = [ - "parity-scale-codec", + "futures", + "libp2p-core", + "log", + "parking_lot 0.12.1", + "smallvec", + "trust-dns-resolver", ] [[package]] -name = "impl-rlp" -version = "0.3.0" +name = "libp2p-identify" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f28220f89297a075ddc7245cd538076ee98b01f2a9c23a53a4f1105d5a322808" +checksum = "5455f472243e63b9c497ff320ded0314254a9eb751799a39c283c6f20b793f3c" dependencies = [ - "rlp", + "asynchronous-codec", + "either", + "futures", + "futures-timer", + "libp2p-core", + "libp2p-identity", + "libp2p-swarm", + "log", + "lru 0.10.1", + "quick-protobuf", + "quick-protobuf-codec", + "smallvec", + "thiserror", + "void", ] [[package]] -name = "impl-serde" -version = "0.4.0" +name = "libp2p-identity" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebc88fc67028ae3db0c853baa36269d398d5f45b6982f95549ff5def78c935cd" +checksum = "276bb57e7af15d8f100d3c11cbdd32c6752b7eef4ba7a18ecf464972c07abcce" dependencies = [ - "serde", + "bs58 0.4.0", + "ed25519-dalek", + "log", + "multiaddr", + "multihash", + "quick-protobuf", + "rand 0.8.5", + "sha2 0.10.7", + "thiserror", + "zeroize", ] [[package]] -name = "impl-trait-for-tuples" -version = "0.2.2" +name = "libp2p-kad" +version = "0.43.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11d7a9f6330b71fea57921c9b61c47ee6e84f72d394754eff6163ae67e7395eb" +checksum = "39d5ef876a2b2323d63c258e63c2f8e36f205fe5a11f0b3095d59635650790ff" dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", + "arrayvec 0.7.4", + "asynchronous-codec", + "bytes", + "either", + "fnv", + "futures", + "futures-timer", + "instant", + "libp2p-core", + "libp2p-identity", + "libp2p-swarm", + "log", + "quick-protobuf", + "rand 0.8.5", + "sha2 0.10.7", + "smallvec", + "thiserror", + "uint", + "unsigned-varint", + "void", ] [[package]] -name = "include_dir" -version = "0.7.3" +name = "libp2p-mdns" +version = "0.43.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18762faeff7122e89e0857b02f7ce6fcc0d101d5e9ad2ad7846cc01d61b7f19e" +checksum = "19983e1f949f979a928f2c603de1cf180cc0dc23e4ac93a62651ccb18341460b" dependencies = [ - "include_dir_macros", + "data-encoding", + "futures", + "if-watch", + "libp2p-core", + "libp2p-identity", + "libp2p-swarm", + "log", + "rand 0.8.5", + "smallvec", + "socket2 0.4.9", + "tokio", + "trust-dns-proto", + "void", ] [[package]] -name = "include_dir_macros" -version = "0.7.3" +name = "libp2p-metrics" +version = "0.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b139284b5cf57ecfa712bcc66950bb635b31aff41c188e8a4cfc758eca374a3f" +checksum = "a42ec91e227d7d0dafa4ce88b333cdf5f277253873ab087555c92798db2ddd46" dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", + "libp2p-core", + "libp2p-identify", + "libp2p-kad", + "libp2p-ping", + "libp2p-swarm", + "prometheus-client", ] [[package]] -name = "indexmap" -version = "1.9.3" +name = "libp2p-noise" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" +checksum = "9c3673da89d29936bc6435bafc638e2f184180d554ce844db65915113f86ec5e" dependencies = [ - "autocfg", - "hashbrown 0.12.3", - "serde", + "bytes", + "curve25519-dalek 3.2.0", + "futures", + "libp2p-core", + "libp2p-identity", + "log", + "once_cell", + "quick-protobuf", + "rand 0.8.5", + "sha2 0.10.7", + "snow", + "static_assertions", + "thiserror", + "x25519-dalek 1.1.1", + "zeroize", ] [[package]] -name = "indexmap" -version = "2.0.0" +name = "libp2p-ping" +version = "0.42.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5477fe2230a79769d8dc68e0eabf5437907c0457a5614a9e8dddb67f65eb65d" +checksum = "3e57759c19c28a73ef1eb3585ca410cefb72c1a709fcf6de1612a378e4219202" dependencies = [ - "equivalent", - "hashbrown 0.14.0", + "either", + "futures", + "futures-timer", + "instant", + "libp2p-core", + "libp2p-swarm", + "log", + "rand 0.8.5", + "void", ] [[package]] -name = "indexmap-nostd" -version = "0.4.0" +name = "libp2p-quic" +version = "0.7.0-alpha.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e04e2fd2b8188ea827b32ef11de88377086d690286ab35747ef7f9bf3ccb590" +checksum = "c6b26abd81cd2398382a1edfe739b539775be8a90fa6914f39b2ab49571ec735" +dependencies = [ + "bytes", + "futures", + "futures-timer", + "if-watch", + "libp2p-core", + "libp2p-identity", + "libp2p-tls", + "log", + "parking_lot 0.12.1", + "quinn-proto", + "rand 0.8.5", + "rustls 0.20.8", + "thiserror", + "tokio", +] [[package]] -name = "indicatif" -version = "0.17.5" +name = "libp2p-request-response" +version = "0.24.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ff8cc23a7393a397ed1d7f56e6365cba772aba9f9912ab968b03043c395d057" +checksum = "7ffdb374267d42dc5ed5bc53f6e601d4a64ac5964779c6e40bb9e4f14c1e30d5" dependencies = [ - "console", + "async-trait", + "futures", "instant", - "number_prefix", - "portable-atomic", - "unicode-width", + "libp2p-core", + "libp2p-identity", + "libp2p-swarm", + "rand 0.8.5", + "smallvec", ] [[package]] -name = "inout" -version = "0.1.3" +name = "libp2p-swarm" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a0c10553d664a4d0bcff9f4215d0aac67a639cc68ef660840afe309b807bc9f5" +checksum = "903b3d592d7694e56204d211f29d31bc004be99386644ba8731fc3e3ef27b296" dependencies = [ - "generic-array 0.14.7", + "either", + "fnv", + "futures", + "futures-timer", + "instant", + "libp2p-core", + "libp2p-identity", + "libp2p-swarm-derive", + "log", + "rand 0.8.5", + "smallvec", + "tokio", + "void", ] [[package]] -name = "instant" -version = "0.1.12" +name = "libp2p-swarm-derive" +version = "0.32.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" +checksum = "0fba456131824ab6acd4c7bf61e9c0f0a3014b5fc9868ccb8e10d344594cdc4f" dependencies = [ - "cfg-if 1.0.0", + "heck 0.4.1", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "integer-encoding" -version = "3.0.4" +name = "libp2p-tcp" +version = "0.39.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8bb03732005da905c88227371639bf1ad885cc712789c011c31c5fb3ab3ccf02" +checksum = "33d33698596d7722d85d3ab0c86c2c322254fce1241e91208e3679b4eb3026cf" +dependencies = [ + "futures", + "futures-timer", + "if-watch", + "libc", + "libp2p-core", + "log", + "socket2 0.4.9", + "tokio", +] [[package]] -name = "integer-sqrt" -version = "0.1.5" +name = "libp2p-tls" +version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "276ec31bcb4a9ee45f58bec6f9ec700ae4cf4f4f8f2fa7e06cb406bd5ffdd770" +checksum = "ff08d13d0dc66e5e9ba6279c1de417b84fa0d0adc3b03e5732928c180ec02781" dependencies = [ - "num-traits", + "futures", + "futures-rustls", + "libp2p-core", + "libp2p-identity", + "rcgen 0.10.0", + "ring 0.16.20", + "rustls 0.20.8", + "thiserror", + "webpki 0.22.2", + "x509-parser 0.14.0", + "yasna", ] [[package]] -name = "interceptor" -version = "0.8.2" +name = "libp2p-wasm-ext" +version = "0.39.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e8a11ae2da61704edada656798b61c94b35ecac2c58eb955156987d5e6be90b" +checksum = "77dff9d32353a5887adb86c8afc1de1a94d9e8c3bc6df8b2201d7cdf5c848f43" +dependencies = [ + "futures", + "js-sys", + "libp2p-core", + "parity-send-wrapper", + "wasm-bindgen", + "wasm-bindgen-futures", +] + +[[package]] +name = "libp2p-webrtc" +version = "0.4.0-alpha.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dba48592edbc2f60b4bc7c10d65445b0c3964c07df26fdf493b6880d33be36f8" dependencies = [ "async-trait", + "asynchronous-codec", "bytes", + "futures", + "futures-timer", + "hex", + "if-watch", + "libp2p-core", + "libp2p-identity", + "libp2p-noise", "log", + "multihash", + "quick-protobuf", + "quick-protobuf-codec", "rand 0.8.5", - "rtcp", - "rtp", + "rcgen 0.9.3", + "serde", + "stun", "thiserror", + "tinytemplate", "tokio", - "waitgroup", - "webrtc-srtp", - "webrtc-util", + "tokio-util", + "webrtc", ] [[package]] -name = "intx" -version = "0.1.0" +name = "libp2p-websocket" +version = "0.41.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f38a50a899dc47a6d0ed5508e7f601a2e34c3a85303514b5d137f3c10a0c75" +checksum = "111273f7b3d3510524c752e8b7a5314b7f7a1fee7e68161c01a7d72cbb06db9f" +dependencies = [ + "either", + "futures", + "futures-rustls", + "libp2p-core", + "log", + "parking_lot 0.12.1", + "quicksink", + "rw-stream-sink", + "soketto", + "url", + "webpki-roots", +] [[package]] -name = "io-lifetimes" -version = "1.0.11" +name = "libp2p-yamux" +version = "0.43.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" +checksum = "4dcd21d950662700a385d4c6d68e2f5f54d778e97068cdd718522222ef513bda" dependencies = [ - "hermit-abi 0.3.2", - "libc", - "windows-sys 0.48.0", + "futures", + "libp2p-core", + "log", + "thiserror", + "yamux", ] [[package]] -name = "ip_network" -version = "0.4.1" +name = "libsecp256k1" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa2f047c0a98b2f299aa5d6d7088443570faae494e9ae1305e48be000c9e0eb1" +checksum = "95b09eff1b35ed3b33b877ced3a691fc7a481919c7e29c53c906226fcf55e2a1" +dependencies = [ + "arrayref", + "base64 0.13.1", + "digest 0.9.0", + "hmac-drbg", + "libsecp256k1-core", + "libsecp256k1-gen-ecmult", + "libsecp256k1-gen-genmult", + "rand 0.8.5", + "serde", + "sha2 0.9.9", + "typenum", +] [[package]] -name = "ipconfig" -version = "0.3.2" +name = "libsecp256k1-core" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b58db92f96b720de98181bbbe63c831e87005ab460c1bf306eb2622b4707997f" +checksum = "5be9b9bb642d8522a44d533eab56c16c738301965504753b03ad1de3425d5451" dependencies = [ - "socket2 0.5.5", - "widestring", - "windows-sys 0.48.0", - "winreg", + "crunchy", + "digest 0.9.0", + "subtle 2.4.1", ] [[package]] -name = "ipnet" -version = "2.8.0" +name = "libsecp256k1-gen-ecmult" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28b29a3cd74f0f4598934efe3aeba42bae0eb4680554128851ebbecb02af14e6" +checksum = "3038c808c55c87e8a172643a7d87187fc6c4174468159cb3090659d55bcb4809" +dependencies = [ + "libsecp256k1-core", +] [[package]] -name = "is-terminal" -version = "0.4.9" +name = "libsecp256k1-gen-genmult" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb0889898416213fab133e1d33a0e5858a48177452750691bde3666d0fdbaf8b" +checksum = "3db8d6ba2cec9eacc40e6e8ccc98931840301f1006e95647ceb2dd5c3aa06f7c" dependencies = [ - "hermit-abi 0.3.2", - "rustix 0.38.21", - "windows-sys 0.48.0", + "libsecp256k1-core", ] [[package]] -name = "is_executable" -version = "1.0.1" +name = "libz-sys" +version = "1.1.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa9acdc6d67b75e626ad644734e8bc6df893d9cd2a834129065d3dd6158ea9c8" +checksum = "56ee889ecc9568871456d42f603d6a0ce59ff328d291063a45cbdf0036baf6db" dependencies = [ - "winapi", + "cc", + "libc", + "pkg-config", + "vcpkg", ] [[package]] -name = "isahc" -version = "1.7.2" +name = "linked-hash-map" +version = "0.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "334e04b4d781f436dc315cb1e7515bd96826426345d498149e4bde36b67f8ee9" -dependencies = [ - "async-channel", - "castaway", - "crossbeam-utils", - "curl", - "curl-sys", - "encoding_rs", - "event-listener", - "futures-lite", - "http", - "log", - "mime", - "once_cell", - "polling", - "slab", - "sluice", - "tracing", - "tracing-futures", - "url", - "waker-fn", -] +checksum = "0717cef1bc8b636c6e1c1bbdefc09e6322da8a9321966e8928ef80d20f7f770f" [[package]] -name = "itertools" -version = "0.10.5" +name = "linked_hash_set" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" +checksum = "47186c6da4d81ca383c7c47c1bfc80f4b95f4720514d860a5407aaf4233f9588" dependencies = [ - "either", + "linked-hash-map", ] [[package]] -name = "itertools" -version = "0.11.0" +name = "linregress" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1c173a5686ce8bfa551b3563d0c2170bf24ca44da99c7ca4bfdab5418c3fe57" +checksum = "4de0b5f52a9f84544d268f5fabb71b38962d6aa3c6600b8bcd27d44ccf9c9c45" dependencies = [ - "either", + "nalgebra", ] [[package]] -name = "itoa" -version = "1.0.9" +name = "linux-raw-sys" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" +checksum = "f051f77a7c8e6957c0696eac88f26b0117e54f52d3fc682ab19397a8812846a4" [[package]] -name = "jobserver" -version = "0.1.26" +name = "linux-raw-sys" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "936cfd212a0155903bcbc060e316fb6cc7cbf2e1907329391ebadc1fe0ce77c2" +checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" + +[[package]] +name = "linux-raw-sys" +version = "0.4.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da2479e8c062e40bf0066ffa0bc823de0a9368974af99c9f6df941d2c231e03f" + +[[package]] +name = "lioness" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ae926706ba42c425c9457121178330d75e273df2e82e28b758faf3de3a9acb9" dependencies = [ - "libc", + "arrayref", + "blake2 0.8.1", + "chacha", + "keystream", ] [[package]] -name = "js-sys" -version = "0.3.64" +name = "lock_api" +version = "0.4.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" +checksum = "c1cc9717a20b1bb222f333e6a92fd32f7d8a18ddc5a3191a11af45dcbf4dcd16" dependencies = [ - "wasm-bindgen", + "autocfg", + "scopeguard", ] [[package]] -name = "jsonpath_lib" -version = "0.3.0" +name = "log" +version = "0.4.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaa63191d68230cccb81c5aa23abd53ed64d83337cacbb25a7b8c7979523774f" +checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" dependencies = [ - "log", - "serde", - "serde_json", + "value-bag", ] [[package]] -name = "jsonrpsee" -version = "0.16.2" +name = "lru" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d291e3a5818a2384645fd9756362e6d89cf0541b0b916fa7702ea4a9833608e" +checksum = "b6e8aaa3f231bb4bd57b84b2d5dc3ae7f350265df8aa96492e0bc394a1571909" dependencies = [ - "jsonrpsee-core 0.16.2", - "jsonrpsee-http-client 0.16.2", - "jsonrpsee-proc-macros 0.16.2", - "jsonrpsee-server", - "jsonrpsee-types 0.16.2", - "jsonrpsee-ws-client 0.16.2", - "tracing", + "hashbrown 0.12.3", ] [[package]] -name = "jsonrpsee" -version = "0.17.1" +name = "lru" +version = "0.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b971ce0f6cd1521ede485afc564b95b2c8e7079b9da41d4273bd9b55140a55d" +checksum = "718e8fae447df0c7e1ba7f5189829e63fd536945c8988d61444c19039f16b670" dependencies = [ - "jsonrpsee-core 0.17.1", - "jsonrpsee-proc-macros 0.17.1", - "jsonrpsee-types 0.17.1", - "jsonrpsee-ws-client 0.17.1", - "tracing", + "hashbrown 0.13.2", ] [[package]] -name = "jsonrpsee" -version = "0.20.1" +name = "lru-cache" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ad9b31183a8bcbe843e32ca8554ad2936633548d95a7bb6a8e14c767dea6b05" +checksum = "31e24f1ad8321ca0e8a1e0ac13f23cb668e6f5466c2c57319f6a5cf1cc8e3b1c" dependencies = [ - "jsonrpsee-client-transport 0.20.1", - "jsonrpsee-core 0.20.1", - "jsonrpsee-http-client 0.20.1", - "jsonrpsee-types 0.20.1", + "linked-hash-map", ] [[package]] -name = "jsonrpsee-client-transport" -version = "0.16.2" +name = "mach" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "965de52763f2004bc91ac5bcec504192440f0b568a5d621c59d9dbd6f886c3fb" +checksum = "b823e83b2affd8f40a9ee8c29dbc56404c1e34cd2710921f2801e2cf29527afa" dependencies = [ - "futures-util", - "http", - "jsonrpsee-core 0.16.2", - "jsonrpsee-types 0.16.2", - "pin-project", - "rustls-native-certs", - "soketto", - "thiserror", - "tokio", - "tokio-rustls 0.23.4", - "tokio-util", - "tracing", - "webpki-roots", + "libc", ] [[package]] -name = "jsonrpsee-client-transport" -version = "0.17.1" +name = "macro_magic" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ca00d975eda834826b04ad57d4e690c67439bb51b02eb0f8b7e4c30fcef8ab9" +checksum = "e03844fc635e92f3a0067e25fa4bf3e3dbf3f2927bf3aa01bb7bc8f1c428949d" dependencies = [ - "futures-util", - "http", - "jsonrpsee-core 0.17.1", - "pin-project", - "rustls-native-certs", - "soketto", - "thiserror", - "tokio", - "tokio-rustls 0.24.1", - "tokio-util", - "tracing", + "macro_magic_core", + "macro_magic_macros", + "quote 1.0.33", + "syn 2.0.38", ] [[package]] -name = "jsonrpsee-client-transport" -version = "0.20.1" +name = "macro_magic_core" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97f2743cad51cc86b0dbfe316309eeb87a9d96a3d7f4dd7a99767c4b5f065335" +checksum = "468155613a44cfd825f1fb0ffa532b018253920d404e6fca1e8d43155198a46d" dependencies = [ - "futures-util", - "http", - "jsonrpsee-core 0.20.1", - "pin-project", - "rustls-native-certs", - "soketto", - "thiserror", - "tokio", - "tokio-rustls 0.24.1", - "tokio-util", - "tracing", - "url", + "const-random", + "derive-syn-parse", + "macro_magic_core_macros", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 2.0.38", ] [[package]] -name = "jsonrpsee-core" -version = "0.16.2" +name = "macro_magic_core_macros" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4e70b4439a751a5de7dd5ed55eacff78ebf4ffe0fc009cb1ebb11417f5b536b" +checksum = "9ea73aa640dc01d62a590d48c0c3521ed739d53b27f919b25c3551e233481654" dependencies = [ - "anyhow", - "arrayvec 0.7.4", - "async-lock", - "async-trait", - "beef", - "futures-channel", - "futures-timer", - "futures-util", - "globset", - "hyper", - "jsonrpsee-types 0.16.2", - "parking_lot 0.12.1", - "rand 0.8.5", - "rustc-hash", - "serde", - "serde_json", - "soketto", - "thiserror", - "tokio", - "tracing", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 2.0.38", ] [[package]] -name = "jsonrpsee-core" -version = "0.17.1" +name = "macro_magic_macros" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b83cca7a5a7899eed8b2935d5f755c8c4052ad66ab5b328bd34ac2b3ffd3515f" +checksum = "ef9d79ae96aaba821963320eb2b6e34d17df1e5a83d8a1985c29cc5be59577b3" dependencies = [ - "anyhow", - "async-lock", - "async-trait", - "beef", - "futures-timer", - "futures-util", - "jsonrpsee-types 0.17.1", - "rustc-hash", - "serde", - "serde_json", - "thiserror", - "tokio", - "tokio-stream", - "tracing", + "macro_magic_core", + "quote 1.0.33", + "syn 2.0.38", ] [[package]] -name = "jsonrpsee-core" -version = "0.20.1" +name = "match_cfg" +version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35dc957af59ce98373bcdde0c1698060ca6c2d2e9ae357b459c7158b6df33330" -dependencies = [ - "anyhow", - "async-lock", - "async-trait", - "beef", - "futures-timer", - "futures-util", - "hyper", - "jsonrpsee-types 0.20.1", - "rustc-hash", - "serde", - "serde_json", - "thiserror", - "tokio", - "tracing", -] +checksum = "ffbee8634e0d45d258acb448e7eaab3fce7a0a467395d4d9f228e3c1f01fb2e4" [[package]] -name = "jsonrpsee-http-client" -version = "0.16.2" +name = "matchers" +version = "0.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc345b0a43c6bc49b947ebeb936e886a419ee3d894421790c969cc56040542ad" +checksum = "f099785f7595cc4b4553a174ce30dd7589ef93391ff414dbb67f62392b9e0ce1" dependencies = [ - "async-trait", - "hyper", - "hyper-rustls 0.23.2", - "jsonrpsee-core 0.16.2", - "jsonrpsee-types 0.16.2", - "rustc-hash", - "serde", - "serde_json", - "thiserror", - "tokio", - "tracing", + "regex-automata 0.1.10", ] [[package]] -name = "jsonrpsee-http-client" -version = "0.20.1" +name = "matches" +version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0dd865d0072764cb937b0110a92b5f53e995f7101cb346beca03d93a2dea79de" -dependencies = [ - "async-trait", - "hyper", - "hyper-rustls 0.24.1", - "jsonrpsee-core 0.20.1", - "jsonrpsee-types 0.20.1", - "serde", - "serde_json", - "thiserror", - "tokio", - "tower", - "tracing", - "url", -] +checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" [[package]] -name = "jsonrpsee-proc-macros" -version = "0.16.2" +name = "matrixmultiply" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baa6da1e4199c10d7b1d0a6e5e8bd8e55f351163b6f4b3cbb044672a69bd4c1c" +checksum = "090126dc04f95dc0d1c1c91f61bdd474b3930ca064c1edc8a849da2c6cbe1e77" dependencies = [ - "heck 0.4.1", - "proc-macro-crate", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", + "autocfg", + "rawpointer", ] [[package]] -name = "jsonrpsee-proc-macros" -version = "0.17.1" +name = "md-5" +version = "0.10.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d814a21d9a819f8de1a41b819a263ffd68e4bb5f043d936db1c49b54684bde0a" +checksum = "6365506850d44bff6e2fbcb5176cf63650e48bd45ef2fe2665ae1570e0f4b9ca" dependencies = [ - "heck 0.4.1", - "proc-macro-crate", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", + "digest 0.10.7", ] [[package]] -name = "jsonrpsee-server" -version = "0.16.2" +name = "memchr" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fb69dad85df79527c019659a992498d03f8495390496da2f07e6c24c2b356fc" -dependencies = [ - "futures-channel", - "futures-util", - "http", - "hyper", - "jsonrpsee-core 0.16.2", - "jsonrpsee-types 0.16.2", - "serde", - "serde_json", - "soketto", - "tokio", - "tokio-stream", - "tokio-util", - "tower", - "tracing", -] +checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" [[package]] -name = "jsonrpsee-types" -version = "0.16.2" +name = "memfd" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5bd522fe1ce3702fd94812965d7bb7a3364b1c9aba743944c5a00529aae80f8c" +checksum = "ffc89ccdc6e10d6907450f753537ebc5c5d3460d2e4e62ea74bd571db62c0f9e" dependencies = [ - "anyhow", - "beef", - "serde", - "serde_json", - "thiserror", - "tracing", + "rustix 0.37.23", ] [[package]] -name = "jsonrpsee-types" -version = "0.17.1" +name = "memmap2" +version = "0.5.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd301ccc3e08718393432d1961539d78c4580dcca86014dfe6769c308b2c08b2" +checksum = "83faa42c0a078c393f6b29d5db232d8be22776a891f8f56e5284faee4a20b327" dependencies = [ - "anyhow", - "beef", - "serde", - "serde_json", - "thiserror", - "tracing", + "libc", ] [[package]] -name = "jsonrpsee-types" -version = "0.20.1" +name = "memoffset" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa9e25aec855b2a7d3ed90fded6c41e8c3fb72b63f071e1be3f0004eba19b625" +checksum = "5aa361d4faea93603064a027415f07bd8e1d5c88c9fbf68bf56a285428fd79ce" dependencies = [ - "anyhow", - "beef", - "serde", - "serde_json", - "thiserror", - "tracing", + "autocfg", ] [[package]] -name = "jsonrpsee-ws-client" -version = "0.16.2" +name = "memoffset" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b83daeecfc6517cfe210df24e570fb06213533dfb990318fae781f4c7119dd9" +checksum = "d61c719bcfbcf5d62b3a09efa6088de8c54bc0bfcd3ea7ae39fcc186108b8de1" dependencies = [ - "http", - "jsonrpsee-client-transport 0.16.2", - "jsonrpsee-core 0.16.2", - "jsonrpsee-types 0.16.2", + "autocfg", ] [[package]] -name = "jsonrpsee-ws-client" -version = "0.17.1" +name = "memoffset" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89a69852133d549b07cb37ff2d0ec540eae0d20abb75ae923f5d39bc7536d987" +checksum = "5a634b1c61a95585bd15607c6ab0c4e5b226e695ff2800ba0cdccddf208c406c" dependencies = [ - "http", - "jsonrpsee-client-transport 0.17.1", - "jsonrpsee-core 0.17.1", - "jsonrpsee-types 0.17.1", + "autocfg", ] [[package]] -name = "k256" -version = "0.13.1" +name = "memory-db" +version = "0.32.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cadb76004ed8e97623117f3df85b17aaa6626ab0b0831e6573f104df16cd1bcc" +checksum = "808b50db46293432a45e63bc15ea51e0ab4c0a1647b8eb114e31a3e698dd6fbe" dependencies = [ - "cfg-if 1.0.0", - "ecdsa 0.16.7", - "elliptic-curve 0.13.5", - "once_cell", - "sha2 0.10.7", + "hash-db", ] [[package]] -name = "keccak" -version = "0.1.4" +name = "merlin" +version = "2.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f6d5ed8676d904364de097082f4e7d240b571b67989ced0240f08b7f966f940" +checksum = "4e261cf0f8b3c42ded9f7d2bb59dea03aa52bc8a1cbc7482f9fc3fd1229d3b42" dependencies = [ - "cpufeatures", + "byteorder", + "keccak", + "rand_core 0.5.1", + "zeroize", ] [[package]] -name = "keystream" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c33070833c9ee02266356de0c43f723152bd38bd96ddf52c82b3af10c9138b28" - -[[package]] -name = "kv-log-macro" -version = "1.0.7" +name = "merlin" +version = "3.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0de8b303297635ad57c9f5059fd9cee7a47f8e8daa09df0fcd07dd39fb22977f" +checksum = "58c38e2799fc0978b65dfff8023ec7843e2330bb462f19198840b34b6582397d" dependencies = [ - "log", + "byteorder", + "keccak", + "rand_core 0.6.4", + "zeroize", ] [[package]] -name = "kvdb" -version = "0.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7d770dcb02bf6835887c3a979b5107a04ff4bbde97a5f0928d27404a155add9" -dependencies = [ - "smallvec", +name = "messages-relay" +version = "0.1.0" +dependencies = [ + "async-std", + "async-trait", + "bp-messages", + "env_logger", + "finality-relay", + "futures", + "hex", + "log", + "num-traits", + "parking_lot 0.12.1", + "relay-utils", + "sp-arithmetic", ] [[package]] -name = "kvdb-memorydb" -version = "0.13.0" +name = "mime" +version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf7a85fe66f9ff9cd74e169fdd2c94c6e1e74c412c99a73b4df3200b5d3760b2" -dependencies = [ - "kvdb", - "parking_lot 0.12.1", -] +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" [[package]] -name = "kvdb-rocksdb" -version = "0.19.0" +name = "minimal-lexical" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b644c70b92285f66bfc2032922a79000ea30af7bc2ab31902992a5dcb9b434f6" -dependencies = [ - "kvdb", - "num_cpus", - "parking_lot 0.12.1", - "regex", - "rocksdb", - "smallvec", -] +checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" [[package]] -name = "landlock" -version = "0.3.0" +name = "miniz_oxide" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1530c5b973eeed4ac216af7e24baf5737645a6272e361f1fb95710678b67d9cc" +checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" dependencies = [ - "enumflags2", - "libc", - "thiserror", + "adler", ] [[package]] -name = "lazy_static" -version = "1.4.0" +name = "mio" +version = "0.8.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" +checksum = "3dce281c5e46beae905d4de1870d8b1509a9142b62eedf18b443b011ca8343d0" +dependencies = [ + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", + "windows-sys 0.48.0", +] [[package]] -name = "lazycell" -version = "1.3.0" +name = "mixnet" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" +checksum = "daa3eb39495d8e2e2947a1d862852c90cc6a4a8845f8b41c8829cb9fcc047f4a" +dependencies = [ + "arrayref", + "arrayvec 0.7.4", + "bitflags 1.3.2", + "blake2 0.10.6", + "c2-chacha", + "curve25519-dalek 4.0.0", + "either", + "hashlink", + "lioness", + "log", + "parking_lot 0.12.1", + "rand 0.8.5", + "rand_chacha 0.3.1", + "rand_distr", + "subtle 2.4.1", + "thiserror", + "zeroize", +] [[package]] -name = "libc" -version = "0.2.149" +name = "mockall" +version = "0.11.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a08173bc88b7955d1b3145aa561539096c421ac8debde8cbc3612ec635fee29b" +checksum = "4c84490118f2ee2d74570d114f3d0493cbf02790df303d2707606c3e14e07c96" +dependencies = [ + "cfg-if 1.0.0", + "downcast", + "fragile", + "lazy_static", + "mockall_derive", + "predicates", + "predicates-tree", +] [[package]] -name = "libloading" -version = "0.7.4" +name = "mockall_derive" +version = "0.11.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b67380fd3b2fbe7527a606e18729d21c6f3951633d0500574c4dc22d2d638b9f" +checksum = "22ce75669015c4f47b289fd4d4f56e894e4c96003ffdf3ac51313126f94c6cbb" dependencies = [ "cfg-if 1.0.0", - "winapi", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "libm" -version = "0.2.7" +name = "multiaddr" +version = "0.17.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7012b1bbb0719e1097c47611d3898568c546d597c2e74d66f6087edd5233ff4" +checksum = "2b36f567c7099511fa8612bbbb52dda2419ce0bdbacf31714e3a5ffdb766d3bd" +dependencies = [ + "arrayref", + "byteorder", + "data-encoding", + "log", + "multibase", + "multihash", + "percent-encoding", + "serde", + "static_assertions", + "unsigned-varint", + "url", +] [[package]] -name = "libnghttp2-sys" -version = "0.1.7+1.45.0" +name = "multibase" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57ed28aba195b38d5ff02b9170cbff627e336a20925e43b4945390401c5dc93f" +checksum = "9b3539ec3c1f04ac9748a260728e855f261b4977f5c3406612c884564f329404" dependencies = [ - "cc", - "libc", + "base-x", + "data-encoding", + "data-encoding-macro", ] [[package]] -name = "libp2p" -version = "0.51.3" +name = "multihash" +version = "0.17.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f210d259724eae82005b5c48078619b7745edb7b76de370b03f8ba59ea103097" +checksum = "835d6ff01d610179fbce3de1694d007e500bf33a7f29689838941d6bf783ae40" dependencies = [ - "bytes", - "futures", - "futures-timer", - "getrandom 0.2.10", - "instant", - "libp2p-allow-block-list", - "libp2p-connection-limits", - "libp2p-core", - "libp2p-dns", - "libp2p-identify", - "libp2p-identity", - "libp2p-kad", - "libp2p-mdns", - "libp2p-metrics", - "libp2p-noise", - "libp2p-ping", - "libp2p-quic", - "libp2p-request-response", - "libp2p-swarm", - "libp2p-tcp", - "libp2p-wasm-ext", - "libp2p-webrtc", - "libp2p-websocket", - "libp2p-yamux", - "multiaddr", - "pin-project", + "core2", + "digest 0.10.7", + "multihash-derive", + "sha2 0.10.7", + "unsigned-varint", ] [[package]] -name = "libp2p-allow-block-list" -version = "0.1.1" +name = "multihash-derive" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "510daa05efbc25184458db837f6f9a5143888f1caa742426d92e1833ddd38a50" +checksum = "fc076939022111618a5026d3be019fd8b366e76314538ff9a1b59ffbcbf98bcd" dependencies = [ - "libp2p-core", - "libp2p-identity", - "libp2p-swarm", - "void", + "proc-macro-crate", + "proc-macro-error", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", + "synstructure", ] [[package]] -name = "libp2p-connection-limits" -version = "0.1.0" +name = "multimap" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4caa33f1d26ed664c4fe2cca81a08c8e07d4c1c04f2f4ac7655c2dd85467fda0" -dependencies = [ - "libp2p-core", - "libp2p-identity", - "libp2p-swarm", - "void", -] +checksum = "e5ce46fe64a9d73be07dcbe690a38ce1b293be448fd8ce1e6c1b8062c9f72c6a" [[package]] -name = "libp2p-core" -version = "0.39.2" +name = "multistream-select" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c1df63c0b582aa434fb09b2d86897fa2b419ffeccf934b36f87fcedc8e835c2" +checksum = "c8552ab875c1313b97b8d20cb857b9fd63e2d1d6a0a1b53ce9821e575405f27a" dependencies = [ - "either", - "fnv", + "bytes", "futures", - "futures-timer", - "instant", - "libp2p-identity", "log", - "multiaddr", - "multihash", - "multistream-select", - "once_cell", - "parking_lot 0.12.1", "pin-project", - "quick-protobuf", - "rand 0.8.5", - "rw-stream-sink", "smallvec", - "thiserror", "unsigned-varint", - "void", ] [[package]] -name = "libp2p-dns" -version = "0.39.0" +name = "nalgebra" +version = "0.32.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "146ff7034daae62077c415c2376b8057368042df6ab95f5432ad5e88568b1554" +checksum = "307ed9b18cc2423f29e83f84fd23a8e73628727990181f18641a8b5dc2ab1caa" dependencies = [ - "futures", - "libp2p-core", - "log", - "parking_lot 0.12.1", - "smallvec", - "trust-dns-resolver", + "approx", + "matrixmultiply", + "nalgebra-macros", + "num-complex", + "num-rational", + "num-traits", + "simba", + "typenum", ] [[package]] -name = "libp2p-identify" -version = "0.42.2" +name = "nalgebra-macros" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5455f472243e63b9c497ff320ded0314254a9eb751799a39c283c6f20b793f3c" +checksum = "91761aed67d03ad966ef783ae962ef9bbaca728d2dd7ceb7939ec110fffad998" dependencies = [ - "asynchronous-codec", - "either", - "futures", - "futures-timer", - "libp2p-core", - "libp2p-identity", - "libp2p-swarm", - "log", - "lru 0.10.1", - "quick-protobuf", - "quick-protobuf-codec", - "smallvec", - "thiserror", - "void", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "libp2p-identity" -version = "0.1.3" +name = "netlink-packet-core" +version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "276bb57e7af15d8f100d3c11cbdd32c6752b7eef4ba7a18ecf464972c07abcce" +checksum = "345b8ab5bd4e71a2986663e88c56856699d060e78e152e6e9d7966fcd5491297" dependencies = [ - "bs58 0.4.0", - "ed25519-dalek", - "log", - "multiaddr", - "multihash", - "quick-protobuf", - "rand 0.8.5", - "sha2 0.10.7", + "anyhow", + "byteorder", + "libc", + "netlink-packet-utils", +] + +[[package]] +name = "netlink-packet-route" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d9ea4302b9759a7a88242299225ea3688e63c85ea136371bb6cf94fd674efaab" +dependencies = [ + "anyhow", + "bitflags 1.3.2", + "byteorder", + "libc", + "netlink-packet-core", + "netlink-packet-utils", +] + +[[package]] +name = "netlink-packet-utils" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ede8a08c71ad5a95cdd0e4e52facd37190977039a4704eb82a283f713747d34" +dependencies = [ + "anyhow", + "byteorder", + "paste", "thiserror", - "zeroize", ] [[package]] -name = "libp2p-kad" -version = "0.43.3" +name = "netlink-proto" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39d5ef876a2b2323d63c258e63c2f8e36f205fe5a11f0b3095d59635650790ff" +checksum = "65b4b14489ab424703c092062176d52ba55485a89c076b4f9db05092b7223aa6" dependencies = [ - "arrayvec 0.7.4", - "asynchronous-codec", "bytes", - "either", - "fnv", "futures", - "futures-timer", - "instant", - "libp2p-core", - "libp2p-identity", - "libp2p-swarm", "log", - "quick-protobuf", - "rand 0.8.5", - "sha2 0.10.7", - "smallvec", + "netlink-packet-core", + "netlink-sys", "thiserror", - "uint", - "unsigned-varint", - "void", + "tokio", ] [[package]] -name = "libp2p-mdns" -version = "0.43.1" +name = "netlink-sys" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19983e1f949f979a928f2c603de1cf180cc0dc23e4ac93a62651ccb18341460b" +checksum = "6471bf08e7ac0135876a9581bf3217ef0333c191c128d34878079f42ee150411" dependencies = [ - "data-encoding", + "bytes", "futures", - "if-watch", - "libp2p-core", - "libp2p-identity", - "libp2p-swarm", + "libc", "log", - "rand 0.8.5", - "smallvec", - "socket2 0.4.9", "tokio", - "trust-dns-proto", - "void", ] [[package]] -name = "libp2p-metrics" -version = "0.12.0" +name = "nix" +version = "0.24.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a42ec91e227d7d0dafa4ce88b333cdf5f277253873ab087555c92798db2ddd46" +checksum = "fa52e972a9a719cecb6864fb88568781eb706bac2cd1d4f04a648542dbf78069" dependencies = [ - "libp2p-core", - "libp2p-identify", - "libp2p-kad", - "libp2p-ping", - "libp2p-swarm", - "prometheus-client", + "bitflags 1.3.2", + "cfg-if 1.0.0", + "libc", + "memoffset 0.6.5", ] [[package]] -name = "libp2p-noise" -version = "0.42.2" +name = "no-std-net" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c3673da89d29936bc6435bafc638e2f184180d554ce844db65915113f86ec5e" -dependencies = [ - "bytes", - "curve25519-dalek 3.2.0", - "futures", - "libp2p-core", - "libp2p-identity", - "log", - "once_cell", - "quick-protobuf", - "rand 0.8.5", - "sha2 0.10.7", - "snow", - "static_assertions", - "thiserror", - "x25519-dalek 1.1.1", - "zeroize", -] +checksum = "43794a0ace135be66a25d3ae77d41b91615fb68ae937f904090203e81f755b65" [[package]] -name = "libp2p-ping" -version = "0.42.0" +name = "nodrop" +version = "0.1.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e57759c19c28a73ef1eb3585ca410cefb72c1a709fcf6de1612a378e4219202" +checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" + +[[package]] +name = "nohash-hasher" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2bf50223579dc7cdcfb3bfcacf7069ff68243f8c363f62ffa99cf000a6b9c451" + +[[package]] +name = "nom" +version = "7.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d273983c5a657a70a3e8f2a01329822f3b8c8172b73826411a55751e404a0a4a" dependencies = [ - "either", - "futures", - "futures-timer", - "instant", - "libp2p-core", - "libp2p-swarm", - "log", - "rand 0.8.5", - "void", + "memchr", + "minimal-lexical", ] [[package]] -name = "libp2p-quic" -version = "0.7.0-alpha.3" +name = "normalize-line-endings" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6b26abd81cd2398382a1edfe739b539775be8a90fa6914f39b2ab49571ec735" +checksum = "61807f77802ff30975e01f4f071c8ba10c022052f98b3294119f3e615d13e5be" + +[[package]] +name = "ntapi" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8a3895c6391c39d7fe7ebc444a87eb2991b2a0bc718fdabd071eec617fc68e4" dependencies = [ - "bytes", - "futures", - "futures-timer", - "if-watch", - "libp2p-core", - "libp2p-identity", - "libp2p-tls", - "log", - "parking_lot 0.12.1", - "quinn-proto", - "rand 0.8.5", - "rustls 0.20.8", - "thiserror", - "tokio", + "winapi", ] [[package]] -name = "libp2p-request-response" -version = "0.24.1" +name = "num-bigint" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ffdb374267d42dc5ed5bc53f6e601d4a64ac5964779c6e40bb9e4f14c1e30d5" +checksum = "f93ab6289c7b344a8a9f60f88d80aa20032336fe78da341afc91c8a2341fc75f" dependencies = [ - "async-trait", - "futures", - "instant", - "libp2p-core", - "libp2p-identity", - "libp2p-swarm", - "rand 0.8.5", - "smallvec", + "autocfg", + "num-integer", + "num-traits", ] [[package]] -name = "libp2p-swarm" -version = "0.42.2" +name = "num-complex" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "903b3d592d7694e56204d211f29d31bc004be99386644ba8731fc3e3ef27b296" +checksum = "02e0d21255c828d6f128a1e41534206671e8c3ea0c62f32291e808dc82cff17d" dependencies = [ - "either", - "fnv", - "futures", - "futures-timer", - "instant", - "libp2p-core", - "libp2p-identity", - "libp2p-swarm-derive", - "log", - "rand 0.8.5", - "smallvec", - "tokio", - "void", + "num-traits", ] [[package]] -name = "libp2p-swarm-derive" -version = "0.32.0" +name = "num-format" +version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fba456131824ab6acd4c7bf61e9c0f0a3014b5fc9868ccb8e10d344594cdc4f" +checksum = "a652d9771a63711fd3c3deb670acfbe5c30a4072e664d7a3bf5a9e1056ac72c3" dependencies = [ - "heck 0.4.1", - "quote 1.0.33", - "syn 1.0.109", + "arrayvec 0.7.4", + "itoa", ] [[package]] -name = "libp2p-tcp" -version = "0.39.0" +name = "num-integer" +version = "0.1.45" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33d33698596d7722d85d3ab0c86c2c322254fce1241e91208e3679b4eb3026cf" +checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" dependencies = [ - "futures", - "futures-timer", - "if-watch", - "libc", - "libp2p-core", - "log", - "socket2 0.4.9", - "tokio", + "autocfg", + "num-traits", ] [[package]] -name = "libp2p-tls" -version = "0.1.0" +name = "num-rational" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff08d13d0dc66e5e9ba6279c1de417b84fa0d0adc3b03e5732928c180ec02781" +checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" dependencies = [ - "futures", - "futures-rustls", - "libp2p-core", - "libp2p-identity", - "rcgen 0.10.0", - "ring 0.16.20", - "rustls 0.20.8", - "thiserror", - "webpki 0.22.2", - "x509-parser 0.14.0", - "yasna", + "autocfg", + "num-bigint", + "num-integer", + "num-traits", ] [[package]] -name = "libp2p-wasm-ext" -version = "0.39.0" +name = "num-traits" +version = "0.2.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77dff9d32353a5887adb86c8afc1de1a94d9e8c3bc6df8b2201d7cdf5c848f43" +checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" dependencies = [ - "futures", - "js-sys", - "libp2p-core", - "parity-send-wrapper", - "wasm-bindgen", - "wasm-bindgen-futures", + "autocfg", + "libm", ] [[package]] -name = "libp2p-webrtc" -version = "0.4.0-alpha.4" +name = "num_cpus" +version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dba48592edbc2f60b4bc7c10d65445b0c3964c07df26fdf493b6880d33be36f8" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" dependencies = [ - "async-trait", - "asynchronous-codec", - "bytes", - "futures", - "futures-timer", - "hex", - "if-watch", - "libp2p-core", - "libp2p-identity", - "libp2p-noise", - "log", - "multihash", - "quick-protobuf", - "quick-protobuf-codec", - "rand 0.8.5", - "rcgen 0.9.3", - "serde", - "stun", - "thiserror", - "tinytemplate", - "tokio", - "tokio-util", - "webrtc", + "hermit-abi 0.3.2", + "libc", ] [[package]] -name = "libp2p-websocket" -version = "0.41.0" +name = "num_threads" +version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "111273f7b3d3510524c752e8b7a5314b7f7a1fee7e68161c01a7d72cbb06db9f" +checksum = "2819ce041d2ee131036f4fc9d6ae7ae125a3a40e97ba64d04fe799ad9dabbb44" dependencies = [ - "either", - "futures", - "futures-rustls", - "libp2p-core", - "log", - "parking_lot 0.12.1", - "quicksink", - "rw-stream-sink", - "soketto", - "url", - "webpki-roots", + "libc", ] [[package]] -name = "libp2p-yamux" -version = "0.43.1" +name = "object" +version = "0.30.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dcd21d950662700a385d4c6d68e2f5f54d778e97068cdd718522222ef513bda" +checksum = "03b4680b86d9cfafba8fc491dc9b6df26b68cf40e9e6cd73909194759a63c385" dependencies = [ - "futures", - "libp2p-core", - "log", - "thiserror", - "yamux", + "crc32fast", + "hashbrown 0.13.2", + "indexmap 1.9.3", + "memchr", ] [[package]] -name = "librocksdb-sys" -version = "0.11.0+8.1.1" +name = "object" +version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3386f101bcb4bd252d8e9d2fb41ec3b0862a15a62b478c355b2982efa469e3e" +checksum = "8bda667d9f2b5051b8833f59f3bf748b28ef54f850f4fcb389a252aa383866d1" dependencies = [ - "bindgen", - "bzip2-sys", - "cc", - "glob", - "libc", - "libz-sys", - "tikv-jemalloc-sys", + "memchr", ] [[package]] -name = "libsecp256k1" -version = "0.7.1" +name = "oid-registry" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95b09eff1b35ed3b33b877ced3a691fc7a481919c7e29c53c906226fcf55e2a1" +checksum = "38e20717fa0541f39bd146692035c37bedfa532b3e5071b35761082407546b2a" dependencies = [ - "arrayref", - "base64 0.13.1", - "digest 0.9.0", - "hmac-drbg", - "libsecp256k1-core", - "libsecp256k1-gen-ecmult", - "libsecp256k1-gen-genmult", - "rand 0.8.5", - "serde", - "sha2 0.9.9", - "typenum", + "asn1-rs 0.3.1", ] [[package]] -name = "libsecp256k1-core" -version = "0.3.0" +name = "oid-registry" +version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5be9b9bb642d8522a44d533eab56c16c738301965504753b03ad1de3425d5451" +checksum = "9bedf36ffb6ba96c2eb7144ef6270557b52e54b20c0a8e1eb2ff99a6c6959bff" dependencies = [ - "crunchy", - "digest 0.9.0", - "subtle 2.4.1", + "asn1-rs 0.5.2", ] [[package]] -name = "libsecp256k1-gen-ecmult" -version = "0.3.0" +name = "once_cell" +version = "1.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3038c808c55c87e8a172643a7d87187fc6c4174468159cb3090659d55bcb4809" -dependencies = [ - "libsecp256k1-core", -] +checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" [[package]] -name = "libsecp256k1-gen-genmult" +name = "opaque-debug" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2839e79665f131bdb5782e51f2c6c9599c133c6098982a54c794358bf432529c" + +[[package]] +name = "opaque-debug" version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3db8d6ba2cec9eacc40e6e8ccc98931840301f1006e95647ceb2dd5c3aa06f7c" -dependencies = [ - "libsecp256k1-core", -] +checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" [[package]] -name = "libz-sys" -version = "1.1.9" +name = "openssl-probe" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56ee889ecc9568871456d42f603d6a0ce59ff328d291063a45cbdf0036baf6db" +checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" + +[[package]] +name = "openssl-sys" +version = "0.9.90" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "374533b0e45f3a7ced10fcaeccca020e66656bc03dac384f852e4e5a7a8104a6" dependencies = [ "cc", "libc", @@ -6241,6398 +5487,2177 @@ dependencies = [ ] [[package]] -name = "link-cplusplus" -version = "1.0.9" +name = "p256" +version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d240c6f7e1ba3a28b0249f774e6a9dd0175054b52dfbb61b16eb8505c3785c9" +checksum = "51f44edd08f51e2ade572f141051021c5af22677e42b7dd28a88155151c33594" dependencies = [ - "cc", + "ecdsa 0.14.8", + "elliptic-curve 0.12.3", + "sha2 0.10.7", ] [[package]] -name = "linked-hash-map" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0717cef1bc8b636c6e1c1bbdefc09e6322da8a9321966e8928ef80d20f7f770f" - -[[package]] -name = "linked_hash_set" -version = "0.1.4" +name = "p384" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "47186c6da4d81ca383c7c47c1bfc80f4b95f4720514d860a5407aaf4233f9588" +checksum = "dfc8c5bf642dde52bb9e87c0ecd8ca5a76faac2eeed98dedb7c717997e1080aa" dependencies = [ - "linked-hash-map", + "ecdsa 0.14.8", + "elliptic-curve 0.12.3", + "sha2 0.10.7", ] [[package]] -name = "linregress" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4de0b5f52a9f84544d268f5fabb71b38962d6aa3c6600b8bcd27d44ccf9c9c45" +name = "pallet-authorship" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "nalgebra", + "frame-support", + "frame-system", + "impl-trait-for-tuples", + "parity-scale-codec", + "scale-info", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "linux-raw-sys" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f051f77a7c8e6957c0696eac88f26b0117e54f52d3fc682ab19397a8812846a4" - -[[package]] -name = "linux-raw-sys" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" - -[[package]] -name = "linux-raw-sys" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da2479e8c062e40bf0066ffa0bc823de0a9368974af99c9f6df941d2c231e03f" +name = "pallet-balances" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +dependencies = [ + "frame-benchmarking", + "frame-support", + "frame-system", + "log", + "parity-scale-codec", + "scale-info", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", +] [[package]] -name = "lioness" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ae926706ba42c425c9457121178330d75e273df2e82e28b758faf3de3a9acb9" +name = "pallet-beefy" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "arrayref", - "blake2 0.8.1", - "chacha", - "keystream", + "frame-support", + "frame-system", + "log", + "pallet-authorship", + "pallet-session", + "parity-scale-codec", + "scale-info", + "serde", + "sp-consensus-beefy", + "sp-runtime", + "sp-session", + "sp-staking", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "lock_api" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1cc9717a20b1bb222f333e6a92fd32f7d8a18ddc5a3191a11af45dcbf4dcd16" +name = "pallet-beefy-mmr" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "autocfg", - "scopeguard", + "array-bytes 6.1.0", + "binary-merkle-tree", + "frame-support", + "frame-system", + "log", + "pallet-beefy", + "pallet-mmr", + "pallet-session", + "parity-scale-codec", + "scale-info", + "serde", + "sp-api", + "sp-consensus-beefy", + "sp-core", + "sp-io", + "sp-runtime", + "sp-state-machine", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "log" -version = "0.4.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" +name = "pallet-bridge-beefy" +version = "0.1.0" dependencies = [ - "value-bag", + "bp-beefy", + "bp-runtime", + "bp-test-utils", + "ckb-merkle-mountain-range 0.3.2", + "frame-support", + "frame-system", + "log", + "pallet-beefy-mmr", + "pallet-mmr", + "parity-scale-codec", + "rand 0.8.5", + "scale-info", + "serde", + "sp-consensus-beefy", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "lru" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6e8aaa3f231bb4bd57b84b2d5dc3ae7f350265df8aa96492e0bc394a1571909" +name = "pallet-bridge-grandpa" +version = "0.1.0" dependencies = [ - "hashbrown 0.12.3", + "bp-header-chain", + "bp-runtime", + "bp-test-utils", + "finality-grandpa", + "frame-benchmarking", + "frame-support", + "frame-system", + "log", + "parity-scale-codec", + "scale-info", + "sp-consensus-grandpa", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-trie", ] [[package]] -name = "lru" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "718e8fae447df0c7e1ba7f5189829e63fd536945c8988d61444c19039f16b670" +name = "pallet-bridge-messages" +version = "0.1.0" dependencies = [ - "hashbrown 0.13.2", + "bp-messages", + "bp-runtime", + "bp-test-utils", + "frame-benchmarking", + "frame-support", + "frame-system", + "log", + "num-traits", + "pallet-balances", + "parity-scale-codec", + "scale-info", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "lru" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eedb2bdbad7e0634f83989bf596f497b070130daaa398ab22d84c39e266deec5" - -[[package]] -name = "lru-cache" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31e24f1ad8321ca0e8a1e0ac13f23cb668e6f5466c2c57319f6a5cf1cc8e3b1c" +name = "pallet-bridge-parachains" +version = "0.1.0" dependencies = [ - "linked-hash-map", + "bp-header-chain", + "bp-parachains", + "bp-polkadot-core", + "bp-runtime", + "bp-test-utils", + "frame-benchmarking", + "frame-support", + "frame-system", + "log", + "pallet-bridge-grandpa", + "parity-scale-codec", + "scale-info", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-trie", ] [[package]] -name = "lz4" -version = "1.24.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e9e2dd86df36ce760a60f6ff6ad526f7ba1f14ba0356f8254fb6905e6494df1" +name = "pallet-bridge-relayers" +version = "0.1.0" dependencies = [ - "libc", - "lz4-sys", + "bp-messages", + "bp-relayers", + "bp-runtime", + "frame-benchmarking", + "frame-support", + "frame-system", + "log", + "pallet-balances", + "pallet-bridge-messages", + "parity-scale-codec", + "scale-info", + "sp-arithmetic", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "lz4-sys" -version = "1.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57d27b317e207b10f69f5e75494119e391a96f48861ae870d1da6edac98ca900" +name = "pallet-grandpa" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "cc", - "libc", + "frame-benchmarking", + "frame-support", + "frame-system", + "log", + "pallet-authorship", + "pallet-session", + "parity-scale-codec", + "scale-info", + "sp-application-crypto", + "sp-consensus-grandpa", + "sp-core", + "sp-io", + "sp-runtime", + "sp-session", + "sp-staking", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "mach" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b823e83b2affd8f40a9ee8c29dbc56404c1e34cd2710921f2801e2cf29527afa" +name = "pallet-mmr" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "libc", + "frame-benchmarking", + "frame-support", + "frame-system", + "log", + "parity-scale-codec", + "scale-info", + "sp-core", + "sp-io", + "sp-mmr-primitives", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "macro_magic" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e03844fc635e92f3a0067e25fa4bf3e3dbf3f2927bf3aa01bb7bc8f1c428949d" +name = "pallet-session" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "macro_magic_core", - "macro_magic_macros", - "quote 1.0.33", - "syn 2.0.38", + "frame-support", + "frame-system", + "impl-trait-for-tuples", + "log", + "pallet-timestamp", + "parity-scale-codec", + "scale-info", + "sp-core", + "sp-io", + "sp-runtime", + "sp-session", + "sp-staking", + "sp-state-machine", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-trie", ] [[package]] -name = "macro_magic_core" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "468155613a44cfd825f1fb0ffa532b018253920d404e6fca1e8d43155198a46d" +name = "pallet-timestamp" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "const-random", - "derive-syn-parse", - "macro_magic_core_macros", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", + "docify", + "frame-benchmarking", + "frame-support", + "frame-system", + "log", + "parity-scale-codec", + "scale-info", + "sp-inherents", + "sp-io", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-storage", + "sp-timestamp", ] [[package]] -name = "macro_magic_core_macros" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ea73aa640dc01d62a590d48c0c3521ed739d53b27f919b25c3551e233481654" +name = "pallet-transaction-payment" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", + "frame-support", + "frame-system", + "parity-scale-codec", + "scale-info", + "serde", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "macro_magic_macros" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef9d79ae96aaba821963320eb2b6e34d17df1e5a83d8a1985c29cc5be59577b3" +name = "pallet-transaction-payment-rpc-runtime-api" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "macro_magic_core", - "quote 1.0.33", - "syn 2.0.38", + "pallet-transaction-payment", + "parity-scale-codec", + "sp-api", + "sp-runtime", + "sp-weights", ] [[package]] -name = "maplit" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e2e65a1a2e43cfcb47a895c4c8b10d1f4a61097f9f254f183aee60cad9c651d" +name = "pallet-utility" +version = "4.0.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +dependencies = [ + "frame-benchmarking", + "frame-support", + "frame-system", + "parity-scale-codec", + "scale-info", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", +] [[package]] -name = "match_cfg" +name = "pallet-xcm-bridge-hub-router" version = "0.1.0" +dependencies = [ + "bp-xcm-bridge-hub-router", + "frame-benchmarking", + "frame-support", + "frame-system", + "log", + "parity-scale-codec", + "scale-info", + "sp-core", + "sp-io", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "staging-xcm", + "staging-xcm-builder", +] + +[[package]] +name = "parachains-relay" +version = "0.1.0" +dependencies = [ + "async-std", + "async-trait", + "bp-polkadot-core", + "futures", + "log", + "parity-scale-codec", + "relay-substrate-client", + "relay-utils", + "sp-core", +] + +[[package]] +name = "parity-scale-codec" +version = "3.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffbee8634e0d45d258acb448e7eaab3fce7a0a467395d4d9f228e3c1f01fb2e4" +checksum = "dd8e946cc0cc711189c0b0249fb8b599cbeeab9784d83c415719368bb8d4ac64" +dependencies = [ + "arrayvec 0.7.4", + "bitvec", + "byte-slice-cast", + "bytes", + "impl-trait-for-tuples", + "parity-scale-codec-derive", + "serde", +] [[package]] -name = "matchers" -version = "0.0.1" +name = "parity-scale-codec-derive" +version = "3.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f099785f7595cc4b4553a174ce30dd7589ef93391ff414dbb67f62392b9e0ce1" +checksum = "2a296c3079b5fefbc499e1de58dc26c09b1b9a5952d26694ee89f04a43ebbb3e" dependencies = [ - "regex-automata 0.1.10", + "proc-macro-crate", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "matches" -version = "0.1.10" +name = "parity-send-wrapper" +version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" +checksum = "aa9777aa91b8ad9dd5aaa04a9b6bcb02c7f1deb952fca5a66034d5e63afc5c6f" [[package]] -name = "matrixmultiply" -version = "0.3.7" +name = "parity-util-mem" +version = "0.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "090126dc04f95dc0d1c1c91f61bdd474b3930ca064c1edc8a849da2c6cbe1e77" +checksum = "0d32c34f4f5ca7f9196001c0aba5a1f9a5a12382c8944b8b0f90233282d1e8f8" dependencies = [ - "autocfg", - "rawpointer", + "cfg-if 1.0.0", + "ethereum-types", + "hashbrown 0.12.3", + "impl-trait-for-tuples", + "lru 0.8.1", + "parity-util-mem-derive", + "parking_lot 0.12.1", + "primitive-types", + "smallvec", + "winapi", ] [[package]] -name = "md-5" -version = "0.10.5" +name = "parity-util-mem-derive" +version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6365506850d44bff6e2fbcb5176cf63650e48bd45ef2fe2665ae1570e0f4b9ca" +checksum = "f557c32c6d268a07c921471619c0295f5efad3a0e76d4f97a05c091a51d110b2" dependencies = [ - "digest 0.10.7", + "proc-macro2 1.0.69", + "syn 1.0.109", + "synstructure", ] [[package]] -name = "memchr" -version = "2.5.0" +name = "parity-wasm" +version = "0.45.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" +checksum = "e1ad0aff30c1da14b1254fcb2af73e1fa9a28670e584a626f53a369d0e157304" [[package]] -name = "memfd" -version = "0.6.3" +name = "parking" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffc89ccdc6e10d6907450f753537ebc5c5d3460d2e4e62ea74bd571db62c0f9e" -dependencies = [ - "rustix 0.37.23", -] +checksum = "14f2252c834a40ed9bb5422029649578e63aa341ac401f74e719dd1afda8394e" [[package]] -name = "memmap2" -version = "0.5.10" +name = "parking_lot" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83faa42c0a078c393f6b29d5db232d8be22776a891f8f56e5284faee4a20b327" +checksum = "7d17b78036a60663b797adeaee46f5c9dfebb86948d1255007a1d6be0271ff99" dependencies = [ - "libc", + "instant", + "lock_api", + "parking_lot_core 0.8.6", ] [[package]] -name = "memoffset" -version = "0.6.5" +name = "parking_lot" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5aa361d4faea93603064a027415f07bd8e1d5c88c9fbf68bf56a285428fd79ce" +checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" dependencies = [ - "autocfg", + "lock_api", + "parking_lot_core 0.9.8", ] [[package]] -name = "memoffset" -version = "0.8.0" +name = "parking_lot_core" +version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d61c719bcfbcf5d62b3a09efa6088de8c54bc0bfcd3ea7ae39fcc186108b8de1" +checksum = "60a2cfe6f0ad2bfc16aefa463b497d5c7a5ecd44a23efa72aa342d90177356dc" dependencies = [ - "autocfg", + "cfg-if 1.0.0", + "instant", + "libc", + "redox_syscall 0.2.16", + "smallvec", + "winapi", ] [[package]] -name = "memoffset" -version = "0.9.0" +name = "parking_lot_core" +version = "0.9.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a634b1c61a95585bd15607c6ab0c4e5b226e695ff2800ba0cdccddf208c406c" +checksum = "93f00c865fe7cabf650081affecd3871070f26767e7b2070a3ffae14c654b447" dependencies = [ - "autocfg", + "cfg-if 1.0.0", + "libc", + "redox_syscall 0.3.5", + "smallvec", + "windows-targets 0.48.1", ] [[package]] -name = "memory-db" -version = "0.32.0" +name = "partial_sort" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "808b50db46293432a45e63bc15ea51e0ab4c0a1647b8eb114e31a3e698dd6fbe" +checksum = "7924d1d0ad836f665c9065e26d016c673ece3993f30d340068b16f282afc1156" + +[[package]] +name = "paste" +version = "1.0.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" + +[[package]] +name = "pbkdf2" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d95f5254224e617595d2cc3cc73ff0a5eaf2637519e25f03388154e9378b6ffa" dependencies = [ - "hash-db", + "crypto-mac 0.11.1", ] [[package]] -name = "merlin" -version = "2.0.1" +name = "pbkdf2" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e261cf0f8b3c42ded9f7d2bb59dea03aa52bc8a1cbc7482f9fc3fd1229d3b42" +checksum = "83a0692ec44e4cf1ef28ca317f14f8f07da2d95ec3fa01f86e4467b725e60917" dependencies = [ - "byteorder", - "keccak", - "rand_core 0.5.1", - "zeroize", + "digest 0.10.7", ] [[package]] -name = "merlin" -version = "3.0.0" +name = "pbkdf2" +version = "0.12.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58c38e2799fc0978b65dfff8023ec7843e2330bb462f19198840b34b6582397d" +checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" dependencies = [ - "byteorder", - "keccak", - "rand_core 0.6.4", - "zeroize", + "digest 0.10.7", ] [[package]] -name = "messages-relay" -version = "0.1.0" +name = "pem" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8835c273a76a90455d7344889b0964598e3316e2a79ede8e36f16bdcf2228b8" dependencies = [ - "async-std", - "async-trait", - "bp-messages", - "env_logger", - "finality-relay", - "futures", - "hex", - "log", - "num-traits", - "parking_lot 0.12.1", - "relay-utils", - "sp-arithmetic", + "base64 0.13.1", ] [[package]] -name = "mick-jaeger" -version = "0.1.8" +name = "pem-rfc7468" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69672161530e8aeca1d1400fbf3f1a1747ff60ea604265a4e906c2442df20532" +checksum = "24d159833a9105500e0398934e205e0773f0b27529557134ecfc51c27646adac" dependencies = [ - "futures", - "rand 0.8.5", - "thrift", + "base64ct", ] [[package]] -name = "millau-bridge-node" -version = "0.1.0" -dependencies = [ - "clap 4.4.8", - "frame-benchmarking", - "frame-benchmarking-cli", - "futures", - "jsonrpsee 0.16.2", - "millau-runtime", - "mmr-rpc", - "node-inspect", - "pallet-transaction-payment-rpc", - "sc-basic-authorship", - "sc-cli", - "sc-client-api", - "sc-consensus", - "sc-consensus-aura", - "sc-consensus-beefy", - "sc-consensus-beefy-rpc", - "sc-consensus-grandpa", - "sc-consensus-grandpa-rpc", - "sc-executor", - "sc-keystore", - "sc-network", - "sc-network-common", - "sc-offchain", - "sc-rpc", - "sc-service", - "sc-telemetry", - "sc-transaction-pool", - "sc-transaction-pool-api", - "serde_json", - "sp-consensus-aura", - "sp-consensus-beefy", - "sp-consensus-grandpa", - "sp-core", - "sp-runtime", - "sp-timestamp", - "substrate-build-script-utils", - "substrate-frame-rpc-system", +name = "percent-encoding" +version = "2.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" + +[[package]] +name = "petgraph" +version = "0.6.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4dd7d28ee937e54fe3080c91faa1c3a46c06de6252988a7f4592ba2310ef22a4" +dependencies = [ + "fixedbitset", + "indexmap 1.9.3", ] [[package]] -name = "millau-runtime" -version = "0.1.0" +name = "pin-project" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fda4ed1c6c173e3fc7a83629421152e01d7b1f9b7f65fb301e490e8cfc656422" dependencies = [ - "bp-header-chain", - "bp-messages", - "bp-millau", - "bp-parachains", - "bp-polkadot-core", - "bp-relayers", - "bp-rialto", - "bp-rialto-parachain", - "bp-runtime", - "bp-westend", - "bp-xcm-bridge-hub-router 0.1.0", - "bridge-runtime-common", - "env_logger", - "frame-benchmarking", - "frame-executive", - "frame-support", - "frame-system", - "frame-system-rpc-runtime-api", - "hex-literal", - "pallet-aura", - "pallet-authorship", - "pallet-balances", - "pallet-beefy", - "pallet-beefy-mmr", - "pallet-bridge-grandpa", - "pallet-bridge-messages", - "pallet-bridge-parachains", - "pallet-bridge-relayers", - "pallet-grandpa", - "pallet-mmr", - "pallet-offences", - "pallet-session", - "pallet-shift-session-manager", - "pallet-sudo", - "pallet-timestamp", - "pallet-transaction-payment", - "pallet-transaction-payment-rpc-runtime-api", - "pallet-utility", - "pallet-xcm", - "pallet-xcm-bridge-hub-router", - "parity-scale-codec", - "scale-info", - "sp-api", - "sp-block-builder", - "sp-consensus-aura", - "sp-consensus-beefy", - "sp-core", - "sp-inherents", - "sp-io", - "sp-offchain", - "sp-runtime", - "sp-session", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-transaction-pool", - "sp-version", - "staging-xcm", - "staging-xcm-builder", - "staging-xcm-executor", - "static_assertions", - "substrate-wasm-builder", + "pin-project-internal", ] [[package]] -name = "mime" -version = "0.3.17" +name = "pin-project-internal" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" +checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" +dependencies = [ + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 2.0.38", +] [[package]] -name = "minimal-lexical" -version = "0.2.1" +name = "pin-project-lite" +version = "0.1.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" +checksum = "257b64915a082f7811703966789728173279bdebb956b143dbcd23f6f970a777" [[package]] -name = "miniz_oxide" -version = "0.7.1" +name = "pin-project-lite" +version = "0.2.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" +checksum = "12cc1b0bf1727a77a54b6654e7b5f1af8604923edc8b81885f8ec92f9e3f0a05" + +[[package]] +name = "pin-utils" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" + +[[package]] +name = "pkcs8" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9eca2c590a5f85da82668fa685c09ce2888b9430e83299debf1f34b65fd4a4ba" dependencies = [ - "adler", + "der 0.6.1", + "spki 0.6.0", ] [[package]] -name = "mio" -version = "0.8.9" +name = "pkcs8" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dce281c5e46beae905d4de1870d8b1509a9142b62eedf18b443b011ca8343d0" +checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7" dependencies = [ - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.48.0", + "der 0.7.7", + "spki 0.7.2", ] [[package]] -name = "mixnet" -version = "0.7.0" +name = "pkg-config" +version = "0.3.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "daa3eb39495d8e2e2947a1d862852c90cc6a4a8845f8b41c8829cb9fcc047f4a" +checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" + +[[package]] +name = "platforms" +version = "3.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3d7ddaed09e0eb771a79ab0fd64609ba0afb0a8366421957936ad14cbd13630" + +[[package]] +name = "polkadot-core-primitives" +version = "1.0.0" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "arrayref", - "arrayvec 0.7.4", - "bitflags 1.3.2", - "blake2 0.10.6", - "c2-chacha", - "curve25519-dalek 4.0.0", - "either", - "hashlink", - "lioness", - "log", - "parking_lot 0.12.1", - "rand 0.8.5", - "rand_chacha 0.3.1", - "rand_distr", - "subtle 2.4.1", - "thiserror", - "zeroize", + "parity-scale-codec", + "scale-info", + "sp-core", + "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "mmr-gadget" -version = "4.0.0-dev" +name = "polkadot-parachain-primitives" +version = "1.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "futures", - "log", + "bounded-collections", + "derive_more", + "frame-support", "parity-scale-codec", - "sc-client-api", - "sc-offchain", - "sp-api", - "sp-blockchain", - "sp-consensus", - "sp-consensus-beefy", + "polkadot-core-primitives", + "scale-info", + "serde", "sp-core", - "sp-mmr-primitives", "sp-runtime", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "mmr-rpc" -version = "4.0.0-dev" +name = "polkadot-primitives" +version = "1.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "anyhow", - "jsonrpsee 0.16.2", + "bitvec", + "hex-literal", "parity-scale-codec", + "polkadot-core-primitives", + "polkadot-parachain-primitives", + "scale-info", "serde", "sp-api", - "sp-blockchain", + "sp-application-crypto", + "sp-arithmetic", + "sp-authority-discovery", + "sp-consensus-slots", "sp-core", - "sp-mmr-primitives", + "sp-inherents", + "sp-io", + "sp-keystore", "sp-runtime", + "sp-staking", + "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "mockall" -version = "0.11.4" +name = "polling" +version = "2.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c84490118f2ee2d74570d114f3d0493cbf02790df303d2707606c3e14e07c96" +checksum = "4b2d323e8ca7996b3e23126511a523f7e62924d93ecd5ae73b333815b0eb3dce" dependencies = [ + "autocfg", + "bitflags 1.3.2", "cfg-if 1.0.0", - "downcast", - "fragile", - "lazy_static", - "mockall_derive", - "predicates", - "predicates-tree", + "concurrent-queue", + "libc", + "log", + "pin-project-lite 0.2.12", + "windows-sys 0.48.0", ] [[package]] -name = "mockall_derive" -version = "0.11.4" +name = "poly1305" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22ce75669015c4f47b289fd4d4f56e894e4c96003ffdf3ac51313126f94c6cbb" +checksum = "048aeb476be11a4b6ca432ca569e375810de9294ae78f4774e78ea98a9246ede" dependencies = [ - "cfg-if 1.0.0", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", + "cpufeatures", + "opaque-debug 0.3.0", + "universal-hash 0.4.1", ] [[package]] -name = "multiaddr" -version = "0.17.1" +name = "polyval" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b36f567c7099511fa8612bbbb52dda2419ce0bdbacf31714e3a5ffdb766d3bd" +checksum = "8419d2b623c7c0896ff2d5d96e2cb4ede590fed28fcc34934f4c33c036e620a1" dependencies = [ - "arrayref", - "byteorder", - "data-encoding", - "log", - "multibase", - "multihash", - "percent-encoding", - "serde", - "static_assertions", - "unsigned-varint", - "url", + "cfg-if 1.0.0", + "cpufeatures", + "opaque-debug 0.3.0", + "universal-hash 0.4.1", ] [[package]] -name = "multibase" -version = "0.9.1" +name = "polyval" +version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b3539ec3c1f04ac9748a260728e855f261b4977f5c3406612c884564f329404" +checksum = "d52cff9d1d4dee5fe6d03729099f4a310a41179e0a10dbf542039873f2e826fb" dependencies = [ - "base-x", - "data-encoding", - "data-encoding-macro", + "cfg-if 1.0.0", + "cpufeatures", + "opaque-debug 0.3.0", + "universal-hash 0.5.1", ] [[package]] -name = "multihash" -version = "0.17.0" +name = "powerfmt" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "835d6ff01d610179fbce3de1694d007e500bf33a7f29689838941d6bf783ae40" +checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391" + +[[package]] +name = "ppv-lite86" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" + +[[package]] +name = "predicates" +version = "2.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59230a63c37f3e18569bdb90e4a89cbf5bf8b06fea0b84e65ea10cc4df47addd" dependencies = [ - "blake2b_simd", - "blake2s_simd", - "blake3", - "core2", - "digest 0.10.7", - "multihash-derive", - "sha2 0.10.7", - "sha3", - "unsigned-varint", + "difflib", + "float-cmp", + "itertools", + "normalize-line-endings", + "predicates-core", + "regex", ] [[package]] -name = "multihash-derive" -version = "0.8.0" +name = "predicates-core" +version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc076939022111618a5026d3be019fd8b366e76314538ff9a1b59ffbcbf98bcd" +checksum = "b794032607612e7abeb4db69adb4e33590fa6cf1149e95fd7cb00e634b92f174" + +[[package]] +name = "predicates-tree" +version = "1.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "368ba315fb8c5052ab692e68a0eefec6ec57b23a36959c14496f0b0df2c0cecf" dependencies = [ - "proc-macro-crate", - "proc-macro-error", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", - "synstructure", + "predicates-core", + "termtree", ] [[package]] -name = "multimap" -version = "0.8.3" +name = "prettyplease" +version = "0.1.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5ce46fe64a9d73be07dcbe690a38ce1b293be448fd8ce1e6c1b8062c9f72c6a" +checksum = "6c8646e95016a7a6c4adea95bafa8a16baab64b583356217f2c85db4a39d9a86" +dependencies = [ + "proc-macro2 1.0.69", + "syn 1.0.109", +] [[package]] -name = "multistream-select" +name = "primitive-types" version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8552ab875c1313b97b8d20cb857b9fd63e2d1d6a0a1b53ce9821e575405f27a" +checksum = "9f3486ccba82358b11a77516035647c34ba167dfa53312630de83b12bd4f3d66" dependencies = [ - "bytes", - "futures", - "log", - "pin-project", - "smallvec", - "unsigned-varint", + "fixed-hash", + "impl-codec", + "impl-rlp", + "impl-serde", + "scale-info", + "uint", ] [[package]] -name = "nalgebra" -version = "0.32.3" +name = "proc-macro-crate" +version = "1.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "307ed9b18cc2423f29e83f84fd23a8e73628727990181f18641a8b5dc2ab1caa" +checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" dependencies = [ - "approx", - "matrixmultiply", - "nalgebra-macros", - "num-complex", - "num-rational", - "num-traits", - "simba", - "typenum", + "once_cell", + "toml_edit", ] [[package]] -name = "nalgebra-macros" -version = "0.2.1" +name = "proc-macro-error" +version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91761aed67d03ad966ef783ae962ef9bbaca728d2dd7ceb7939ec110fffad998" +checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" dependencies = [ + "proc-macro-error-attr", "proc-macro2 1.0.69", "quote 1.0.33", "syn 1.0.109", + "version_check", ] [[package]] -name = "names" -version = "0.13.0" +name = "proc-macro-error-attr" +version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7d66043b25d4a6cccb23619d10c19c25304b355a7dccd4a8e11423dd2382146" +checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" dependencies = [ - "rand 0.8.5", + "proc-macro2 1.0.69", + "quote 1.0.33", + "version_check", ] [[package]] -name = "nanorand" -version = "0.7.0" +name = "proc-macro-hack" +version = "0.5.20+deprecated" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a51313c5820b0b02bd422f4b44776fbf47961755c74ce64afc73bfad10226c3" +checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" [[package]] -name = "netlink-packet-core" -version = "0.4.2" +name = "proc-macro-warning" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "345b8ab5bd4e71a2986663e88c56856699d060e78e152e6e9d7966fcd5491297" +checksum = "9b698b0b09d40e9b7c1a47b132d66a8b54bcd20583d9b6d06e4535e383b4405c" dependencies = [ - "anyhow", - "byteorder", - "libc", - "netlink-packet-utils", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 2.0.38", ] [[package]] -name = "netlink-packet-route" -version = "0.12.0" +name = "proc-macro2" +version = "0.4.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9ea4302b9759a7a88242299225ea3688e63c85ea136371bb6cf94fd674efaab" +checksum = "cf3d2011ab5c909338f7887f4fc896d35932e29146c12c8d01da6b22a80ba759" dependencies = [ - "anyhow", - "bitflags 1.3.2", - "byteorder", - "libc", - "netlink-packet-core", - "netlink-packet-utils", + "unicode-xid 0.1.0", ] [[package]] -name = "netlink-packet-utils" -version = "0.5.2" +name = "proc-macro2" +version = "1.0.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ede8a08c71ad5a95cdd0e4e52facd37190977039a4704eb82a283f713747d34" +checksum = "134c189feb4956b20f6f547d2cf727d4c0fe06722b20a0eec87ed445a97f92da" dependencies = [ - "anyhow", - "byteorder", - "paste", - "thiserror", + "unicode-ident", ] [[package]] -name = "netlink-proto" -version = "0.10.0" +name = "prometheus" +version = "0.13.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65b4b14489ab424703c092062176d52ba55485a89c076b4f9db05092b7223aa6" +checksum = "449811d15fbdf5ceb5c1144416066429cf82316e2ec8ce0c1f6f8a02e7bbcf8c" dependencies = [ - "bytes", - "futures", - "log", - "netlink-packet-core", - "netlink-sys", + "cfg-if 1.0.0", + "fnv", + "lazy_static", + "memchr", + "parking_lot 0.12.1", "thiserror", - "tokio", ] [[package]] -name = "netlink-sys" -version = "0.8.5" +name = "prometheus-client" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6471bf08e7ac0135876a9581bf3217ef0333c191c128d34878079f42ee150411" +checksum = "5d6fa99d535dd930d1249e6c79cb3c2915f9172a540fe2b02a4c8f9ca954721e" dependencies = [ - "bytes", - "futures", - "libc", - "log", - "tokio", + "dtoa", + "itoa", + "parking_lot 0.12.1", + "prometheus-client-derive-encode", ] [[package]] -name = "nix" -version = "0.24.3" +name = "prometheus-client-derive-encode" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa52e972a9a719cecb6864fb88568781eb706bac2cd1d4f04a648542dbf78069" +checksum = "72b6a5217beb0ad503ee7fa752d451c905113d70721b937126158f3106a48cc1" dependencies = [ - "bitflags 1.3.2", - "cfg-if 1.0.0", - "libc", - "memoffset 0.6.5", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", ] [[package]] -name = "no-std-net" -version = "0.6.0" +name = "prost" +version = "0.11.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43794a0ace135be66a25d3ae77d41b91615fb68ae937f904090203e81f755b65" +checksum = "0b82eaa1d779e9a4bc1c3217db8ffbeabaae1dca241bf70183242128d48681cd" +dependencies = [ + "bytes", + "prost-derive", +] [[package]] -name = "node-inspect" -version = "0.9.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "prost-build" +version = "0.11.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "119533552c9a7ffacc21e099c24a0ac8bb19c2a2a3f363de84cd9b844feab270" dependencies = [ - "clap 4.4.8", - "parity-scale-codec", - "sc-cli", - "sc-client-api", - "sc-service", - "sp-blockchain", - "sp-core", - "sp-runtime", - "thiserror", + "bytes", + "heck 0.4.1", + "itertools", + "lazy_static", + "log", + "multimap", + "petgraph", + "prettyplease", + "prost", + "prost-types", + "regex", + "syn 1.0.109", + "tempfile", + "which", ] [[package]] -name = "nodrop" -version = "0.1.14" +name = "prost-derive" +version = "0.11.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" +checksum = "e5d2d8d10f3c6ded6da8b05b5fb3b8a5082514344d56c9f871412d29b4e075b4" +dependencies = [ + "anyhow", + "itertools", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", +] [[package]] -name = "nohash-hasher" -version = "0.2.0" +name = "prost-types" +version = "0.11.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bf50223579dc7cdcfb3bfcacf7069ff68243f8c363f62ffa99cf000a6b9c451" +checksum = "213622a1460818959ac1181aaeb2dc9c7f63df720db7d788b3e24eacd1983e13" +dependencies = [ + "prost", +] [[package]] -name = "nom" -version = "7.1.3" +name = "psm" +version = "0.1.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d273983c5a657a70a3e8f2a01329822f3b8c8172b73826411a55751e404a0a4a" +checksum = "5787f7cda34e3033a72192c018bc5883100330f362ef279a8cbccfce8bb4e874" dependencies = [ - "memchr", - "minimal-lexical", + "cc", ] [[package]] -name = "normalize-line-endings" -version = "0.3.0" +name = "quick-error" +version = "1.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61807f77802ff30975e01f4f071c8ba10c022052f98b3294119f3e615d13e5be" +checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" [[package]] -name = "ntapi" -version = "0.4.1" +name = "quick-protobuf" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8a3895c6391c39d7fe7ebc444a87eb2991b2a0bc718fdabd071eec617fc68e4" +checksum = "9d6da84cc204722a989e01ba2f6e1e276e190f22263d0cb6ce8526fcdb0d2e1f" dependencies = [ - "winapi", + "byteorder", ] [[package]] -name = "num-bigint" -version = "0.4.3" +name = "quick-protobuf-codec" +version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f93ab6289c7b344a8a9f60f88d80aa20032336fe78da341afc91c8a2341fc75f" +checksum = "1693116345026436eb2f10b677806169c1a1260c1c60eaaffe3fb5a29ae23d8b" dependencies = [ - "autocfg", - "num-integer", - "num-traits", + "asynchronous-codec", + "bytes", + "quick-protobuf", + "thiserror", + "unsigned-varint", ] [[package]] -name = "num-complex" -version = "0.4.3" +name = "quicksink" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02e0d21255c828d6f128a1e41534206671e8c3ea0c62f32291e808dc82cff17d" +checksum = "77de3c815e5a160b1539c6592796801df2043ae35e123b46d73380cfa57af858" dependencies = [ - "num-traits", + "futures-core", + "futures-sink", + "pin-project-lite 0.1.12", ] [[package]] -name = "num-format" -version = "0.4.4" +name = "quinn-proto" +version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a652d9771a63711fd3c3deb670acfbe5c30a4072e664d7a3bf5a9e1056ac72c3" +checksum = "67c10f662eee9c94ddd7135043e544f3c82fa839a1e7b865911331961b53186c" dependencies = [ - "arrayvec 0.7.4", - "itoa", + "bytes", + "rand 0.8.5", + "ring 0.16.20", + "rustc-hash", + "rustls 0.20.8", + "slab", + "thiserror", + "tinyvec", + "tracing", + "webpki 0.22.2", ] [[package]] -name = "num-integer" -version = "0.1.45" +name = "quote" +version = "0.6.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" +checksum = "6ce23b6b870e8f94f81fb0a363d65d86675884b34a09043c81e5562f11c1f8e1" dependencies = [ - "autocfg", - "num-traits", + "proc-macro2 0.4.30", ] [[package]] -name = "num-rational" -version = "0.4.1" +name = "quote" +version = "1.0.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" +checksum = "5267fca4496028628a95160fc423a33e8b2e6af8a5302579e322e4b520293cae" dependencies = [ - "autocfg", - "num-bigint", - "num-integer", - "num-traits", + "proc-macro2 1.0.69", ] [[package]] -name = "num-traits" -version = "0.2.17" +name = "radium" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" -dependencies = [ - "autocfg", - "libm", -] +checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" [[package]] -name = "num_cpus" -version = "1.16.0" +name = "rand" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" +checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" dependencies = [ - "hermit-abi 0.3.2", + "getrandom 0.1.16", "libc", + "rand_chacha 0.2.2", + "rand_core 0.5.1", + "rand_hc", ] [[package]] -name = "num_threads" -version = "0.1.6" +name = "rand" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2819ce041d2ee131036f4fc9d6ae7ae125a3a40e97ba64d04fe799ad9dabbb44" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" dependencies = [ "libc", + "rand_chacha 0.3.1", + "rand_core 0.6.4", ] [[package]] -name = "number_prefix" -version = "0.4.0" +name = "rand_chacha" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b246a0e5f20af87141b25c173cd1b609bd7779a4617d6ec582abaf90870f3" +checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" +dependencies = [ + "ppv-lite86", + "rand_core 0.5.1", +] [[package]] -name = "object" -version = "0.30.4" +name = "rand_chacha" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03b4680b86d9cfafba8fc491dc9b6df26b68cf40e9e6cd73909194759a63c385" +checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" dependencies = [ - "crc32fast", - "hashbrown 0.13.2", - "indexmap 1.9.3", - "memchr", + "ppv-lite86", + "rand_core 0.6.4", ] [[package]] -name = "object" -version = "0.31.1" +name = "rand_core" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8bda667d9f2b5051b8833f59f3bf748b28ef54f850f4fcb389a252aa383866d1" +checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" dependencies = [ - "memchr", + "getrandom 0.1.16", ] [[package]] -name = "oid-registry" -version = "0.4.0" +name = "rand_core" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38e20717fa0541f39bd146692035c37bedfa532b3e5071b35761082407546b2a" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "asn1-rs 0.3.1", + "getrandom 0.2.10", ] [[package]] -name = "oid-registry" -version = "0.6.1" +name = "rand_distr" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9bedf36ffb6ba96c2eb7144ef6270557b52e54b20c0a8e1eb2ff99a6c6959bff" +checksum = "32cb0b9bc82b0a0876c2dd994a7e7a2683d3e7390ca40e6886785ef0c7e3ee31" dependencies = [ - "asn1-rs 0.5.2", + "num-traits", + "rand 0.8.5", ] [[package]] -name = "once_cell" -version = "1.18.0" +name = "rand_hc" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" +checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +dependencies = [ + "rand_core 0.5.1", +] [[package]] -name = "opaque-debug" -version = "0.2.3" +name = "rawpointer" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2839e79665f131bdb5782e51f2c6c9599c133c6098982a54c794358bf432529c" +checksum = "60a357793950651c4ed0f3f52338f53b2f809f32d83a07f72909fa13e4c6c1e3" [[package]] -name = "opaque-debug" -version = "0.3.0" +name = "rayon" +version = "1.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" +checksum = "1d2df5196e37bcc87abebc0053e20787d73847bb33134a69841207dd0a47f03b" +dependencies = [ + "either", + "rayon-core", +] [[package]] -name = "openssl-probe" -version = "0.1.5" +name = "rayon-core" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" +checksum = "4b8f95bd6966f5c87776639160a66bd8ab9895d9d4ab01ddba9fc60661aebe8d" +dependencies = [ + "crossbeam-channel", + "crossbeam-deque", + "crossbeam-utils", + "num_cpus", +] [[package]] -name = "openssl-sys" -version = "0.9.90" +name = "rbtag" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "374533b0e45f3a7ced10fcaeccca020e66656bc03dac384f852e4e5a7a8104a6" +checksum = "72c64936fcc0b811890a9d90020f3df5cec9c604efde88af7db6a35d365132a3" dependencies = [ - "cc", - "libc", - "pkg-config", - "vcpkg", + "rbtag_derive", ] [[package]] -name = "option-ext" -version = "0.2.0" +name = "rbtag_derive" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" +checksum = "b75511b710ccca8adbb211e04763bd8c78fed585b0ec188a20ed9b0dd95567c4" +dependencies = [ + "proc-macro2 0.4.30", + "quote 0.6.13", + "syn 0.15.44", +] [[package]] -name = "orchestra" -version = "0.3.3" +name = "rcgen" +version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46d78e1deb2a8d54fc1f063a544130db4da31dfe4d5d3b493186424910222a76" +checksum = "6413f3de1edee53342e6138e75b56d32e7bc6e332b3bd62d497b1929d4cfbcdd" dependencies = [ - "async-trait", - "dyn-clonable", - "futures", - "futures-timer", - "orchestra-proc-macro", - "pin-project", - "prioritized-metered-channel", - "thiserror", - "tracing", + "pem", + "ring 0.16.20", + "time 0.3.30", + "x509-parser 0.13.2", + "yasna", ] [[package]] -name = "orchestra-proc-macro" -version = "0.3.3" +name = "rcgen" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d035b1f968d91a826f2e34a9d6d02cb2af5aa7ca39ebd27922d850ab4b2dd2c6" +checksum = "ffbe84efe2f38dea12e9bfc1f65377fdf03e53a18cb3b995faedf7934c7e785b" dependencies = [ - "expander 2.0.0", - "indexmap 2.0.0", - "itertools 0.11.0", - "petgraph", - "proc-macro-crate", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", + "pem", + "ring 0.16.20", + "time 0.3.30", + "yasna", ] [[package]] -name = "ordered-float" -version = "1.1.1" +name = "redox_syscall" +version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3305af35278dd29f46fcdd139e0b1fbfae2153f0e5928b39b035542dd31e37b7" +checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" dependencies = [ - "num-traits", + "bitflags 1.3.2", ] [[package]] -name = "p256" -version = "0.11.1" +name = "redox_syscall" +version = "0.3.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51f44edd08f51e2ade572f141051021c5af22677e42b7dd28a88155151c33594" +checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" dependencies = [ - "ecdsa 0.14.8", - "elliptic-curve 0.12.3", - "sha2 0.10.7", + "bitflags 1.3.2", ] [[package]] -name = "p384" -version = "0.11.2" +name = "redox_syscall" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfc8c5bf642dde52bb9e87c0ecd8ca5a76faac2eeed98dedb7c717997e1080aa" +checksum = "4722d768eff46b75989dd134e5c353f0d6296e5aaa3132e776cbdb56be7731aa" dependencies = [ - "ecdsa 0.14.8", - "elliptic-curve 0.12.3", - "sha2 0.10.7", + "bitflags 1.3.2", ] [[package]] -name = "pallet-asset-rate" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "redox_users" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "getrandom 0.2.10", + "redox_syscall 0.2.16", + "thiserror", ] [[package]] -name = "pallet-aura" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "ref-cast" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1641819477c319ef452a075ac34a4be92eb9ba09f6841f62d594d50fdcf0bf6b" dependencies = [ - "frame-support", - "frame-system", - "log", - "pallet-timestamp", - "parity-scale-codec", - "scale-info", - "sp-application-crypto", - "sp-consensus-aura", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "ref-cast-impl", ] [[package]] -name = "pallet-authority-discovery" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "ref-cast-impl" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "68bf53dad9b6086826722cdc99140793afd9f62faa14a1ad07eb4f955e7a7216" dependencies = [ - "frame-support", - "frame-system", - "pallet-session", - "parity-scale-codec", - "scale-info", - "sp-application-crypto", - "sp-authority-discovery", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 2.0.38", ] [[package]] -name = "pallet-authorship" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "regalloc2" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "80535183cae11b149d618fbd3c37e38d7cda589d82d7769e196ca9a9042d7621" dependencies = [ - "frame-support", - "frame-system", - "impl-trait-for-tuples", - "parity-scale-codec", - "scale-info", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "fxhash", + "log", + "slice-group-by", + "smallvec", ] [[package]] -name = "pallet-babe" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "regex" +version = "1.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2eae68fc220f7cf2532e4494aded17545fce192d59cd996e0fe7887f4ceb575" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "pallet-authorship", - "pallet-session", - "pallet-timestamp", - "parity-scale-codec", - "scale-info", - "sp-application-crypto", - "sp-consensus-babe", - "sp-core", - "sp-io", - "sp-runtime", - "sp-session", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "aho-corasick", + "memchr", + "regex-automata 0.3.3", + "regex-syntax 0.7.4", ] [[package]] -name = "pallet-bags-list" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "regex-automata" +version = "0.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" dependencies = [ - "aquamarine", - "docify", - "frame-benchmarking", - "frame-election-provider-support", - "frame-support", - "frame-system", - "log", - "pallet-balances", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-tracing", + "regex-syntax 0.6.29", ] [[package]] -name = "pallet-balances" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "regex-automata" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "39354c10dd07468c2e73926b23bb9c2caca74c5501e38a35da70406f1d923310" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "aho-corasick", + "memchr", + "regex-syntax 0.7.4", ] [[package]] -name = "pallet-beefy" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-support", - "frame-system", - "log", - "pallet-authorship", - "pallet-session", - "parity-scale-codec", - "scale-info", - "serde", - "sp-consensus-beefy", - "sp-runtime", - "sp-session", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] +name = "regex-syntax" +version = "0.6.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" [[package]] -name = "pallet-beefy-mmr" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "regex-syntax" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5ea92a5b6195c6ef2a0295ea818b312502c6fc94dde986c5553242e18fd4ce2" + +[[package]] +name = "relay-bridge-hub-kusama-client" +version = "0.1.0" dependencies = [ - "array-bytes 6.1.0", - "binary-merkle-tree", - "frame-support", - "frame-system", - "log", - "pallet-beefy", - "pallet-mmr", - "pallet-session", + "bp-bridge-hub-kusama", + "bp-bridge-hub-polkadot", + "bp-header-chain", + "bp-messages", + "bp-parachains", + "bp-polkadot", + "bp-runtime", + "bridge-runtime-common", "parity-scale-codec", + "relay-substrate-client", "scale-info", - "serde", - "sp-api", - "sp-consensus-beefy", "sp-core", - "sp-io", "sp-runtime", - "sp-state-machine", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "pallet-bounties" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "relay-bridge-hub-polkadot-client" +version = "0.1.0" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "pallet-treasury", + "bp-bridge-hub-kusama", + "bp-bridge-hub-polkadot", + "bp-header-chain", + "bp-kusama", + "bp-messages", + "bp-parachains", + "bp-polkadot-bulletin", + "bp-polkadot-core", + "bp-runtime", + "bridge-runtime-common", "parity-scale-codec", + "relay-substrate-client", "scale-info", + "sp-consensus-grandpa", "sp-core", - "sp-io", "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] [[package]] -name = "pallet-bridge-beefy" +name = "relay-bridge-hub-rococo-client" version = "0.1.0" dependencies = [ - "bp-beefy", + "bp-bridge-hub-rococo", + "bp-bridge-hub-wococo", + "bp-header-chain", + "bp-messages", + "bp-parachains", + "bp-polkadot-core", "bp-runtime", - "bp-test-utils", - "ckb-merkle-mountain-range 0.3.2", - "frame-support", - "frame-system", - "log", - "pallet-beefy-mmr", - "pallet-mmr", + "bp-wococo", + "bridge-runtime-common", "parity-scale-codec", - "rand 0.8.5", + "relay-substrate-client", "scale-info", - "serde", - "sp-consensus-beefy", "sp-core", - "sp-io", "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-weights", + "subxt", ] [[package]] -name = "pallet-bridge-grandpa" +name = "relay-bridge-hub-westend-client" version = "0.1.0" dependencies = [ + "bp-bridge-hub-rococo", + "bp-bridge-hub-westend", "bp-header-chain", + "bp-messages", + "bp-parachains", + "bp-polkadot-core", + "bp-rococo", "bp-runtime", - "bp-test-utils", - "finality-grandpa", - "frame-benchmarking", - "frame-support", - "frame-system", - "log", + "bridge-runtime-common", "parity-scale-codec", + "relay-substrate-client", "scale-info", "sp-consensus-grandpa", "sp-core", - "sp-io", "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-trie", + "sp-weights", + "subxt", ] [[package]] -name = "pallet-bridge-messages" +name = "relay-bridge-hub-wococo-client" version = "0.1.0" dependencies = [ + "bp-bridge-hub-rococo", + "bp-bridge-hub-wococo", + "bp-header-chain", "bp-messages", + "bp-parachains", + "bp-polkadot-core", "bp-runtime", - "bp-test-utils", - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "num-traits", - "pallet-balances", + "bridge-runtime-common", "parity-scale-codec", + "relay-bridge-hub-rococo-client", + "relay-substrate-client", "scale-info", + "sp-consensus-grandpa", "sp-core", - "sp-io", "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-weights", + "subxt", ] [[package]] -name = "pallet-bridge-parachains" +name = "relay-kusama-client" version = "0.1.0" dependencies = [ - "bp-header-chain", - "bp-parachains", + "bp-kusama", "bp-polkadot-core", "bp-runtime", - "bp-test-utils", - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "pallet-bridge-grandpa", "parity-scale-codec", + "relay-substrate-client", + "relay-utils", "scale-info", + "sp-consensus-grandpa", "sp-core", - "sp-io", "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-trie", + "sp-session", + "sp-weights", + "subxt", ] [[package]] -name = "pallet-bridge-relayers" +name = "relay-polkadot-bulletin-client" version = "0.1.0" dependencies = [ + "bp-header-chain", "bp-messages", - "bp-relayers", + "bp-polkadot-bulletin", + "bp-polkadot-core", "bp-runtime", - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "pallet-balances", - "pallet-bridge-messages", + "bridge-runtime-common", "parity-scale-codec", + "relay-substrate-client", + "relay-utils", "scale-info", - "sp-arithmetic", + "sp-consensus-grandpa", "sp-core", - "sp-io", "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-session", + "sp-weights", + "subxt", ] [[package]] -name = "pallet-child-bounties" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "relay-polkadot-client" +version = "0.1.0" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "pallet-bounties", - "pallet-treasury", + "bp-polkadot", + "bp-polkadot-core", + "bp-runtime", "parity-scale-codec", + "relay-substrate-client", + "relay-utils", "scale-info", + "sp-consensus-grandpa", "sp-core", - "sp-io", "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-session", + "sp-weights", + "subxt", ] [[package]] -name = "pallet-collective" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "relay-rococo-client" +version = "0.1.0" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", + "bp-polkadot-core", + "bp-rococo", + "bp-runtime", "parity-scale-codec", + "relay-substrate-client", + "relay-utils", "scale-info", + "sp-consensus-grandpa", "sp-core", - "sp-io", "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-session", + "sp-weights", + "subxt", ] [[package]] -name = "pallet-conviction-voting" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "relay-substrate-client" +version = "0.1.0" dependencies = [ - "assert_matches", - "frame-benchmarking", + "async-std", + "async-trait", + "bp-header-chain", + "bp-messages", + "bp-polkadot-core", + "bp-runtime", + "finality-relay", "frame-support", "frame-system", + "futures", + "jsonrpsee 0.17.1", + "log", + "num-traits", + "pallet-balances", + "pallet-bridge-messages", + "pallet-transaction-payment", + "pallet-transaction-payment-rpc-runtime-api", + "pallet-utility", "parity-scale-codec", + "rand 0.8.5", + "relay-utils", + "sc-chain-spec", + "sc-rpc-api", + "sc-transaction-pool-api", "scale-info", - "serde", - "sp-io", + "sp-consensus-grandpa", + "sp-core", + "sp-rpc", "sp-runtime", "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-trie", + "sp-version", + "staging-xcm", + "thiserror", + "tokio", ] [[package]] -name = "pallet-democracy" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "relay-utils" +version = "0.1.0" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", + "ansi_term", + "anyhow", + "async-std", + "async-trait", + "backoff", + "bp-runtime", + "env_logger", + "futures", + "isahc", + "jsonpath_lib", "log", - "parity-scale-codec", - "scale-info", - "serde", - "sp-core", - "sp-io", + "num-traits", + "serde_json", "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "substrate-prometheus-endpoint", + "sysinfo", + "thiserror", + "time 0.3.30", + "tokio", ] [[package]] -name = "pallet-election-provider-multi-phase" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "relay-westend-client" +version = "0.1.0" dependencies = [ - "frame-benchmarking", - "frame-election-provider-support", - "frame-support", - "frame-system", - "log", - "pallet-election-provider-support-benchmarking", + "bp-polkadot-core", + "bp-runtime", + "bp-westend", "parity-scale-codec", - "rand 0.8.5", + "relay-substrate-client", + "relay-utils", "scale-info", - "sp-arithmetic", + "sp-consensus-grandpa", "sp-core", - "sp-io", - "sp-npos-elections", "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "strum 0.24.1", + "sp-session", + "sp-weights", + "subxt", ] [[package]] -name = "pallet-election-provider-support-benchmarking" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "relay-wococo-client" +version = "0.1.0" dependencies = [ - "frame-benchmarking", - "frame-election-provider-support", - "frame-system", + "bp-polkadot-core", + "bp-runtime", + "bp-wococo", "parity-scale-codec", - "sp-npos-elections", + "relay-rococo-client", + "relay-substrate-client", + "relay-utils", + "sp-core", "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "sp-session", ] [[package]] -name = "pallet-elections-phragmen" -version = "5.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "resolv-conf" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "52e44394d2086d010551b14b53b1f24e31647570cd1deb0379e2c21b329aba00" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-npos-elections", - "sp-runtime", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "hostname", + "quick-error", ] [[package]] -name = "pallet-fast-unstake" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rfc6979" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7743f17af12fa0b03b803ba12cd6a8d9483a587e89c69445e3909655c0b9fabb" dependencies = [ - "docify", - "frame-benchmarking", - "frame-election-provider-support", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-io", - "sp-runtime", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "crypto-bigint 0.4.9", + "hmac 0.12.1", + "zeroize", ] [[package]] -name = "pallet-grandpa" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rfc6979" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "pallet-authorship", - "pallet-session", - "parity-scale-codec", - "scale-info", - "sp-application-crypto", - "sp-consensus-grandpa", - "sp-core", - "sp-io", - "sp-runtime", - "sp-session", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "hmac 0.12.1", + "subtle 2.4.1", ] [[package]] -name = "pallet-identity" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "ring" +version = "0.1.0" +source = "git+https://github.com/w3f/ring-proof#edd1e90b847e560bf60fc2e8712235ccfa11a9a9" dependencies = [ - "enumflags2", - "frame-benchmarking", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "ark-ec", + "ark-ff", + "ark-poly", + "ark-serialize", + "ark-std", + "blake2 0.10.6", + "common", + "fflonk", + "merlin 3.0.0", ] [[package]] -name = "pallet-im-online" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "ring" +version = "0.16.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3053cf52e236a3ed746dfc745aa9cacf1b791d846bdaf412f60a8d7d6e17c8fc" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "pallet-authorship", - "parity-scale-codec", - "scale-info", - "sp-application-crypto", - "sp-core", - "sp-io", - "sp-runtime", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "cc", + "libc", + "once_cell", + "spin 0.5.2", + "untrusted", + "web-sys", + "winapi", ] [[package]] -name = "pallet-indices" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rlp" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bb919243f34364b6bd2fc10ef797edbfa75f33c252e7998527479c6d6b47e1ec" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-keyring", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "bytes", + "rustc-hex", ] [[package]] -name = "pallet-membership" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rtcp" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1919efd6d4a6a85d13388f9487549bb8e359f17198cc03ffd72f79b553873691" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "bytes", + "thiserror", + "webrtc-util", ] [[package]] -name = "pallet-message-queue" -version = "7.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rtnetlink" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "322c53fd76a18698f1c27381d58091de3a043d356aa5bd0d510608b565f469a0" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", + "futures", "log", - "parity-scale-codec", - "scale-info", - "sp-arithmetic", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-weights", + "netlink-packet-route", + "netlink-proto", + "nix", + "thiserror", + "tokio", ] [[package]] -name = "pallet-mmr" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rtp" +version = "0.6.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2a095411ff00eed7b12e4c6a118ba984d113e1079582570d56a5ee723f11f80" dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-mmr-primitives", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "async-trait", + "bytes", + "rand 0.8.5", + "serde", + "thiserror", + "webrtc-util", ] [[package]] -name = "pallet-multisig" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] +name = "rustc-demangle" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" [[package]] -name = "pallet-nis" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-arithmetic", - "sp-core", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] +name = "rustc-hash" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" [[package]] -name = "pallet-nomination-pools" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rustc-hex" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3e75f6a532d0fd9f7f13144f392b6ad56a32696bfcd9c78f797f16bbb6f072d6" + +[[package]] +name = "rustc_version" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" dependencies = [ - "frame-support", - "frame-system", - "log", - "pallet-balances", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-tracing", + "semver", ] [[package]] -name = "pallet-nomination-pools-benchmarking" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rusticata-macros" +version = "4.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "faf0c4a6ece9950b9abdb62b1cfcf2a68b3b67a10ba445b3bb85be2a293d0632" dependencies = [ - "frame-benchmarking", - "frame-election-provider-support", - "frame-support", - "frame-system", - "pallet-bags-list", - "pallet-nomination-pools", - "pallet-staking", - "parity-scale-codec", - "scale-info", - "sp-runtime", - "sp-runtime-interface", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "nom", ] [[package]] -name = "pallet-nomination-pools-runtime-api" -version = "1.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rustix" +version = "0.36.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c37f1bd5ef1b5422177b7646cba67430579cfe2ace80f284fee876bca52ad941" dependencies = [ - "pallet-nomination-pools", - "parity-scale-codec", - "sp-api", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", + "bitflags 1.3.2", + "errno", + "io-lifetimes", + "libc", + "linux-raw-sys 0.1.4", + "windows-sys 0.45.0", ] [[package]] -name = "pallet-offences" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rustix" +version = "0.37.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d69718bf81c6127a49dc64e44a742e8bb9213c0ff8869a22c308f84c1d4ab06" dependencies = [ - "frame-support", - "frame-system", - "log", - "pallet-balances", - "parity-scale-codec", - "scale-info", - "serde", - "sp-runtime", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-offences-benchmarking" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-election-provider-support", - "frame-support", - "frame-system", - "log", - "pallet-babe", - "pallet-balances", - "pallet-grandpa", - "pallet-im-online", - "pallet-offences", - "pallet-session", - "pallet-staking", - "parity-scale-codec", - "scale-info", - "sp-runtime", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-preimage" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-proxy" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-ranked-collective" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-arithmetic", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-recovery" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-referenda" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "assert_matches", - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "serde", - "sp-arithmetic", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-scheduler" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "docify", - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-weights", -] - -[[package]] -name = "pallet-session" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-support", - "frame-system", - "impl-trait-for-tuples", - "log", - "pallet-timestamp", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-session", - "sp-staking", - "sp-state-machine", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-trie", -] - -[[package]] -name = "pallet-session-benchmarking" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "pallet-session", - "pallet-staking", - "parity-scale-codec", - "rand 0.8.5", - "sp-runtime", - "sp-session", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-shift-session-manager" -version = "0.1.0" -dependencies = [ - "frame-support", - "frame-system", - "pallet-session", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-staking", - "sp-state-machine", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-society" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "rand_chacha 0.2.2", - "scale-info", - "sp-arithmetic", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-staking" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-election-provider-support", - "frame-support", - "frame-system", - "log", - "pallet-authorship", - "pallet-session", - "parity-scale-codec", - "rand_chacha 0.2.2", - "scale-info", - "serde", - "sp-application-crypto", - "sp-io", - "sp-runtime", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-staking-reward-curve" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "proc-macro-crate", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", -] - -[[package]] -name = "pallet-staking-reward-fn" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "log", - "sp-arithmetic", -] - -[[package]] -name = "pallet-staking-runtime-api" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "parity-scale-codec", - "sp-api", -] - -[[package]] -name = "pallet-state-trie-migration" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-sudo" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "docify", - "frame-benchmarking", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-timestamp" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "docify", - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-inherents", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-storage", - "sp-timestamp", -] - -[[package]] -name = "pallet-tips" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "pallet-treasury", - "parity-scale-codec", - "scale-info", - "serde", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-transaction-payment" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "serde", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-transaction-payment-rpc" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "jsonrpsee 0.16.2", - "pallet-transaction-payment-rpc-runtime-api", - "parity-scale-codec", - "sp-api", - "sp-blockchain", - "sp-core", - "sp-rpc", - "sp-runtime", - "sp-weights", -] - -[[package]] -name = "pallet-transaction-payment-rpc-runtime-api" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "pallet-transaction-payment", - "parity-scale-codec", - "sp-api", - "sp-runtime", - "sp-weights", -] - -[[package]] -name = "pallet-treasury" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "docify", - "frame-benchmarking", - "frame-support", - "frame-system", - "impl-trait-for-tuples", - "pallet-balances", - "parity-scale-codec", - "scale-info", - "serde", - "sp-core", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-utility" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-vesting" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-whitelist" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-api", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "pallet-xcm" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bounded-collections", - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "serde", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "staging-xcm", - "staging-xcm-executor", -] - -[[package]] -name = "pallet-xcm-benchmarks" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "staging-xcm", - "staging-xcm-builder", - "staging-xcm-executor", -] - -[[package]] -name = "pallet-xcm-bridge-hub-router" -version = "0.1.0" -dependencies = [ - "bp-xcm-bridge-hub-router 0.1.0", - "frame-benchmarking", - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "staging-xcm", - "staging-xcm-builder", -] - -[[package]] -name = "parachain-info" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "cumulus-primitives-core", - "frame-support", - "frame-system", - "parity-scale-codec", - "scale-info", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "parachains-relay" -version = "0.1.0" -dependencies = [ - "async-std", - "async-trait", - "bp-polkadot-core", - "futures", - "log", - "parity-scale-codec", - "relay-substrate-client", - "relay-utils", - "sp-core", -] - -[[package]] -name = "parity-db" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0dab3ac198341b2f0fec6e7f8a6eeed07a41201d98a124260611598c142e76df" -dependencies = [ - "blake2 0.10.6", - "crc32fast", - "fs2", - "hex", - "libc", - "log", - "lz4", - "memmap2", - "parking_lot 0.12.1", - "rand 0.8.5", - "siphasher", - "snap", -] - -[[package]] -name = "parity-scale-codec" -version = "3.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd8e946cc0cc711189c0b0249fb8b599cbeeab9784d83c415719368bb8d4ac64" -dependencies = [ - "arrayvec 0.7.4", - "bitvec", - "byte-slice-cast", - "bytes", - "impl-trait-for-tuples", - "parity-scale-codec-derive", - "serde", -] - -[[package]] -name = "parity-scale-codec-derive" -version = "3.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a296c3079b5fefbc499e1de58dc26c09b1b9a5952d26694ee89f04a43ebbb3e" -dependencies = [ - "proc-macro-crate", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", -] - -[[package]] -name = "parity-send-wrapper" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa9777aa91b8ad9dd5aaa04a9b6bcb02c7f1deb952fca5a66034d5e63afc5c6f" - -[[package]] -name = "parity-util-mem" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d32c34f4f5ca7f9196001c0aba5a1f9a5a12382c8944b8b0f90233282d1e8f8" -dependencies = [ - "cfg-if 1.0.0", - "ethereum-types", - "hashbrown 0.12.3", - "impl-trait-for-tuples", - "lru 0.8.1", - "parity-util-mem-derive", - "parking_lot 0.12.1", - "primitive-types", - "smallvec", - "winapi", -] - -[[package]] -name = "parity-util-mem-derive" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f557c32c6d268a07c921471619c0295f5efad3a0e76d4f97a05c091a51d110b2" -dependencies = [ - "proc-macro2 1.0.69", - "syn 1.0.109", - "synstructure", -] - -[[package]] -name = "parity-wasm" -version = "0.45.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1ad0aff30c1da14b1254fcb2af73e1fa9a28670e584a626f53a369d0e157304" - -[[package]] -name = "parking" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14f2252c834a40ed9bb5422029649578e63aa341ac401f74e719dd1afda8394e" - -[[package]] -name = "parking_lot" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d17b78036a60663b797adeaee46f5c9dfebb86948d1255007a1d6be0271ff99" -dependencies = [ - "instant", - "lock_api", - "parking_lot_core 0.8.6", -] - -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core 0.9.8", -] - -[[package]] -name = "parking_lot_core" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60a2cfe6f0ad2bfc16aefa463b497d5c7a5ecd44a23efa72aa342d90177356dc" -dependencies = [ - "cfg-if 1.0.0", - "instant", - "libc", - "redox_syscall 0.2.16", - "smallvec", - "winapi", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f00c865fe7cabf650081affecd3871070f26767e7b2070a3ffae14c654b447" -dependencies = [ - "cfg-if 1.0.0", - "libc", - "redox_syscall 0.3.5", - "smallvec", - "windows-targets 0.48.1", -] - -[[package]] -name = "partial_sort" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7924d1d0ad836f665c9065e26d016c673ece3993f30d340068b16f282afc1156" - -[[package]] -name = "paste" -version = "1.0.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" - -[[package]] -name = "pbkdf2" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d95f5254224e617595d2cc3cc73ff0a5eaf2637519e25f03388154e9378b6ffa" -dependencies = [ - "crypto-mac 0.11.1", -] - -[[package]] -name = "pbkdf2" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83a0692ec44e4cf1ef28ca317f14f8f07da2d95ec3fa01f86e4467b725e60917" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "pbkdf2" -version = "0.12.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "peeking_take_while" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19b17cddbe7ec3f8bc800887bab5e717348c95ea2ca0b1bf0837fb964dc67099" - -[[package]] -name = "pem" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8835c273a76a90455d7344889b0964598e3316e2a79ede8e36f16bdcf2228b8" -dependencies = [ - "base64 0.13.1", -] - -[[package]] -name = "pem-rfc7468" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24d159833a9105500e0398934e205e0773f0b27529557134ecfc51c27646adac" -dependencies = [ - "base64ct", -] - -[[package]] -name = "percent-encoding" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" - -[[package]] -name = "pest" -version = "2.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d2d1d55045829d65aad9d389139882ad623b33b904e7c9f1b10c5b8927298e5" -dependencies = [ - "thiserror", - "ucd-trie", -] - -[[package]] -name = "pest_derive" -version = "2.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f94bca7e7a599d89dea5dfa309e217e7906c3c007fb9c3299c40b10d6a315d3" -dependencies = [ - "pest", - "pest_generator", -] - -[[package]] -name = "pest_generator" -version = "2.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99d490fe7e8556575ff6911e45567ab95e71617f43781e5c05490dc8d75c965c" -dependencies = [ - "pest", - "pest_meta", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", -] - -[[package]] -name = "pest_meta" -version = "2.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2674c66ebb4b4d9036012091b537aae5878970d6999f81a265034d85b136b341" -dependencies = [ - "once_cell", - "pest", - "sha2 0.10.7", -] - -[[package]] -name = "petgraph" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dd7d28ee937e54fe3080c91faa1c3a46c06de6252988a7f4592ba2310ef22a4" -dependencies = [ - "fixedbitset", - "indexmap 1.9.3", -] - -[[package]] -name = "pin-project" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fda4ed1c6c173e3fc7a83629421152e01d7b1f9b7f65fb301e490e8cfc656422" -dependencies = [ - "pin-project-internal", -] - -[[package]] -name = "pin-project-internal" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" -dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", -] - -[[package]] -name = "pin-project-lite" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "257b64915a082f7811703966789728173279bdebb956b143dbcd23f6f970a777" - -[[package]] -name = "pin-project-lite" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12cc1b0bf1727a77a54b6654e7b5f1af8604923edc8b81885f8ec92f9e3f0a05" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkcs8" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9eca2c590a5f85da82668fa685c09ce2888b9430e83299debf1f34b65fd4a4ba" -dependencies = [ - "der 0.6.1", - "spki 0.6.0", -] - -[[package]] -name = "pkcs8" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7" -dependencies = [ - "der 0.7.7", - "spki 0.7.2", -] - -[[package]] -name = "pkg-config" -version = "0.3.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" - -[[package]] -name = "platforms" -version = "3.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3d7ddaed09e0eb771a79ab0fd64609ba0afb0a8366421957936ad14cbd13630" - -[[package]] -name = "polkadot-approval-distribution" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "futures-timer", - "polkadot-node-jaeger", - "polkadot-node-metrics", - "polkadot-node-network-protocol", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "rand 0.8.5", - "tracing-gum", -] - -[[package]] -name = "polkadot-availability-bitfield-distribution" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "always-assert", - "futures", - "futures-timer", - "polkadot-node-network-protocol", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "rand 0.8.5", - "tracing-gum", -] - -[[package]] -name = "polkadot-availability-distribution" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "derive_more", - "fatality", - "futures", - "parity-scale-codec", - "polkadot-erasure-coding", - "polkadot-node-network-protocol", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "rand 0.8.5", - "schnellru", - "sp-core", - "sp-keystore", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-availability-recovery" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "fatality", - "futures", - "parity-scale-codec", - "polkadot-erasure-coding", - "polkadot-node-network-protocol", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "rand 0.8.5", - "sc-network", - "schnellru", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-cli" -version = "1.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "clap 4.4.8", - "frame-benchmarking-cli", - "futures", - "log", - "polkadot-node-metrics", - "polkadot-node-primitives", - "polkadot-service", - "sc-cli", - "sc-executor", - "sc-service", - "sc-storage-monitor", - "sc-sysinfo", - "sc-tracing", - "sp-core", - "sp-io", - "sp-keyring", - "sp-maybe-compressed-blob", - "substrate-build-script-utils", - "thiserror", - "try-runtime-cli", -] - -[[package]] -name = "polkadot-collator-protocol" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bitvec", - "fatality", - "futures", - "futures-timer", - "polkadot-node-network-protocol", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "sp-core", - "sp-keystore", - "sp-runtime", - "thiserror", - "tokio-util", - "tracing-gum", -] - -[[package]] -name = "polkadot-core-primitives" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "polkadot-dispute-distribution" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "derive_more", - "fatality", - "futures", - "futures-timer", - "indexmap 1.9.3", - "parity-scale-codec", - "polkadot-erasure-coding", - "polkadot-node-network-protocol", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "sc-network", - "schnellru", - "sp-application-crypto", - "sp-keystore", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-erasure-coding" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "parity-scale-codec", - "polkadot-node-primitives", - "polkadot-primitives", - "reed-solomon-novelpoly", - "sp-core", - "sp-trie", - "thiserror", -] - -[[package]] -name = "polkadot-gossip-support" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "futures-timer", - "polkadot-node-network-protocol", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "rand 0.8.5", - "rand_chacha 0.3.1", - "sc-network", - "sc-network-common", - "sp-application-crypto", - "sp-core", - "sp-keystore", - "tracing-gum", -] - -[[package]] -name = "polkadot-network-bridge" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "always-assert", - "async-trait", - "bytes", - "fatality", - "futures", - "parity-scale-codec", - "parking_lot 0.12.1", - "polkadot-node-metrics", - "polkadot-node-network-protocol", - "polkadot-node-subsystem", - "polkadot-overseer", - "polkadot-primitives", - "sc-network", - "sp-consensus", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-collation-generation" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "parity-scale-codec", - "polkadot-erasure-coding", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "sp-core", - "sp-maybe-compressed-blob", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-approval-voting" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bitvec", - "derive_more", - "futures", - "futures-timer", - "kvdb", - "merlin 2.0.1", - "parity-scale-codec", - "polkadot-node-jaeger", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-overseer", - "polkadot-primitives", - "sc-keystore", - "schnellru", - "schnorrkel 0.9.1", - "sp-application-crypto", - "sp-consensus", - "sp-consensus-slots", - "sp-runtime", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-av-store" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bitvec", - "futures", - "futures-timer", - "kvdb", - "parity-scale-codec", - "polkadot-erasure-coding", - "polkadot-node-jaeger", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-overseer", - "polkadot-primitives", - "sp-consensus", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-backing" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bitvec", - "fatality", - "futures", - "polkadot-erasure-coding", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "polkadot-statement-table", - "sp-keystore", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-bitfield-signing" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "sp-keystore", - "thiserror", - "tracing-gum", - "wasm-timer", -] - -[[package]] -name = "polkadot-node-core-candidate-validation" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "futures", - "futures-timer", - "parity-scale-codec", - "polkadot-node-core-pvf", - "polkadot-node-metrics", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-overseer", - "polkadot-parachain-primitives", - "polkadot-primitives", - "sp-maybe-compressed-blob", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-chain-api" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "polkadot-node-metrics", - "polkadot-node-subsystem", - "polkadot-primitives", - "sc-client-api", - "sc-consensus-babe", - "sp-blockchain", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-chain-selection" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "futures-timer", - "kvdb", - "parity-scale-codec", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-dispute-coordinator" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "fatality", - "futures", - "kvdb", - "parity-scale-codec", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "sc-keystore", - "schnellru", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-parachains-inherent" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "futures", - "futures-timer", - "polkadot-node-subsystem", - "polkadot-overseer", - "polkadot-primitives", - "sp-blockchain", - "sp-inherents", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-prospective-parachains" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bitvec", - "fatality", - "futures", - "parity-scale-codec", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-provisioner" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bitvec", - "fatality", - "futures", - "futures-timer", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-pvf" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "always-assert", - "cfg-if 1.0.0", - "futures", - "futures-timer", - "libc", - "parity-scale-codec", - "pin-project", - "polkadot-core-primitives", - "polkadot-node-core-pvf-common", - "polkadot-node-metrics", - "polkadot-node-primitives", - "polkadot-parachain-primitives", - "polkadot-primitives", - "rand 0.8.5", - "slotmap", - "sp-core", - "sp-maybe-compressed-blob", - "sp-wasm-interface", - "substrate-build-script-utils", - "tempfile", - "tokio", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-pvf-checker" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-util", - "polkadot-overseer", - "polkadot-primitives", - "sp-keystore", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-pvf-common" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "cfg-if 1.0.0", - "cpu-time", - "futures", - "landlock", - "libc", - "parity-scale-codec", - "polkadot-parachain-primitives", - "polkadot-primitives", - "sc-executor", - "sc-executor-common", - "sc-executor-wasmtime", - "sp-core", - "sp-externalities", - "sp-io", - "sp-tracing", - "tokio", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-pvf-execute-worker" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "cpu-time", - "futures", - "parity-scale-codec", - "polkadot-node-core-pvf-common", - "polkadot-parachain-primitives", - "polkadot-primitives", - "rayon", - "sp-core", - "sp-maybe-compressed-blob", - "sp-tracing", - "tokio", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-pvf-prepare-worker" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "cfg-if 1.0.0", - "futures", - "libc", - "parity-scale-codec", - "polkadot-node-core-pvf-common", - "polkadot-parachain-primitives", - "polkadot-primitives", - "rayon", - "sc-executor", - "sc-executor-common", - "sc-executor-wasmtime", - "sp-io", - "sp-maybe-compressed-blob", - "sp-tracing", - "tikv-jemalloc-ctl", - "tokio", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-core-runtime-api" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "polkadot-node-metrics", - "polkadot-node-subsystem", - "polkadot-node-subsystem-types", - "polkadot-primitives", - "schnellru", - "sp-consensus-babe", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-jaeger" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "lazy_static", - "log", - "mick-jaeger", - "parity-scale-codec", - "parking_lot 0.12.1", - "polkadot-node-primitives", - "polkadot-primitives", - "sc-network", - "sp-core", - "thiserror", - "tokio", -] - -[[package]] -name = "polkadot-node-metrics" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bs58 0.5.0", - "futures", - "futures-timer", - "log", - "parity-scale-codec", - "polkadot-primitives", - "prioritized-metered-channel", - "sc-cli", - "sc-service", - "sc-tracing", - "substrate-prometheus-endpoint", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-network-protocol" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-channel", - "async-trait", - "bitvec", - "derive_more", - "fatality", - "futures", - "hex", - "parity-scale-codec", - "polkadot-node-jaeger", - "polkadot-node-primitives", - "polkadot-primitives", - "rand 0.8.5", - "sc-authority-discovery", - "sc-network", - "strum 0.24.1", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-node-primitives" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bounded-vec", - "futures", - "parity-scale-codec", - "polkadot-parachain-primitives", - "polkadot-primitives", - "schnorrkel 0.9.1", - "serde", - "sp-application-crypto", - "sp-consensus-babe", - "sp-core", - "sp-keystore", - "sp-maybe-compressed-blob", - "sp-runtime", - "thiserror", - "zstd 0.12.4", -] - -[[package]] -name = "polkadot-node-subsystem" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "polkadot-node-jaeger", - "polkadot-node-subsystem-types", - "polkadot-overseer", -] - -[[package]] -name = "polkadot-node-subsystem-types" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "derive_more", - "futures", - "orchestra", - "polkadot-node-jaeger", - "polkadot-node-network-protocol", - "polkadot-node-primitives", - "polkadot-primitives", - "polkadot-statement-table", - "sc-client-api", - "sc-network", - "sc-transaction-pool-api", - "smallvec", - "sp-api", - "sp-authority-discovery", - "sp-consensus-babe", - "substrate-prometheus-endpoint", - "thiserror", -] - -[[package]] -name = "polkadot-node-subsystem-util" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "derive_more", - "fatality", - "futures", - "futures-channel", - "itertools 0.10.5", - "kvdb", - "parity-db", - "parity-scale-codec", - "parking_lot 0.11.2", - "pin-project", - "polkadot-node-jaeger", - "polkadot-node-metrics", - "polkadot-node-network-protocol", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-types", - "polkadot-overseer", - "polkadot-primitives", - "prioritized-metered-channel", - "rand 0.8.5", - "sc-client-api", - "schnellru", - "sp-application-crypto", - "sp-core", - "sp-keystore", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-overseer" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "futures", - "futures-timer", - "orchestra", - "parking_lot 0.12.1", - "polkadot-node-metrics", - "polkadot-node-network-protocol", - "polkadot-node-primitives", - "polkadot-node-subsystem-types", - "polkadot-primitives", - "sc-client-api", - "schnellru", - "sp-api", - "sp-core", - "tikv-jemalloc-ctl", - "tracing-gum", -] - -[[package]] -name = "polkadot-parachain-primitives" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bounded-collections", - "derive_more", - "frame-support", - "parity-scale-codec", - "polkadot-core-primitives", - "scale-info", - "serde", - "sp-core", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "polkadot-primitives" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bitvec", - "hex-literal", - "parity-scale-codec", - "polkadot-core-primitives", - "polkadot-parachain-primitives", - "scale-info", - "serde", - "sp-api", - "sp-application-crypto", - "sp-arithmetic", - "sp-authority-discovery", - "sp-consensus-slots", - "sp-core", - "sp-inherents", - "sp-io", - "sp-keystore", - "sp-runtime", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "polkadot-rpc" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "jsonrpsee 0.16.2", - "mmr-rpc", - "pallet-transaction-payment-rpc", - "polkadot-primitives", - "sc-chain-spec", - "sc-client-api", - "sc-consensus-babe", - "sc-consensus-babe-rpc", - "sc-consensus-beefy", - "sc-consensus-beefy-rpc", - "sc-consensus-epochs", - "sc-consensus-grandpa", - "sc-consensus-grandpa-rpc", - "sc-rpc", - "sc-sync-state-rpc", - "sc-transaction-pool-api", - "sp-api", - "sp-block-builder", - "sp-blockchain", - "sp-consensus", - "sp-consensus-babe", - "sp-keystore", - "sp-runtime", - "substrate-frame-rpc-system", - "substrate-state-trie-migration-rpc", -] - -[[package]] -name = "polkadot-runtime-common" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bitvec", - "frame-benchmarking", - "frame-election-provider-support", - "frame-support", - "frame-system", - "impl-trait-for-tuples", - "libsecp256k1", - "log", - "pallet-asset-rate", - "pallet-authorship", - "pallet-babe", - "pallet-balances", - "pallet-election-provider-multi-phase", - "pallet-fast-unstake", - "pallet-session", - "pallet-staking", - "pallet-staking-reward-fn", - "pallet-timestamp", - "pallet-transaction-payment", - "pallet-treasury", - "pallet-vesting", - "parity-scale-codec", - "polkadot-primitives", - "polkadot-runtime-parachains", - "rustc-hex", - "scale-info", - "serde", - "serde_derive", - "slot-range-helper", - "sp-api", - "sp-core", - "sp-inherents", - "sp-io", - "sp-npos-elections", - "sp-runtime", - "sp-session", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "staging-xcm", - "staging-xcm-builder", - "static_assertions", -] - -[[package]] -name = "polkadot-runtime-metrics" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bs58 0.5.0", - "frame-benchmarking", - "parity-scale-codec", - "polkadot-primitives", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-tracing", -] - -[[package]] -name = "polkadot-runtime-parachains" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "bitflags 1.3.2", - "bitvec", - "derive_more", - "frame-benchmarking", - "frame-support", - "frame-system", - "impl-trait-for-tuples", - "log", - "pallet-authority-discovery", - "pallet-authorship", - "pallet-babe", - "pallet-balances", - "pallet-message-queue", - "pallet-session", - "pallet-staking", - "pallet-timestamp", - "pallet-vesting", - "parity-scale-codec", - "polkadot-core-primitives", - "polkadot-parachain-primitives", - "polkadot-primitives", - "polkadot-runtime-metrics", - "rand 0.8.5", - "rand_chacha 0.3.1", - "rustc-hex", - "scale-info", - "serde", - "sp-api", - "sp-application-crypto", - "sp-core", - "sp-inherents", - "sp-io", - "sp-keystore", - "sp-runtime", - "sp-session", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "staging-xcm", - "staging-xcm-executor", - "static_assertions", -] - -[[package]] -name = "polkadot-service" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "frame-benchmarking", - "frame-benchmarking-cli", - "frame-support", - "frame-system", - "frame-system-rpc-runtime-api", - "futures", - "hex-literal", - "is_executable", - "kvdb", - "kvdb-rocksdb", - "log", - "mmr-gadget", - "pallet-babe", - "pallet-im-online", - "pallet-staking", - "pallet-transaction-payment", - "pallet-transaction-payment-rpc-runtime-api", - "parity-db", - "parity-scale-codec", - "polkadot-approval-distribution", - "polkadot-availability-bitfield-distribution", - "polkadot-availability-distribution", - "polkadot-availability-recovery", - "polkadot-collator-protocol", - "polkadot-core-primitives", - "polkadot-dispute-distribution", - "polkadot-gossip-support", - "polkadot-network-bridge", - "polkadot-node-collation-generation", - "polkadot-node-core-approval-voting", - "polkadot-node-core-av-store", - "polkadot-node-core-backing", - "polkadot-node-core-bitfield-signing", - "polkadot-node-core-candidate-validation", - "polkadot-node-core-chain-api", - "polkadot-node-core-chain-selection", - "polkadot-node-core-dispute-coordinator", - "polkadot-node-core-parachains-inherent", - "polkadot-node-core-prospective-parachains", - "polkadot-node-core-provisioner", - "polkadot-node-core-pvf", - "polkadot-node-core-pvf-checker", - "polkadot-node-core-runtime-api", - "polkadot-node-network-protocol", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-types", - "polkadot-node-subsystem-util", - "polkadot-overseer", - "polkadot-parachain-primitives", - "polkadot-primitives", - "polkadot-rpc", - "polkadot-runtime-parachains", - "polkadot-statement-distribution", - "rococo-runtime", - "sc-authority-discovery", - "sc-basic-authorship", - "sc-block-builder", - "sc-chain-spec", - "sc-client-api", - "sc-client-db", - "sc-consensus", - "sc-consensus-babe", - "sc-consensus-beefy", - "sc-consensus-grandpa", - "sc-consensus-slots", - "sc-executor", - "sc-keystore", - "sc-network", - "sc-network-common", - "sc-network-sync", - "sc-offchain", - "sc-service", - "sc-sync-state-rpc", - "sc-sysinfo", - "sc-telemetry", - "sc-transaction-pool", - "sc-transaction-pool-api", - "schnellru", - "serde", - "serde_json", - "sp-api", - "sp-authority-discovery", - "sp-block-builder", - "sp-blockchain", - "sp-consensus", - "sp-consensus-babe", - "sp-consensus-beefy", - "sp-consensus-grandpa", - "sp-core", - "sp-inherents", - "sp-io", - "sp-keyring", - "sp-keystore", - "sp-mmr-primitives", - "sp-offchain", - "sp-runtime", - "sp-session", - "sp-state-machine", - "sp-storage", - "sp-timestamp", - "sp-transaction-pool", - "sp-version", - "sp-weights", - "substrate-prometheus-endpoint", - "thiserror", - "tracing-gum", - "westend-runtime", -] - -[[package]] -name = "polkadot-statement-distribution" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "arrayvec 0.7.4", - "bitvec", - "fatality", - "futures", - "futures-timer", - "indexmap 1.9.3", - "parity-scale-codec", - "polkadot-node-network-protocol", - "polkadot-node-primitives", - "polkadot-node-subsystem", - "polkadot-node-subsystem-types", - "polkadot-node-subsystem-util", - "polkadot-primitives", - "sp-keystore", - "sp-staking", - "thiserror", - "tracing-gum", -] - -[[package]] -name = "polkadot-statement-table" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "parity-scale-codec", - "polkadot-primitives", - "sp-core", -] - -[[package]] -name = "polling" -version = "2.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b2d323e8ca7996b3e23126511a523f7e62924d93ecd5ae73b333815b0eb3dce" -dependencies = [ - "autocfg", - "bitflags 1.3.2", - "cfg-if 1.0.0", - "concurrent-queue", - "libc", - "log", - "pin-project-lite 0.2.12", - "windows-sys 0.48.0", -] - -[[package]] -name = "poly1305" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "048aeb476be11a4b6ca432ca569e375810de9294ae78f4774e78ea98a9246ede" -dependencies = [ - "cpufeatures", - "opaque-debug 0.3.0", - "universal-hash 0.4.1", -] - -[[package]] -name = "poly1305" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8159bd90725d2df49889a078b54f4f79e87f1f8a8444194cdca81d38f5393abf" -dependencies = [ - "cpufeatures", - "opaque-debug 0.3.0", - "universal-hash 0.5.1", -] - -[[package]] -name = "polyval" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8419d2b623c7c0896ff2d5d96e2cb4ede590fed28fcc34934f4c33c036e620a1" -dependencies = [ - "cfg-if 1.0.0", - "cpufeatures", - "opaque-debug 0.3.0", - "universal-hash 0.4.1", -] - -[[package]] -name = "polyval" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d52cff9d1d4dee5fe6d03729099f4a310a41179e0a10dbf542039873f2e826fb" -dependencies = [ - "cfg-if 1.0.0", - "cpufeatures", - "opaque-debug 0.3.0", - "universal-hash 0.5.1", -] - -[[package]] -name = "portable-atomic" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "edc55135a600d700580e406b4de0d59cb9ad25e344a3a091a97ded2622ec4ec6" - -[[package]] -name = "powerfmt" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391" - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "predicates" -version = "2.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59230a63c37f3e18569bdb90e4a89cbf5bf8b06fea0b84e65ea10cc4df47addd" -dependencies = [ - "difflib", - "float-cmp", - "itertools 0.10.5", - "normalize-line-endings", - "predicates-core", - "regex", -] - -[[package]] -name = "predicates-core" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b794032607612e7abeb4db69adb4e33590fa6cf1149e95fd7cb00e634b92f174" - -[[package]] -name = "predicates-tree" -version = "1.0.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "368ba315fb8c5052ab692e68a0eefec6ec57b23a36959c14496f0b0df2c0cecf" -dependencies = [ - "predicates-core", - "termtree", -] - -[[package]] -name = "prettyplease" -version = "0.1.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c8646e95016a7a6c4adea95bafa8a16baab64b583356217f2c85db4a39d9a86" -dependencies = [ - "proc-macro2 1.0.69", - "syn 1.0.109", -] - -[[package]] -name = "prettyplease" -version = "0.2.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92139198957b410250d43fad93e630d956499a625c527eda65175c8680f83387" -dependencies = [ - "proc-macro2 1.0.69", - "syn 2.0.38", -] - -[[package]] -name = "primitive-types" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f3486ccba82358b11a77516035647c34ba167dfa53312630de83b12bd4f3d66" -dependencies = [ - "fixed-hash 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)", - "impl-codec", - "impl-rlp", - "impl-serde", - "scale-info", - "uint", -] - -[[package]] -name = "prioritized-metered-channel" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e99f0c89bd88f393aab44a4ab949351f7bc7e7e1179d11ecbfe50cbe4c47e342" -dependencies = [ - "coarsetime", - "crossbeam-queue", - "derive_more", - "futures", - "futures-timer", - "nanorand", - "thiserror", - "tracing", -] - -[[package]] -name = "proc-macro-crate" -version = "1.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" -dependencies = [ - "once_cell", - "toml_edit", -] - -[[package]] -name = "proc-macro-error" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" -dependencies = [ - "proc-macro-error-attr", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", - "version_check", -] - -[[package]] -name = "proc-macro-error-attr" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" -dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "version_check", -] - -[[package]] -name = "proc-macro-hack" -version = "0.5.20+deprecated" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" - -[[package]] -name = "proc-macro-warning" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b698b0b09d40e9b7c1a47b132d66a8b54bcd20583d9b6d06e4535e383b4405c" -dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", -] - -[[package]] -name = "proc-macro2" -version = "0.4.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf3d2011ab5c909338f7887f4fc896d35932e29146c12c8d01da6b22a80ba759" -dependencies = [ - "unicode-xid 0.1.0", -] - -[[package]] -name = "proc-macro2" -version = "1.0.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "134c189feb4956b20f6f547d2cf727d4c0fe06722b20a0eec87ed445a97f92da" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "prometheus" -version = "0.13.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "449811d15fbdf5ceb5c1144416066429cf82316e2ec8ce0c1f6f8a02e7bbcf8c" -dependencies = [ - "cfg-if 1.0.0", - "fnv", - "lazy_static", - "memchr", - "parking_lot 0.12.1", - "thiserror", -] - -[[package]] -name = "prometheus-client" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d6fa99d535dd930d1249e6c79cb3c2915f9172a540fe2b02a4c8f9ca954721e" -dependencies = [ - "dtoa", - "itoa", - "parking_lot 0.12.1", - "prometheus-client-derive-encode", -] - -[[package]] -name = "prometheus-client-derive-encode" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b6a5217beb0ad503ee7fa752d451c905113d70721b937126158f3106a48cc1" -dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", -] - -[[package]] -name = "prost" -version = "0.11.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b82eaa1d779e9a4bc1c3217db8ffbeabaae1dca241bf70183242128d48681cd" -dependencies = [ - "bytes", - "prost-derive", -] - -[[package]] -name = "prost-build" -version = "0.11.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "119533552c9a7ffacc21e099c24a0ac8bb19c2a2a3f363de84cd9b844feab270" -dependencies = [ - "bytes", - "heck 0.4.1", - "itertools 0.10.5", - "lazy_static", - "log", - "multimap", - "petgraph", - "prettyplease 0.1.25", - "prost", - "prost-types", - "regex", - "syn 1.0.109", - "tempfile", - "which", -] - -[[package]] -name = "prost-derive" -version = "0.11.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5d2d8d10f3c6ded6da8b05b5fb3b8a5082514344d56c9f871412d29b4e075b4" -dependencies = [ - "anyhow", - "itertools 0.10.5", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", -] - -[[package]] -name = "prost-types" -version = "0.11.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "213622a1460818959ac1181aaeb2dc9c7f63df720db7d788b3e24eacd1983e13" -dependencies = [ - "prost", -] - -[[package]] -name = "psm" -version = "0.1.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5787f7cda34e3033a72192c018bc5883100330f362ef279a8cbccfce8bb4e874" -dependencies = [ - "cc", -] - -[[package]] -name = "quick-error" -version = "1.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" - -[[package]] -name = "quick-protobuf" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d6da84cc204722a989e01ba2f6e1e276e190f22263d0cb6ce8526fcdb0d2e1f" -dependencies = [ - "byteorder", -] - -[[package]] -name = "quick-protobuf-codec" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1693116345026436eb2f10b677806169c1a1260c1c60eaaffe3fb5a29ae23d8b" -dependencies = [ - "asynchronous-codec", - "bytes", - "quick-protobuf", - "thiserror", - "unsigned-varint", -] - -[[package]] -name = "quicksink" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77de3c815e5a160b1539c6592796801df2043ae35e123b46d73380cfa57af858" -dependencies = [ - "futures-core", - "futures-sink", - "pin-project-lite 0.1.12", -] - -[[package]] -name = "quinn-proto" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67c10f662eee9c94ddd7135043e544f3c82fa839a1e7b865911331961b53186c" -dependencies = [ - "bytes", - "rand 0.8.5", - "ring 0.16.20", - "rustc-hash", - "rustls 0.20.8", - "slab", - "thiserror", - "tinyvec", - "tracing", - "webpki 0.22.2", -] - -[[package]] -name = "quote" -version = "0.6.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ce23b6b870e8f94f81fb0a363d65d86675884b34a09043c81e5562f11c1f8e1" -dependencies = [ - "proc-macro2 0.4.30", -] - -[[package]] -name = "quote" -version = "1.0.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5267fca4496028628a95160fc423a33e8b2e6af8a5302579e322e4b520293cae" -dependencies = [ - "proc-macro2 1.0.69", -] - -[[package]] -name = "radium" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.10", -] - -[[package]] -name = "rand_distr" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32cb0b9bc82b0a0876c2dd994a7e7a2683d3e7390ca40e6886785ef0c7e3ee31" -dependencies = [ - "num-traits", - "rand 0.8.5", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_pcg" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59cad018caf63deb318e5a4586d99a24424a364f40f1e5778c29aca23f4fc73e" -dependencies = [ - "rand_core 0.6.4", -] - -[[package]] -name = "rawpointer" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60a357793950651c4ed0f3f52338f53b2f809f32d83a07f72909fa13e4c6c1e3" - -[[package]] -name = "rayon" -version = "1.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d2df5196e37bcc87abebc0053e20787d73847bb33134a69841207dd0a47f03b" -dependencies = [ - "either", - "rayon-core", -] - -[[package]] -name = "rayon-core" -version = "1.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b8f95bd6966f5c87776639160a66bd8ab9895d9d4ab01ddba9fc60661aebe8d" -dependencies = [ - "crossbeam-channel", - "crossbeam-deque", - "crossbeam-utils", - "num_cpus", -] - -[[package]] -name = "rbtag" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72c64936fcc0b811890a9d90020f3df5cec9c604efde88af7db6a35d365132a3" -dependencies = [ - "rbtag_derive", -] - -[[package]] -name = "rbtag_derive" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b75511b710ccca8adbb211e04763bd8c78fed585b0ec188a20ed9b0dd95567c4" -dependencies = [ - "proc-macro2 0.4.30", - "quote 0.6.13", - "syn 0.15.44", -] - -[[package]] -name = "rcgen" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6413f3de1edee53342e6138e75b56d32e7bc6e332b3bd62d497b1929d4cfbcdd" -dependencies = [ - "pem", - "ring 0.16.20", - "time 0.3.30", - "x509-parser 0.13.2", - "yasna", -] - -[[package]] -name = "rcgen" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffbe84efe2f38dea12e9bfc1f65377fdf03e53a18cb3b995faedf7934c7e785b" -dependencies = [ - "pem", - "ring 0.16.20", - "time 0.3.30", - "yasna", -] - -[[package]] -name = "redox_syscall" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" -dependencies = [ - "bitflags 1.3.2", -] - -[[package]] -name = "redox_syscall" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" -dependencies = [ - "bitflags 1.3.2", -] - -[[package]] -name = "redox_syscall" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4722d768eff46b75989dd134e5c353f0d6296e5aaa3132e776cbdb56be7731aa" -dependencies = [ - "bitflags 1.3.2", -] - -[[package]] -name = "redox_users" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" -dependencies = [ - "getrandom 0.2.10", - "redox_syscall 0.2.16", - "thiserror", -] - -[[package]] -name = "reed-solomon-novelpoly" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3bd8f48b2066e9f69ab192797d66da804d1935bf22763204ed3675740cb0f221" -dependencies = [ - "derive_more", - "fs-err", - "itertools 0.10.5", - "static_init 0.5.2", - "thiserror", -] - -[[package]] -name = "ref-cast" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1641819477c319ef452a075ac34a4be92eb9ba09f6841f62d594d50fdcf0bf6b" -dependencies = [ - "ref-cast-impl", -] - -[[package]] -name = "ref-cast-impl" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68bf53dad9b6086826722cdc99140793afd9f62faa14a1ad07eb4f955e7a7216" -dependencies = [ - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", -] - -[[package]] -name = "regalloc2" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80535183cae11b149d618fbd3c37e38d7cda589d82d7769e196ca9a9042d7621" -dependencies = [ - "fxhash", - "log", - "slice-group-by", - "smallvec", -] - -[[package]] -name = "regex" -version = "1.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2eae68fc220f7cf2532e4494aded17545fce192d59cd996e0fe7887f4ceb575" -dependencies = [ - "aho-corasick", - "memchr", - "regex-automata 0.3.3", - "regex-syntax 0.7.4", -] - -[[package]] -name = "regex-automata" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" -dependencies = [ - "regex-syntax 0.6.29", -] - -[[package]] -name = "regex-automata" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39354c10dd07468c2e73926b23bb9c2caca74c5501e38a35da70406f1d923310" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax 0.7.4", -] - -[[package]] -name = "regex-syntax" -version = "0.6.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" - -[[package]] -name = "regex-syntax" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5ea92a5b6195c6ef2a0295ea818b312502c6fc94dde986c5553242e18fd4ce2" - -[[package]] -name = "relay-bridge-hub-kusama-client" -version = "0.1.0" -dependencies = [ - "bp-bridge-hub-kusama", - "bp-bridge-hub-polkadot", - "bp-header-chain", - "bp-messages", - "bp-parachains", - "bp-polkadot", - "bp-runtime", - "bridge-runtime-common", - "parity-scale-codec", - "relay-substrate-client", - "scale-info", - "sp-core", - "sp-runtime", -] - -[[package]] -name = "relay-bridge-hub-polkadot-client" -version = "0.1.0" -dependencies = [ - "bp-bridge-hub-kusama", - "bp-bridge-hub-polkadot", - "bp-header-chain", - "bp-kusama", - "bp-messages", - "bp-parachains", - "bp-polkadot-bulletin", - "bp-polkadot-core", - "bp-runtime", - "bridge-runtime-common", - "parity-scale-codec", - "relay-substrate-client", - "scale-info", - "sp-consensus-grandpa", - "sp-core", - "sp-runtime", -] - -[[package]] -name = "relay-bridge-hub-rococo-client" -version = "0.1.0" -dependencies = [ - "bp-bridge-hub-rococo", - "bp-bridge-hub-wococo", - "bp-header-chain", - "bp-messages", - "bp-parachains", - "bp-polkadot-core", - "bp-runtime", - "bp-wococo", - "bridge-runtime-common", - "parity-scale-codec", - "relay-substrate-client", - "scale-info", - "sp-core", - "sp-runtime", - "sp-weights", - "subxt", -] - -[[package]] -name = "relay-bridge-hub-westend-client" -version = "0.1.0" -dependencies = [ - "bp-bridge-hub-rococo", - "bp-bridge-hub-westend", - "bp-header-chain", - "bp-messages", - "bp-parachains", - "bp-polkadot-core", - "bp-rococo", - "bp-runtime", - "bridge-runtime-common", - "parity-scale-codec", - "relay-substrate-client", - "scale-info", - "sp-consensus-grandpa", - "sp-core", - "sp-runtime", - "sp-weights", - "subxt", -] - -[[package]] -name = "relay-bridge-hub-wococo-client" -version = "0.1.0" -dependencies = [ - "bp-bridge-hub-rococo", - "bp-bridge-hub-wococo", - "bp-header-chain", - "bp-messages", - "bp-parachains", - "bp-polkadot-core", - "bp-runtime", - "bridge-runtime-common", - "parity-scale-codec", - "relay-bridge-hub-rococo-client", - "relay-substrate-client", - "scale-info", - "sp-consensus-grandpa", - "sp-core", - "sp-runtime", - "sp-weights", - "subxt", -] - -[[package]] -name = "relay-kusama-client" -version = "0.1.0" -dependencies = [ - "bp-kusama", - "bp-polkadot-core", - "bp-runtime", - "parity-scale-codec", - "relay-substrate-client", - "relay-utils", - "scale-info", - "sp-consensus-grandpa", - "sp-core", - "sp-runtime", - "sp-session", - "sp-weights", - "subxt", -] - -[[package]] -name = "relay-millau-client" -version = "0.1.0" -dependencies = [ - "bp-messages", - "bp-millau", - "bp-runtime", - "frame-support", - "frame-system", - "millau-runtime", - "pallet-transaction-payment", - "parity-scale-codec", - "relay-substrate-client", - "relay-utils", - "sp-core", - "sp-runtime", - "sp-session", -] - -[[package]] -name = "relay-polkadot-bulletin-client" -version = "0.1.0" -dependencies = [ - "bp-header-chain", - "bp-messages", - "bp-polkadot-bulletin", - "bp-polkadot-core", - "bp-runtime", - "bridge-runtime-common", - "parity-scale-codec", - "relay-substrate-client", - "relay-utils", - "scale-info", - "sp-consensus-grandpa", - "sp-core", - "sp-runtime", - "sp-session", - "sp-weights", - "subxt", -] - -[[package]] -name = "relay-polkadot-client" -version = "0.1.0" -dependencies = [ - "bp-polkadot", - "bp-polkadot-core", - "bp-runtime", - "parity-scale-codec", - "relay-substrate-client", - "relay-utils", - "scale-info", - "sp-consensus-grandpa", - "sp-core", - "sp-runtime", - "sp-session", - "sp-weights", - "subxt", -] - -[[package]] -name = "relay-rialto-client" -version = "0.1.0" -dependencies = [ - "bp-messages", - "bp-rialto", - "bp-runtime", - "frame-support", - "frame-system", - "pallet-transaction-payment", - "parity-scale-codec", - "relay-substrate-client", - "relay-utils", - "rialto-runtime", - "sp-core", - "sp-runtime", - "sp-session", -] - -[[package]] -name = "relay-rialto-parachain-client" -version = "0.1.0" -dependencies = [ - "bp-bridge-hub-cumulus", - "bp-header-chain", - "bp-messages", - "bp-millau", - "bp-polkadot-core", - "bp-rialto-parachain", - "bp-runtime", - "bridge-runtime-common", - "parity-scale-codec", - "relay-substrate-client", - "scale-info", - "sp-core", - "sp-runtime", - "sp-weights", - "subxt", -] - -[[package]] -name = "relay-rococo-client" -version = "0.1.0" -dependencies = [ - "bp-polkadot-core", - "bp-rococo", - "bp-runtime", - "parity-scale-codec", - "relay-substrate-client", - "relay-utils", - "scale-info", - "sp-consensus-grandpa", - "sp-core", - "sp-runtime", - "sp-session", - "sp-weights", - "subxt", -] - -[[package]] -name = "relay-substrate-client" -version = "0.1.0" -dependencies = [ - "async-std", - "async-trait", - "bp-header-chain", - "bp-messages", - "bp-polkadot-core", - "bp-runtime", - "finality-relay", - "frame-support", - "frame-system", - "futures", - "jsonrpsee 0.17.1", - "log", - "num-traits", - "pallet-balances", - "pallet-bridge-messages", - "pallet-transaction-payment", - "pallet-transaction-payment-rpc-runtime-api", - "pallet-utility", - "parity-scale-codec", - "rand 0.8.5", - "relay-utils", - "sc-chain-spec", - "sc-rpc-api", - "sc-transaction-pool-api", - "scale-info", - "sp-consensus-grandpa", - "sp-core", - "sp-rpc", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-trie", - "sp-version", - "staging-xcm", - "thiserror", - "tokio", -] - -[[package]] -name = "relay-utils" -version = "0.1.0" -dependencies = [ - "ansi_term", - "anyhow", - "async-std", - "async-trait", - "backoff", - "bp-runtime", - "env_logger", - "futures", - "isahc", - "jsonpath_lib", - "log", - "num-traits", - "serde_json", - "sp-runtime", - "substrate-prometheus-endpoint", - "sysinfo", - "thiserror", - "time 0.3.30", - "tokio", -] - -[[package]] -name = "relay-westend-client" -version = "0.1.0" -dependencies = [ - "bp-polkadot-core", - "bp-runtime", - "bp-westend", - "parity-scale-codec", - "relay-substrate-client", - "relay-utils", - "scale-info", - "sp-consensus-grandpa", - "sp-core", - "sp-runtime", - "sp-session", - "sp-weights", - "subxt", -] - -[[package]] -name = "relay-wococo-client" -version = "0.1.0" -dependencies = [ - "bp-polkadot-core", - "bp-runtime", - "bp-wococo", - "parity-scale-codec", - "relay-rococo-client", - "relay-substrate-client", - "relay-utils", - "sp-core", - "sp-runtime", - "sp-session", -] - -[[package]] -name = "resolv-conf" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52e44394d2086d010551b14b53b1f24e31647570cd1deb0379e2c21b329aba00" -dependencies = [ - "hostname", - "quick-error", -] - -[[package]] -name = "rfc6979" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7743f17af12fa0b03b803ba12cd6a8d9483a587e89c69445e3909655c0b9fabb" -dependencies = [ - "crypto-bigint 0.4.9", - "hmac 0.12.1", - "zeroize", -] - -[[package]] -name = "rfc6979" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" -dependencies = [ - "hmac 0.12.1", - "subtle 2.4.1", -] - -[[package]] -name = "rialto-bridge-node" -version = "0.1.0" -dependencies = [ - "clap 4.4.8", - "frame-benchmarking", - "frame-benchmarking-cli", - "frame-support", - "node-inspect", - "polkadot-node-core-pvf", - "polkadot-node-core-pvf-common", - "polkadot-node-core-pvf-execute-worker", - "polkadot-node-core-pvf-prepare-worker", - "polkadot-primitives", - "polkadot-runtime-parachains", - "polkadot-service", - "rialto-runtime", - "sc-cli", - "sc-executor", - "sc-service", - "serde_json", - "sp-authority-discovery", - "sp-consensus-babe", - "sp-consensus-beefy", - "sp-consensus-grandpa", - "sp-core", - "sp-runtime", - "substrate-build-script-utils", -] - -[[package]] -name = "rialto-parachain-collator" -version = "0.1.0" -dependencies = [ - "clap 4.4.8", - "cumulus-client-cli", - "cumulus-client-consensus-aura", - "cumulus-client-consensus-common", - "cumulus-client-network", - "cumulus-client-service", - "cumulus-primitives-core", - "cumulus-primitives-parachain-inherent", - "cumulus-relay-chain-interface", - "frame-benchmarking", - "frame-benchmarking-cli", - "jsonrpsee 0.16.2", - "log", - "pallet-transaction-payment-rpc", - "parity-scale-codec", - "polkadot-cli", - "polkadot-primitives", - "polkadot-service", - "rialto-parachain-runtime", - "sc-basic-authorship", - "sc-chain-spec", - "sc-cli", - "sc-client-api", - "sc-consensus", - "sc-executor", - "sc-network", - "sc-network-sync", - "sc-rpc", - "sc-rpc-api", - "sc-service", - "sc-telemetry", - "sc-tracing", - "sc-transaction-pool", - "serde", - "sp-api", - "sp-block-builder", - "sp-consensus-aura", - "sp-core", - "sp-keystore", - "sp-offchain", - "sp-runtime", - "sp-session", - "sp-timestamp", - "sp-transaction-pool", - "substrate-build-script-utils", - "substrate-frame-rpc-system", - "substrate-prometheus-endpoint", -] - -[[package]] -name = "rialto-parachain-runtime" -version = "0.1.0" -dependencies = [ - "bp-header-chain", - "bp-messages", - "bp-millau", - "bp-polkadot-core", - "bp-relayers", - "bp-rialto-parachain", - "bp-runtime", - "bridge-runtime-common", - "cumulus-pallet-aura-ext", - "cumulus-pallet-dmp-queue", - "cumulus-pallet-parachain-system", - "cumulus-pallet-xcm", - "cumulus-pallet-xcmp-queue", - "cumulus-primitives-core", - "cumulus-primitives-timestamp", - "frame-benchmarking", - "frame-executive", - "frame-support", - "frame-system", - "frame-system-benchmarking", - "frame-system-rpc-runtime-api", - "hex-literal", - "pallet-aura", - "pallet-balances", - "pallet-bridge-grandpa", - "pallet-bridge-messages", - "pallet-bridge-relayers", - "pallet-sudo", - "pallet-timestamp", - "pallet-transaction-payment", - "pallet-transaction-payment-rpc-runtime-api", - "pallet-xcm", - "parachain-info", - "parity-scale-codec", - "polkadot-parachain-primitives", - "scale-info", - "sp-api", - "sp-block-builder", - "sp-consensus-aura", - "sp-core", - "sp-inherents", - "sp-io", - "sp-offchain", - "sp-runtime", - "sp-session", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-transaction-pool", - "sp-version", - "staging-xcm", - "staging-xcm-builder", - "staging-xcm-executor", - "static_assertions", - "substrate-wasm-builder", -] - -[[package]] -name = "rialto-runtime" -version = "0.1.0" -dependencies = [ - "bp-header-chain", - "bp-messages", - "bp-millau", - "bp-relayers", - "bp-rialto", - "bp-runtime", - "bridge-runtime-common", - "env_logger", - "frame-benchmarking", - "frame-executive", - "frame-support", - "frame-system", - "frame-system-rpc-runtime-api", - "pallet-authority-discovery", - "pallet-authorship", - "pallet-babe", - "pallet-balances", - "pallet-beefy", - "pallet-beefy-mmr", - "pallet-bridge-beefy", - "pallet-bridge-grandpa", - "pallet-bridge-messages", - "pallet-bridge-relayers", - "pallet-grandpa", - "pallet-message-queue", - "pallet-mmr", - "pallet-offences", - "pallet-session", - "pallet-shift-session-manager", - "pallet-sudo", - "pallet-timestamp", - "pallet-transaction-payment", - "pallet-transaction-payment-rpc-runtime-api", - "pallet-xcm", - "parity-scale-codec", - "polkadot-primitives", - "polkadot-runtime-common", - "polkadot-runtime-parachains", - "scale-info", - "sp-api", - "sp-authority-discovery", - "sp-block-builder", - "sp-consensus-babe", - "sp-consensus-beefy", - "sp-core", - "sp-inherents", - "sp-io", - "sp-offchain", - "sp-runtime", - "sp-session", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-transaction-pool", - "sp-version", - "staging-xcm", - "staging-xcm-builder", - "staging-xcm-executor", - "static_assertions", - "substrate-wasm-builder", -] - -[[package]] -name = "ring" -version = "0.1.0" -source = "git+https://github.com/w3f/ring-proof#edd1e90b847e560bf60fc2e8712235ccfa11a9a9" -dependencies = [ - "ark-ec", - "ark-ff", - "ark-poly", - "ark-serialize", - "ark-std", - "blake2 0.10.6", - "common", - "fflonk", - "merlin 3.0.0", -] - -[[package]] -name = "ring" -version = "0.16.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3053cf52e236a3ed746dfc745aa9cacf1b791d846bdaf412f60a8d7d6e17c8fc" -dependencies = [ - "cc", - "libc", - "once_cell", - "spin 0.5.2", - "untrusted", - "web-sys", - "winapi", -] - -[[package]] -name = "rlp" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb919243f34364b6bd2fc10ef797edbfa75f33c252e7998527479c6d6b47e1ec" -dependencies = [ - "bytes", - "rustc-hex", -] - -[[package]] -name = "rocksdb" -version = "0.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb6f170a4041d50a0ce04b0d2e14916d6ca863ea2e422689a5b694395d299ffe" -dependencies = [ - "libc", - "librocksdb-sys", -] - -[[package]] -name = "rococo-runtime" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "binary-merkle-tree", - "frame-benchmarking", - "frame-executive", - "frame-support", - "frame-system", - "frame-system-benchmarking", - "frame-system-rpc-runtime-api", - "frame-try-runtime", - "hex-literal", - "log", - "pallet-asset-rate", - "pallet-authority-discovery", - "pallet-authorship", - "pallet-babe", - "pallet-balances", - "pallet-beefy", - "pallet-beefy-mmr", - "pallet-bounties", - "pallet-child-bounties", - "pallet-collective", - "pallet-conviction-voting", - "pallet-democracy", - "pallet-elections-phragmen", - "pallet-grandpa", - "pallet-identity", - "pallet-im-online", - "pallet-indices", - "pallet-membership", - "pallet-message-queue", - "pallet-mmr", - "pallet-multisig", - "pallet-nis", - "pallet-offences", - "pallet-preimage", - "pallet-proxy", - "pallet-ranked-collective", - "pallet-recovery", - "pallet-referenda", - "pallet-scheduler", - "pallet-session", - "pallet-society", - "pallet-staking", - "pallet-state-trie-migration", - "pallet-sudo", - "pallet-timestamp", - "pallet-tips", - "pallet-transaction-payment", - "pallet-transaction-payment-rpc-runtime-api", - "pallet-treasury", - "pallet-utility", - "pallet-vesting", - "pallet-whitelist", - "pallet-xcm", - "pallet-xcm-benchmarks", - "parity-scale-codec", - "polkadot-parachain-primitives", - "polkadot-primitives", - "polkadot-runtime-common", - "polkadot-runtime-parachains", - "rococo-runtime-constants", - "scale-info", - "serde", - "serde_derive", - "smallvec", - "sp-api", - "sp-arithmetic", - "sp-authority-discovery", - "sp-block-builder", - "sp-consensus-babe", - "sp-consensus-beefy", - "sp-core", - "sp-genesis-builder", - "sp-inherents", - "sp-io", - "sp-mmr-primitives", - "sp-offchain", - "sp-runtime", - "sp-session", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-storage", - "sp-transaction-pool", - "sp-version", - "staging-xcm", - "staging-xcm-builder", - "staging-xcm-executor", - "static_assertions", - "substrate-wasm-builder", -] - -[[package]] -name = "rococo-runtime-constants" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-support", - "polkadot-primitives", - "polkadot-runtime-common", - "smallvec", - "sp-core", - "sp-runtime", - "sp-weights", -] - -[[package]] -name = "rpassword" -version = "7.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6678cf63ab3491898c0d021b493c94c9b221d91295294a2a5746eacbe5928322" -dependencies = [ - "libc", - "rtoolbox", - "winapi", -] - -[[package]] -name = "rtcp" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1919efd6d4a6a85d13388f9487549bb8e359f17198cc03ffd72f79b553873691" -dependencies = [ - "bytes", - "thiserror", - "webrtc-util", -] - -[[package]] -name = "rtnetlink" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "322c53fd76a18698f1c27381d58091de3a043d356aa5bd0d510608b565f469a0" -dependencies = [ - "futures", - "log", - "netlink-packet-route", - "netlink-proto", - "nix", - "thiserror", - "tokio", -] - -[[package]] -name = "rtoolbox" -version = "0.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "034e22c514f5c0cb8a10ff341b9b048b5ceb21591f31c8f44c43b960f9b3524a" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "rtp" -version = "0.6.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2a095411ff00eed7b12e4c6a118ba984d113e1079582570d56a5ee723f11f80" -dependencies = [ - "async-trait", - "bytes", - "rand 0.8.5", - "serde", - "thiserror", - "webrtc-util", -] - -[[package]] -name = "rustc-demangle" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" - -[[package]] -name = "rustc-hash" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" - -[[package]] -name = "rustc-hex" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e75f6a532d0fd9f7f13144f392b6ad56a32696bfcd9c78f797f16bbb6f072d6" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver 1.0.18", -] - -[[package]] -name = "rusticata-macros" -version = "4.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "faf0c4a6ece9950b9abdb62b1cfcf2a68b3b67a10ba445b3bb85be2a293d0632" -dependencies = [ - "nom", -] - -[[package]] -name = "rustix" -version = "0.36.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c37f1bd5ef1b5422177b7646cba67430579cfe2ace80f284fee876bca52ad941" -dependencies = [ - "bitflags 1.3.2", - "errno", - "io-lifetimes", - "libc", - "linux-raw-sys 0.1.4", - "windows-sys 0.45.0", -] - -[[package]] -name = "rustix" -version = "0.37.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d69718bf81c6127a49dc64e44a742e8bb9213c0ff8869a22c308f84c1d4ab06" -dependencies = [ - "bitflags 1.3.2", - "errno", - "io-lifetimes", - "libc", - "linux-raw-sys 0.3.8", - "windows-sys 0.48.0", -] - -[[package]] -name = "rustix" -version = "0.38.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b426b0506e5d50a7d8dafcf2e81471400deb602392c7dd110815afb4eaf02a3" -dependencies = [ - "bitflags 2.4.1", - "errno", - "libc", - "linux-raw-sys 0.4.10", - "windows-sys 0.48.0", -] - -[[package]] -name = "rustls" -version = "0.19.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35edb675feee39aec9c99fa5ff985081995a06d594114ae14cbe797ad7b7a6d7" -dependencies = [ - "base64 0.13.1", - "log", - "ring 0.16.20", - "sct 0.6.1", - "webpki 0.21.4", -] - -[[package]] -name = "rustls" -version = "0.20.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fff78fc74d175294f4e83b28343315ffcfb114b156f0185e9741cb5570f50e2f" -dependencies = [ - "log", - "ring 0.16.20", - "sct 0.7.0", - "webpki 0.22.2", -] - -[[package]] -name = "rustls" -version = "0.21.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79ea77c539259495ce8ca47f53e66ae0330a8819f67e23ac96ca02f50e7b7d36" -dependencies = [ - "log", - "ring 0.16.20", - "rustls-webpki", - "sct 0.7.0", -] - -[[package]] -name = "rustls-native-certs" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9aace74cb666635c918e9c12bc0d348266037aa8eb599b5cba565709a8dff00" -dependencies = [ - "openssl-probe", - "rustls-pemfile", - "schannel", - "security-framework", -] - -[[package]] -name = "rustls-pemfile" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2" -dependencies = [ - "base64 0.21.2", -] - -[[package]] -name = "rustls-webpki" -version = "0.101.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d93931baf2d282fff8d3a532bbfd7653f734643161b87e3e01e59a04439bf0d" -dependencies = [ - "ring 0.16.20", - "untrusted", -] - -[[package]] -name = "rustversion" -version = "1.0.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" - -[[package]] -name = "ruzstd" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3ffab8f9715a0d455df4bbb9d21e91135aab3cd3ca187af0cd0c3c3f868fdc" -dependencies = [ - "byteorder", - "thiserror-core", - "twox-hash", -] - -[[package]] -name = "rw-stream-sink" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26338f5e09bb721b85b135ea05af7767c90b52f6de4f087d4f4a3a9d64e7dc04" -dependencies = [ - "futures", - "pin-project", - "static_assertions", -] - -[[package]] -name = "ryu" -version = "1.0.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" - -[[package]] -name = "safe_arch" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f398075ce1e6a179b46f51bd88d0598b92b00d3551f1a2d4ac49e771b56ac354" -dependencies = [ - "bytemuck", -] - -[[package]] -name = "same-file" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "sc-allocator" -version = "4.1.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "log", - "sp-core", - "sp-wasm-interface", - "thiserror", -] - -[[package]] -name = "sc-authority-discovery" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "futures", - "futures-timer", - "ip_network", - "libp2p", - "log", - "multihash", - "parity-scale-codec", - "prost", - "prost-build", - "rand 0.8.5", - "sc-client-api", - "sc-network", - "sp-api", - "sp-authority-discovery", - "sp-blockchain", - "sp-core", - "sp-keystore", - "sp-runtime", - "substrate-prometheus-endpoint", - "thiserror", -] - -[[package]] -name = "sc-basic-authorship" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "futures-timer", - "log", - "parity-scale-codec", - "sc-block-builder", - "sc-client-api", - "sc-proposer-metrics", - "sc-telemetry", - "sc-transaction-pool-api", - "sp-api", - "sp-blockchain", - "sp-consensus", - "sp-core", - "sp-inherents", - "sp-runtime", - "substrate-prometheus-endpoint", -] - -[[package]] -name = "sc-block-builder" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "parity-scale-codec", - "sc-client-api", - "sp-api", - "sp-block-builder", - "sp-blockchain", - "sp-core", - "sp-inherents", - "sp-runtime", -] - -[[package]] -name = "sc-chain-spec" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "memmap2", - "sc-chain-spec-derive", - "sc-client-api", - "sc-executor", - "sc-network", - "sc-telemetry", - "serde", - "serde_json", - "sp-blockchain", - "sp-core", - "sp-runtime", - "sp-state-machine", -] - -[[package]] -name = "sc-chain-spec-derive" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "proc-macro-crate", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", -] - -[[package]] -name = "sc-cli" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "array-bytes 6.1.0", - "chrono", - "clap 4.4.8", - "fdlimit", - "futures", - "libp2p-identity", - "log", - "names", - "parity-scale-codec", - "rand 0.8.5", - "regex", - "rpassword", - "sc-client-api", - "sc-client-db", - "sc-keystore", - "sc-mixnet", - "sc-network", - "sc-service", - "sc-telemetry", - "sc-tracing", - "sc-utils", - "serde", - "serde_json", - "sp-blockchain", - "sp-core", - "sp-keyring", - "sp-keystore", - "sp-panic-handler", - "sp-runtime", - "sp-version", - "thiserror", - "tiny-bip39", - "tokio", -] - -[[package]] -name = "sc-client-api" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "fnv", - "futures", - "log", - "parity-scale-codec", - "parking_lot 0.12.1", - "sc-executor", - "sc-transaction-pool-api", - "sc-utils", - "sp-api", - "sp-blockchain", - "sp-consensus", - "sp-core", - "sp-database", - "sp-externalities", - "sp-runtime", - "sp-state-machine", - "sp-statement-store", - "sp-storage", - "sp-trie", - "substrate-prometheus-endpoint", -] - -[[package]] -name = "sc-client-db" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "hash-db", - "kvdb", - "kvdb-memorydb", - "kvdb-rocksdb", - "linked-hash-map", - "log", - "parity-db", - "parity-scale-codec", - "parking_lot 0.12.1", - "sc-client-api", - "sc-state-db", - "schnellru", - "sp-arithmetic", - "sp-blockchain", - "sp-core", - "sp-database", - "sp-runtime", - "sp-state-machine", - "sp-trie", -] - -[[package]] -name = "sc-consensus" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "futures", - "futures-timer", - "libp2p-identity", - "log", - "mockall", - "parking_lot 0.12.1", - "sc-client-api", - "sc-utils", - "serde", - "sp-api", - "sp-blockchain", - "sp-consensus", - "sp-core", - "sp-runtime", - "sp-state-machine", - "substrate-prometheus-endpoint", - "thiserror", -] - -[[package]] -name = "sc-consensus-aura" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "futures", - "log", - "parity-scale-codec", - "sc-block-builder", - "sc-client-api", - "sc-consensus", - "sc-consensus-slots", - "sc-telemetry", - "sp-api", - "sp-application-crypto", - "sp-block-builder", - "sp-blockchain", - "sp-consensus", - "sp-consensus-aura", - "sp-consensus-slots", - "sp-core", - "sp-inherents", - "sp-keystore", - "sp-runtime", - "substrate-prometheus-endpoint", - "thiserror", -] - -[[package]] -name = "sc-consensus-babe" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "fork-tree", - "futures", - "log", - "num-bigint", - "num-rational", - "num-traits", - "parity-scale-codec", - "parking_lot 0.12.1", - "sc-client-api", - "sc-consensus", - "sc-consensus-epochs", - "sc-consensus-slots", - "sc-telemetry", - "sc-transaction-pool-api", - "sp-api", - "sp-application-crypto", - "sp-block-builder", - "sp-blockchain", - "sp-consensus", - "sp-consensus-babe", - "sp-consensus-slots", - "sp-core", - "sp-inherents", - "sp-keystore", - "sp-runtime", - "substrate-prometheus-endpoint", - "thiserror", -] - -[[package]] -name = "sc-consensus-babe-rpc" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "jsonrpsee 0.16.2", - "sc-consensus-babe", - "sc-consensus-epochs", - "sc-rpc-api", - "serde", - "sp-api", - "sp-application-crypto", - "sp-blockchain", - "sp-consensus", - "sp-consensus-babe", - "sp-core", - "sp-keystore", - "sp-runtime", - "thiserror", -] - -[[package]] -name = "sc-consensus-beefy" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "array-bytes 6.1.0", - "async-channel", - "async-trait", - "fnv", - "futures", - "log", - "parity-scale-codec", - "parking_lot 0.12.1", - "sc-client-api", - "sc-consensus", - "sc-network", - "sc-network-gossip", - "sc-network-sync", - "sc-utils", - "sp-api", - "sp-application-crypto", - "sp-arithmetic", - "sp-blockchain", - "sp-consensus", - "sp-consensus-beefy", - "sp-core", - "sp-keystore", - "sp-mmr-primitives", - "sp-runtime", - "substrate-prometheus-endpoint", - "thiserror", - "wasm-timer", -] - -[[package]] -name = "sc-consensus-beefy-rpc" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "jsonrpsee 0.16.2", - "log", - "parity-scale-codec", - "parking_lot 0.12.1", - "sc-consensus-beefy", - "sc-rpc", - "serde", - "sp-consensus-beefy", - "sp-core", - "sp-runtime", - "thiserror", -] - -[[package]] -name = "sc-consensus-epochs" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "fork-tree", - "parity-scale-codec", - "sc-client-api", - "sc-consensus", - "sp-blockchain", - "sp-runtime", + "bitflags 1.3.2", + "errno", + "io-lifetimes", + "libc", + "linux-raw-sys 0.3.8", + "windows-sys 0.48.0", ] [[package]] -name = "sc-consensus-grandpa" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rustix" +version = "0.38.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b426b0506e5d50a7d8dafcf2e81471400deb602392c7dd110815afb4eaf02a3" dependencies = [ - "ahash 0.8.3", - "array-bytes 6.1.0", - "async-trait", - "dyn-clone", - "finality-grandpa", - "fork-tree", - "futures", - "futures-timer", - "log", - "parity-scale-codec", - "parking_lot 0.12.1", - "rand 0.8.5", - "sc-block-builder", - "sc-chain-spec", - "sc-client-api", - "sc-consensus", - "sc-network", - "sc-network-common", - "sc-network-gossip", - "sc-telemetry", - "sc-transaction-pool-api", - "sc-utils", - "serde_json", - "sp-api", - "sp-application-crypto", - "sp-arithmetic", - "sp-blockchain", - "sp-consensus", - "sp-consensus-grandpa", - "sp-core", - "sp-keystore", - "sp-runtime", - "substrate-prometheus-endpoint", - "thiserror", + "bitflags 2.4.1", + "errno", + "libc", + "linux-raw-sys 0.4.10", + "windows-sys 0.48.0", ] [[package]] -name = "sc-consensus-grandpa-rpc" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rustls" +version = "0.19.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35edb675feee39aec9c99fa5ff985081995a06d594114ae14cbe797ad7b7a6d7" dependencies = [ - "finality-grandpa", - "futures", - "jsonrpsee 0.16.2", + "base64 0.13.1", "log", - "parity-scale-codec", - "sc-client-api", - "sc-consensus-grandpa", - "sc-rpc", - "serde", - "sp-blockchain", - "sp-core", - "sp-runtime", - "thiserror", + "ring 0.16.20", + "sct 0.6.1", + "webpki 0.21.4", ] [[package]] -name = "sc-consensus-slots" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rustls" +version = "0.20.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fff78fc74d175294f4e83b28343315ffcfb114b156f0185e9741cb5570f50e2f" dependencies = [ - "async-trait", - "futures", - "futures-timer", "log", - "parity-scale-codec", - "sc-client-api", - "sc-consensus", - "sc-telemetry", - "sp-arithmetic", - "sp-blockchain", - "sp-consensus", - "sp-consensus-slots", - "sp-core", - "sp-inherents", - "sp-runtime", - "sp-state-machine", -] - -[[package]] -name = "sc-executor" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "parity-scale-codec", - "parking_lot 0.12.1", - "sc-executor-common", - "sc-executor-wasmtime", - "schnellru", - "sp-api", - "sp-core", - "sp-externalities", - "sp-io", - "sp-panic-handler", - "sp-runtime-interface", - "sp-trie", - "sp-version", - "sp-wasm-interface", - "tracing", -] - -[[package]] -name = "sc-executor-common" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "sc-allocator", - "sp-maybe-compressed-blob", - "sp-wasm-interface", - "thiserror", - "wasm-instrument", + "ring 0.16.20", + "sct 0.7.0", + "webpki 0.22.2", ] [[package]] -name = "sc-executor-wasmtime" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rustls" +version = "0.21.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79ea77c539259495ce8ca47f53e66ae0330a8819f67e23ac96ca02f50e7b7d36" dependencies = [ - "anyhow", - "cfg-if 1.0.0", - "libc", "log", - "rustix 0.36.15", - "sc-allocator", - "sc-executor-common", - "sp-runtime-interface", - "sp-wasm-interface", - "wasmtime", + "ring 0.16.20", + "rustls-webpki", + "sct 0.7.0", ] [[package]] -name = "sc-informant" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rustls-native-certs" +version = "0.6.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a9aace74cb666635c918e9c12bc0d348266037aa8eb599b5cba565709a8dff00" dependencies = [ - "ansi_term", - "futures", - "futures-timer", - "log", - "sc-client-api", - "sc-network", - "sc-network-common", - "sp-blockchain", - "sp-runtime", + "openssl-probe", + "rustls-pemfile", + "schannel", + "security-framework", ] [[package]] -name = "sc-keystore" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rustls-pemfile" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2" dependencies = [ - "array-bytes 6.1.0", - "parking_lot 0.12.1", - "serde_json", - "sp-application-crypto", - "sp-core", - "sp-keystore", - "thiserror", + "base64 0.21.2", ] [[package]] -name = "sc-mixnet" -version = "0.1.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rustls-webpki" +version = "0.101.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d93931baf2d282fff8d3a532bbfd7653f734643161b87e3e01e59a04439bf0d" dependencies = [ - "array-bytes 4.2.0", - "arrayvec 0.7.4", - "blake2 0.10.6", - "futures", - "futures-timer", - "libp2p-identity", - "log", - "mixnet", - "multiaddr", - "parity-scale-codec", - "parking_lot 0.12.1", - "sc-client-api", - "sc-network", - "sc-transaction-pool-api", - "sp-api", - "sp-consensus", - "sp-core", - "sp-keystore", - "sp-mixnet", - "sp-runtime", - "thiserror", + "ring 0.16.20", + "untrusted", ] [[package]] -name = "sc-network" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "array-bytes 6.1.0", - "async-channel", - "async-trait", - "asynchronous-codec", - "bytes", - "either", - "fnv", - "futures", - "futures-timer", - "ip_network", - "libp2p", - "linked_hash_set", - "log", - "mockall", - "parity-scale-codec", - "parking_lot 0.12.1", - "partial_sort", - "pin-project", - "rand 0.8.5", - "sc-client-api", - "sc-network-common", - "sc-utils", - "serde", - "serde_json", - "smallvec", - "sp-arithmetic", - "sp-blockchain", - "sp-core", - "sp-runtime", - "substrate-prometheus-endpoint", - "thiserror", - "unsigned-varint", - "wasm-timer", - "zeroize", +name = "rustversion" +version = "1.0.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" + +[[package]] +name = "ruzstd" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac3ffab8f9715a0d455df4bbb9d21e91135aab3cd3ca187af0cd0c3c3f868fdc" +dependencies = [ + "byteorder", + "thiserror-core", + "twox-hash", ] [[package]] -name = "sc-network-bitswap" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "rw-stream-sink" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26338f5e09bb721b85b135ea05af7767c90b52f6de4f087d4f4a3a9d64e7dc04" dependencies = [ - "async-channel", - "cid", "futures", - "libp2p-identity", - "log", - "prost", - "prost-build", - "sc-client-api", - "sc-network", - "sp-blockchain", - "sp-runtime", - "thiserror", - "unsigned-varint", + "pin-project", + "static_assertions", ] [[package]] -name = "sc-network-common" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "ryu" +version = "1.0.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" + +[[package]] +name = "safe_arch" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f398075ce1e6a179b46f51bd88d0598b92b00d3551f1a2d4ac49e771b56ac354" dependencies = [ - "async-trait", - "bitflags 1.3.2", - "futures", - "libp2p-identity", - "parity-scale-codec", - "prost-build", - "sc-consensus", - "sp-consensus", - "sp-consensus-grandpa", - "sp-runtime", + "bytemuck", ] [[package]] -name = "sc-network-gossip" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" dependencies = [ - "ahash 0.8.3", - "futures", - "futures-timer", - "libp2p", - "log", - "sc-network", - "sc-network-common", - "schnellru", - "sp-runtime", - "substrate-prometheus-endpoint", - "tracing", + "winapi-util", ] [[package]] -name = "sc-network-light" -version = "0.10.0-dev" +name = "sc-allocator" +version = "4.1.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "array-bytes 6.1.0", - "async-channel", - "futures", - "libp2p-identity", "log", - "parity-scale-codec", - "prost", - "prost-build", - "sc-client-api", - "sc-network", - "sp-blockchain", "sp-core", - "sp-runtime", + "sp-wasm-interface", "thiserror", ] [[package]] -name = "sc-network-sync" -version = "0.10.0-dev" +name = "sc-chain-spec" +version = "4.0.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "array-bytes 6.1.0", - "async-channel", - "async-trait", - "fork-tree", - "futures", - "futures-timer", - "libp2p", - "log", - "mockall", - "parity-scale-codec", - "prost", - "prost-build", + "memmap2", + "sc-chain-spec-derive", "sc-client-api", - "sc-consensus", + "sc-executor", "sc-network", - "sc-network-common", - "sc-utils", - "schnellru", - "smallvec", - "sp-arithmetic", + "sc-telemetry", + "serde", + "serde_json", "sp-blockchain", - "sp-consensus", - "sp-consensus-grandpa", "sp-core", "sp-runtime", - "substrate-prometheus-endpoint", - "thiserror", - "tokio-stream", + "sp-state-machine", ] [[package]] -name = "sc-network-transactions" -version = "0.10.0-dev" +name = "sc-chain-spec-derive" +version = "4.0.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "array-bytes 6.1.0", - "futures", - "libp2p", - "log", - "parity-scale-codec", - "sc-network", - "sc-network-common", - "sc-utils", - "sp-consensus", - "sp-runtime", - "substrate-prometheus-endpoint", + "proc-macro-crate", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 2.0.38", ] [[package]] -name = "sc-offchain" +name = "sc-client-api" version = "4.0.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "array-bytes 6.1.0", - "bytes", "fnv", "futures", - "futures-timer", - "hyper", - "hyper-rustls 0.24.1", - "libp2p", "log", - "num_cpus", - "once_cell", "parity-scale-codec", "parking_lot 0.12.1", - "rand 0.8.5", - "sc-client-api", - "sc-network", - "sc-network-common", + "sc-executor", "sc-transaction-pool-api", "sc-utils", "sp-api", + "sp-blockchain", + "sp-consensus", "sp-core", + "sp-database", "sp-externalities", - "sp-keystore", - "sp-offchain", "sp-runtime", - "threadpool", - "tracing", -] - -[[package]] -name = "sc-proposer-metrics" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "log", + "sp-state-machine", + "sp-statement-store", + "sp-storage", + "sp-trie", "substrate-prometheus-endpoint", ] [[package]] -name = "sc-rpc" -version = "4.0.0-dev" +name = "sc-consensus" +version = "0.10.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ + "async-trait", "futures", - "jsonrpsee 0.16.2", + "futures-timer", + "libp2p-identity", "log", - "parity-scale-codec", + "mockall", "parking_lot 0.12.1", - "sc-block-builder", - "sc-chain-spec", "sc-client-api", - "sc-mixnet", - "sc-rpc-api", - "sc-tracing", - "sc-transaction-pool-api", "sc-utils", - "serde_json", + "serde", "sp-api", "sp-blockchain", + "sp-consensus", "sp-core", - "sp-keystore", - "sp-offchain", - "sp-rpc", "sp-runtime", - "sp-session", - "sp-statement-store", - "sp-version", - "tokio", + "sp-state-machine", + "substrate-prometheus-endpoint", + "thiserror", ] [[package]] -name = "sc-rpc-api" +name = "sc-executor" version = "0.10.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "jsonrpsee 0.16.2", "parity-scale-codec", - "sc-chain-spec", - "sc-mixnet", - "sc-transaction-pool-api", - "scale-info", - "serde", - "serde_json", + "parking_lot 0.12.1", + "sc-executor-common", + "sc-executor-wasmtime", + "schnellru", + "sp-api", "sp-core", - "sp-rpc", - "sp-runtime", + "sp-externalities", + "sp-io", + "sp-panic-handler", + "sp-runtime-interface", + "sp-trie", "sp-version", + "sp-wasm-interface", + "tracing", +] + +[[package]] +name = "sc-executor-common" +version = "0.10.0-dev" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" +dependencies = [ + "sc-allocator", + "sp-maybe-compressed-blob", + "sp-wasm-interface", "thiserror", + "wasm-instrument", ] [[package]] -name = "sc-rpc-server" -version = "4.0.0-dev" +name = "sc-executor-wasmtime" +version = "0.10.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "http", - "jsonrpsee 0.16.2", + "anyhow", + "cfg-if 1.0.0", + "libc", "log", - "serde_json", - "substrate-prometheus-endpoint", - "tokio", - "tower", - "tower-http", + "rustix 0.36.15", + "sc-allocator", + "sc-executor-common", + "sp-runtime-interface", + "sp-wasm-interface", + "wasmtime", ] [[package]] -name = "sc-rpc-spec-v2" -version = "0.10.0-dev" +name = "sc-mixnet" +version = "0.1.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "array-bytes 6.1.0", - "futures", - "futures-util", - "hex", - "jsonrpsee 0.16.2", + "array-bytes 4.2.0", + "arrayvec 0.7.4", + "blake2 0.10.6", + "futures", + "futures-timer", + "libp2p-identity", "log", + "mixnet", + "multiaddr", "parity-scale-codec", "parking_lot 0.12.1", - "sc-chain-spec", "sc-client-api", + "sc-network", "sc-transaction-pool-api", - "sc-utils", - "serde", "sp-api", - "sp-blockchain", + "sp-consensus", "sp-core", + "sp-keystore", + "sp-mixnet", "sp-runtime", - "sp-version", "thiserror", - "tokio", - "tokio-stream", ] [[package]] -name = "sc-service" +name = "sc-network" version = "0.10.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ + "array-bytes 6.1.0", + "async-channel", "async-trait", - "directories", - "exit-future", + "asynchronous-codec", + "bytes", + "either", + "fnv", "futures", "futures-timer", - "jsonrpsee 0.16.2", + "ip_network", + "libp2p", + "linked_hash_set", "log", + "mockall", "parity-scale-codec", "parking_lot 0.12.1", + "partial_sort", "pin-project", "rand 0.8.5", - "sc-block-builder", - "sc-chain-spec", "sc-client-api", - "sc-client-db", - "sc-consensus", - "sc-executor", - "sc-informant", - "sc-keystore", - "sc-network", - "sc-network-bitswap", "sc-network-common", - "sc-network-light", - "sc-network-sync", - "sc-network-transactions", - "sc-rpc", - "sc-rpc-server", - "sc-rpc-spec-v2", - "sc-sysinfo", - "sc-telemetry", - "sc-tracing", - "sc-transaction-pool", - "sc-transaction-pool-api", "sc-utils", "serde", "serde_json", - "sp-api", + "smallvec", + "sp-arithmetic", "sp-blockchain", - "sp-consensus", "sp-core", - "sp-externalities", - "sp-keystore", "sp-runtime", - "sp-session", - "sp-state-machine", - "sp-storage", - "sp-transaction-pool", - "sp-transaction-storage-proof", - "sp-trie", - "sp-version", - "static_init 1.0.3", "substrate-prometheus-endpoint", - "tempfile", "thiserror", - "tokio", - "tracing", - "tracing-futures", + "unsigned-varint", + "wasm-timer", + "zeroize", ] [[package]] -name = "sc-state-db" +name = "sc-network-common" version = "0.10.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ - "log", + "async-trait", + "bitflags 1.3.2", + "futures", + "libp2p-identity", "parity-scale-codec", - "parking_lot 0.12.1", - "sp-core", -] - -[[package]] -name = "sc-storage-monitor" -version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "clap 4.4.8", - "fs4", - "log", - "sc-client-db", - "sp-core", - "thiserror", - "tokio", + "prost-build", + "sc-consensus", + "sp-consensus", + "sp-consensus-grandpa", + "sp-runtime", ] [[package]] -name = "sc-sync-state-rpc" +name = "sc-rpc-api" version = "0.10.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" dependencies = [ "jsonrpsee 0.16.2", "parity-scale-codec", "sc-chain-spec", - "sc-client-api", - "sc-consensus-babe", - "sc-consensus-epochs", - "sc-consensus-grandpa", + "sc-mixnet", + "sc-transaction-pool-api", + "scale-info", "serde", "serde_json", - "sp-blockchain", + "sp-core", + "sp-rpc", "sp-runtime", + "sp-version", "thiserror", ] -[[package]] -name = "sc-sysinfo" -version = "6.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "futures", - "libc", - "log", - "rand 0.8.5", - "rand_pcg", - "regex", - "sc-telemetry", - "serde", - "serde_json", - "sp-core", - "sp-io", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - [[package]] name = "sc-telemetry" version = "4.0.0-dev" @@ -12652,72 +7677,6 @@ dependencies = [ "wasm-timer", ] -[[package]] -name = "sc-tracing" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "ansi_term", - "atty", - "chrono", - "lazy_static", - "libc", - "log", - "parking_lot 0.12.1", - "regex", - "rustc-hash", - "sc-client-api", - "sc-tracing-proc-macro", - "serde", - "sp-api", - "sp-blockchain", - "sp-core", - "sp-rpc", - "sp-runtime", - "sp-tracing", - "thiserror", - "tracing", - "tracing-log", - "tracing-subscriber", -] - -[[package]] -name = "sc-tracing-proc-macro" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "proc-macro-crate", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", -] - -[[package]] -name = "sc-transaction-pool" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "futures", - "futures-timer", - "linked-hash-map", - "log", - "parity-scale-codec", - "parking_lot 0.12.1", - "sc-client-api", - "sc-transaction-pool-api", - "sc-utils", - "serde", - "sp-api", - "sp-blockchain", - "sp-core", - "sp-runtime", - "sp-tracing", - "sp-transaction-pool", - "substrate-prometheus-endpoint", - "thiserror", -] - [[package]] name = "sc-transaction-pool-api" version = "4.0.0-dev" @@ -12922,12 +7881,6 @@ version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" -[[package]] -name = "scratch" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3cf7c11c38cb994f3d40e8a8cde3bbd1f72a435e4c49e85d6553d8312306152" - [[package]] name = "sct" version = "0.6.1" @@ -13038,29 +7991,11 @@ dependencies = [ "libc", ] -[[package]] -name = "semver" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a3186ec9e65071a2095434b1f5bb24838d4e8e130f584c790f6033c79943537" -dependencies = [ - "semver-parser", -] - [[package]] name = "semver" version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b0293b4b29daaf487284529cc2f5675b8e57c61f70167ba415a463651fd6a918" -dependencies = [ - "serde", -] - -[[package]] -name = "semver-parser" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3" [[package]] name = "serde" @@ -13182,12 +8117,6 @@ dependencies = [ "lazy_static", ] -[[package]] -name = "shlex" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43b2853a4d09f215c24cc5489c992ce46052d359b5109343cbafbf26bc62f8a3" - [[package]] name = "signal-hook" version = "0.3.17" @@ -13273,27 +8202,6 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "826167069c09b99d56f31e9ae5c99049e932a98c9dc2dac47645b08dbbf76ba7" -[[package]] -name = "slot-range-helper" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "enumn", - "parity-scale-codec", - "paste", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "slotmap" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1e08e261d0e8f5c43123b7adf3e4ca1690d655377ac93a03b2c9d3e98de1342" -dependencies = [ - "version_check", -] - [[package]] name = "sluice" version = "0.5.5" @@ -13321,91 +8229,38 @@ dependencies = [ "async-executor", "async-fs", "async-io", - "async-lock", - "async-net", - "async-process", - "blocking", - "futures-lite", -] - -[[package]] -name = "smoldot" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cce5e2881b30bad7ef89f383a816ad0b22c45915911f28499026de4a76d20ee" -dependencies = [ - "arrayvec 0.7.4", - "async-lock", - "atomic", - "base64 0.21.2", - "bip39", - "blake2-rfc", - "bs58 0.5.0", - "crossbeam-queue", - "derive_more", - "ed25519-zebra 3.1.0", - "either", - "event-listener", - "fnv", - "futures-channel", - "futures-util", - "hashbrown 0.14.0", - "hex", - "hmac 0.12.1", - "itertools 0.10.5", - "libsecp256k1", - "merlin 3.0.0", - "no-std-net", - "nom", - "num-bigint", - "num-rational", - "num-traits", - "pbkdf2 0.12.2", - "pin-project", - "rand 0.8.5", - "rand_chacha 0.3.1", - "ruzstd", - "schnorrkel 0.10.2", - "serde", - "serde_json", - "sha2 0.10.7", - "siphasher", - "slab", - "smallvec", - "smol", - "snow", - "soketto", - "tiny-keccak", - "twox-hash", - "wasmi 0.30.0", + "async-lock", + "async-net", + "async-process", + "blocking", + "futures-lite", ] [[package]] name = "smoldot" -version = "0.11.0" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0bb30cf57b7b5f6109ce17c3164445e2d6f270af2cb48f6e4d31c2967c9a9f5" +checksum = "1cce5e2881b30bad7ef89f383a816ad0b22c45915911f28499026de4a76d20ee" dependencies = [ "arrayvec 0.7.4", "async-lock", - "atomic-take", + "atomic", "base64 0.21.2", "bip39", "blake2-rfc", "bs58 0.5.0", - "chacha20 0.9.1", "crossbeam-queue", "derive_more", - "ed25519-zebra 4.0.2", + "ed25519-zebra", "either", "event-listener", "fnv", - "futures-lite", + "futures-channel", "futures-util", "hashbrown 0.14.0", "hex", "hmac 0.12.1", - "itertools 0.11.0", + "itertools", "libsecp256k1", "merlin 3.0.0", "no-std-net", @@ -13415,7 +8270,6 @@ dependencies = [ "num-traits", "pbkdf2 0.12.2", "pin-project", - "poly1305 0.8.0", "rand 0.8.5", "rand_chacha 0.3.1", "ruzstd", @@ -13423,15 +8277,15 @@ dependencies = [ "serde", "serde_json", "sha2 0.10.7", - "sha3", "siphasher", "slab", "smallvec", + "smol", + "snow", "soketto", + "tiny-keccak", "twox-hash", - "wasmi 0.31.0", - "x25519-dalek 2.0.0", - "zeroize", + "wasmi", ] [[package]] @@ -13450,7 +8304,7 @@ dependencies = [ "futures-util", "hashbrown 0.14.0", "hex", - "itertools 0.10.5", + "itertools", "log", "lru 0.10.1", "parking_lot 0.12.1", @@ -13460,51 +8314,9 @@ dependencies = [ "siphasher", "slab", "smol", - "smoldot 0.8.0", -] - -[[package]] -name = "smoldot-light" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "256b5bad1d6b49045e95fe87492ce73d5af81545d8b4d8318a872d2007024c33" -dependencies = [ - "async-channel", - "async-lock", - "base64 0.21.2", - "blake2-rfc", - "derive_more", - "either", - "event-listener", - "fnv", - "futures-channel", - "futures-lite", - "futures-util", - "hashbrown 0.14.0", - "hex", - "itertools 0.11.0", - "log", - "lru 0.11.0", - "no-std-net", - "parking_lot 0.12.1", - "pin-project", - "rand 0.8.5", - "rand_chacha 0.3.1", - "serde", - "serde_json", - "siphasher", - "slab", - "smol", - "smoldot 0.11.0", - "zeroize", + "smoldot", ] -[[package]] -name = "snap" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e9f0ab6ef7eb7353d9119c170a436d1bf248eea575ac42d19d12f4e34130831" - [[package]] name = "snow" version = "0.9.3" @@ -13587,7 +8399,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aaf dependencies = [ "Inflector", "blake2 0.10.6", - "expander 2.0.0", + "expander", "proc-macro-crate", "proc-macro2 1.0.69", "quote 1.0.33", @@ -13634,17 +8446,6 @@ dependencies = [ "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", ] -[[package]] -name = "sp-block-builder" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "sp-api", - "sp-inherents", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - [[package]] name = "sp-blockchain" version = "4.0.0-dev" @@ -13678,42 +8479,6 @@ dependencies = [ "thiserror", ] -[[package]] -name = "sp-consensus-aura" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "parity-scale-codec", - "scale-info", - "sp-api", - "sp-application-crypto", - "sp-consensus-slots", - "sp-inherents", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-timestamp", -] - -[[package]] -name = "sp-consensus-babe" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "parity-scale-codec", - "scale-info", - "serde", - "sp-api", - "sp-application-crypto", - "sp-consensus-slots", - "sp-core", - "sp-inherents", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-timestamp", -] - [[package]] name = "sp-consensus-beefy" version = "4.0.0-dev" @@ -13775,7 +8540,7 @@ dependencies = [ "bounded-collections", "bs58 0.5.0", "dyn-clonable", - "ed25519-zebra 3.1.0", + "ed25519-zebra", "futures", "hash-db", "hash256-std-hasher", @@ -13999,30 +8764,6 @@ dependencies = [ "thiserror", ] -[[package]] -name = "sp-npos-elections" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "parity-scale-codec", - "scale-info", - "serde", - "sp-arithmetic", - "sp-core", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", -] - -[[package]] -name = "sp-offchain" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "sp-api", - "sp-core", - "sp-runtime", -] - [[package]] name = "sp-panic-handler" version = "8.0.0" @@ -14218,30 +8959,6 @@ dependencies = [ "tracing-subscriber", ] -[[package]] -name = "sp-transaction-pool" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "sp-api", - "sp-runtime", -] - -[[package]] -name = "sp-transaction-storage-proof" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-inherents", - "sp-runtime", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-trie", -] - [[package]] name = "sp-trie" version = "22.0.0" @@ -14333,17 +9050,6 @@ version = "0.9.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" -[[package]] -name = "spinners" -version = "4.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08615eea740067d9899969bc2891c68a19c315cb1f66640af9a9ecb91b13bcab" -dependencies = [ - "lazy_static", - "maplit", - "strum 0.24.1", -] - [[package]] name = "spki" version = "0.6.0" @@ -14450,74 +9156,6 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" -[[package]] -name = "static_init" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11b73400442027c4adedda20a9f9b7945234a5bd8d5f7e86da22bd5d0622369c" -dependencies = [ - "cfg_aliases", - "libc", - "parking_lot 0.11.2", - "static_init_macro 0.5.0", -] - -[[package]] -name = "static_init" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a2a1c578e98c1c16fc3b8ec1328f7659a500737d7a0c6d625e73e830ff9c1f6" -dependencies = [ - "bitflags 1.3.2", - "cfg_aliases", - "libc", - "parking_lot 0.11.2", - "parking_lot_core 0.8.6", - "static_init_macro 1.0.2", - "winapi", -] - -[[package]] -name = "static_init_macro" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2261c91034a1edc3fc4d1b80e89d82714faede0515c14a75da10cb941546bbf" -dependencies = [ - "cfg_aliases", - "memchr", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", -] - -[[package]] -name = "static_init_macro" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70a2595fc3aa78f2d0e45dd425b22282dd863273761cc77780914b2cf3003acf" -dependencies = [ - "cfg_aliases", - "memchr", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 1.0.109", -] - -[[package]] -name = "storage-proof-fuzzer" -version = "0.1.0" -dependencies = [ - "bp-runtime", - "env_logger", - "honggfuzz", - "log", - "sp-core", - "sp-runtime", - "sp-state-machine", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-trie", -] - [[package]] name = "strsim" version = "0.8.0" @@ -14536,7 +9174,7 @@ version = "0.3.26" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0c6b5c64445ba8094a6ab0c3cd2ad323e07171012d9c98b0b15651daf1787a10" dependencies = [ - "clap 2.34.0", + "clap", "lazy_static", "structopt-derive", ] @@ -14630,30 +9268,6 @@ dependencies = [ "zeroize", ] -[[package]] -name = "substrate-build-script-utils" -version = "3.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" - -[[package]] -name = "substrate-frame-rpc-system" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-system-rpc-runtime-api", - "futures", - "jsonrpsee 0.16.2", - "log", - "parity-scale-codec", - "sc-rpc-api", - "sc-transaction-pool-api", - "sp-api", - "sp-block-builder", - "sp-blockchain", - "sp-core", - "sp-runtime", -] - [[package]] name = "substrate-prometheus-endpoint" version = "0.10.0-dev" @@ -14675,12 +9289,9 @@ dependencies = [ "async-trait", "bp-header-chain", "bp-messages", - "bp-millau", "bp-parachains", "bp-polkadot-bulletin", "bp-polkadot-core", - "bp-rialto", - "bp-rialto-parachain", "bp-runtime", "bp-test-utils", "bridge-runtime-common", @@ -14690,16 +9301,11 @@ dependencies = [ "hex", "hex-literal", "log", - "millau-runtime", "num-format", "num-traits", "pallet-bridge-parachains", "parachains-relay", "parity-scale-codec", - "polkadot-parachain-primitives", - "polkadot-primitives", - "polkadot-runtime-common", - "polkadot-runtime-parachains", "rbtag", "relay-bridge-hub-kusama-client", "relay-bridge-hub-polkadot-client", @@ -14707,25 +9313,18 @@ dependencies = [ "relay-bridge-hub-westend-client", "relay-bridge-hub-wococo-client", "relay-kusama-client", - "relay-millau-client", "relay-polkadot-bulletin-client", "relay-polkadot-client", - "relay-rialto-client", - "relay-rialto-parachain-client", "relay-rococo-client", "relay-substrate-client", "relay-utils", "relay-westend-client", "relay-wococo-client", - "rialto-parachain-runtime", - "rialto-runtime", "signal-hook", "signal-hook-async-std", "sp-core", "sp-keyring", "sp-runtime", - "staging-xcm", - "staging-xcm-executor", "structopt", "strum 0.25.0", "substrate-relay-helper", @@ -14744,8 +9343,6 @@ dependencies = [ "bp-parachains", "bp-polkadot-core", "bp-relayers", - "bp-rialto", - "bp-rialto-parachain", "bp-rococo", "bp-runtime", "bp-wococo", @@ -14764,68 +9361,19 @@ dependencies = [ "pallet-bridge-grandpa", "pallet-bridge-messages", "pallet-bridge-parachains", - "pallet-grandpa", - "pallet-transaction-payment", - "parachains-relay", - "parity-scale-codec", - "relay-rialto-client", - "relay-rococo-client", - "relay-substrate-client", - "relay-utils", - "relay-wococo-client", - "rialto-runtime", - "sp-consensus-grandpa", - "sp-core", - "sp-runtime", - "thiserror", -] - -[[package]] -name = "substrate-rpc-client" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "jsonrpsee 0.16.2", - "log", - "sc-rpc-api", - "serde", - "sp-runtime", -] - -[[package]] -name = "substrate-state-trie-migration-rpc" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "jsonrpsee 0.16.2", + "pallet-grandpa", + "pallet-transaction-payment", + "parachains-relay", "parity-scale-codec", - "sc-client-api", - "sc-rpc-api", - "serde", + "relay-bridge-hub-rococo-client", + "relay-bridge-hub-wococo-client", + "relay-rococo-client", + "relay-substrate-client", + "relay-utils", + "sp-consensus-grandpa", "sp-core", "sp-runtime", - "sp-state-machine", - "sp-trie", - "trie-db", -] - -[[package]] -name = "substrate-wasm-builder" -version = "5.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "ansi_term", - "build-helper", - "cargo_metadata", - "filetime", - "parity-wasm", - "sp-maybe-compressed-blob", - "strum 0.24.1", - "tempfile", - "toml 0.7.6", - "walkdir", - "wasm-opt", + "thiserror", ] [[package]] @@ -14918,7 +9466,7 @@ dependencies = [ "futures-util", "serde", "serde_json", - "smoldot-light 0.6.0", + "smoldot-light", "thiserror", "tokio", "tokio-stream", @@ -15120,12 +9668,6 @@ dependencies = [ "syn 2.0.38", ] -[[package]] -name = "thousands" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3bf63baf9f5039dadc247375c29eb13706706cfde997d0330d05aa63a77d8820" - [[package]] name = "thread_local" version = "1.1.7" @@ -15136,49 +9678,6 @@ dependencies = [ "once_cell", ] -[[package]] -name = "threadpool" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaa" -dependencies = [ - "num_cpus", -] - -[[package]] -name = "thrift" -version = "0.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b82ca8f46f95b3ce96081fe3dd89160fdea970c254bb72925255d1b62aae692e" -dependencies = [ - "byteorder", - "integer-encoding", - "log", - "ordered-float", - "threadpool", -] - -[[package]] -name = "tikv-jemalloc-ctl" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e37706572f4b151dff7a0146e040804e9c26fe3a3118591112f05cf12a4216c1" -dependencies = [ - "libc", - "paste", - "tikv-jemalloc-sys", -] - -[[package]] -name = "tikv-jemalloc-sys" -version = "0.5.3+5.3.0-patched" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a678df20055b43e57ef8cddde41cdfda9a3c1a060b67f4c5836dfb1d78543ba8" -dependencies = [ - "cc", - "libc", -] - [[package]] name = "time" version = "0.1.45" @@ -15304,28 +9803,6 @@ dependencies = [ "syn 2.0.38", ] -[[package]] -name = "tokio-retry" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f57eb36ecbe0fc510036adff84824dd3c24bb781e21bfa67b69d556aa85214f" -dependencies = [ - "pin-project", - "rand 0.8.5", - "tokio", -] - -[[package]] -name = "tokio-rustls" -version = "0.23.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c43ee83903113e03984cb9e5cebe6c04a5116269e900e3ddba8f068a62adda59" -dependencies = [ - "rustls 0.20.8", - "tokio", - "webpki 0.22.2", -] - [[package]] name = "tokio-rustls" version = "0.24.1" @@ -15345,7 +9822,6 @@ dependencies = [ "futures-core", "pin-project-lite 0.2.12", "tokio", - "tokio-util", ] [[package]] @@ -15421,24 +9897,6 @@ dependencies = [ "tracing", ] -[[package]] -name = "tower-http" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ac8060a61f8758a61562f6fb53ba3cbe1ca906f001df2e53cccddcdbee91e7c" -dependencies = [ - "bitflags 2.4.1", - "bytes", - "futures-core", - "futures-util", - "http", - "http-body", - "http-range-header", - "pin-project-lite 0.2.12", - "tower-layer", - "tower-service", -] - [[package]] name = "tower-layer" version = "0.3.2" @@ -15495,30 +9953,6 @@ dependencies = [ "tracing", ] -[[package]] -name = "tracing-gum" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "coarsetime", - "polkadot-node-jaeger", - "polkadot-primitives", - "tracing", - "tracing-gum-proc-macro", -] - -[[package]] -name = "tracing-gum-proc-macro" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "expander 2.0.0", - "proc-macro-crate", - "proc-macro2 1.0.69", - "quote 1.0.33", - "syn 2.0.38", -] - [[package]] name = "tracing-log" version = "0.1.3" @@ -15550,7 +9984,6 @@ dependencies = [ "chrono", "lazy_static", "matchers", - "parking_lot 0.11.2", "regex", "serde", "serde_json", @@ -15637,41 +10070,6 @@ version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" -[[package]] -name = "try-runtime-cli" -version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "async-trait", - "clap 4.4.8", - "frame-remote-externalities", - "hex", - "log", - "parity-scale-codec", - "sc-cli", - "sc-executor", - "serde", - "serde_json", - "sp-api", - "sp-consensus-aura", - "sp-consensus-babe", - "sp-core", - "sp-debug-derive", - "sp-externalities", - "sp-inherents", - "sp-io", - "sp-keystore", - "sp-rpc", - "sp-runtime", - "sp-state-machine", - "sp-timestamp", - "sp-transaction-storage-proof", - "sp-version", - "sp-weights", - "substrate-rpc-client", - "zstd 0.12.4", -] - [[package]] name = "tt-call" version = "1.0.9" @@ -15715,12 +10113,6 @@ version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" -[[package]] -name = "ucd-trie" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed646292ffc8188ef8ea4d1e0e0150fb15a5c2e12ad9b8fc191ae7a8a7f3c4b9" - [[package]] name = "uint" version = "0.9.5" @@ -15827,12 +10219,6 @@ dependencies = [ "percent-encoding", ] -[[package]] -name = "utf8parse" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" - [[package]] name = "uuid" version = "1.4.1" @@ -16005,46 +10391,6 @@ dependencies = [ "parity-wasm", ] -[[package]] -name = "wasm-opt" -version = "0.114.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d005a95f934878a1fb446a816d51c3601a0120ff929005ba3bab3c749cfd1c7" -dependencies = [ - "anyhow", - "libc", - "strum 0.24.1", - "strum_macros 0.24.3", - "tempfile", - "thiserror", - "wasm-opt-cxx-sys", - "wasm-opt-sys", -] - -[[package]] -name = "wasm-opt-cxx-sys" -version = "0.114.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d04e240598162810fad3b2e96fa0dec6dba1eb65a03f3bd99a9248ab8b56caa" -dependencies = [ - "anyhow", - "cxx", - "cxx-build", - "wasm-opt-sys", -] - -[[package]] -name = "wasm-opt-sys" -version = "0.114.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2efd2aaca519d64098c4faefc8b7433a97ed511caf4c9e516384eb6aef1ff4f9" -dependencies = [ - "anyhow", - "cc", - "cxx", - "cxx-build", -] - [[package]] name = "wasm-timer" version = "0.2.5" @@ -16070,20 +10416,7 @@ dependencies = [ "smallvec", "spin 0.9.8", "wasmi_arena", - "wasmi_core 0.12.0", - "wasmparser-nostd", -] - -[[package]] -name = "wasmi" -version = "0.31.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f341edb80021141d4ae6468cbeefc50798716a347d4085c3811900049ea8945" -dependencies = [ - "smallvec", - "spin 0.9.8", - "wasmi_arena", - "wasmi_core 0.13.0", + "wasmi_core", "wasmparser-nostd", ] @@ -16105,18 +10438,6 @@ dependencies = [ "paste", ] -[[package]] -name = "wasmi_core" -version = "0.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcf1a7db34bff95b85c261002720c00c3a6168256dcb93041d3fa2054d19856a" -dependencies = [ - "downcast-rs", - "libm", - "num-traits", - "paste", -] - [[package]] name = "wasmparser" version = "0.102.0" @@ -16579,125 +10900,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "westend-runtime" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "binary-merkle-tree", - "bitvec", - "frame-benchmarking", - "frame-election-provider-support", - "frame-executive", - "frame-support", - "frame-system", - "frame-system-benchmarking", - "frame-system-rpc-runtime-api", - "frame-try-runtime", - "hex-literal", - "log", - "pallet-asset-rate", - "pallet-authority-discovery", - "pallet-authorship", - "pallet-babe", - "pallet-bags-list", - "pallet-balances", - "pallet-beefy", - "pallet-beefy-mmr", - "pallet-collective", - "pallet-conviction-voting", - "pallet-democracy", - "pallet-election-provider-multi-phase", - "pallet-election-provider-support-benchmarking", - "pallet-elections-phragmen", - "pallet-fast-unstake", - "pallet-grandpa", - "pallet-identity", - "pallet-im-online", - "pallet-indices", - "pallet-membership", - "pallet-message-queue", - "pallet-mmr", - "pallet-multisig", - "pallet-nomination-pools", - "pallet-nomination-pools-benchmarking", - "pallet-nomination-pools-runtime-api", - "pallet-offences", - "pallet-offences-benchmarking", - "pallet-preimage", - "pallet-proxy", - "pallet-recovery", - "pallet-referenda", - "pallet-scheduler", - "pallet-session", - "pallet-session-benchmarking", - "pallet-society", - "pallet-staking", - "pallet-staking-reward-curve", - "pallet-staking-runtime-api", - "pallet-state-trie-migration", - "pallet-sudo", - "pallet-timestamp", - "pallet-transaction-payment", - "pallet-transaction-payment-rpc-runtime-api", - "pallet-treasury", - "pallet-utility", - "pallet-vesting", - "pallet-whitelist", - "pallet-xcm", - "pallet-xcm-benchmarks", - "parity-scale-codec", - "polkadot-parachain-primitives", - "polkadot-primitives", - "polkadot-runtime-common", - "polkadot-runtime-parachains", - "rustc-hex", - "scale-info", - "serde", - "serde_derive", - "smallvec", - "sp-api", - "sp-application-crypto", - "sp-arithmetic", - "sp-authority-discovery", - "sp-block-builder", - "sp-consensus-babe", - "sp-consensus-beefy", - "sp-core", - "sp-genesis-builder", - "sp-inherents", - "sp-io", - "sp-mmr-primitives", - "sp-npos-elections", - "sp-offchain", - "sp-runtime", - "sp-session", - "sp-staking", - "sp-std 8.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=master)", - "sp-storage", - "sp-transaction-pool", - "sp-version", - "staging-xcm", - "staging-xcm-builder", - "staging-xcm-executor", - "substrate-wasm-builder", - "westend-runtime-constants", -] - -[[package]] -name = "westend-runtime-constants" -version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=master#1cf7d3aafa0e7edaa20d34581e0f1656895cb9c2" -dependencies = [ - "frame-support", - "polkadot-primitives", - "polkadot-runtime-common", - "smallvec", - "sp-core", - "sp-runtime", - "sp-weights", -] - [[package]] name = "which" version = "4.4.0" diff --git a/Cargo.toml b/Cargo.toml index e73b387a460b3..958808d9ca71f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -8,20 +8,12 @@ license = "GPL-3.0-only" resolver = "2" members = [ - "bin/millau/node", - "bin/millau/runtime", - "bin/rialto/node", - "bin/rialto/runtime", - "bin/rialto-parachain/node", - "bin/rialto-parachain/runtime", "bin/runtime-common", - "fuzz/storage-proof", "modules/beefy", "modules/grandpa", "modules/messages", "modules/parachains", "modules/relayers", - "modules/shift-session-manager", "modules/xcm-bridge-hub-router", "primitives/beefy", "primitives/chain-asset-hub-kusama", @@ -36,11 +28,8 @@ members = [ "primitives/chain-bridge-hub-westend", "primitives/chain-bridge-hub-wococo", "primitives/chain-kusama", - "primitives/chain-millau", "primitives/chain-polkadot", "primitives/chain-polkadot-bulletin", - "primitives/chain-rialto", - "primitives/chain-rialto-parachain", "primitives/chain-rococo", "primitives/chain-westend", "primitives/chain-wococo", @@ -59,11 +48,8 @@ members = [ "relays/client-bridge-hub-westend", "relays/client-bridge-hub-wococo", "relays/client-kusama", - "relays/client-millau", "relays/client-polkadot", "relays/client-polkadot-bulletin", - "relays/client-rialto", - "relays/client-rialto-parachain", "relays/client-rococo", "relays/client-substrate", "relays/client-westend", diff --git a/README.md b/README.md index da46fe67d924a..f8191f432adfa 100644 --- a/README.md +++ b/README.md @@ -68,7 +68,7 @@ For example, consider the case below where we want to bridge two Substrate based ``` +---------------+ +---------------+ | | | | -| Rialto | | Millau | +| Rococo | | Westend | | | | | +-------+-------+ +-------+-------+ ^ ^ @@ -79,9 +79,9 @@ For example, consider the case below where we want to bridge two Substrate based +---------------+ ``` -The Millau chain must be able to accept Rialto headers and verify their integrity. It does this by using a runtime +The Rococo chain must be able to accept Westend headers and verify their integrity. It does this by using a runtime module designed to track GRANDPA finality. Since two blockchains can't interact directly they need an external service, -called a relayer, to communicate. The relayer will subscribe to new Rialto headers via RPC and submit them to the Millau +called a relayer, to communicate. The relayer will subscribe to new Rococo headers via RPC and submit them to the Westend chain for verification. Take a look at [Bridge High Level Documentation](./docs/high-level-overview.md) for more in-depth description of the @@ -94,164 +94,23 @@ Here's an overview of how the project is laid out. The main bits are the `bin`, messages between chains. ``` -├── bin // Node and Runtime for the various Substrate chains -│ └── ... -├── deployments // Useful tools for deploying test networks +├── modules // Substrate Runtime Modules (a.k.a Pallets) +│ ├── beefy // On-Chain BEEFY Light Client (in progress) +│ ├── grandpa // On-Chain GRANDPA Light Client +│ ├── messages // Cross Chain Message Passing +│ ├── parachains // On-Chain Parachains Light Client +│ ├── relayers // Relayer Rewards Registry +│ ├── xcm-bridge-hub // Multiple Dynamic Bridges Support +│ ├── xcm-bridge-hub-router // XCM Router that may be used to Connect to XCM Bridge Hub +├── primitives // Code shared between modules, runtimes, and relays │ └── ... -├── modules // Substrate Runtime Modules (a.k.a Pallets) -│ ├── beefy // On-Chain BEEFY Light Client (in progress) -│ ├── grandpa // On-Chain GRANDPA Light Client -│ ├── messages // Cross Chain Message Passing -│ ├── parachains // On-Chain Parachains Light Client -│ ├── relayers // Relayer rewards registry +├── relays // Application for sending finality proofs and messages between chains │ └── ... -├── primitives // Code shared between modules, runtimes, and relays -│ └── ... -├── relays // Application for sending finality proofs and messages between chains -│ └── ... -└── scripts // Useful development and maintenance scripts +└── scripts // Useful development and maintenance scripts ``` ## Running the Bridge -To run the Bridge you need to be able to connect the bridge relay node to the RPC interface of nodes on each side of the -bridge (source and target chain). - -There are 2 ways to run the bridge, described below: - -- building & running from source: with this option, you'll be able to run the bridge between two standalone chains that -are running GRANDPA finality gadget to achieve finality; - -- running a Docker Compose setup: this is a recommended option, where you'll see bridges with parachains, complex relays -and more. - -### Using the Source - -First you'll need to build the bridge nodes and relay. This can be done as follows: - -```bash -# In `parity-bridges-common` folder -cargo build -p rialto-bridge-node -cargo build -p millau-bridge-node -cargo build -p substrate-relay -``` - -### Running a Dev network - -We will launch a dev network to demonstrate how to relay a message between two Substrate based chains (named Rialto and -Millau). - -To do this we will need two nodes, two relayers which will relay headers, and two relayers which will relay messages. - -#### Running from local scripts - -To run a simple dev network you can use the scripts located in the [`deployments/local-scripts` -folder](./deployments/local-scripts). - -First, we must run the two Substrate nodes. - -```bash -# In `parity-bridges-common` folder -./deployments/local-scripts/run-rialto-node.sh -./deployments/local-scripts/run-millau-node.sh -``` - -After the nodes are up we can run the header relayers. - -```bash -./deployments/local-scripts/relay-millau-to-rialto.sh -./deployments/local-scripts/relay-rialto-to-millau.sh -``` - -At this point you should see the relayer submitting headers from the Millau Substrate chain to the Rialto Substrate -chain. - -``` -# Header Relayer Logs -[Millau_to_Rialto_Sync] [date] DEBUG bridge Going to submit finality proof of Millau header #147 to Rialto -[...] [date] INFO bridge Synced 147 of 147 headers -[...] [date] DEBUG bridge Going to submit finality proof of Millau header #148 to Rialto -[...] [date] INFO bridge Synced 148 of 149 headers -``` - -Finally, we can run the message relayers. - -```bash -./deployments/local-scripts/relay-messages-millau-to-rialto.sh -./deployments/local-scripts/relay-messages-rialto-to-millau.sh -``` - -You will also see the message lane relayers listening for new messages. - -``` -# Message Relayer Logs -[Millau_to_Rialto_MessageLane_00000000] [date] DEBUG bridge Asking Millau::ReceivingConfirmationsDelivery about best message nonces -[...] [date] INFO bridge Synced Some(2) of Some(3) nonces in Millau::MessagesDelivery -> Rialto::MessagesDelivery race -[...] [date] DEBUG bridge Asking Millau::MessagesDelivery about message nonces -[...] [date] DEBUG bridge Received best nonces from Millau::ReceivingConfirmationsDelivery: TargetClientNonces { - latest_nonce: 0, nonces_data: () } -[...] [date] DEBUG bridge Asking Millau::ReceivingConfirmationsDelivery about finalized message nonces -[...] [date] DEBUG bridge Received finalized nonces from Millau::ReceivingConfirmationsDelivery: TargetClientNonces { - latest_nonce: 0, nonces_data: () } -[...] [date] DEBUG bridge Received nonces from Millau::MessagesDelivery: SourceClientNonces { new_nonces: {}, confirmed_nonce: Some(0) } -[...] [date] DEBUG bridge Asking Millau node about its state -[...] [date] DEBUG bridge Received state from Millau node: ClientState { best_self: HeaderId(1593, 0xacac***), best_finalized_self: - HeaderId(1590, 0x0be81d...), best_finalized_peer_at_best_self: HeaderId(0, 0xdcdd89...) } -``` - -To send a message see the ["How to send a message" section](#how-to-send-a-message). - -### How to send a message - -In this section we'll show you how to quickly send a bridge message. The message is just an encoded XCM `Trap(43)` -message. - -```bash -# In `parity-bridges-common` folder -./scripts/send-message-from-millau-rialto.sh -``` - -After sending a message you will see the following logs showing a message was successfully sent: - -``` -INFO bridge Sending message to Rialto. Size: 11. -TRACE bridge Sent transaction to Millau node: 0x5e68... -``` - -And at the Rialto node logs you'll something like this: - -``` -... runtime::bridge-messages: Received messages: total=1, valid=1. Weight used: Weight(ref_time: 1215065371, proof_size: - 48559)/Weight(ref_time: 1215065371, proof_size: 54703). -``` - -It means that the message has been delivered and dispatched. Message may be dispatched with an error, though - the goal -of our test bridge is to ensure that messages are successfully delivered and all involved components are working. - -## Full Network Docker Compose Setup - -For a more sophisticated deployment which includes bidirectional header sync, message passing, monitoring dashboards, -etc. see the [Deployments README](./deployments/README.md). - -You should note that you can find images for all the bridge components published on [Docker -Hub](https://hub.docker.com/u/paritytech). - -To run a Rialto node for example, you can use the following command: - -```bash -docker run -p 30333:30333 -p 9933:9933 -p 9944:9944 \ - -it paritytech/rialto-bridge-node --dev --tmp \ - --rpc-cors=all --unsafe-rpc-external -``` - -## Community - -Main hangout for the community is [Element](https://element.io/) (formerly Riot). Element is a chat server like, for -example, Discord. Most discussions around Polkadot and Substrate happen in various Element "rooms" (channels). So, -joining Element might be a good idea, anyway. - -If you are interested in information exchange and development of Polkadot related bridges please feel free to join the -[Polkadot Bridges](https://app.element.io/#/room/#bridges:web3.foundation) Element channel. - -The [Substrate Technical](https://app.element.io/#/room/#substrate-technical:matrix.org) Element channel is most suited -for discussions regarding Substrate itself. +Apart from live Rococo <> Westend bridge, you may spin up local networks and test see how it works locally. More +details may be found in +[this document](https://github.com/paritytech/polkadot-sdk/tree/master//cumulus/parachains/runtimes/bridge-hubs/README.md). diff --git a/bin/millau/node/Cargo.toml b/bin/millau/node/Cargo.toml deleted file mode 100644 index 426cb9e863ee1..0000000000000 --- a/bin/millau/node/Cargo.toml +++ /dev/null @@ -1,61 +0,0 @@ -[package] -name = "millau-bridge-node" -description = "Substrate node compatible with Millau runtime" -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -build = "build.rs" -repository = "https://github.com/paritytech/parity-bridges-common/" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[dependencies] -clap = { version = "4.4.8", features = ["derive"] } -futures = "0.3.29" -jsonrpsee = { version = "0.16.2", features = ["server"] } -serde_json = "1.0.108" - -# Bridge dependencies - -millau-runtime = { path = "../runtime" } - -# Substrate Dependencies - -sc-consensus-beefy = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-consensus-beefy-rpc = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-consensus-beefy = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -frame-benchmarking = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -frame-benchmarking-cli = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -node-inspect = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -mmr-rpc = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -pallet-transaction-payment-rpc = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-basic-authorship = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-cli = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master"} -sc-client-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-consensus = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-consensus-aura = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-executor = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-consensus-grandpa = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-consensus-grandpa-rpc = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-keystore = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-network = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-offchain = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-rpc = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-service = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-telemetry = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-transaction-pool = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-transaction-pool-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-consensus-aura = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-consensus-grandpa = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-timestamp = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -substrate-frame-rpc-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-network-common = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -[build-dependencies] -substrate-build-script-utils = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -frame-benchmarking-cli = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -[features] -default = [] -runtime-benchmarks = [ "millau-runtime/runtime-benchmarks" ] diff --git a/bin/millau/node/build.rs b/bin/millau/node/build.rs deleted file mode 100644 index d9b50049e2628..0000000000000 --- a/bin/millau/node/build.rs +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use substrate_build_script_utils::{generate_cargo_keys, rerun_if_git_head_changed}; - -fn main() { - generate_cargo_keys(); - - rerun_if_git_head_changed(); -} diff --git a/bin/millau/node/src/chain_spec.rs b/bin/millau/node/src/chain_spec.rs deleted file mode 100644 index 01883bb4ef083..0000000000000 --- a/bin/millau/node/src/chain_spec.rs +++ /dev/null @@ -1,237 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use millau_runtime::{ - AccountId, AuraConfig, BalancesConfig, BeefyConfig, BridgeRialtoMessagesConfig, - BridgeRialtoParachainMessagesConfig, BridgeWestendGrandpaConfig, GrandpaConfig, - RuntimeGenesisConfig, SessionConfig, SessionKeys, Signature, SudoConfig, SystemConfig, - WASM_BINARY, -}; -use sp_consensus_aura::sr25519::AuthorityId as AuraId; -use sp_consensus_beefy::ecdsa_crypto::AuthorityId as BeefyId; -use sp_consensus_grandpa::AuthorityId as GrandpaId; -use sp_core::{sr25519, Pair, Public}; -use sp_runtime::traits::{IdentifyAccount, Verify}; - -/// "Names" of the authorities accounts at local testnet. -const LOCAL_AUTHORITIES_ACCOUNTS: [&str; 5] = ["Alice", "Bob", "Charlie", "Dave", "Eve"]; -/// "Names" of the authorities accounts at development testnet. -const DEV_AUTHORITIES_ACCOUNTS: [&str; 1] = [LOCAL_AUTHORITIES_ACCOUNTS[0]]; -/// "Names" of all possible authorities accounts. -const ALL_AUTHORITIES_ACCOUNTS: [&str; 5] = LOCAL_AUTHORITIES_ACCOUNTS; -/// "Name" of the `sudo` account. -const SUDO_ACCOUNT: &str = "Sudo"; -/// "Name" of the account, which owns the with-Westend GRANDPA pallet. -const WESTEND_GRANDPA_PALLET_OWNER: &str = "Westend.GrandpaOwner"; -/// "Name" of the account, which owns the with-Rialto messages pallet. -const RIALTO_MESSAGES_PALLET_OWNER: &str = "Rialto.MessagesOwner"; -/// "Name" of the account, which owns the with-RialtoParachain messages pallet. -const RIALTO_PARACHAIN_MESSAGES_PALLET_OWNER: &str = "RialtoParachain.MessagesOwner"; - -/// Specialized `ChainSpec`. This is a specialization of the general Substrate ChainSpec type. -pub type ChainSpec = sc_service::GenericChainSpec; - -/// The chain specification option. This is expected to come in from the CLI and -/// is little more than one of a number of alternatives which can easily be converted -/// from a string (`--chain=...`) into a `ChainSpec`. -#[derive(Clone, Debug)] -pub enum Alternative { - /// Whatever the current runtime is, with just Alice as an auth. - Development, - /// Whatever the current runtime is, with simple Alice/Bob/Charlie/Dave/Eve auths. - LocalTestnet, -} - -/// Helper function to generate a crypto pair from seed -pub fn get_from_seed(seed: &str) -> ::Public { - TPublic::Pair::from_string(&format!("//{seed}"), None) - .expect("static values are valid; qed") - .public() -} - -type AccountPublic = ::Signer; - -/// Helper function to generate an account ID from seed -pub fn get_account_id_from_seed(seed: &str) -> AccountId -where - AccountPublic: From<::Public>, -{ - AccountPublic::from(get_from_seed::(seed)).into_account() -} - -/// Helper function to generate an authority key for Aura -pub fn get_authority_keys_from_seed(s: &str) -> (AccountId, AuraId, BeefyId, GrandpaId) { - ( - get_account_id_from_seed::(s), - get_from_seed::(s), - get_from_seed::(s), - get_from_seed::(s), - ) -} - -impl Alternative { - /// Get an actual chain config from one of the alternatives. - pub(crate) fn load(self) -> ChainSpec { - let properties = Some( - serde_json::json!({ - "tokenDecimals": 9, - "tokenSymbol": "MLAU" - }) - .as_object() - .expect("Map given; qed") - .clone(), - ); - match self { - Alternative::Development => ChainSpec::from_genesis( - "Millau Development", - "millau_dev", - sc_service::ChainType::Development, - || { - testnet_genesis( - DEV_AUTHORITIES_ACCOUNTS - .into_iter() - .map(get_authority_keys_from_seed) - .collect(), - get_account_id_from_seed::(SUDO_ACCOUNT), - endowed_accounts(), - true, - ) - }, - vec![], - None, - None, - None, - properties, - None, - ), - Alternative::LocalTestnet => ChainSpec::from_genesis( - "Millau Local", - "millau_local", - sc_service::ChainType::Local, - || { - testnet_genesis( - LOCAL_AUTHORITIES_ACCOUNTS - .into_iter() - .map(get_authority_keys_from_seed) - .collect(), - get_account_id_from_seed::(SUDO_ACCOUNT), - endowed_accounts(), - true, - ) - }, - vec![], - None, - None, - None, - properties, - None, - ), - } - } -} - -/// We're using the same set of endowed accounts on all Millau chains (dev/local) to make -/// sure that all accounts, required for bridge to be functional (e.g. relayers fund account, -/// accounts used by relayers in our test deployments, accounts used for demonstration -/// purposes), are all available on these chains. -fn endowed_accounts() -> Vec { - let all_authorities = ALL_AUTHORITIES_ACCOUNTS.iter().flat_map(|x| { - [ - get_account_id_from_seed::(x), - get_account_id_from_seed::(&format!("{x}//stash")), - ] - }); - vec![ - // Sudo account - get_account_id_from_seed::(SUDO_ACCOUNT), - // Regular (unused) accounts - get_account_id_from_seed::("Ferdie"), - get_account_id_from_seed::("Ferdie//stash"), - // Accounts, used by Westend<>Millau bridge - get_account_id_from_seed::(WESTEND_GRANDPA_PALLET_OWNER), - get_account_id_from_seed::("Westend.HeadersRelay1"), - get_account_id_from_seed::("Westend.HeadersRelay2"), - get_account_id_from_seed::("Westend.AssetHubWestendHeaders1"), - get_account_id_from_seed::("Westend.AssetHubWestendHeaders2"), - // Accounts, used by Rialto<>Millau bridge - get_account_id_from_seed::(RIALTO_MESSAGES_PALLET_OWNER), - get_account_id_from_seed::("Rialto.HeadersAndMessagesRelay"), - get_account_id_from_seed::("Rialto.OutboundMessagesRelay.Lane00000001"), - get_account_id_from_seed::("Rialto.InboundMessagesRelay.Lane00000001"), - get_account_id_from_seed::("Rialto.MessagesSender"), - // Accounts, used by RialtoParachain<>Millau bridge - get_account_id_from_seed::(RIALTO_PARACHAIN_MESSAGES_PALLET_OWNER), - get_account_id_from_seed::("RialtoParachain.HeadersAndMessagesRelay1"), - get_account_id_from_seed::("RialtoParachain.HeadersAndMessagesRelay2"), - get_account_id_from_seed::("RialtoParachain.RialtoHeadersRelay1"), - get_account_id_from_seed::("RialtoParachain.RialtoHeadersRelay2"), - get_account_id_from_seed::("RialtoParachain.MessagesSender"), - ] - .into_iter() - .chain(all_authorities) - .collect() -} - -fn session_keys(aura: AuraId, beefy: BeefyId, grandpa: GrandpaId) -> SessionKeys { - SessionKeys { aura, beefy, grandpa } -} - -fn testnet_genesis( - initial_authorities: Vec<(AccountId, AuraId, BeefyId, GrandpaId)>, - root_key: AccountId, - endowed_accounts: Vec, - _enable_println: bool, -) -> RuntimeGenesisConfig { - RuntimeGenesisConfig { - system: SystemConfig { - code: WASM_BINARY.expect("Millau development WASM not available").to_vec(), - ..Default::default() - }, - balances: BalancesConfig { - balances: endowed_accounts.iter().cloned().map(|k| (k, 1 << 50)).collect(), - }, - aura: AuraConfig { authorities: Vec::new() }, - beefy: BeefyConfig::default(), - grandpa: GrandpaConfig { authorities: Vec::new(), ..Default::default() }, - sudo: SudoConfig { key: Some(root_key) }, - session: SessionConfig { - keys: initial_authorities - .iter() - .map(|x| { - (x.0.clone(), x.0.clone(), session_keys(x.1.clone(), x.2.clone(), x.3.clone())) - }) - .collect::>(), - }, - bridge_westend_grandpa: BridgeWestendGrandpaConfig { - // for our deployments to avoid multiple same-nonces transactions: - // //Alice is already used to initialize Rialto<->Millau bridge - // => let's use //Westend.GrandpaOwner to initialize Westend->Millau bridge - owner: Some(get_account_id_from_seed::(WESTEND_GRANDPA_PALLET_OWNER)), - ..Default::default() - }, - bridge_rialto_messages: BridgeRialtoMessagesConfig { - owner: Some(get_account_id_from_seed::(RIALTO_MESSAGES_PALLET_OWNER)), - ..Default::default() - }, - bridge_rialto_parachain_messages: BridgeRialtoParachainMessagesConfig { - owner: Some(get_account_id_from_seed::( - RIALTO_PARACHAIN_MESSAGES_PALLET_OWNER, - )), - ..Default::default() - }, - xcm_pallet: Default::default(), - } -} diff --git a/bin/millau/node/src/cli.rs b/bin/millau/node/src/cli.rs deleted file mode 100644 index 12499b5718d6d..0000000000000 --- a/bin/millau/node/src/cli.rs +++ /dev/null @@ -1,73 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use clap::Parser; -use sc_cli::RunCmd; - -#[derive(Debug, Parser)] -pub struct Cli { - #[structopt(subcommand)] - pub subcommand: Option, - - #[structopt(flatten)] - pub run: RunCmd, -} - -/// Possible subcommands of the main binary. -#[derive(Debug, Parser)] -#[allow(clippy::large_enum_variant)] -pub enum Subcommand { - /// Key management CLI utilities - #[clap(subcommand)] - Key(sc_cli::KeySubcommand), - - /// Verify a signature for a message, provided on `STDIN`, with a given (public or secret) key. - Verify(sc_cli::VerifyCmd), - - /// Generate a seed that provides a vanity address. - Vanity(sc_cli::VanityCmd), - - /// Sign a message, with a given (secret) key. - Sign(sc_cli::SignCmd), - - /// Build a chain specification. - BuildSpec(sc_cli::BuildSpecCmd), - - /// Validate blocks. - CheckBlock(sc_cli::CheckBlockCmd), - - /// Export blocks. - ExportBlocks(sc_cli::ExportBlocksCmd), - - /// Export the state of a given block into a chain spec. - ExportState(sc_cli::ExportStateCmd), - - /// Import blocks. - ImportBlocks(sc_cli::ImportBlocksCmd), - - /// Remove the whole chain. - PurgeChain(sc_cli::PurgeChainCmd), - - /// Revert the chain to a previous state. - Revert(sc_cli::RevertCmd), - - /// Inspect blocks or extrinsics. - Inspect(node_inspect::cli::InspectCmd), - - /// Benchmark runtime pallets. - #[clap(subcommand)] - Benchmark(frame_benchmarking_cli::BenchmarkCmd), -} diff --git a/bin/millau/node/src/command.rs b/bin/millau/node/src/command.rs deleted file mode 100644 index 745b393786e1d..0000000000000 --- a/bin/millau/node/src/command.rs +++ /dev/null @@ -1,154 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use crate::{ - cli::{Cli, Subcommand}, - service, - service::new_partial, -}; -use frame_benchmarking_cli::BenchmarkCmd; -use millau_runtime::{Block, RuntimeApi}; -use sc_cli::SubstrateCli; -use sc_service::PartialComponents; - -impl SubstrateCli for Cli { - fn impl_name() -> String { - "Millau Bridge Node".into() - } - - fn impl_version() -> String { - env!("CARGO_PKG_VERSION").into() - } - - fn description() -> String { - "Millau Bridge Node".into() - } - - fn author() -> String { - "Parity Technologies".into() - } - - fn support_url() -> String { - "https://github.com/paritytech/parity-bridges-common/".into() - } - - fn copyright_start_year() -> i32 { - 2019 - } - - fn executable_name() -> String { - "millau-bridge-node".into() - } - - fn load_spec(&self, id: &str) -> Result, String> { - Ok(Box::new( - match id { - "" | "dev" => crate::chain_spec::Alternative::Development, - "local" => crate::chain_spec::Alternative::LocalTestnet, - _ => return Err(format!("Unsupported chain specification: {id}")), - } - .load(), - )) - } -} - -/// Parse and run command line arguments -pub fn run() -> sc_cli::Result<()> { - let cli = Cli::from_args(); - // make sure to set correct crypto version. - sp_core::crypto::set_default_ss58_version(sp_core::crypto::Ss58AddressFormat::custom( - millau_runtime::SS58Prefix::get() as u16, - )); - - match &cli.subcommand { - Some(Subcommand::Benchmark(cmd)) => { - let runner = cli.create_runner(cmd)?; - match cmd { - BenchmarkCmd::Pallet(cmd) => - if cfg!(feature = "runtime-benchmarks") { - runner.sync_run(|config| cmd.run::(config)) - } else { - println!( - "Benchmarking wasn't enabled when building the node. \ - You can enable it with `--features runtime-benchmarks`." - ); - Ok(()) - }, - _ => Err("Unsupported benchmarking subcommand".into()), - } - }, - Some(Subcommand::Key(cmd)) => cmd.run(&cli), - Some(Subcommand::Sign(cmd)) => cmd.run(), - Some(Subcommand::Verify(cmd)) => cmd.run(), - Some(Subcommand::Vanity(cmd)) => cmd.run(), - Some(Subcommand::BuildSpec(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.sync_run(|config| cmd.run(config.chain_spec, config.network)) - }, - Some(Subcommand::CheckBlock(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.async_run(|config| { - let PartialComponents { client, task_manager, import_queue, .. } = - new_partial(&config)?; - Ok((cmd.run(client, import_queue), task_manager)) - }) - }, - Some(Subcommand::ExportBlocks(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.async_run(|config| { - let PartialComponents { client, task_manager, .. } = new_partial(&config)?; - Ok((cmd.run(client, config.database), task_manager)) - }) - }, - Some(Subcommand::ExportState(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.async_run(|config| { - let PartialComponents { client, task_manager, .. } = new_partial(&config)?; - Ok((cmd.run(client, config.chain_spec), task_manager)) - }) - }, - Some(Subcommand::ImportBlocks(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.async_run(|config| { - let PartialComponents { client, task_manager, import_queue, .. } = - new_partial(&config)?; - Ok((cmd.run(client, import_queue), task_manager)) - }) - }, - Some(Subcommand::PurgeChain(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.sync_run(|config| cmd.run(config.database)) - }, - Some(Subcommand::Revert(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.async_run(|config| { - let PartialComponents { client, task_manager, backend, .. } = new_partial(&config)?; - Ok((cmd.run(client, backend, None), task_manager)) - }) - }, - Some(Subcommand::Inspect(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner - .sync_run(|config| cmd.run::(config)) - }, - None => { - let runner = cli.create_runner(&cli.run)?; - runner.run_node_until_exit(|config| async move { - service::new_full(config).map_err(sc_cli::Error::Service) - }) - }, - } -} diff --git a/bin/millau/node/src/lib.rs b/bin/millau/node/src/lib.rs deleted file mode 100644 index 382d1c2d7fb1c..0000000000000 --- a/bin/millau/node/src/lib.rs +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Substrate Node Template CLI library. -#![warn(missing_docs)] - -mod chain_spec; -#[macro_use] -mod service; -mod cli; -mod command; - -/// Node run result. -pub type Result = sc_cli::Result<()>; - -/// Run node. -pub fn run() -> Result { - command::run() -} diff --git a/bin/millau/node/src/main.rs b/bin/millau/node/src/main.rs deleted file mode 100644 index cf6dd9f733a16..0000000000000 --- a/bin/millau/node/src/main.rs +++ /dev/null @@ -1,30 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Millau bridge node. - -#![warn(missing_docs)] - -mod chain_spec; -#[macro_use] -mod service; -mod cli; -mod command; - -/// Run the Millau Node -fn main() -> sc_cli::Result<()> { - command::run() -} diff --git a/bin/millau/node/src/service.rs b/bin/millau/node/src/service.rs deleted file mode 100644 index cb57dd118cc71..0000000000000 --- a/bin/millau/node/src/service.rs +++ /dev/null @@ -1,479 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Service and ServiceFactory implementation. Specialized wrapper over substrate service. - -use jsonrpsee::RpcModule; -use millau_runtime::{self, opaque::Block, RuntimeApi}; -use sc_client_api::{Backend, BlockBackend}; -use sc_consensus_aura::{CompatibilityMode, ImportQueueParams, SlotProportion, StartAuraParams}; -use sc_consensus_grandpa::SharedVoterState; -pub use sc_executor::NativeElseWasmExecutor; -use sc_executor::{HeapAllocStrategy, WasmExecutor, DEFAULT_HEAP_ALLOC_STRATEGY}; -use sc_service::{error::Error as ServiceError, Configuration, TaskManager}; -use sc_telemetry::{Telemetry, TelemetryWorker}; -use sc_transaction_pool_api::OffchainTransactionPoolFactory; -use sp_consensus_aura::sr25519::AuthorityPair as AuraPair; -use std::{sync::Arc, time::Duration}; - -// Our native executor instance. -pub struct ExecutorDispatch; - -impl sc_executor::NativeExecutionDispatch for ExecutorDispatch { - /// Only enable the benchmarking host functions when we actually want to benchmark. - #[cfg(feature = "runtime-benchmarks")] - type ExtendHostFunctions = frame_benchmarking::benchmarking::HostFunctions; - /// Otherwise we only use the default Substrate host functions. - #[cfg(not(feature = "runtime-benchmarks"))] - type ExtendHostFunctions = (); - - fn dispatch(method: &str, data: &[u8]) -> Option> { - millau_runtime::api::dispatch(method, data) - } - - fn native_version() -> sc_executor::NativeVersion { - millau_runtime::native_version() - } -} - -type FullClient = - sc_service::TFullClient>; -type FullBackend = sc_service::TFullBackend; -type FullSelectChain = sc_consensus::LongestChain; - -#[allow(clippy::type_complexity)] -pub fn new_partial( - config: &Configuration, -) -> Result< - sc_service::PartialComponents< - FullClient, - FullBackend, - FullSelectChain, - sc_consensus::DefaultImportQueue, - sc_transaction_pool::FullPool, - ( - sc_consensus_grandpa::GrandpaBlockImport< - FullBackend, - Block, - FullClient, - FullSelectChain, - >, - sc_consensus_grandpa::LinkHalf, - sc_consensus_beefy::BeefyVoterLinks, - sc_consensus_beefy::BeefyRPCLinks, - Option, - ), - >, - ServiceError, -> { - let telemetry = config - .telemetry_endpoints - .clone() - .filter(|x| !x.is_empty()) - .map(|endpoints| -> Result<_, sc_telemetry::Error> { - let worker = TelemetryWorker::new(16)?; - let telemetry = worker.handle().new_telemetry(endpoints); - Ok((worker, telemetry)) - }) - .transpose()?; - - let heap_pages = config - .default_heap_pages - .map_or(DEFAULT_HEAP_ALLOC_STRATEGY, |h| HeapAllocStrategy::Static { extra_pages: h as _ }); - let executor = NativeElseWasmExecutor::::new_with_wasm_executor( - WasmExecutor::builder() - .with_execution_method(config.wasm_method) - .with_onchain_heap_alloc_strategy(heap_pages) - .with_offchain_heap_alloc_strategy(heap_pages) - .with_max_runtime_instances(config.max_runtime_instances) - .with_runtime_cache_size(config.runtime_cache_size) - .build(), - ); - - let (client, backend, keystore_container, task_manager) = - sc_service::new_full_parts::( - config, - telemetry.as_ref().map(|(_, telemetry)| telemetry.handle()), - executor, - )?; - let client = Arc::new(client); - - let telemetry = telemetry.map(|(worker, telemetry)| { - task_manager.spawn_handle().spawn("telemetry", None, worker.run()); - telemetry - }); - - let select_chain = sc_consensus::LongestChain::new(backend.clone()); - - let transaction_pool = sc_transaction_pool::BasicPool::new_full( - config.transaction_pool.clone(), - config.role.is_authority().into(), - config.prometheus_registry(), - task_manager.spawn_essential_handle(), - client.clone(), - ); - - let (grandpa_block_import, grandpa_link) = sc_consensus_grandpa::block_import( - client.clone(), - 512, - &client, - select_chain.clone(), - telemetry.as_ref().map(|x| x.handle()), - )?; - - let (beefy_block_import, beefy_voter_links, beefy_rpc_links) = - sc_consensus_beefy::beefy_block_import_and_links( - grandpa_block_import.clone(), - backend.clone(), - client.clone(), - config.prometheus_registry().cloned(), - ); - - let slot_duration = sc_consensus_aura::slot_duration(&*client)?; - - let import_queue = - sc_consensus_aura::import_queue::(ImportQueueParams { - block_import: beefy_block_import, - justification_import: Some(Box::new(grandpa_block_import.clone())), - client: client.clone(), - create_inherent_data_providers: move |_, ()| async move { - let timestamp = sp_timestamp::InherentDataProvider::from_system_time(); - - let slot = - sp_consensus_aura::inherents::InherentDataProvider::from_timestamp_and_slot_duration( - *timestamp, - slot_duration, - ); - - Ok((slot, timestamp)) - }, - spawner: &task_manager.spawn_essential_handle(), - registry: config.prometheus_registry(), - check_for_equivocation: Default::default(), - telemetry: telemetry.as_ref().map(|x| x.handle()), - compatibility_mode: CompatibilityMode::None, - })?; - - Ok(sc_service::PartialComponents { - client, - backend, - task_manager, - import_queue, - keystore_container, - select_chain, - transaction_pool, - other: (grandpa_block_import, grandpa_link, beefy_voter_links, beefy_rpc_links, telemetry), - }) -} - -/// Builds a new service for a full client. -pub fn new_full(config: Configuration) -> Result { - use sc_service::WarpSyncParams; - - let sc_service::PartialComponents { - client, - backend, - mut task_manager, - import_queue, - keystore_container, - select_chain, - transaction_pool, - other: (block_import, grandpa_link, beefy_voter_links, beefy_rpc_links, mut telemetry), - } = new_partial(&config)?; - - let genesis_hash = client.block_hash(0).ok().flatten().expect("Genesis block exists; qed"); - - let mut net_config = sc_network::config::FullNetworkConfiguration::new(&config.network); - - // Note: GrandPa is pushed before the Polkadot-specific protocols. This doesn't change - // anything in terms of behaviour, but makes the logs more consistent with the other - // Substrate nodes. - let grandpa_protocol_name = sc_consensus_grandpa::protocol_standard_name( - &client.block_hash(0).ok().flatten().expect("Genesis block exists; qed"), - &config.chain_spec, - ); - net_config.add_notification_protocol(sc_consensus_grandpa::grandpa_peers_set_config( - grandpa_protocol_name.clone(), - )); - - let beefy_gossip_proto_name = - sc_consensus_beefy::gossip_protocol_name(genesis_hash, config.chain_spec.fork_id()); - // `beefy_on_demand_justifications_handler` is given to `beefy-gadget` task to be run, - // while `beefy_req_resp_cfg` is added to `config.network.request_response_protocols`. - let (beefy_on_demand_justifications_handler, beefy_req_resp_cfg) = - sc_consensus_beefy::communication::request_response::BeefyJustifsRequestHandler::new( - genesis_hash, - config.chain_spec.fork_id(), - client.clone(), - config.prometheus_registry().cloned(), - ); - net_config.add_notification_protocol( - sc_consensus_beefy::communication::beefy_peers_set_config(beefy_gossip_proto_name.clone()), - ); - net_config.add_request_response_protocol(beefy_req_resp_cfg); - - let role = config.role.clone(); - let warp_sync = Arc::new(sc_consensus_grandpa::warp_proof::NetworkProvider::new( - backend.clone(), - grandpa_link.shared_authority_set().clone(), - Vec::default(), - )); - - let (network, system_rpc_tx, tx_handler_controller, network_starter, sync_service) = - sc_service::build_network(sc_service::BuildNetworkParams { - config: &config, - net_config, - client: client.clone(), - transaction_pool: transaction_pool.clone(), - spawn_handle: task_manager.spawn_handle(), - import_queue, - block_announce_validator_builder: None, - warp_sync_params: Some(WarpSyncParams::WithProvider(warp_sync)), - block_relay: None, - })?; - - if config.offchain_worker.enabled { - use futures::FutureExt; - - task_manager.spawn_handle().spawn( - "offchain-workers-runner", - "offchain-work", - sc_offchain::OffchainWorkers::new(sc_offchain::OffchainWorkerOptions { - runtime_api_provider: client.clone(), - keystore: Some(keystore_container.keystore()), - offchain_db: backend.offchain_storage(), - transaction_pool: Some(OffchainTransactionPoolFactory::new( - transaction_pool.clone(), - )), - network_provider: network.clone(), - is_validator: role.is_authority(), - enable_http_requests: false, - custom_extensions: move |_| vec![], - }) - .run(client.clone(), task_manager.spawn_handle()) - .boxed(), - ); - } - - let force_authoring = config.force_authoring; - let backoff_authoring_blocks: Option<()> = None; - let name = config.network.node_name.clone(); - let enable_grandpa = !config.disable_grandpa; - let prometheus_registry = config.prometheus_registry().cloned(); - let shared_voter_state = SharedVoterState::empty(); - - let rpc_extensions_builder = { - use sc_consensus_grandpa::FinalityProofProvider as GrandpaFinalityProofProvider; - - use mmr_rpc::{Mmr, MmrApiServer}; - use pallet_transaction_payment_rpc::{TransactionPayment, TransactionPaymentApiServer}; - use sc_consensus_beefy_rpc::{Beefy, BeefyApiServer}; - use sc_consensus_grandpa_rpc::{Grandpa, GrandpaApiServer}; - use sc_rpc::DenyUnsafe; - use substrate_frame_rpc_system::{System, SystemApiServer}; - - let backend = backend.clone(); - let client = client.clone(); - let pool = transaction_pool.clone(); - - let justification_stream = grandpa_link.justification_stream(); - let shared_authority_set = grandpa_link.shared_authority_set().clone(); - let shared_voter_state = shared_voter_state.clone(); - - let finality_proof_provider = GrandpaFinalityProofProvider::new_for_service( - backend.clone(), - Some(shared_authority_set.clone()), - ); - - Box::new(move |_, subscription_executor: sc_rpc::SubscriptionTaskExecutor| { - let mut io = RpcModule::new(()); - let map_err = |e| sc_service::Error::Other(format!("{e}")); - io.merge(System::new(client.clone(), pool.clone(), DenyUnsafe::No).into_rpc()) - .map_err(map_err)?; - io.merge(TransactionPayment::new(client.clone()).into_rpc()).map_err(map_err)?; - io.merge( - Grandpa::new( - subscription_executor.clone(), - shared_authority_set.clone(), - shared_voter_state.clone(), - justification_stream.clone(), - finality_proof_provider.clone(), - ) - .into_rpc(), - ) - .map_err(map_err)?; - io.merge( - Beefy::::new( - beefy_rpc_links.from_voter_justif_stream.clone(), - beefy_rpc_links.from_voter_best_beefy_stream.clone(), - subscription_executor, - ) - .map_err(|e| sc_service::Error::Other(format!("{e}")))? - .into_rpc(), - ) - .map_err(map_err)?; - io.merge( - Mmr::new( - client.clone(), - backend - .offchain_storage() - .ok_or("Backend doesn't provide the required offchain storage")?, - ) - .into_rpc(), - ) - .map_err(map_err)?; - Ok(io) - }) - }; - - let _rpc_handlers = sc_service::spawn_tasks(sc_service::SpawnTasksParams { - network: network.clone(), - client: client.clone(), - keystore: keystore_container.keystore(), - task_manager: &mut task_manager, - transaction_pool: transaction_pool.clone(), - sync_service: sync_service.clone(), - rpc_builder: rpc_extensions_builder, - backend: backend.clone(), - system_rpc_tx, - config, - tx_handler_controller, - telemetry: telemetry.as_mut(), - })?; - - if role.is_authority() { - let proposer_factory = sc_basic_authorship::ProposerFactory::new( - task_manager.spawn_handle(), - client.clone(), - transaction_pool.clone(), - prometheus_registry.as_ref(), - telemetry.as_ref().map(|x| x.handle()), - ); - - let slot_duration = sc_consensus_aura::slot_duration(&*client)?; - - let aura = sc_consensus_aura::start_aura::( - StartAuraParams { - slot_duration, - client: client.clone(), - select_chain, - block_import, - proposer_factory, - create_inherent_data_providers: move |_, ()| async move { - let timestamp = sp_timestamp::InherentDataProvider::from_system_time(); - - let slot = - sp_consensus_aura::inherents::InherentDataProvider::from_timestamp_and_slot_duration( - *timestamp, - slot_duration, - ); - - Ok((slot, timestamp)) - }, - force_authoring, - backoff_authoring_blocks, - keystore: keystore_container.keystore(), - sync_oracle: sync_service.clone(), - justification_sync_link: sync_service.clone(), - block_proposal_slot_portion: SlotProportion::new(2f32 / 3f32), - max_block_proposal_slot_portion: None, - telemetry: telemetry.as_ref().map(|x| x.handle()), - compatibility_mode: CompatibilityMode::None, - }, - )?; - - // the AURA authoring task is considered essential, i.e. if it - // fails we take down the service with it. - task_manager - .spawn_essential_handle() - .spawn_blocking("aura", Some("block-authoring"), aura); - } - - // if the node isn't actively participating in consensus then it doesn't - // need a keystore, regardless of which protocol we use below. - let keystore = if role.is_authority() { Some(keystore_container.keystore()) } else { None }; - - let justifications_protocol_name = beefy_on_demand_justifications_handler.protocol_name(); - let payload_provider = sp_consensus_beefy::mmr::MmrRootProvider::new(client.clone()); - let beefy_params = sc_consensus_beefy::BeefyParams { - client: client.clone(), - backend, - payload_provider, - runtime: client, - key_store: keystore.clone(), - network_params: sc_consensus_beefy::BeefyNetworkParams { - network: network.clone(), - sync: sync_service.clone(), - gossip_protocol_name: beefy_gossip_proto_name, - justifications_protocol_name, - _phantom: core::marker::PhantomData::, - }, - min_block_delta: 2, - prometheus_registry: prometheus_registry.clone(), - links: beefy_voter_links, - on_demand_justifications_handler: beefy_on_demand_justifications_handler, - }; - - // Start the BEEFY bridge gadget. - task_manager.spawn_essential_handle().spawn_blocking( - "beefy-gadget", - None, - sc_consensus_beefy::start_beefy_gadget::<_, _, _, _, _, _, _>(beefy_params), - ); - - let grandpa_config = sc_consensus_grandpa::Config { - // FIXME #1578 make this available through chainspec - gossip_duration: Duration::from_millis(333), - justification_generation_period: 512, - name: Some(name), - observer_enabled: false, - keystore, - local_role: role, - telemetry: telemetry.as_ref().map(|x| x.handle()), - protocol_name: grandpa_protocol_name, - }; - - if enable_grandpa { - // start the full GRANDPA voter - // NOTE: non-authorities could run the GRANDPA observer protocol, but at - // this point the full voter should provide better guarantees of block - // and vote data availability than the observer. The observer has not - // been tested extensively yet and having most nodes in a network run it - // could lead to finality stalls. - let grandpa_config = sc_consensus_grandpa::GrandpaParams { - config: grandpa_config, - link: grandpa_link, - network, - sync: sync_service, - voting_rule: sc_consensus_grandpa::VotingRulesBuilder::default().build(), - prometheus_registry, - shared_voter_state, - telemetry: telemetry.as_ref().map(|x| x.handle()), - offchain_tx_pool_factory: OffchainTransactionPoolFactory::new(transaction_pool), - }; - - // the GRANDPA voter task is considered infallible, i.e. - // if it fails we take down the service with it. - task_manager.spawn_essential_handle().spawn_blocking( - "grandpa-voter", - None, - sc_consensus_grandpa::run_grandpa_voter(grandpa_config)?, - ); - } - - network_starter.start_network(); - Ok(task_manager) -} diff --git a/bin/millau/runtime/Cargo.toml b/bin/millau/runtime/Cargo.toml deleted file mode 100644 index 7e963d6b74d0b..0000000000000 --- a/bin/millau/runtime/Cargo.toml +++ /dev/null @@ -1,155 +0,0 @@ -[package] -name = "millau-runtime" -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -repository = "https://github.com/paritytech/parity-bridges-common/" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[dependencies] -hex-literal = "0.4" -codec = { package = "parity-scale-codec", version = "3.1.5", default-features = false, features = ["derive"] } -scale-info = { version = "2.10.0", default-features = false, features = ["derive"] } - -# Bridge dependencies - -bp-header-chain = { path = "../../../primitives/header-chain", default-features = false } -bp-messages = { path = "../../../primitives/messages", default-features = false } -bp-millau = { path = "../../../primitives/chain-millau", default-features = false } -bp-parachains = { path = "../../../primitives/parachains", default-features = false } -bp-polkadot-core = { path = "../../../primitives/polkadot-core", default-features = false } -bp-relayers = { path = "../../../primitives/relayers", default-features = false } -bp-rialto = { path = "../../../primitives/chain-rialto", default-features = false } -bp-rialto-parachain = { path = "../../../primitives/chain-rialto-parachain", default-features = false } -bp-runtime = { path = "../../../primitives/runtime", default-features = false } -bp-westend = { path = "../../../primitives/chain-westend", default-features = false } -bp-xcm-bridge-hub-router = { path = "../../../primitives/xcm-bridge-hub-router", default-features = false } -bridge-runtime-common = { path = "../../runtime-common", default-features = false } -pallet-bridge-grandpa = { path = "../../../modules/grandpa", default-features = false } -pallet-bridge-messages = { path = "../../../modules/messages", default-features = false } -pallet-bridge-parachains = { path = "../../../modules/parachains", default-features = false } -pallet-bridge-relayers = { path = "../../../modules/relayers", default-features = false } -pallet-shift-session-manager = { path = "../../../modules/shift-session-manager", default-features = false } -pallet-xcm-bridge-hub-router = { path = "../../../modules/xcm-bridge-hub-router", default-features = false } - -# Substrate Dependencies - -sp-consensus-beefy = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-benchmarking = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false, optional = true } -frame-executive = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-support = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-system-rpc-runtime-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-aura = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-authorship = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-balances = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-beefy = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-beefy-mmr = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-grandpa = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-mmr = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-offences = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-session = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false, features = ["historical"]} -pallet-sudo = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-timestamp = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-transaction-payment = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-transaction-payment-rpc-runtime-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-utility = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-block-builder = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-consensus-aura = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-inherents = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-io = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-offchain = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-session = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-std = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-transaction-pool = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-version = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -# Polkadot Dependencies -pallet-xcm = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -xcm = { package = "staging-xcm", git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -xcm-builder = { package = "staging-xcm-builder", git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -xcm-executor = { package = "staging-xcm-executor", git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -[dev-dependencies] -bridge-runtime-common = { path = "../../runtime-common", features = ["integrity-test", "std"] } -env_logger = "0.10" -static_assertions = "1.1" - -[build-dependencies] -substrate-wasm-builder = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -[features] -default = [ "std" ] -std = [ - "bp-messages/std", - "bp-millau/std", - "bp-parachains/std", - "bp-polkadot-core/std", - "bp-relayers/std", - "bp-rialto-parachain/std", - "bp-rialto/std", - "bp-runtime/std", - "bp-westend/std", - "bp-xcm-bridge-hub-router/std", - "bridge-runtime-common/std", - "codec/std", - "frame-executive/std", - "frame-support/std", - "frame-system-rpc-runtime-api/std", - "frame-system/std", - "pallet-aura/std", - "pallet-authorship/std", - "pallet-balances/std", - "pallet-beefy-mmr/std", - "pallet-beefy/std", - "pallet-bridge-grandpa/std", - "pallet-bridge-messages/std", - "pallet-bridge-parachains/std", - "pallet-bridge-relayers/std", - "pallet-grandpa/std", - "pallet-mmr/std", - "pallet-offences/std", - "pallet-session/std", - "pallet-shift-session-manager/std", - "pallet-sudo/std", - "pallet-timestamp/std", - "pallet-transaction-payment-rpc-runtime-api/std", - "pallet-transaction-payment/std", - "pallet-utility/std", - "pallet-xcm-bridge-hub-router/std", - "pallet-xcm/std", - "scale-info/std", - "sp-api/std", - "sp-block-builder/std", - "sp-consensus-aura/std", - "sp-consensus-beefy/std", - "sp-core/std", - "sp-inherents/std", - "sp-io/std", - "sp-offchain/std", - "sp-runtime/std", - "sp-session/std", - "sp-std/std", - "sp-transaction-pool/std", - "sp-version/std", - "xcm-builder/std", - "xcm-executor/std", - "xcm/std", -] -runtime-benchmarks = [ - "bridge-runtime-common/runtime-benchmarks", - "frame-benchmarking/runtime-benchmarks", - "frame-support/runtime-benchmarks", - "frame-system/runtime-benchmarks", - "pallet-bridge-grandpa/runtime-benchmarks", - "pallet-bridge-messages/runtime-benchmarks", - "pallet-bridge-parachains/runtime-benchmarks", - "pallet-bridge-relayers/runtime-benchmarks", - "pallet-xcm-bridge-hub-router/runtime-benchmarks", - "pallet-xcm/runtime-benchmarks", - "sp-runtime/runtime-benchmarks", - "xcm-builder/runtime-benchmarks", -] diff --git a/bin/millau/runtime/build.rs b/bin/millau/runtime/build.rs deleted file mode 100644 index 25e220e46fc3b..0000000000000 --- a/bin/millau/runtime/build.rs +++ /dev/null @@ -1,26 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use substrate_wasm_builder::WasmBuilder; - -fn main() { - WasmBuilder::new() - .with_current_project() - .import_memory() - .export_heap_base() - .disable_runtime_version_section_check() - .build() -} diff --git a/bin/millau/runtime/src/lib.rs b/bin/millau/runtime/src/lib.rs deleted file mode 100644 index a349551a873c0..0000000000000 --- a/bin/millau/runtime/src/lib.rs +++ /dev/null @@ -1,1300 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! The Millau runtime. This can be compiled with `#[no_std]`, ready for Wasm. - -#![cfg_attr(not(feature = "std"), no_std)] -// `construct_runtime!` does a lot of recursion and requires us to increase the limit to 256. -#![recursion_limit = "256"] -// Runtime-generated enums -#![allow(clippy::large_enum_variant)] -// From construct_runtime macro -#![allow(clippy::from_over_into)] - -// Make the WASM binary available. -#[cfg(feature = "std")] -include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs")); - -pub mod rialto_messages; -pub mod rialto_parachain_messages; -pub mod weights; -pub mod xcm_config; - -use bp_parachains::SingleParaStoredHeaderDataBuilder; -#[cfg(feature = "runtime-benchmarks")] -use bp_relayers::{RewardsAccountOwner, RewardsAccountParams}; -use bp_runtime::HeaderId; -use pallet_grandpa::{ - fg_primitives, AuthorityId as GrandpaId, AuthorityList as GrandpaAuthorityList, -}; -use pallet_transaction_payment::{FeeDetails, Multiplier, RuntimeDispatchInfo}; -use sp_api::impl_runtime_apis; -use sp_consensus_aura::sr25519::AuthorityId as AuraId; -use sp_consensus_beefy::{ecdsa_crypto::AuthorityId as BeefyId, mmr::MmrLeafVersion, ValidatorSet}; -use sp_core::OpaqueMetadata; -use sp_runtime::{ - create_runtime_str, generic, impl_opaque_keys, - traits::{Block as BlockT, IdentityLookup, Keccak256, NumberFor, OpaqueKeys}, - transaction_validity::{TransactionSource, TransactionValidity}, - ApplyExtrinsicResult, FixedPointNumber, KeyTypeId, Perquintill, -}; -use sp_std::prelude::*; -#[cfg(feature = "std")] -use sp_version::NativeVersion; -use sp_version::RuntimeVersion; -use xcm_builder::{NetworkExportTable, NetworkExportTableItem}; - -// to be able to use Millau runtime in `bridge-runtime-common` tests -pub use bridge_runtime_common; - -// A few exports that help ease life for downstream crates. -pub use frame_support::{ - construct_runtime, - dispatch::DispatchClass, - parameter_types, - traits::{ - ConstBool, ConstU128, ConstU32, ConstU64, ConstU8, Currency, ExistenceRequirement, - Imbalance, KeyOwnerProofSystem, - }, - weights::{ - constants::WEIGHT_REF_TIME_PER_SECOND, ConstantMultiplier, IdentityFee, RuntimeDbWeight, - Weight, - }, - StorageValue, -}; - -pub use frame_system::Call as SystemCall; -pub use pallet_balances::Call as BalancesCall; -pub use pallet_bridge_grandpa::Call as BridgeGrandpaCall; -pub use pallet_bridge_messages::Call as MessagesCall; -pub use pallet_bridge_parachains::Call as BridgeParachainsCall; -pub use pallet_sudo::Call as SudoCall; -pub use pallet_timestamp::Call as TimestampCall; -pub use pallet_xcm::Call as XcmCall; - -use bridge_runtime_common::{ - generate_bridge_reject_obsolete_headers_and_messages, - refund_relayer_extension::{ - ActualFeeRefund, RefundBridgedParachainMessages, RefundSignedExtensionAdapter, - RefundableMessagesLane, RefundableParachain, - }, -}; -#[cfg(any(feature = "std", test))] -pub use sp_runtime::BuildStorage; -pub use sp_runtime::{Perbill, Permill}; - -/// An index to a block. -pub type BlockNumber = bp_millau::BlockNumber; - -/// Alias to 512-bit hash when used in the context of a transaction signature on the chain. -pub type Signature = bp_millau::Signature; - -/// Some way of identifying an account on the chain. We intentionally make it equivalent -/// to the public key of our transaction signing scheme. -pub type AccountId = bp_millau::AccountId; - -/// The type for looking up accounts. We don't expect more than 4 billion of them, but you -/// never know... -pub type AccountIndex = u32; - -/// Balance of an account. -pub type Balance = bp_millau::Balance; - -/// Nonce of a transaction in the chain. -pub type Nonce = bp_millau::Nonce; - -/// A hash of some data used by the chain. -pub type Hash = bp_millau::Hash; - -/// Hashing algorithm used by the chain. -pub type Hashing = bp_millau::Hasher; - -/// Opaque types. These are used by the CLI to instantiate machinery that don't need to know -/// the specifics of the runtime. They can then be made to be agnostic over specific formats -/// of data like extrinsics, allowing for them to continue syncing the network through upgrades -/// to even the core data structures. -pub mod opaque { - use super::*; - - pub use sp_runtime::OpaqueExtrinsic as UncheckedExtrinsic; - - /// Opaque block header type. - pub type Header = generic::Header; - /// Opaque block type. - pub type Block = generic::Block; - /// Opaque block identifier type. - pub type BlockId = generic::BlockId; -} - -impl_opaque_keys! { - pub struct SessionKeys { - pub aura: Aura, - pub beefy: Beefy, - pub grandpa: Grandpa, - } -} - -/// This runtime version. -#[sp_version::runtime_version] -pub const VERSION: RuntimeVersion = RuntimeVersion { - spec_name: create_runtime_str!("millau-runtime"), - impl_name: create_runtime_str!("millau-runtime"), - authoring_version: 1, - spec_version: 1, - impl_version: 1, - apis: RUNTIME_API_VERSIONS, - transaction_version: 1, - state_version: 0, -}; - -/// The version information used to identify this runtime when compiled natively. -#[cfg(feature = "std")] -pub fn native_version() -> NativeVersion { - NativeVersion { runtime_version: VERSION, can_author_with: Default::default() } -} - -parameter_types! { - pub const BlockHashCount: BlockNumber = 250; - pub const Version: RuntimeVersion = VERSION; - pub const DbWeight: RuntimeDbWeight = RuntimeDbWeight { - read: 60_000_000, // ~0.06 ms = ~60 µs - write: 200_000_000, // ~0.2 ms = 200 µs - }; - pub const SS58Prefix: u8 = 60; -} - -impl frame_system::Config for Runtime { - /// The basic call filter to use in dispatchable. - type BaseCallFilter = frame_support::traits::Everything; - /// The identifier used to distinguish between accounts. - type AccountId = AccountId; - /// The aggregated dispatch type that is available for extrinsics. - type RuntimeCall = RuntimeCall; - /// The lookup mechanism to get account ID from whatever is passed in dispatchers. - type Lookup = IdentityLookup; - /// The index type for storing how many extrinsics an account has signed. - type Nonce = Nonce; - /// The type for hashing blocks and tries. - type Hash = Hash; - /// The hashing algorithm used. - type Hashing = Hashing; - /// The header type. - type Block = Block; - /// The ubiquitous event type. - type RuntimeEvent = RuntimeEvent; - /// The ubiquitous origin type. - type RuntimeOrigin = RuntimeOrigin; - /// Maximum number of block number to block hash mappings to keep (oldest pruned first). - type BlockHashCount = BlockHashCount; - /// Version of the runtime. - type Version = Version; - /// Provides information about the pallet setup in the runtime. - type PalletInfo = PalletInfo; - /// What to do if a new account is created. - type OnNewAccount = (); - /// What to do if an account is fully reaped from the system. - type OnKilledAccount = (); - /// The data to be stored in an account. - type AccountData = pallet_balances::AccountData; - // TODO: update me (https://github.com/paritytech/parity-bridges-common/issues/78) - /// Weight information for the extrinsics of this pallet. - type SystemWeightInfo = (); - /// Block and extrinsics weights: base values and limits. - type BlockWeights = bp_millau::BlockWeights; - /// The maximum length of a block (in bytes). - type BlockLength = bp_millau::BlockLength; - /// The weight of database operations that the runtime can invoke. - type DbWeight = DbWeight; - /// The designated SS58 prefix of this chain. - type SS58Prefix = SS58Prefix; - /// The set code logic, just the default since we're not a parachain. - type OnSetCode = (); - type MaxConsumers = frame_support::traits::ConstU32<16>; -} - -impl pallet_aura::Config for Runtime { - type AuthorityId = AuraId; - type MaxAuthorities = ConstU32<10>; - type DisabledValidators = (); - type AllowMultipleBlocksPerSlot = ConstBool; -} - -impl pallet_beefy::Config for Runtime { - type BeefyId = BeefyId; - type MaxAuthorities = ConstU32<10>; - type MaxSetIdSessionEntries = ConstU64<0>; - type OnNewValidatorSet = MmrLeaf; - type WeightInfo = (); - type KeyOwnerProof = sp_core::Void; - type EquivocationReportSystem = (); - type MaxNominators = ConstU32<256>; -} - -impl pallet_grandpa::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - // TODO: update me (https://github.com/paritytech/parity-bridges-common/issues/78) - type WeightInfo = (); - type MaxAuthorities = ConstU32<10>; - type MaxSetIdSessionEntries = ConstU64<0>; - type KeyOwnerProof = >::Proof; - type EquivocationReportSystem = - pallet_grandpa::EquivocationReportSystem; - type MaxNominators = ConstU32<256>; -} - -/// MMR helper types. -mod mmr { - use super::Runtime; - pub use pallet_mmr::primitives::*; - - pub type Leaf = <::LeafData as LeafDataProvider>::LeafData; - pub type Hashing = ::Hashing; - pub type Hash = ::Output; -} - -impl pallet_mmr::Config for Runtime { - const INDEXING_PREFIX: &'static [u8] = b"mmr"; - type Hashing = Keccak256; - type OnNewRoot = pallet_beefy_mmr::DepositBeefyDigest; - type WeightInfo = (); - type LeafData = pallet_beefy_mmr::Pallet; -} - -parameter_types! { - /// Version of the produced MMR leaf. - /// - /// The version consists of two parts; - /// - `major` (3 bits) - /// - `minor` (5 bits) - /// - /// `major` should be updated only if decoding the previous MMR Leaf format from the payload - /// is not possible (i.e. backward incompatible change). - /// `minor` should be updated if fields are added to the previous MMR Leaf, which given SCALE - /// encoding does not prevent old leafs from being decoded. - /// - /// Hence we expect `major` to be changed really rarely (think never). - /// See [`MmrLeafVersion`] type documentation for more details. - pub LeafVersion: MmrLeafVersion = MmrLeafVersion::new(0, 0); -} - -pub struct BeefyDummyDataProvider; - -impl sp_consensus_beefy::mmr::BeefyDataProvider<()> for BeefyDummyDataProvider { - fn extra_data() {} -} - -impl pallet_beefy_mmr::Config for Runtime { - type LeafVersion = LeafVersion; - type BeefyAuthorityToMerkleLeaf = pallet_beefy_mmr::BeefyEcdsaToEthereum; - type LeafExtra = (); - type BeefyDataProvider = BeefyDummyDataProvider; -} - -parameter_types! { - pub const MinimumPeriod: u64 = bp_millau::SLOT_DURATION / 2; -} - -impl pallet_timestamp::Config for Runtime { - /// A timestamp: milliseconds since the UNIX epoch. - type Moment = u64; - type OnTimestampSet = Aura; - type MinimumPeriod = MinimumPeriod; - // TODO: update me (https://github.com/paritytech/parity-bridges-common/issues/78) - type WeightInfo = (); -} - -parameter_types! { - pub const ExistentialDeposit: bp_millau::Balance = 500; -} - -impl pallet_balances::Config for Runtime { - /// The type for recording an account's balance. - type Balance = Balance; - /// The ubiquitous event type. - type RuntimeEvent = RuntimeEvent; - type DustRemoval = (); - type ExistentialDeposit = ExistentialDeposit; - type AccountStore = System; - // TODO: update me (https://github.com/paritytech/parity-bridges-common/issues/78) - type WeightInfo = (); - // For weight estimation, we assume that the most locks on an individual account will be 50. - // This number may need to be adjusted in the future if this assumption no longer holds true. - type MaxLocks = ConstU32<50>; - type MaxReserves = ConstU32<50>; - type ReserveIdentifier = [u8; 8]; - type RuntimeHoldReason = RuntimeHoldReason; - type FreezeIdentifier = (); - type MaxHolds = ConstU32<0>; - type MaxFreezes = ConstU32<0>; -} - -parameter_types! { - pub const TransactionBaseFee: Balance = 0; - pub const TransactionByteFee: Balance = 1; - // values for following parameters are copied from polkadot repo, but it is fine - // not to sync them - we're not going to make Rialto a full copy of one of Polkadot-like chains - pub const TargetBlockFullness: Perquintill = Perquintill::from_percent(25); - pub AdjustmentVariable: Multiplier = Multiplier::saturating_from_rational(3, 100_000); - pub MinimumMultiplier: Multiplier = Multiplier::saturating_from_rational(1, 1_000_000u128); - pub MaximumMultiplier: Multiplier = sp_runtime::traits::Bounded::max_value(); -} - -impl pallet_transaction_payment::Config for Runtime { - type OnChargeTransaction = pallet_transaction_payment::CurrencyAdapter; - type OperationalFeeMultiplier = ConstU8<5>; - type WeightToFee = bp_millau::WeightToFee; - type LengthToFee = ConstantMultiplier; - type FeeMultiplierUpdate = pallet_transaction_payment::TargetedFeeAdjustment< - Runtime, - TargetBlockFullness, - AdjustmentVariable, - MinimumMultiplier, - MaximumMultiplier, - >; - type RuntimeEvent = RuntimeEvent; -} - -impl pallet_sudo::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type RuntimeCall = RuntimeCall; - type WeightInfo = pallet_sudo::weights::SubstrateWeight; -} - -parameter_types! { - /// Authorities are changing every 5 minutes. - pub const Period: BlockNumber = bp_millau::SESSION_LENGTH; - pub const Offset: BlockNumber = 0; - pub const RelayerStakeReserveId: [u8; 8] = *b"brdgrlrs"; - pub ReportLongevity: u64 = Period::get() * 10; -} - -impl pallet_session::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type ValidatorId = ::AccountId; - type ValidatorIdOf = (); - type ShouldEndSession = pallet_session::PeriodicSessions; - type NextSessionRotation = pallet_session::PeriodicSessions; - type SessionManager = pallet_shift_session_manager::Pallet; - type SessionHandler = ::KeyTypeIdProviders; - type Keys = SessionKeys; - // TODO: update me (https://github.com/paritytech/parity-bridges-common/issues/78) - type WeightInfo = (); -} - -impl frame_system::offchain::SendTransactionTypes for Runtime -where - RuntimeCall: From, -{ - type Extrinsic = UncheckedExtrinsic; - type OverarchingCall = RuntimeCall; -} - -impl pallet_authorship::Config for Runtime { - type FindAuthor = pallet_session::FindAccountFromAuthorIndex; - type EventHandler = (); -} - -pub struct FullIdentificationOf; -impl sp_runtime::traits::Convert> for FullIdentificationOf { - fn convert(_: AccountId) -> Option<()> { - Some(()) - } -} - -impl pallet_session::historical::Config for Runtime { - type FullIdentification = (); - type FullIdentificationOf = FullIdentificationOf; -} - -impl pallet_offences::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type IdentificationTuple = pallet_session::historical::IdentificationTuple; - type OnOffenceHandler = (); -} - -impl pallet_bridge_relayers::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type Reward = Balance; - type PaymentProcedure = - bp_relayers::PayRewardFromAccount, AccountId>; - type StakeAndSlash = pallet_bridge_relayers::StakeAndSlashNamed< - AccountId, - BlockNumber, - Balances, - RelayerStakeReserveId, - ConstU64<1_000>, - ConstU64<8>, - >; - type WeightInfo = (); -} - -pub type RialtoGrandpaInstance = (); -impl pallet_bridge_grandpa::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type BridgedChain = bp_rialto::Rialto; - type MaxFreeMandatoryHeadersPerBlock = ConstU32<4>; - type HeadersToKeep = ConstU32<{ bp_rialto::DAYS }>; - type WeightInfo = pallet_bridge_grandpa::weights::BridgeWeight; -} - -pub type WestendGrandpaInstance = pallet_bridge_grandpa::Instance1; -impl pallet_bridge_grandpa::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type BridgedChain = bp_westend::Westend; - type MaxFreeMandatoryHeadersPerBlock = ConstU32<4>; - type HeadersToKeep = ConstU32<{ bp_westend::DAYS }>; - type WeightInfo = pallet_bridge_grandpa::weights::BridgeWeight; -} - -impl pallet_shift_session_manager::Config for Runtime {} - -parameter_types! { - pub const MaxMessagesToPruneAtOnce: bp_messages::MessageNonce = 8; - pub const MaxUnrewardedRelayerEntriesAtInboundLane: bp_messages::MessageNonce = - bp_rialto::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX; - pub const MaxUnconfirmedMessagesAtInboundLane: bp_messages::MessageNonce = - bp_rialto::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX; - pub const RootAccountForPayments: Option = None; - pub const RialtoChainId: bp_runtime::ChainId = bp_runtime::RIALTO_CHAIN_ID; - pub const RialtoParachainChainId: bp_runtime::ChainId = bp_runtime::RIALTO_PARACHAIN_CHAIN_ID; - pub RialtoActiveOutboundLanes: &'static [bp_messages::LaneId] = &[rialto_messages::XCM_LANE]; - pub RialtoParachainActiveOutboundLanes: &'static [bp_messages::LaneId] = &[rialto_parachain_messages::XCM_LANE]; -} - -/// Instance of the messages pallet used to relay messages to/from Rialto chain. -pub type WithRialtoMessagesInstance = (); - -impl pallet_bridge_messages::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type WeightInfo = weights::RialtoMessagesWeightInfo; - type ActiveOutboundLanes = RialtoActiveOutboundLanes; - type MaxUnrewardedRelayerEntriesAtInboundLane = MaxUnrewardedRelayerEntriesAtInboundLane; - type MaxUnconfirmedMessagesAtInboundLane = MaxUnconfirmedMessagesAtInboundLane; - - type MaximalOutboundPayloadSize = crate::rialto_messages::ToRialtoMaximalOutboundPayloadSize; - type OutboundPayload = crate::rialto_messages::ToRialtoMessagePayload; - - type InboundPayload = crate::rialto_messages::FromRialtoMessagePayload; - type InboundRelayer = bp_rialto::AccountId; - type DeliveryPayments = (); - - type TargetHeaderChain = crate::rialto_messages::RialtoAsTargetHeaderChain; - type LaneMessageVerifier = crate::rialto_messages::ToRialtoMessageVerifier; - type DeliveryConfirmationPayments = pallet_bridge_relayers::DeliveryConfirmationPaymentsAdapter< - Runtime, - WithRialtoMessagesInstance, - frame_support::traits::ConstU64<100_000>, - >; - type OnMessagesDelivered = (); - - type SourceHeaderChain = crate::rialto_messages::RialtoAsSourceHeaderChain; - type MessageDispatch = crate::rialto_messages::FromRialtoMessageDispatch; - type BridgedChainId = RialtoChainId; -} - -/// Instance of the messages pallet used to relay messages to/from RialtoParachain chain. -pub type WithRialtoParachainMessagesInstance = pallet_bridge_messages::Instance1; - -impl pallet_bridge_messages::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type WeightInfo = weights::RialtoParachainMessagesWeightInfo; - type ActiveOutboundLanes = RialtoParachainActiveOutboundLanes; - type MaxUnrewardedRelayerEntriesAtInboundLane = MaxUnrewardedRelayerEntriesAtInboundLane; - type MaxUnconfirmedMessagesAtInboundLane = MaxUnconfirmedMessagesAtInboundLane; - - type MaximalOutboundPayloadSize = - crate::rialto_parachain_messages::ToRialtoParachainMaximalOutboundPayloadSize; - type OutboundPayload = crate::rialto_parachain_messages::ToRialtoParachainMessagePayload; - - type InboundPayload = crate::rialto_parachain_messages::FromRialtoParachainMessagePayload; - type InboundRelayer = bp_rialto_parachain::AccountId; - type DeliveryPayments = (); - - type TargetHeaderChain = crate::rialto_parachain_messages::RialtoParachainAsTargetHeaderChain; - type LaneMessageVerifier = crate::rialto_parachain_messages::ToRialtoParachainMessageVerifier; - type DeliveryConfirmationPayments = pallet_bridge_relayers::DeliveryConfirmationPaymentsAdapter< - Runtime, - WithRialtoParachainMessagesInstance, - frame_support::traits::ConstU64<100_000>, - >; - type OnMessagesDelivered = (); - - type SourceHeaderChain = crate::rialto_parachain_messages::RialtoParachainAsSourceHeaderChain; - type MessageDispatch = crate::rialto_parachain_messages::FromRialtoParachainMessageDispatch; - type BridgedChainId = RialtoParachainChainId; -} - -parameter_types! { - pub const RialtoParachainMessagesLane: bp_messages::LaneId = rialto_parachain_messages::XCM_LANE; - pub const RialtoParasPalletName: &'static str = bp_rialto::PARAS_PALLET_NAME; - pub const WestendParasPalletName: &'static str = bp_westend::PARAS_PALLET_NAME; - pub const MaxRialtoParaHeadDataSize: u32 = bp_rialto::MAX_NESTED_PARACHAIN_HEAD_DATA_SIZE; - pub const MaxWestendParaHeadDataSize: u32 = bp_westend::MAX_NESTED_PARACHAIN_HEAD_DATA_SIZE; -} - -/// Instance of the with-Rialto parachains pallet. -pub type WithRialtoParachainsInstance = (); - -impl pallet_bridge_parachains::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type WeightInfo = pallet_bridge_parachains::weights::BridgeWeight; - type BridgesGrandpaPalletInstance = RialtoGrandpaInstance; - type ParasPalletName = RialtoParasPalletName; - type ParaStoredHeaderDataBuilder = - SingleParaStoredHeaderDataBuilder; - type HeadsToKeep = ConstU32<1024>; - type MaxParaHeadDataSize = MaxRialtoParaHeadDataSize; -} - -/// Instance of the with-Westend parachains pallet. -pub type WithWestendParachainsInstance = pallet_bridge_parachains::Instance1; - -impl pallet_bridge_parachains::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type WeightInfo = pallet_bridge_parachains::weights::BridgeWeight; - type BridgesGrandpaPalletInstance = WestendGrandpaInstance; - type ParasPalletName = WestendParasPalletName; - type ParaStoredHeaderDataBuilder = - SingleParaStoredHeaderDataBuilder; - type HeadsToKeep = ConstU32<1024>; - type MaxParaHeadDataSize = MaxWestendParaHeadDataSize; -} - -impl pallet_utility::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type RuntimeCall = RuntimeCall; - type PalletsOrigin = OriginCaller; - type WeightInfo = (); -} - -// this config is totally incorrect - the pallet is not actually used at this runtime. We need -// it only to be able to run benchmarks and make required traits (and default weights for tests). -parameter_types! { - pub BridgeTable: Vec - = vec![ - NetworkExportTableItem::new( - xcm_config::RialtoNetwork::get(), - None, - xcm_config::TokenLocation::get(), - Some((xcm_config::TokenAssetId::get(), 1_000_000_000_u128).into()) - ) - ]; -} -impl pallet_xcm_bridge_hub_router::Config for Runtime { - type WeightInfo = (); - - type UniversalLocation = xcm_config::UniversalLocation; - type BridgedNetworkId = xcm_config::RialtoNetwork; - type Bridges = NetworkExportTable; - - type BridgeHubOrigin = frame_system::EnsureRoot; - type ToBridgeHubSender = xcm_config::XcmRouter; - type WithBridgeHubChannel = xcm_config::EmulatedSiblingXcmpChannel; - - type ByteFee = ConstU128<1_000>; - type FeeAsset = xcm_config::TokenAssetId; -} - -construct_runtime!( - pub enum Runtime { - System: frame_system::{Pallet, Call, Config, Storage, Event}, - Sudo: pallet_sudo::{Pallet, Call, Config, Storage, Event}, - Utility: pallet_utility, - - // Must be before session. - Aura: pallet_aura::{Pallet, Config}, - - Timestamp: pallet_timestamp::{Pallet, Call, Storage, Inherent}, - Balances: pallet_balances::{Pallet, Call, Storage, Config, Event}, - TransactionPayment: pallet_transaction_payment::{Pallet, Storage, Event}, - - // Consensus support. - Authorship: pallet_authorship::{Pallet, Storage}, - Offences: pallet_offences::{Pallet, Storage, Event}, - Historical: pallet_session::historical::{Pallet}, - - Session: pallet_session::{Pallet, Call, Storage, Event, Config}, - Grandpa: pallet_grandpa::{Pallet, Call, Storage, Config, Event}, - ShiftSessionManager: pallet_shift_session_manager::{Pallet}, - - // BEEFY Bridges support. - Beefy: pallet_beefy::{Pallet, Storage, Config}, - Mmr: pallet_mmr::{Pallet, Storage}, - MmrLeaf: pallet_beefy_mmr::{Pallet, Storage}, - - // Rialto bridge modules. - BridgeRelayers: pallet_bridge_relayers::{Pallet, Call, Storage, Event}, - BridgeRialtoGrandpa: pallet_bridge_grandpa::{Pallet, Call, Storage, Event}, - BridgeRialtoMessages: pallet_bridge_messages::{Pallet, Call, Storage, Event, Config}, - - // Westend bridge modules. - BridgeWestendGrandpa: pallet_bridge_grandpa::::{Pallet, Call, Config, Storage, Event}, - BridgeWestendParachains: pallet_bridge_parachains::::{Pallet, Call, Storage, Event}, - - // RialtoParachain bridge modules. - BridgeRialtoParachains: pallet_bridge_parachains::{Pallet, Call, Storage, Event}, - BridgeRialtoParachainMessages: pallet_bridge_messages::::{Pallet, Call, Storage, Event, Config}, - - // Pallet for sending XCM. - XcmPallet: pallet_xcm::{Pallet, Call, Storage, Event, Origin, Config} = 99, - - // Pallets that are not actually used here (yet?), but we need to run benchmarks on it. - XcmBridgeHubRouter: pallet_xcm_bridge_hub_router::{Pallet, Storage} = 200, - } -); - -generate_bridge_reject_obsolete_headers_and_messages! { - RuntimeCall, AccountId, - // Grandpa - BridgeRialtoGrandpa, BridgeWestendGrandpa, - // Parachains - BridgeRialtoParachains, - //Messages - BridgeRialtoMessages, BridgeRialtoParachainMessages -} - -bp_runtime::generate_static_str_provider!(BridgeRefundRialtoPara2000Lane0Msgs); -/// Signed extension that refunds relayers that are delivering messages from the Rialto parachain. -pub type PriorityBoostPerMessage = ConstU64<324_316_715>; -pub type BridgeRefundRialtoParachainMessages = RefundSignedExtensionAdapter< - RefundBridgedParachainMessages< - Runtime, - RefundableParachain, - RefundableMessagesLane, - ActualFeeRefund, - PriorityBoostPerMessage, - StrBridgeRefundRialtoPara2000Lane0Msgs, - >, ->; - -/// The address format for describing accounts. -pub type Address = AccountId; -/// Block header type as expected by this runtime. -pub type Header = generic::Header; -/// Block type as expected by this runtime. -pub type Block = generic::Block; -/// A Block signed with a Justification -pub type SignedBlock = generic::SignedBlock; -/// BlockId type as expected by this runtime. -pub type BlockId = generic::BlockId; -/// The SignedExtension to the basic transaction logic. -pub type SignedExtra = ( - frame_system::CheckNonZeroSender, - frame_system::CheckSpecVersion, - frame_system::CheckTxVersion, - frame_system::CheckGenesis, - frame_system::CheckEra, - frame_system::CheckNonce, - frame_system::CheckWeight, - pallet_transaction_payment::ChargeTransactionPayment, - BridgeRejectObsoleteHeadersAndMessages, - BridgeRefundRialtoParachainMessages, -); -/// The payload being signed in transactions. -pub type SignedPayload = generic::SignedPayload; -/// Unchecked extrinsic type as expected by this runtime. -pub type UncheckedExtrinsic = - generic::UncheckedExtrinsic; -/// Extrinsic type that has already been checked. -pub type CheckedExtrinsic = generic::CheckedExtrinsic; -/// Executive: handles dispatch to the various modules. -pub type Executive = frame_executive::Executive< - Runtime, - Block, - frame_system::ChainContext, - Runtime, - AllPalletsWithSystem, ->; - -#[cfg(feature = "runtime-benchmarks")] -mod benches { - frame_benchmarking::define_benchmarks!( - [pallet_bridge_messages, MessagesBench::] - [pallet_bridge_messages, MessagesBench::] - [pallet_bridge_grandpa, BridgeRialtoGrandpa] - [pallet_bridge_parachains, ParachainsBench::] - [pallet_bridge_relayers, RelayersBench::] - [pallet_xcm_bridge_hub_router, XcmBridgeHubRouterBench::] - ); -} - -impl_runtime_apis! { - impl sp_api::Core for Runtime { - fn version() -> RuntimeVersion { - VERSION - } - - fn execute_block(block: Block) { - Executive::execute_block(block); - } - - fn initialize_block(header: &::Header) { - Executive::initialize_block(header) - } - } - - impl sp_api::Metadata for Runtime { - fn metadata() -> OpaqueMetadata { - OpaqueMetadata::new(Runtime::metadata().into()) - } - - fn metadata_at_version(version: u32) -> Option { - Runtime::metadata_at_version(version) - } - - fn metadata_versions() -> sp_std::vec::Vec { - Runtime::metadata_versions() - } - } - - impl sp_block_builder::BlockBuilder for Runtime { - fn apply_extrinsic(extrinsic: ::Extrinsic) -> ApplyExtrinsicResult { - Executive::apply_extrinsic(extrinsic) - } - - fn finalize_block() -> ::Header { - Executive::finalize_block() - } - - fn inherent_extrinsics(data: sp_inherents::InherentData) -> Vec<::Extrinsic> { - data.create_extrinsics() - } - - fn check_inherents( - block: Block, - data: sp_inherents::InherentData, - ) -> sp_inherents::CheckInherentsResult { - data.check_extrinsics(&block) - } - } - - impl frame_system_rpc_runtime_api::AccountNonceApi for Runtime { - fn account_nonce(account: AccountId) -> Nonce { - System::account_nonce(account) - } - } - - impl sp_transaction_pool::runtime_api::TaggedTransactionQueue for Runtime { - fn validate_transaction( - source: TransactionSource, - tx: ::Extrinsic, - block_hash: ::Hash, - ) -> TransactionValidity { - Executive::validate_transaction(source, tx, block_hash) - } - } - - impl sp_offchain::OffchainWorkerApi for Runtime { - fn offchain_worker(header: &::Header) { - Executive::offchain_worker(header) - } - } - - impl sp_consensus_aura::AuraApi for Runtime { - fn slot_duration() -> sp_consensus_aura::SlotDuration { - sp_consensus_aura::SlotDuration::from_millis(Aura::slot_duration()) - } - - fn authorities() -> Vec { - Aura::authorities().to_vec() - } - } - - impl pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi< - Block, - Balance, - > for Runtime { - fn query_info(uxt: ::Extrinsic, len: u32) -> RuntimeDispatchInfo { - TransactionPayment::query_info(uxt, len) - } - fn query_fee_details(uxt: ::Extrinsic, len: u32) -> FeeDetails { - TransactionPayment::query_fee_details(uxt, len) - } - fn query_weight_to_fee(weight: Weight) -> Balance { - TransactionPayment::weight_to_fee(weight) - } - fn query_length_to_fee(length: u32) -> Balance { - TransactionPayment::length_to_fee(length) - } - } - - impl sp_session::SessionKeys for Runtime { - fn generate_session_keys(seed: Option>) -> Vec { - SessionKeys::generate(seed) - } - - fn decode_session_keys( - encoded: Vec, - ) -> Option, sp_core::crypto::KeyTypeId)>> { - SessionKeys::decode_into_raw_public_keys(&encoded) - } - } - - impl sp_consensus_beefy::BeefyApi for Runtime { - fn beefy_genesis() -> Option { - Beefy::genesis_block() - } - - fn validator_set() -> Option> { - Beefy::validator_set() - } - - fn submit_report_equivocation_unsigned_extrinsic( - _equivocation_proof: sp_consensus_beefy::EquivocationProof< - NumberFor, - sp_consensus_beefy::ecdsa_crypto::AuthorityId, - sp_consensus_beefy::ecdsa_crypto::Signature - >, - _key_owner_proof: sp_consensus_beefy::OpaqueKeyOwnershipProof, - ) -> Option<()> { None } - - fn generate_key_ownership_proof( - _set_id: sp_consensus_beefy::ValidatorSetId, - _authority_id: sp_consensus_beefy::ecdsa_crypto::AuthorityId, - ) -> Option { None } - } - - impl pallet_mmr::primitives::MmrApi< - Block, - mmr::Hash, - BlockNumber, - > for Runtime { - fn mmr_root() -> Result { - Ok(Mmr::mmr_root()) - } - - fn mmr_leaf_count() -> Result { - Ok(Mmr::mmr_leaves()) - } - - fn generate_proof( - block_numbers: Vec, - best_known_block_number: Option, - ) -> Result<(Vec, mmr::Proof), mmr::Error> { - Mmr::generate_proof(block_numbers, best_known_block_number).map( - |(leaves, proof)| { - ( - leaves - .into_iter() - .map(|leaf| mmr::EncodableOpaqueLeaf::from_leaf(&leaf)) - .collect(), - proof, - ) - }, - ) - } - - fn verify_proof(leaves: Vec, proof: mmr::Proof) - -> Result<(), mmr::Error> - { - let leaves = leaves.into_iter().map(|leaf| - leaf.into_opaque_leaf() - .try_decode() - .ok_or(mmr::Error::Verify)).collect::, mmr::Error>>()?; - Mmr::verify_leaves(leaves, proof) - } - - fn verify_proof_stateless( - root: mmr::Hash, - leaves: Vec, - proof: mmr::Proof - ) -> Result<(), mmr::Error> { - let nodes = leaves.into_iter().map(|leaf|mmr::DataOrHash::Data(leaf.into_opaque_leaf())).collect(); - pallet_mmr::verify_leaves_proof::(root, nodes, proof) - } - } - - impl fg_primitives::GrandpaApi for Runtime { - fn current_set_id() -> fg_primitives::SetId { - Grandpa::current_set_id() - } - - fn grandpa_authorities() -> GrandpaAuthorityList { - Grandpa::grandpa_authorities() - } - - fn submit_report_equivocation_unsigned_extrinsic( - equivocation_proof: fg_primitives::EquivocationProof< - ::Hash, - NumberFor, - >, - key_owner_proof: fg_primitives::OpaqueKeyOwnershipProof, - ) -> Option<()> { - let key_owner_proof = key_owner_proof.decode()?; - - Grandpa::submit_unsigned_equivocation_report( - equivocation_proof, - key_owner_proof, - ) - } - - fn generate_key_ownership_proof( - _set_id: fg_primitives::SetId, - _authority_id: GrandpaId, - ) -> Option { - // NOTE: this is the only implementation possible since we've - // defined our key owner proof type as a bottom type (i.e. a type - // with no values). - None - } - } - - impl bp_rialto::RialtoFinalityApi for Runtime { - fn best_finalized() -> Option> { - BridgeRialtoGrandpa::best_finalized() - } - - fn synced_headers_grandpa_info( - ) -> Vec> { - BridgeRialtoGrandpa::synced_headers_grandpa_info() - } - } - - impl bp_westend::WestendFinalityApi for Runtime { - fn best_finalized() -> Option> { - BridgeWestendGrandpa::best_finalized() - } - - fn synced_headers_grandpa_info( - ) -> Vec> { - BridgeWestendGrandpa::synced_headers_grandpa_info() - } - } - - impl bp_bridged_chain::AssetHubWestendFinalityApi for Runtime { - fn best_finalized() -> Option> { - pallet_bridge_parachains::Pallet::< - Runtime, - WithWestendParachainsInstance, - >::best_parachain_head_id::().unwrap_or(None) - } - } - - impl bp_rialto_parachain::RialtoParachainFinalityApi for Runtime { - fn best_finalized() -> Option> { - pallet_bridge_parachains::Pallet::< - Runtime, - WithRialtoParachainsInstance, - >::best_parachain_head_id::().unwrap_or(None) - } - } - - impl bp_rialto::ToRialtoOutboundLaneApi for Runtime { - fn message_details( - lane: bp_messages::LaneId, - begin: bp_messages::MessageNonce, - end: bp_messages::MessageNonce, - ) -> Vec { - bridge_runtime_common::messages_api::outbound_message_details::< - Runtime, - WithRialtoMessagesInstance, - >(lane, begin, end) - } - } - - impl bp_rialto::FromRialtoInboundLaneApi for Runtime { - fn message_details( - lane: bp_messages::LaneId, - messages: Vec<(bp_messages::MessagePayload, bp_messages::OutboundMessageDetails)>, - ) -> Vec { - bridge_runtime_common::messages_api::inbound_message_details::< - Runtime, - WithRialtoMessagesInstance, - >(lane, messages) - } - } - - impl bp_rialto_parachain::ToRialtoParachainOutboundLaneApi for Runtime { - fn message_details( - lane: bp_messages::LaneId, - begin: bp_messages::MessageNonce, - end: bp_messages::MessageNonce, - ) -> Vec { - bridge_runtime_common::messages_api::outbound_message_details::< - Runtime, - WithRialtoParachainMessagesInstance, - >(lane, begin, end) - } - } - - impl bp_rialto_parachain::FromRialtoParachainInboundLaneApi for Runtime { - fn message_details( - lane: bp_messages::LaneId, - messages: Vec<(bp_messages::MessagePayload, bp_messages::OutboundMessageDetails)>, - ) -> Vec { - bridge_runtime_common::messages_api::inbound_message_details::< - Runtime, - WithRialtoParachainMessagesInstance, - >(lane, messages) - } - } - - #[cfg(feature = "runtime-benchmarks")] - impl frame_benchmarking::Benchmark for Runtime { - fn benchmark_metadata(extra: bool) -> ( - Vec, - Vec, - ) { - use frame_benchmarking::{Benchmarking, BenchmarkList}; - use frame_support::traits::StorageInfoTrait; - - use pallet_bridge_messages::benchmarking::Pallet as MessagesBench; - use pallet_bridge_parachains::benchmarking::Pallet as ParachainsBench; - use pallet_bridge_relayers::benchmarking::Pallet as RelayersBench; - use pallet_xcm_bridge_hub_router::benchmarking::Pallet as XcmBridgeHubRouterBench; - - let mut list = Vec::::new(); - list_benchmarks!(list, extra); - - let storage_info = AllPalletsWithSystem::storage_info(); - return (list, storage_info) - } - - fn dispatch_benchmark( - config: frame_benchmarking::BenchmarkConfig, - ) -> Result, sp_runtime::RuntimeString> { - use frame_benchmarking::{Benchmarking, BenchmarkBatch}; - use frame_support::traits::TrackedStorageKey; - - let whitelist: Vec = vec![ - // Block Number - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac").to_vec().into(), - // Execution Phase - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a").to_vec().into(), - // Event Count - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850").to_vec().into(), - // System Events - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7").to_vec().into(), - // Caller 0 Account - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7b99d880ec681799c0cf30e8886371da946c154ffd9992e395af90b5b13cc6f295c77033fce8a9045824a6690bbf99c6db269502f0a8d1d2a008542d5690a0749").to_vec().into(), - ]; - - use bridge_runtime_common::messages_benchmarking::{ - generate_xcm_builder_bridge_message_sample, - prepare_message_delivery_proof_from_grandpa_chain, - prepare_message_delivery_proof_from_parachain, - prepare_message_proof_from_grandpa_chain, - prepare_message_proof_from_parachain, - }; - use pallet_bridge_messages::benchmarking::{ - Pallet as MessagesBench, - Config as MessagesConfig, - MessageDeliveryProofParams, - MessageProofParams, - }; - use pallet_bridge_parachains::benchmarking::{ - Pallet as ParachainsBench, - Config as ParachainsConfig, - }; - use pallet_bridge_relayers::benchmarking::{ - Pallet as RelayersBench, - Config as RelayersConfig, - }; - use pallet_xcm_bridge_hub_router::benchmarking::{ - Pallet as XcmBridgeHubRouterBench, - Config as XcmBridgeHubRouterConfig, - }; - use rialto_messages::WithRialtoMessageBridge; - use rialto_parachain_messages::WithRialtoParachainMessageBridge; - - impl MessagesConfig for Runtime { - fn prepare_message_proof( - params: MessageProofParams, - ) -> (rialto_messages::FromRialtoMessagesProof, Weight) { - prepare_message_proof_from_parachain::< - Runtime, - WithRialtoParachainsInstance, - WithRialtoParachainMessageBridge, - >(params, generate_xcm_builder_bridge_message_sample(xcm::v3::Junctions::Here)) - } - - fn prepare_message_delivery_proof( - params: MessageDeliveryProofParams, - ) -> rialto_messages::ToRialtoMessagesDeliveryProof { - prepare_message_delivery_proof_from_parachain::< - Runtime, - WithRialtoParachainsInstance, - WithRialtoParachainMessageBridge, - >(params) - } - - fn is_relayer_rewarded(relayer: &Self::AccountId) -> bool { - let lane = >::bench_lane_id(); - let bridged_chain_id = bp_runtime::RIALTO_PARACHAIN_CHAIN_ID; - pallet_bridge_relayers::Pallet::::relayer_reward( - relayer, - RewardsAccountParams::new(lane, bridged_chain_id, RewardsAccountOwner::BridgedChain) - ).is_some() - } - } - - impl MessagesConfig for Runtime { - fn prepare_message_proof( - params: MessageProofParams, - ) -> (rialto_messages::FromRialtoMessagesProof, Weight) { - prepare_message_proof_from_grandpa_chain::< - Runtime, - RialtoGrandpaInstance, - WithRialtoMessageBridge, - >(params, generate_xcm_builder_bridge_message_sample(xcm::v3::Junctions::Here)) - } - - fn prepare_message_delivery_proof( - params: MessageDeliveryProofParams, - ) -> rialto_messages::ToRialtoMessagesDeliveryProof { - prepare_message_delivery_proof_from_grandpa_chain::< - Runtime, - RialtoGrandpaInstance, - WithRialtoMessageBridge, - >(params) - } - - fn is_relayer_rewarded(relayer: &Self::AccountId) -> bool { - let lane = >::bench_lane_id(); - let bridged_chain_id = bp_runtime::RIALTO_CHAIN_ID; - pallet_bridge_relayers::Pallet::::relayer_reward( - relayer, - RewardsAccountParams::new(lane, bridged_chain_id, RewardsAccountOwner::BridgedChain) - ).is_some() - } - } - - impl ParachainsConfig for Runtime { - fn parachains() -> Vec { - use bp_runtime::Parachain; - vec![bp_polkadot_core::parachains::ParaId(bp_rialto_parachain::RialtoParachain::PARACHAIN_ID)] - } - - fn prepare_parachain_heads_proof( - parachains: &[bp_polkadot_core::parachains::ParaId], - parachain_head_size: u32, - proof_size: bp_runtime::StorageProofSize, - ) -> ( - pallet_bridge_parachains::RelayBlockNumber, - pallet_bridge_parachains::RelayBlockHash, - bp_polkadot_core::parachains::ParaHeadsProof, - Vec<(bp_polkadot_core::parachains::ParaId, bp_polkadot_core::parachains::ParaHash)>, - ) { - bridge_runtime_common::parachains_benchmarking::prepare_parachain_heads_proof::< - Runtime, - WithRialtoParachainsInstance, - >( - parachains, - parachain_head_size, - proof_size, - ) - } - } - - impl RelayersConfig for Runtime { - fn prepare_rewards_account( - account_params: RewardsAccountParams, - reward: Balance, - ) { - let rewards_account = bp_relayers::PayRewardFromAccount::< - Balances, - AccountId - >::rewards_account(account_params); - Self::deposit_account(rewards_account, reward); - } - - fn deposit_account(account: AccountId, balance: Balance) { - use frame_support::traits::fungible::Mutate; - Balances::mint_into(&account, balance.saturating_add(ExistentialDeposit::get())).unwrap(); - } - } - - impl XcmBridgeHubRouterConfig<()> for Runtime { - fn make_congested() { - xcm_config::EmulatedSiblingXcmpChannel::make_congested() - } - } - - let mut batches = Vec::::new(); - let params = (&config, &whitelist); - - add_benchmarks!(params, batches); - - Ok(batches) - } - } -} - -#[cfg(test)] -mod tests { - use super::*; - - #[test] - fn call_size() { - const BRIDGES_PALLETS_MAX_CALL_SIZE: usize = 200; - assert!( - core::mem::size_of::>() <= - BRIDGES_PALLETS_MAX_CALL_SIZE - ); - assert!( - core::mem::size_of::>() <= - BRIDGES_PALLETS_MAX_CALL_SIZE - ); - const MAX_CALL_SIZE: usize = 230; // value from polkadot-runtime tests - assert!(core::mem::size_of::() <= MAX_CALL_SIZE); - } -} - -/// TODO: Note: I know this does not belong here, but I don't want to add it to the -/// `chain-asset-hub-westend` or `chain-westend`, because we wont use it for production and I don't -/// want to bring this to the bridges subtree now. Anyway, we plan to retire millau/rialto, so this -/// hack will disappear with that. -pub mod bp_bridged_chain { - use bp_messages::Weight; - pub use bp_polkadot_core::{ - AccountId, AccountInfoStorageMapKeyProvider, AccountPublic, Balance, BlockNumber, Hash, - Hasher, Hashing, Header, Nonce, Perbill, Signature, SignedBlock, UncheckedExtrinsic, - EXTRA_STORAGE_PROOF_SIZE, TX_EXTRA_BYTES, - }; - use bp_runtime::{decl_bridge_finality_runtime_apis, Chain, Parachain}; - - /// `AssetHubWestend` parachain definition - #[derive(Debug, Clone, Copy)] - pub struct AssetHubWestend; - - // AssetHubWestend seems to use the same configuration as all Polkadot-like chains, so we'll use - // Westend primitives here. - impl Chain for AssetHubWestend { - type BlockNumber = BlockNumber; - type Hash = Hash; - type Hasher = Hasher; - type Header = Header; - - type AccountId = AccountId; - type Balance = Balance; - type Nonce = Nonce; - type Signature = Signature; - - fn max_extrinsic_size() -> u32 { - bp_westend::Westend::max_extrinsic_size() - } - - fn max_extrinsic_weight() -> Weight { - bp_westend::Westend::max_extrinsic_weight() - } - } - - impl Parachain for AssetHubWestend { - const PARACHAIN_ID: u32 = 1000; - } - - decl_bridge_finality_runtime_apis!(AssetHubWestend); -} diff --git a/bin/millau/runtime/src/rialto_messages.rs b/bin/millau/runtime/src/rialto_messages.rs deleted file mode 100644 index 8b778600f9723..0000000000000 --- a/bin/millau/runtime/src/rialto_messages.rs +++ /dev/null @@ -1,216 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Everything required to serve Millau <-> Rialto messages. - -use crate::{RialtoGrandpaInstance, Runtime, RuntimeOrigin, WithRialtoMessagesInstance}; - -use bp_messages::LaneId; -use bridge_runtime_common::{ - messages::{ - self, source::TargetHeaderChainAdapter, target::SourceHeaderChainAdapter, MessageBridge, - }, - messages_xcm_extension::{SenderAndLane, XcmBlobHauler, XcmBlobHaulerAdapter}, -}; -use frame_support::{parameter_types, weights::Weight}; -use pallet_bridge_relayers::WeightInfoExt as _; -use sp_runtime::RuntimeDebug; -use xcm::latest::prelude::*; -use xcm_builder::HaulBlobExporter; - -/// Default lane that is used to send messages to Rialto. -pub const XCM_LANE: LaneId = LaneId([0, 0, 0, 0]); -/// Weight of 2 XCM instructions is for simple `Trap(42)` program, coming through bridge -/// (it is prepended with `UniversalOrigin` instruction). It is used just for simplest manual -/// tests, confirming that we don't break encoding somewhere between. -pub const BASE_XCM_WEIGHT_TWICE: Weight = crate::xcm_config::BaseXcmWeight::get().saturating_mul(2); - -parameter_types! { - /// Weight credit for our test messages. - /// - /// 2 XCM instructions is for simple `Trap(42)` program, coming through bridge - /// (it is prepended with `UniversalOrigin` instruction). - pub const WeightCredit: Weight = BASE_XCM_WEIGHT_TWICE; - /// Lane used by the with-Rialto bridge. - pub RialtoSenderAndLane: SenderAndLane = SenderAndLane::new(Here.into(), XCM_LANE); - - /// Dummy message used in configuration. - pub DummyXcmMessage: Xcm<()> = Xcm::new(); -} - -/// Message payload for Millau -> Rialto messages. -pub type ToRialtoMessagePayload = messages::source::FromThisChainMessagePayload; - -/// Message verifier for Millau -> Rialto messages. -pub type ToRialtoMessageVerifier = - messages::source::FromThisChainMessageVerifier; - -/// Message payload for Rialto -> Millau messages. -pub type FromRialtoMessagePayload = messages::target::FromBridgedChainMessagePayload; - -/// Messages proof for Rialto -> Millau messages. -pub type FromRialtoMessagesProof = messages::target::FromBridgedChainMessagesProof; - -/// Messages delivery proof for Millau -> Rialto messages. -pub type ToRialtoMessagesDeliveryProof = - messages::source::FromBridgedChainMessagesDeliveryProof; - -/// Call-dispatch based message dispatch for Rialto -> Millau messages. -pub type FromRialtoMessageDispatch = - bridge_runtime_common::messages_xcm_extension::XcmBlobMessageDispatch< - crate::xcm_config::OnMillauBlobDispatcher, - (), - (), - >; - -/// Maximal outbound payload size of Millau -> Rialto messages. -pub type ToRialtoMaximalOutboundPayloadSize = - messages::source::FromThisChainMaximalOutboundPayloadSize; - -/// Millau <-> Rialto message bridge. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct WithRialtoMessageBridge; - -impl MessageBridge for WithRialtoMessageBridge { - const BRIDGED_MESSAGES_PALLET_NAME: &'static str = bp_millau::WITH_MILLAU_MESSAGES_PALLET_NAME; - - type ThisChain = Millau; - type BridgedChain = Rialto; - type BridgedHeaderChain = - pallet_bridge_grandpa::GrandpaChainHeaders; -} - -/// Millau chain from message lane point of view. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct Millau; - -impl messages::UnderlyingChainProvider for Millau { - type Chain = bp_millau::Millau; -} - -impl messages::ThisChainWithMessages for Millau { - type RuntimeOrigin = RuntimeOrigin; -} - -/// Rialto chain from message lane point of view. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct Rialto; -/// Rialto as source header chain. -pub type RialtoAsSourceHeaderChain = SourceHeaderChainAdapter; -/// Rialto as target header chain. -pub type RialtoAsTargetHeaderChain = TargetHeaderChainAdapter; - -impl messages::UnderlyingChainProvider for Rialto { - type Chain = bp_rialto::Rialto; -} - -impl messages::BridgedChainWithMessages for Rialto {} - -/// Export XCM messages to be relayed to Rialto. -pub type ToRialtoBlobExporter = HaulBlobExporter< - XcmBlobHaulerAdapter, - crate::xcm_config::RialtoNetwork, - (), ->; - -/// To-Rialto XCM hauler. -pub struct ToRialtoXcmBlobHauler; - -impl XcmBlobHauler for ToRialtoXcmBlobHauler { - type Runtime = Runtime; - type MessagesInstance = WithRialtoMessagesInstance; - type SenderAndLane = RialtoSenderAndLane; - - type ToSourceChainSender = crate::xcm_config::XcmRouter; - type CongestedMessage = DummyXcmMessage; - type UncongestedMessage = DummyXcmMessage; -} - -impl pallet_bridge_messages::WeightInfoExt for crate::weights::RialtoMessagesWeightInfo { - fn expected_extra_storage_proof_size() -> u32 { - bp_rialto::EXTRA_STORAGE_PROOF_SIZE - } - - fn receive_messages_proof_overhead_from_runtime() -> Weight { - pallet_bridge_relayers::weights::BridgeWeight::::receive_messages_proof_overhead_from_runtime() - } - - fn receive_messages_delivery_proof_overhead_from_runtime() -> Weight { - pallet_bridge_relayers::weights::BridgeWeight::::receive_messages_delivery_proof_overhead_from_runtime() - } -} - -#[cfg(test)] -mod tests { - use super::*; - use crate::{Runtime, WithRialtoMessagesInstance}; - - use bridge_runtime_common::{ - assert_complete_bridge_types, - integrity::{ - assert_complete_bridge_constants, check_message_lane_weights, - AssertBridgeMessagesPalletConstants, AssertBridgePalletNames, AssertChainConstants, - AssertCompleteBridgeConstants, - }, - }; - - #[test] - fn ensure_millau_message_lane_weights_are_correct() { - check_message_lane_weights::( - bp_rialto::EXTRA_STORAGE_PROOF_SIZE, - bp_millau::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX, - bp_millau::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX, - false, - ); - } - - #[test] - fn ensure_bridge_integrity() { - assert_complete_bridge_types!( - runtime: Runtime, - with_bridged_chain_grandpa_instance: RialtoGrandpaInstance, - with_bridged_chain_messages_instance: WithRialtoMessagesInstance, - bridge: WithRialtoMessageBridge, - this_chain: bp_millau::Millau, - bridged_chain: bp_rialto::Rialto, - ); - - assert_complete_bridge_constants::< - Runtime, - RialtoGrandpaInstance, - WithRialtoMessagesInstance, - WithRialtoMessageBridge, - >(AssertCompleteBridgeConstants { - this_chain_constants: AssertChainConstants { - block_length: bp_millau::BlockLength::get(), - block_weights: bp_millau::BlockWeights::get(), - }, - messages_pallet_constants: AssertBridgeMessagesPalletConstants { - max_unrewarded_relayers_in_bridged_confirmation_tx: - bp_rialto::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX, - max_unconfirmed_messages_in_bridged_confirmation_tx: - bp_rialto::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX, - bridged_chain_id: bp_runtime::RIALTO_CHAIN_ID, - }, - pallet_names: AssertBridgePalletNames { - with_this_chain_messages_pallet_name: bp_millau::WITH_MILLAU_MESSAGES_PALLET_NAME, - with_bridged_chain_grandpa_pallet_name: bp_rialto::WITH_RIALTO_GRANDPA_PALLET_NAME, - with_bridged_chain_messages_pallet_name: - bp_rialto::WITH_RIALTO_MESSAGES_PALLET_NAME, - }, - }); - } -} diff --git a/bin/millau/runtime/src/rialto_parachain_messages.rs b/bin/millau/runtime/src/rialto_parachain_messages.rs deleted file mode 100644 index 1c4807f0cd332..0000000000000 --- a/bin/millau/runtime/src/rialto_parachain_messages.rs +++ /dev/null @@ -1,227 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Everything required to serve Millau <-> RialtoParachain messages. - -use crate::{ - Runtime, RuntimeOrigin, WithRialtoParachainMessagesInstance, WithRialtoParachainsInstance, -}; - -use bp_messages::LaneId; -use bridge_runtime_common::{ - messages::{ - self, source::TargetHeaderChainAdapter, target::SourceHeaderChainAdapter, MessageBridge, - }, - messages_xcm_extension::{SenderAndLane, XcmBlobHauler, XcmBlobHaulerAdapter}, -}; -use frame_support::{parameter_types, weights::Weight}; -use pallet_bridge_relayers::WeightInfoExt as _; -use sp_runtime::RuntimeDebug; -use xcm::latest::prelude::*; -use xcm_builder::HaulBlobExporter; - -/// Default lane that is used to send messages to Rialto parachain. -pub const XCM_LANE: LaneId = LaneId([0, 0, 0, 0]); -/// Weight of 2 XCM instructions is for simple `Trap(42)` program, coming through bridge -/// (it is prepended with `UniversalOrigin` instruction). It is used just for simplest manual -/// tests, confirming that we don't break encoding somewhere between. -pub const BASE_XCM_WEIGHT_TWICE: Weight = crate::xcm_config::BaseXcmWeight::get().saturating_mul(2); - -parameter_types! { - /// Weight credit for our test messages. - /// - /// 2 XCM instructions is for simple `Trap(42)` program, coming through bridge - /// (it is prepended with `UniversalOrigin` instruction). - pub const WeightCredit: Weight = BASE_XCM_WEIGHT_TWICE; - /// Lane used by the with-RialtoParachain bridge. - pub RialtoParachainSenderAndLane: SenderAndLane = SenderAndLane::new(Here.into(), XCM_LANE); - - /// Dummy message used in configuration. - pub DummyXcmMessage: Xcm<()> = Xcm::new(); -} - -/// Message payload for Millau -> RialtoParachain messages. -pub type ToRialtoParachainMessagePayload = messages::source::FromThisChainMessagePayload; - -/// Message verifier for Millau -> RialtoParachain messages. -pub type ToRialtoParachainMessageVerifier = - messages::source::FromThisChainMessageVerifier; - -/// Message payload for RialtoParachain -> Millau messages. -pub type FromRialtoParachainMessagePayload = messages::target::FromBridgedChainMessagePayload; - -/// Call-dispatch based message dispatch for RialtoParachain -> Millau messages. -pub type FromRialtoParachainMessageDispatch = - bridge_runtime_common::messages_xcm_extension::XcmBlobMessageDispatch< - crate::xcm_config::OnMillauBlobDispatcher, - (), - (), - >; - -/// Maximal outbound payload size of Millau -> RialtoParachain messages. -pub type ToRialtoParachainMaximalOutboundPayloadSize = - messages::source::FromThisChainMaximalOutboundPayloadSize; - -/// Millau <-> RialtoParachain message bridge. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct WithRialtoParachainMessageBridge; - -impl MessageBridge for WithRialtoParachainMessageBridge { - const BRIDGED_MESSAGES_PALLET_NAME: &'static str = bp_millau::WITH_MILLAU_MESSAGES_PALLET_NAME; - - type ThisChain = Millau; - type BridgedChain = RialtoParachain; - type BridgedHeaderChain = pallet_bridge_parachains::ParachainHeaders< - Runtime, - WithRialtoParachainsInstance, - bp_rialto_parachain::RialtoParachain, - >; -} - -/// Millau chain from message lane point of view. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct Millau; - -impl messages::UnderlyingChainProvider for Millau { - type Chain = bp_millau::Millau; -} - -impl messages::ThisChainWithMessages for Millau { - type RuntimeOrigin = RuntimeOrigin; -} - -/// RialtoParachain chain from message lane point of view. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct RialtoParachain; -/// RialtoParachain as source header chain. -pub type RialtoParachainAsSourceHeaderChain = - SourceHeaderChainAdapter; -/// RialtoParachain as target header chain. -pub type RialtoParachainAsTargetHeaderChain = - TargetHeaderChainAdapter; - -impl messages::UnderlyingChainProvider for RialtoParachain { - type Chain = bp_rialto_parachain::RialtoParachain; -} - -impl messages::BridgedChainWithMessages for RialtoParachain {} - -/// Export XCM messages to be relayed to Rialto. -pub type ToRialtoParachainBlobExporter = HaulBlobExporter< - XcmBlobHaulerAdapter, - crate::xcm_config::RialtoParachainNetwork, - (), ->; - -/// To-RialtoParachain XCM hauler. -pub struct ToRialtoParachainXcmBlobHauler; - -impl XcmBlobHauler for ToRialtoParachainXcmBlobHauler { - type Runtime = Runtime; - type MessagesInstance = WithRialtoParachainMessagesInstance; - type SenderAndLane = RialtoParachainSenderAndLane; - - type ToSourceChainSender = crate::xcm_config::XcmRouter; - type CongestedMessage = DummyXcmMessage; - type UncongestedMessage = DummyXcmMessage; -} - -impl pallet_bridge_messages::WeightInfoExt - for crate::weights::RialtoParachainMessagesWeightInfo -{ - fn expected_extra_storage_proof_size() -> u32 { - bp_rialto_parachain::EXTRA_STORAGE_PROOF_SIZE - } - - fn receive_messages_proof_overhead_from_runtime() -> Weight { - pallet_bridge_relayers::weights::BridgeWeight::::receive_messages_proof_overhead_from_runtime() - } - - fn receive_messages_delivery_proof_overhead_from_runtime() -> Weight { - pallet_bridge_relayers::weights::BridgeWeight::::receive_messages_delivery_proof_overhead_from_runtime() - } -} - -#[cfg(test)] -mod tests { - use super::*; - use crate::{ - PriorityBoostPerMessage, RialtoGrandpaInstance, Runtime, - WithRialtoParachainMessagesInstance, - }; - - use bridge_runtime_common::{ - assert_complete_bridge_types, - integrity::{ - assert_complete_bridge_constants, check_message_lane_weights, - AssertBridgeMessagesPalletConstants, AssertBridgePalletNames, AssertChainConstants, - AssertCompleteBridgeConstants, - }, - }; - - #[test] - fn ensure_millau_message_lane_weights_are_correct() { - check_message_lane_weights::( - bp_rialto_parachain::EXTRA_STORAGE_PROOF_SIZE, - bp_millau::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX, - bp_millau::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX, - true, - ); - } - - #[test] - fn ensure_bridge_integrity() { - assert_complete_bridge_types!( - runtime: Runtime, - with_bridged_chain_grandpa_instance: RialtoGrandpaInstance, - with_bridged_chain_messages_instance: WithRialtoParachainMessagesInstance, - bridge: WithRialtoParachainMessageBridge, - this_chain: bp_millau::Millau, - bridged_chain: bp_rialto::Rialto, - ); - - assert_complete_bridge_constants::< - Runtime, - RialtoGrandpaInstance, - WithRialtoParachainMessagesInstance, - WithRialtoParachainMessageBridge, - >(AssertCompleteBridgeConstants { - this_chain_constants: AssertChainConstants { - block_length: bp_millau::BlockLength::get(), - block_weights: bp_millau::BlockWeights::get(), - }, - messages_pallet_constants: AssertBridgeMessagesPalletConstants { - max_unrewarded_relayers_in_bridged_confirmation_tx: - bp_rialto_parachain::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX, - max_unconfirmed_messages_in_bridged_confirmation_tx: - bp_rialto_parachain::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX, - bridged_chain_id: bp_runtime::RIALTO_PARACHAIN_CHAIN_ID, - }, - pallet_names: AssertBridgePalletNames { - with_this_chain_messages_pallet_name: bp_millau::WITH_MILLAU_MESSAGES_PALLET_NAME, - with_bridged_chain_grandpa_pallet_name: bp_rialto::WITH_RIALTO_GRANDPA_PALLET_NAME, - with_bridged_chain_messages_pallet_name: - bp_rialto_parachain::WITH_RIALTO_PARACHAIN_MESSAGES_PALLET_NAME, - }, - }); - - bridge_runtime_common::priority_calculator::ensure_priority_boost_is_sane::< - Runtime, - WithRialtoParachainMessagesInstance, - PriorityBoostPerMessage, - >(1_000_000); - } -} diff --git a/bin/millau/runtime/src/weights/mod.rs b/bin/millau/runtime/src/weights/mod.rs deleted file mode 100644 index 801ff9b3c8f68..0000000000000 --- a/bin/millau/runtime/src/weights/mod.rs +++ /dev/null @@ -1,21 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -mod pallet_bridge_messages_messages_bench_runtime_with_rialto_messages_instance; -mod pallet_bridge_messages_messages_bench_runtime_with_rialto_parachain_messages_instance; - -pub use pallet_bridge_messages_messages_bench_runtime_with_rialto_messages_instance::WeightInfo as RialtoMessagesWeightInfo; -pub use pallet_bridge_messages_messages_bench_runtime_with_rialto_parachain_messages_instance::WeightInfo as RialtoParachainMessagesWeightInfo; diff --git a/bin/millau/runtime/src/weights/pallet_bridge_messages_messages_bench_runtime_with_rialto_messages_instance.rs b/bin/millau/runtime/src/weights/pallet_bridge_messages_messages_bench_runtime_with_rialto_messages_instance.rs deleted file mode 100644 index b58402d275638..0000000000000 --- a/bin/millau/runtime/src/weights/pallet_bridge_messages_messages_bench_runtime_with_rialto_messages_instance.rs +++ /dev/null @@ -1,188 +0,0 @@ - -//! Autogenerated weights for `pallet_bridge_messages` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-05-01, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `covid`, CPU: `11th Gen Intel(R) Core(TM) i7-11800H @ 2.30GHz` -//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 - -// Executed Command: -// target/release/millau-bridge-node -// benchmark -// pallet -// --chain=dev -// --steps=50 -// --repeat=20 -// --pallet=pallet_bridge_messages -// --extrinsic=* -// --execution=wasm -// --wasm-execution=Compiled -// --heap-pages=4096 -// --output=./bin/millau/runtime/src/weights/ - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_parens)] -#![allow(unused_imports)] - -use frame_support::{traits::Get, weights::Weight}; -use core::marker::PhantomData; - -/// Weight functions for `pallet_bridge_messages`. -pub struct WeightInfo(PhantomData); -impl pallet_bridge_messages::WeightInfo for WeightInfo { - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), added: 2048, mode: MaxEncodedLen) - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - fn receive_single_message_proof() -> Weight { - // Proof Size summary in bytes: - // Measured: `490` - // Estimated: `57170` - // Minimum execution time: 51_189_000 picoseconds. - Weight::from_parts(52_881_000, 0) - .saturating_add(Weight::from_parts(0, 57170)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), added: 2048, mode: MaxEncodedLen) - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - fn receive_two_messages_proof() -> Weight { - // Proof Size summary in bytes: - // Measured: `490` - // Estimated: `57170` - // Minimum execution time: 65_083_000 picoseconds. - Weight::from_parts(66_878_000, 0) - .saturating_add(Weight::from_parts(0, 57170)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), added: 2048, mode: MaxEncodedLen) - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - fn receive_single_message_proof_with_outbound_lane_state() -> Weight { - // Proof Size summary in bytes: - // Measured: `490` - // Estimated: `57170` - // Minimum execution time: 57_919_000 picoseconds. - Weight::from_parts(58_927_000, 0) - .saturating_add(Weight::from_parts(0, 57170)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), added: 2048, mode: MaxEncodedLen) - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - fn receive_single_message_proof_1_kb() -> Weight { - // Proof Size summary in bytes: - // Measured: `490` - // Estimated: `57170` - // Minimum execution time: 52_202_000 picoseconds. - Weight::from_parts(53_617_000, 0) - .saturating_add(Weight::from_parts(0, 57170)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), added: 2048, mode: MaxEncodedLen) - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - fn receive_single_message_proof_16_kb() -> Weight { - // Proof Size summary in bytes: - // Measured: `490` - // Estimated: `57170` - // Minimum execution time: 74_726_000 picoseconds. - Weight::from_parts(76_379_000, 0) - .saturating_add(Weight::from_parts(0, 57170)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), added: 2048, mode: MaxEncodedLen) - /// Storage: BridgeRialtoMessages OutboundLanes (r:1 w:1) - /// Proof: BridgeRialtoMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: 539, mode: MaxEncodedLen) - /// Storage: BridgeRelayers RelayerRewards (r:1 w:1) - /// Proof: BridgeRelayers RelayerRewards (max_values: None, max_size: Some(65), added: 2540, mode: MaxEncodedLen) - fn receive_delivery_proof_for_single_message() -> Weight { - // Proof Size summary in bytes: - // Measured: `515` - // Estimated: `9584` - // Minimum execution time: 45_156_000 picoseconds. - Weight::from_parts(46_535_000, 0) - .saturating_add(Weight::from_parts(0, 9584)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(2)) - } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), added: 2048, mode: MaxEncodedLen) - /// Storage: BridgeRialtoMessages OutboundLanes (r:1 w:1) - /// Proof: BridgeRialtoMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: 539, mode: MaxEncodedLen) - /// Storage: BridgeRelayers RelayerRewards (r:1 w:1) - /// Proof: BridgeRelayers RelayerRewards (max_values: None, max_size: Some(65), added: 2540, mode: MaxEncodedLen) - fn receive_delivery_proof_for_two_messages_by_single_relayer() -> Weight { - // Proof Size summary in bytes: - // Measured: `532` - // Estimated: `9584` - // Minimum execution time: 44_104_000 picoseconds. - Weight::from_parts(45_602_000, 0) - .saturating_add(Weight::from_parts(0, 9584)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(2)) - } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), added: 2048, mode: MaxEncodedLen) - /// Storage: BridgeRialtoMessages OutboundLanes (r:1 w:1) - /// Proof: BridgeRialtoMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: 539, mode: MaxEncodedLen) - /// Storage: BridgeRelayers RelayerRewards (r:2 w:2) - /// Proof: BridgeRelayers RelayerRewards (max_values: None, max_size: Some(65), added: 2540, mode: MaxEncodedLen) - fn receive_delivery_proof_for_two_messages_by_two_relayers() -> Weight { - // Proof Size summary in bytes: - // Measured: `532` - // Estimated: `12124` - // Minimum execution time: 46_880_000 picoseconds. - Weight::from_parts(48_472_000, 0) - .saturating_add(Weight::from_parts(0, 12124)) - .saturating_add(T::DbWeight::get().reads(5)) - .saturating_add(T::DbWeight::get().writes(3)) - } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), added: 2048, mode: MaxEncodedLen) - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - /// The range of component `i` is `[128, 2048]`. - /// The range of component `i` is `[128, 2048]`. - fn receive_single_message_proof_with_dispatch(i: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `490` - // Estimated: `57170` - // Minimum execution time: 107_297_000 picoseconds. - Weight::from_parts(98_819_194, 0) - .saturating_add(Weight::from_parts(0, 57170)) - // Standard Error: 2_195 - .saturating_add(Weight::from_parts(448_268, 0).saturating_mul(i.into())) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } -} diff --git a/bin/millau/runtime/src/weights/pallet_bridge_messages_messages_bench_runtime_with_rialto_parachain_messages_instance.rs b/bin/millau/runtime/src/weights/pallet_bridge_messages_messages_bench_runtime_with_rialto_parachain_messages_instance.rs deleted file mode 100644 index c71cb11fdc717..0000000000000 --- a/bin/millau/runtime/src/weights/pallet_bridge_messages_messages_bench_runtime_with_rialto_parachain_messages_instance.rs +++ /dev/null @@ -1,188 +0,0 @@ - -//! Autogenerated weights for `pallet_bridge_messages` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-05-01, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `covid`, CPU: `11th Gen Intel(R) Core(TM) i7-11800H @ 2.30GHz` -//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 - -// Executed Command: -// target/release/millau-bridge-node -// benchmark -// pallet -// --chain=dev -// --steps=50 -// --repeat=20 -// --pallet=pallet_bridge_messages -// --extrinsic=* -// --execution=wasm -// --wasm-execution=Compiled -// --heap-pages=4096 -// --output=./bin/millau/runtime/src/weights/ - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_parens)] -#![allow(unused_imports)] - -use frame_support::{traits::Get, weights::Weight}; -use core::marker::PhantomData; - -/// Weight functions for `pallet_bridge_messages`. -pub struct WeightInfo(PhantomData); -impl pallet_bridge_messages::WeightInfo for WeightInfo { - /// Storage: BridgeRialtoParachainMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoParachainMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:1 w:0) - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: Some(196), added: 1681, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachainMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoParachainMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - fn receive_single_message_proof() -> Weight { - // Proof Size summary in bytes: - // Measured: `428` - // Estimated: `56803` - // Minimum execution time: 49_949_000 picoseconds. - Weight::from_parts(51_439_000, 0) - .saturating_add(Weight::from_parts(0, 56803)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: BridgeRialtoParachainMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoParachainMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:1 w:0) - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: Some(196), added: 1681, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachainMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoParachainMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - fn receive_two_messages_proof() -> Weight { - // Proof Size summary in bytes: - // Measured: `428` - // Estimated: `56803` - // Minimum execution time: 62_552_000 picoseconds. - Weight::from_parts(64_899_000, 0) - .saturating_add(Weight::from_parts(0, 56803)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: BridgeRialtoParachainMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoParachainMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:1 w:0) - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: Some(196), added: 1681, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachainMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoParachainMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - fn receive_single_message_proof_with_outbound_lane_state() -> Weight { - // Proof Size summary in bytes: - // Measured: `428` - // Estimated: `56803` - // Minimum execution time: 56_795_000 picoseconds. - Weight::from_parts(58_441_000, 0) - .saturating_add(Weight::from_parts(0, 56803)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: BridgeRialtoParachainMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoParachainMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:1 w:0) - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: Some(196), added: 1681, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachainMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoParachainMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - fn receive_single_message_proof_1_kb() -> Weight { - // Proof Size summary in bytes: - // Measured: `428` - // Estimated: `56803` - // Minimum execution time: 51_340_000 picoseconds. - Weight::from_parts(52_533_000, 0) - .saturating_add(Weight::from_parts(0, 56803)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: BridgeRialtoParachainMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoParachainMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:1 w:0) - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: Some(196), added: 1681, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachainMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoParachainMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - fn receive_single_message_proof_16_kb() -> Weight { - // Proof Size summary in bytes: - // Measured: `428` - // Estimated: `56803` - // Minimum execution time: 74_022_000 picoseconds. - Weight::from_parts(75_115_000, 0) - .saturating_add(Weight::from_parts(0, 56803)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: BridgeRialtoParachainMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoParachainMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:1 w:0) - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: Some(196), added: 1681, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachainMessages OutboundLanes (r:1 w:1) - /// Proof: BridgeRialtoParachainMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: 539, mode: MaxEncodedLen) - /// Storage: BridgeRelayers RelayerRewards (r:1 w:1) - /// Proof: BridgeRelayers RelayerRewards (max_values: None, max_size: Some(65), added: 2540, mode: MaxEncodedLen) - fn receive_delivery_proof_for_single_message() -> Weight { - // Proof Size summary in bytes: - // Measured: `453` - // Estimated: `9217` - // Minimum execution time: 43_296_000 picoseconds. - Weight::from_parts(45_022_000, 0) - .saturating_add(Weight::from_parts(0, 9217)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(2)) - } - /// Storage: BridgeRialtoParachainMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoParachainMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:1 w:0) - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: Some(196), added: 1681, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachainMessages OutboundLanes (r:1 w:1) - /// Proof: BridgeRialtoParachainMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: 539, mode: MaxEncodedLen) - /// Storage: BridgeRelayers RelayerRewards (r:1 w:1) - /// Proof: BridgeRelayers RelayerRewards (max_values: None, max_size: Some(65), added: 2540, mode: MaxEncodedLen) - fn receive_delivery_proof_for_two_messages_by_single_relayer() -> Weight { - // Proof Size summary in bytes: - // Measured: `470` - // Estimated: `9217` - // Minimum execution time: 42_618_000 picoseconds. - Weight::from_parts(43_972_000, 0) - .saturating_add(Weight::from_parts(0, 9217)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(2)) - } - /// Storage: BridgeRialtoParachainMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoParachainMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:1 w:0) - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: Some(196), added: 1681, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachainMessages OutboundLanes (r:1 w:1) - /// Proof: BridgeRialtoParachainMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: 539, mode: MaxEncodedLen) - /// Storage: BridgeRelayers RelayerRewards (r:2 w:2) - /// Proof: BridgeRelayers RelayerRewards (max_values: None, max_size: Some(65), added: 2540, mode: MaxEncodedLen) - fn receive_delivery_proof_for_two_messages_by_two_relayers() -> Weight { - // Proof Size summary in bytes: - // Measured: `470` - // Estimated: `11757` - // Minimum execution time: 45_954_000 picoseconds. - Weight::from_parts(46_892_000, 0) - .saturating_add(Weight::from_parts(0, 11757)) - .saturating_add(T::DbWeight::get().reads(5)) - .saturating_add(T::DbWeight::get().writes(3)) - } - /// Storage: BridgeRialtoParachainMessages PalletOperatingMode (r:1 w:0) - /// Proof: BridgeRialtoParachainMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), added: 497, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:1 w:0) - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: Some(196), added: 1681, mode: MaxEncodedLen) - /// Storage: BridgeRialtoParachainMessages InboundLanes (r:1 w:1) - /// Proof: BridgeRialtoParachainMessages InboundLanes (max_values: None, max_size: Some(49180), added: 51655, mode: MaxEncodedLen) - /// The range of component `i` is `[128, 2048]`. - /// The range of component `i` is `[128, 2048]`. - fn receive_single_message_proof_with_dispatch(i: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `428` - // Estimated: `56803` - // Minimum execution time: 107_766_000 picoseconds. - Weight::from_parts(97_865_035, 0) - .saturating_add(Weight::from_parts(0, 56803)) - // Standard Error: 2_179 - .saturating_add(Weight::from_parts(447_749, 0).saturating_mul(i.into())) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(1)) - } -} diff --git a/bin/millau/runtime/src/xcm_config.rs b/bin/millau/runtime/src/xcm_config.rs deleted file mode 100644 index 45236360ddcc1..0000000000000 --- a/bin/millau/runtime/src/xcm_config.rs +++ /dev/null @@ -1,410 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! XCM configurations for the Millau runtime. - -use super::{ - rialto_messages::ToRialtoBlobExporter, - rialto_parachain_messages::ToRialtoParachainBlobExporter, AccountId, AllPalletsWithSystem, - Balances, Runtime, RuntimeCall, RuntimeEvent, RuntimeOrigin, XcmPallet, -}; -use bp_millau::WeightToFee; -use bridge_runtime_common::CustomNetworkId; -use frame_support::{ - parameter_types, - traits::{ConstU32, Everything, Nothing}, - weights::Weight, -}; -use frame_system::EnsureRoot; -use xcm::latest::prelude::*; -use xcm_builder::{ - AccountId32Aliases, CurrencyAdapter as XcmCurrencyAdapter, IsConcrete, MintLocation, - SignedAccountId32AsNative, SignedToAccountId32, SovereignSignedViaLocation, TakeWeightCredit, - UsingComponents, -}; -use xcm_executor::traits::ExportXcm; - -parameter_types! { - /// The location of the `MLAU` token, from the context of this chain. Since this token is native to this - /// chain, we make it synonymous with it and thus it is the `Here` location, which means "equivalent to - /// the context". - pub const TokenLocation: MultiLocation = Here.into_location(); - /// Token asset identifier. - pub TokenAssetId: AssetId = TokenLocation::get().into(); - /// The Millau network ID. - pub const ThisNetwork: NetworkId = CustomNetworkId::Millau.as_network_id(); - /// The Rialto network ID. - pub const RialtoNetwork: NetworkId = CustomNetworkId::Rialto.as_network_id(); - /// The RialtoParachain network ID. - pub const RialtoParachainNetwork: NetworkId = CustomNetworkId::RialtoParachain.as_network_id(); - - /// Our XCM location ancestry - i.e. our location within the Consensus Universe. - /// - /// Since Kusama is a top-level relay-chain with its own consensus, it's just our network ID. - pub UniversalLocation: InteriorMultiLocation = ThisNetwork::get().into(); - /// The check account, which holds any native assets that have been teleported out and not back in (yet). - pub CheckAccount: (AccountId, MintLocation) = (XcmPallet::check_account(), MintLocation::Local); -} - -/// The canonical means of converting a `MultiLocation` into an `AccountId`, used when we want to -/// determine the sovereign account controlled by a location. -pub type SovereignAccountOf = ( - // We can directly alias an `AccountId32` into a local account. - AccountId32Aliases, -); - -/// Our asset transactor. This is what allows us to interest with the runtime facilities from the -/// point of view of XCM-only concepts like `MultiLocation` and `MultiAsset`. -/// -/// Ours is only aware of the Balances pallet, which is mapped to `TokenLocation`. -pub type LocalAssetTransactor = XcmCurrencyAdapter< - // Use this currency: - Balances, - // Use this currency when it is a fungible asset matching the given location or name: - IsConcrete, - // We can convert the MultiLocations with our converter above: - SovereignAccountOf, - // Our chain's account ID type (we can't get away without mentioning it explicitly): - AccountId, - // We track our teleports in/out to keep total issuance correct. - CheckAccount, ->; - -/// The means that we convert the XCM message origin location into a local dispatch origin. -type LocalOriginConverter = ( - // A `Signed` origin of the sovereign account that the original location controls. - SovereignSignedViaLocation, - // The AccountId32 location type can be expressed natively as a `Signed` origin. - SignedAccountId32AsNative, -); - -parameter_types! { - /// The amount of weight an XCM operation takes. This is a safe overestimate. - pub const BaseXcmWeight: Weight = Weight::from_parts(1_000_000_000, 64 * 1024); - /// Maximum number of instructions in a single XCM fragment. A sanity check against weight - /// calculations getting too crazy. - pub const MaxInstructions: u32 = 100; -} - -/// The XCM router. We are not sending messages to sibling/parent/child chains here. -pub type XcmRouter = EmulatedSiblingXcmpChannel; - -/// The barriers one of which must be passed for an XCM message to be executed. -pub type Barrier = ( - // Weight that is paid for may be consumed. - TakeWeightCredit, -); - -/// Dispatches received XCM messages from other chain. -pub type OnMillauBlobDispatcher = xcm_builder::BridgeBlobDispatcher< - crate::xcm_config::XcmRouter, - crate::xcm_config::UniversalLocation, - (), ->; - -/// XCM weigher type. -pub type XcmWeigher = xcm_builder::FixedWeightBounds; - -pub struct XcmConfig; -impl xcm_executor::Config for XcmConfig { - type RuntimeCall = RuntimeCall; - type XcmSender = (); - type AssetTransactor = LocalAssetTransactor; - type OriginConverter = LocalOriginConverter; - type IsReserve = (); - type IsTeleporter = (); - type UniversalLocation = UniversalLocation; - type Barrier = Barrier; - type Weigher = XcmWeigher; - // The weight trader piggybacks on the existing transaction-fee conversion logic. - type Trader = UsingComponents; - type ResponseHandler = XcmPallet; - type AssetTrap = XcmPallet; - type AssetLocker = (); - type AssetExchanger = (); - type AssetClaims = XcmPallet; - type SubscriptionService = XcmPallet; - type PalletInstancesInfo = AllPalletsWithSystem; - type MaxAssetsIntoHolding = ConstU32<64>; - type FeeManager = (); - type MessageExporter = ToRialtoOrRialtoParachainSwitchExporter; - type UniversalAliases = Nothing; - type CallDispatcher = RuntimeCall; - type SafeCallFilter = Everything; - type Aliasers = Nothing; -} - -/// Type to convert an `Origin` type value into a `MultiLocation` value which represents an interior -/// location of this chain. -pub type LocalOriginToLocation = ( - // Usual Signed origin to be used in XCM as a corresponding AccountId32 - SignedToAccountId32, -); - -#[cfg(feature = "runtime-benchmarks")] -parameter_types! { - pub ReachableDest: Option = None; -} - -impl pallet_xcm::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - // We don't allow any messages to be sent via the transaction yet. This is basically safe to - // enable, (safe the possibility of someone spamming the parachain if they're willing to pay - // the DOT to send from the Relay-chain). But it's useless until we bring in XCM v3 which will - // make `DescendOrigin` a bit more useful. - type SendXcmOrigin = xcm_builder::EnsureXcmOrigin; - type XcmRouter = (); - // Anyone can execute XCM messages locally. - type ExecuteXcmOrigin = xcm_builder::EnsureXcmOrigin; - type XcmExecuteFilter = Everything; - type XcmExecutor = xcm_executor::XcmExecutor; - // Anyone is able to use teleportation regardless of who they are and what they want to - // teleport. - type XcmTeleportFilter = Everything; - // Anyone is able to use reserve transfers regardless of who they are and what they want to - // transfer. - type XcmReserveTransferFilter = Everything; - type Weigher = XcmWeigher; - type UniversalLocation = UniversalLocation; - type RuntimeOrigin = RuntimeOrigin; - type RuntimeCall = RuntimeCall; - const VERSION_DISCOVERY_QUEUE_SIZE: u32 = 100; - type AdvertisedXcmVersion = pallet_xcm::CurrentXcmVersion; - type Currency = Balances; - type CurrencyMatcher = (); - type TrustedLockers = (); - type SovereignAccountOf = SovereignAccountOf; - type MaxLockers = frame_support::traits::ConstU32<8>; - type WeightInfo = pallet_xcm::TestWeightInfo; - #[cfg(feature = "runtime-benchmarks")] - type ReachableDest = ReachableDest; - type AdminOrigin = EnsureRoot; - type MaxRemoteLockConsumers = ConstU32<0>; - type RemoteLockConsumerIdentifier = (); -} - -pub struct ToRialtoOrRialtoParachainSwitchExporter; - -impl ExportXcm for ToRialtoOrRialtoParachainSwitchExporter { - type Ticket = (NetworkId, (sp_std::prelude::Vec, XcmHash)); - - fn validate( - network: NetworkId, - channel: u32, - universal_source: &mut Option, - destination: &mut Option, - message: &mut Option>, - ) -> SendResult { - if network == RialtoNetwork::get() { - ToRialtoBlobExporter::validate(network, channel, universal_source, destination, message) - .map(|result| ((RialtoNetwork::get(), result.0), result.1)) - } else if network == RialtoParachainNetwork::get() { - ToRialtoParachainBlobExporter::validate( - network, - channel, - universal_source, - destination, - message, - ) - .map(|result| ((RialtoParachainNetwork::get(), result.0), result.1)) - } else { - Err(SendError::Unroutable) - } - } - - fn deliver(ticket: Self::Ticket) -> Result { - let (network, ticket) = ticket; - if network == RialtoNetwork::get() { - ToRialtoBlobExporter::deliver(ticket) - } else if network == RialtoParachainNetwork::get() { - ToRialtoParachainBlobExporter::deliver(ticket) - } else { - Err(SendError::Unroutable) - } - } -} - -/// Emulating XCMP channel with sibling chain. We don't have required infra here, at Millau, -/// so we have to provide at least something to be able to run benchmarks. -pub struct EmulatedSiblingXcmpChannel; - -impl SendXcm for EmulatedSiblingXcmpChannel { - type Ticket = (); - - fn validate( - _destination: &mut Option, - _message: &mut Option>, - ) -> SendResult { - Ok(((), Default::default())) - } - - fn deliver(_ticket: Self::Ticket) -> Result { - Ok(XcmHash::default()) - } -} - -impl EmulatedSiblingXcmpChannel { - /// Start emulating congested channel. - pub fn make_congested() { - frame_support::storage::unhashed::put(b"EmulatedSiblingXcmpChannel.Congested", &true); - } -} - -impl bp_xcm_bridge_hub_router::XcmChannelStatusProvider for EmulatedSiblingXcmpChannel { - fn is_congested() -> bool { - frame_support::storage::unhashed::get_or_default(b"EmulatedSiblingXcmpChannel.Congested") - } -} - -#[cfg(test)] -mod tests { - use super::*; - use crate::{ - rialto_messages::FromRialtoMessageDispatch, WithRialtoMessagesInstance, - WithRialtoParachainMessagesInstance, - }; - use bp_messages::{ - target_chain::{DispatchMessage, DispatchMessageData, MessageDispatch}, - LaneId, MessageKey, - }; - use bridge_runtime_common::messages_xcm_extension::XcmBlobMessageDispatchResult; - use codec::Encode; - use pallet_bridge_messages::OutboundLanes; - use sp_runtime::BuildStorage; - use xcm_executor::XcmExecutor; - - fn new_test_ext() -> sp_io::TestExternalities { - sp_io::TestExternalities::new( - frame_system::GenesisConfig::::default().build_storage().unwrap(), - ) - } - - fn prepare_outbound_xcm_message(destination: NetworkId) -> Xcm { - vec![ExportMessage { - network: destination, - destination: destination.into(), - xcm: vec![Instruction::Trap(42)].into(), - }] - .into() - } - - #[test] - fn xcm_messages_to_rialto_are_sent_using_bridge_exporter() { - new_test_ext().execute_with(|| { - // ensure that the there are no messages queued - assert_eq!( - OutboundLanes::::get( - crate::rialto_messages::XCM_LANE - ) - .latest_generated_nonce, - 0, - ); - - // export message instruction "sends" message to Rialto - XcmExecutor::::execute_xcm_in_credit( - Here, - prepare_outbound_xcm_message(RialtoNetwork::get()), - Default::default(), - Weight::MAX, - Weight::MAX, - ) - .ensure_complete() - .expect("runtime configuration must be correct"); - - // ensure that the message has been queued - assert_eq!( - OutboundLanes::::get( - crate::rialto_messages::XCM_LANE - ) - .latest_generated_nonce, - 1, - ); - }) - } - - #[test] - fn xcm_messages_to_rialto_parachain_are_sent_using_bridge_exporter() { - new_test_ext().execute_with(|| { - // ensure that the there are no messages queued - assert_eq!( - OutboundLanes::::get( - crate::rialto_parachain_messages::XCM_LANE - ) - .latest_generated_nonce, - 0, - ); - - // export message instruction "sends" message to Rialto - XcmExecutor::::execute_xcm_in_credit( - Here, - prepare_outbound_xcm_message(RialtoParachainNetwork::get()), - Default::default(), - Weight::MAX, - Weight::MAX, - ) - .ensure_complete() - .expect("runtime configuration must be correct"); - - // ensure that the message has been queued - assert_eq!( - OutboundLanes::::get( - crate::rialto_parachain_messages::XCM_LANE - ) - .latest_generated_nonce, - 1, - ); - }) - } - - fn prepare_inbound_bridge_message() -> DispatchMessage> { - let xcm = xcm::VersionedXcm::::V3(vec![Instruction::Trap(42)].into()); - let location = - xcm::VersionedInteriorMultiLocation::V3(X1(GlobalConsensus(ThisNetwork::get()))); - // this is the `BridgeMessage` from polkadot xcm builder, but it has no constructor - // or public fields, so just tuple - let bridge_message = (location, xcm).encode(); - DispatchMessage { - key: MessageKey { lane_id: LaneId([0, 0, 0, 0]), nonce: 1 }, - data: DispatchMessageData { payload: Ok(bridge_message) }, - } - } - - #[test] - fn xcm_messages_from_rialto_are_dispatched() { - let incoming_message = prepare_inbound_bridge_message(); - - // we care only about handing message to the XCM dispatcher, so we don't care about its - // actual dispatch - let dispatch_result = FromRialtoMessageDispatch::dispatch(incoming_message); - assert!(matches!( - dispatch_result.dispatch_level_result, - XcmBlobMessageDispatchResult::Dispatched, - )); - } - - #[test] - fn xcm_messages_from_rialto_parachain_are_dispatched() { - let incoming_message = prepare_inbound_bridge_message(); - - // we care only about handing message to the XCM dispatcher, so we don't care about its - // actual dispatch - let dispatch_result = FromRialtoMessageDispatch::dispatch(incoming_message); - assert!(matches!( - dispatch_result.dispatch_level_result, - XcmBlobMessageDispatchResult::Dispatched, - )); - } -} diff --git a/bin/rialto-parachain/node/Cargo.toml b/bin/rialto-parachain/node/Cargo.toml deleted file mode 100644 index 053ee24577377..0000000000000 --- a/bin/rialto-parachain/node/Cargo.toml +++ /dev/null @@ -1,81 +0,0 @@ -[package] -name = "rialto-parachain-collator" -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -repository = "https://github.com/paritytech/parity-bridges-common/" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[build-dependencies] -substrate-build-script-utils = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -[[bin]] -name = 'rialto-parachain-collator' - -[features] -default = [] -runtime-benchmarks = [ 'rialto-parachain-runtime/runtime-benchmarks' ] - -[dependencies] -clap = { version = "4.4.8", features = ["derive"] } -log = '0.4.20' -codec = { package = 'parity-scale-codec', version = '3.1.5' } -serde = { version = '1.0', features = ['derive'] } - -# RPC related Dependencies -jsonrpsee = { version = "0.16.2", features = ["server"] } - -# Local Dependencies -rialto-parachain-runtime = { path = '../runtime' } - -# Substrate Dependencies -frame-benchmarking = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -frame-benchmarking-cli = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -pallet-transaction-payment-rpc = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -substrate-frame-rpc-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -substrate-prometheus-endpoint = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -## Substrate Client Dependencies -sc-basic-authorship = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-chain-spec = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-cli = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-client-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-consensus = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-executor = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-network = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-network-sync = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-rpc = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-rpc-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-service = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master"} -sc-telemetry = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-transaction-pool = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-tracing = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -## Substrate Primitive Dependencies -sp-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-block-builder = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-consensus-aura = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-keystore = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-offchain = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-session = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-timestamp = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-transaction-pool = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -# Cumulus dependencies -cumulus-client-consensus-aura = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -cumulus-client-consensus-common = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -cumulus-client-cli = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -cumulus-client-network = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -cumulus-client-service = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -cumulus-primitives-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -cumulus-primitives-parachain-inherent = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -cumulus-relay-chain-interface = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -# Polkadot dependencies -polkadot-cli = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -polkadot-primitives = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -polkadot-service = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } diff --git a/bin/rialto-parachain/node/build.rs b/bin/rialto-parachain/node/build.rs deleted file mode 100644 index 8ba8a31e9a79f..0000000000000 --- a/bin/rialto-parachain/node/build.rs +++ /dev/null @@ -1,22 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use substrate_build_script_utils::{generate_cargo_keys, rerun_if_git_head_changed}; - -fn main() { - generate_cargo_keys(); - rerun_if_git_head_changed(); -} diff --git a/bin/rialto-parachain/node/src/chain_spec.rs b/bin/rialto-parachain/node/src/chain_spec.rs deleted file mode 100644 index b42c9a6a8f5ee..0000000000000 --- a/bin/rialto-parachain/node/src/chain_spec.rs +++ /dev/null @@ -1,202 +0,0 @@ -// Copyright 2020-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use cumulus_primitives_core::ParaId; -use rialto_parachain_runtime::{AccountId, AuraId, BridgeMillauMessagesConfig, Signature}; -use sc_chain_spec::{ChainSpecExtension, ChainSpecGroup}; -use sc_service::ChainType; -use serde::{Deserialize, Serialize}; -use sp_core::{sr25519, Pair, Public}; -use sp_runtime::traits::{IdentifyAccount, Verify}; - -/// "Names" of the authorities accounts at local testnet. -const LOCAL_AUTHORITIES_ACCOUNTS: [&str; 2] = ["Alice", "Bob"]; -/// "Names" of the authorities accounts at development testnet. -const DEV_AUTHORITIES_ACCOUNTS: [&str; 2] = LOCAL_AUTHORITIES_ACCOUNTS; -/// "Names" of all possible authorities accounts. -const ALL_AUTHORITIES_ACCOUNTS: [&str; 2] = LOCAL_AUTHORITIES_ACCOUNTS; -/// "Name" of the `sudo` account. -const SUDO_ACCOUNT: &str = "Sudo"; -/// "Name" of the account, which owns the with-Millau messages pallet. -const MILLAU_MESSAGES_PALLET_OWNER: &str = "Millau.MessagesOwner"; - -/// Specialized `ChainSpec` for the normal parachain runtime. -pub type ChainSpec = - sc_service::GenericChainSpec; - -/// Helper function to generate a crypto pair from seed -pub fn get_from_seed(seed: &str) -> ::Public { - TPublic::Pair::from_string(&format!("//{seed}"), None) - .expect("static values are valid; qed") - .public() -} - -/// The extensions for the [`ChainSpec`]. -#[derive( - Debug, Clone, PartialEq, Eq, Serialize, Deserialize, ChainSpecGroup, ChainSpecExtension, -)] -#[serde(deny_unknown_fields)] -pub struct Extensions { - /// The relay chain of the Parachain. - pub relay_chain: String, - /// The id of the Parachain. - pub para_id: u32, -} - -impl Extensions { - /// Try to get the extension from the given `ChainSpec`. - pub fn try_get(chain_spec: &dyn sc_service::ChainSpec) -> Option<&Self> { - sc_chain_spec::get_extension(chain_spec.extensions()) - } -} - -type AccountPublic = ::Signer; - -/// Helper function to generate an account ID from seed -pub fn get_account_id_from_seed(seed: &str) -> AccountId -where - AccountPublic: From<::Public>, -{ - AccountPublic::from(get_from_seed::(seed)).into_account() -} - -/// We're using the same set of endowed accounts on all RialtoParachain chains (dev/local) to make -/// sure that all accounts, required for bridge to be functional (e.g. relayers fund account, -/// accounts used by relayers in our test deployments, accounts used for demonstration -/// purposes), are all available on these chains. -fn endowed_accounts() -> Vec { - let all_authorities = ALL_AUTHORITIES_ACCOUNTS.iter().flat_map(|x| { - [ - get_account_id_from_seed::(x), - get_account_id_from_seed::(&format!("{x}//stash")), - ] - }); - vec![ - // Sudo account - get_account_id_from_seed::(SUDO_ACCOUNT), - // Regular (unused) accounts - get_account_id_from_seed::("Charlie"), - get_account_id_from_seed::("Dave"), - get_account_id_from_seed::("Eve"), - get_account_id_from_seed::("Ferdie"), - get_account_id_from_seed::("Charlie//stash"), - get_account_id_from_seed::("Dave//stash"), - get_account_id_from_seed::("Eve//stash"), - get_account_id_from_seed::("Ferdie//stash"), - // Accounts, used by RialtoParachain<>Millau bridge - get_account_id_from_seed::(MILLAU_MESSAGES_PALLET_OWNER), - get_account_id_from_seed::("Millau.HeadersAndMessagesRelay1"), - get_account_id_from_seed::("Millau.HeadersAndMessagesRelay2"), - get_account_id_from_seed::("Millau.MessagesSender"), - ] - .into_iter() - .chain(all_authorities) - .collect() -} - -pub fn development_config(id: ParaId) -> ChainSpec { - // Give your base currency a unit name and decimal places - let mut properties = sc_chain_spec::Properties::new(); - properties.insert("tokenSymbol".into(), "UNIT".into()); - properties.insert("tokenDecimals".into(), 12.into()); - - ChainSpec::from_genesis( - // Name - "Development", - // ID - "dev", - ChainType::Local, - move || { - testnet_genesis( - get_account_id_from_seed::(SUDO_ACCOUNT), - DEV_AUTHORITIES_ACCOUNTS.into_iter().map(get_from_seed::).collect(), - endowed_accounts(), - id, - ) - }, - vec![], - None, - None, - None, - None, - Extensions { - relay_chain: "rococo-local".into(), // You MUST set this to the correct network! - para_id: id.into(), - }, - ) -} - -pub fn local_testnet_config(id: ParaId) -> ChainSpec { - // Give your base currency a unit name and decimal places - let mut properties = sc_chain_spec::Properties::new(); - properties.insert("tokenSymbol".into(), "UNIT".into()); - properties.insert("tokenDecimals".into(), 12.into()); - - ChainSpec::from_genesis( - // Name - "Local Testnet", - // ID - "local_testnet", - ChainType::Local, - move || { - testnet_genesis( - get_account_id_from_seed::(SUDO_ACCOUNT), - LOCAL_AUTHORITIES_ACCOUNTS.into_iter().map(get_from_seed::).collect(), - endowed_accounts(), - id, - ) - }, - Vec::new(), - None, - None, - None, - None, - Extensions { - relay_chain: "rococo-local".into(), // You MUST set this to the correct network! - para_id: id.into(), - }, - ) -} - -fn testnet_genesis( - root_key: AccountId, - initial_authorities: Vec, - endowed_accounts: Vec, - id: ParaId, -) -> rialto_parachain_runtime::RuntimeGenesisConfig { - rialto_parachain_runtime::RuntimeGenesisConfig { - system: rialto_parachain_runtime::SystemConfig { - code: rialto_parachain_runtime::WASM_BINARY - .expect("WASM binary was not build, please build it!") - .to_vec(), - ..Default::default() - }, - balances: rialto_parachain_runtime::BalancesConfig { - balances: endowed_accounts.iter().cloned().map(|k| (k, 1 << 60)).collect(), - }, - sudo: rialto_parachain_runtime::SudoConfig { key: Some(root_key) }, - parachain_info: rialto_parachain_runtime::ParachainInfoConfig { - parachain_id: id, - ..Default::default() - }, - aura: rialto_parachain_runtime::AuraConfig { authorities: initial_authorities }, - aura_ext: Default::default(), - bridge_millau_messages: BridgeMillauMessagesConfig { - owner: Some(get_account_id_from_seed::(MILLAU_MESSAGES_PALLET_OWNER)), - ..Default::default() - }, - } -} diff --git a/bin/rialto-parachain/node/src/cli.rs b/bin/rialto-parachain/node/src/cli.rs deleted file mode 100644 index c8c457752d600..0000000000000 --- a/bin/rialto-parachain/node/src/cli.rs +++ /dev/null @@ -1,109 +0,0 @@ -// Copyright 2020-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -#![allow(clippy::large_enum_variant)] - -use crate::chain_spec; -use clap::Parser; -use cumulus_client_cli::{ExportGenesisStateCommand, ExportGenesisWasmCommand}; -use std::path::PathBuf; - -/// Sub-commands supported by the collator. -#[derive(Debug, Parser)] -pub enum Subcommand { - /// Export the genesis state of the parachain. - #[clap(name = "export-genesis-state")] - ExportGenesisState(ExportGenesisStateCommand), - - /// Export the genesis wasm of the parachain. - #[clap(name = "export-genesis-wasm")] - ExportGenesisWasm(ExportGenesisWasmCommand), - - /// Build a chain specification. - BuildSpec(sc_cli::BuildSpecCmd), - - /// Validate blocks. - CheckBlock(sc_cli::CheckBlockCmd), - - /// Export blocks. - ExportBlocks(sc_cli::ExportBlocksCmd), - - /// Export the state of a given block into a chain spec. - ExportState(sc_cli::ExportStateCmd), - - /// Import blocks. - ImportBlocks(sc_cli::ImportBlocksCmd), - - /// Remove the whole chain. - PurgeChain(cumulus_client_cli::PurgeChainCmd), - - /// Revert the chain to a previous state. - Revert(sc_cli::RevertCmd), - - /// The custom benchmark subcommand benchmarking runtime pallets. - #[clap(subcommand)] - Benchmark(frame_benchmarking_cli::BenchmarkCmd), -} - -#[derive(Debug, Parser)] -#[clap( - propagate_version = true, - args_conflicts_with_subcommands = true, - subcommand_negates_reqs = true -)] -pub struct Cli { - #[clap(subcommand)] - pub subcommand: Option, - - #[clap(long)] - pub parachain_id: Option, - - #[clap(flatten)] - pub run: cumulus_client_cli::RunCmd, - - /// Relaychain arguments - #[clap(raw = true)] - pub relaychain_args: Vec, -} - -#[derive(Debug)] -pub struct RelayChainCli { - /// The actual relay chain CLI object. - pub base: polkadot_cli::RunCmd, - - /// Optional chain id that should be passed to the relay chain. - pub chain_id: Option, - - /// The base path that should be used by the relay chain. - pub base_path: Option, -} - -impl RelayChainCli { - /// Parse the relay chain CLI parameters using the para chain `Configuration`. - pub fn new<'a>( - para_config: &sc_service::Configuration, - relay_chain_args: impl Iterator, - ) -> Self { - let extension = chain_spec::Extensions::try_get(&*para_config.chain_spec); - let chain_id = extension.map(|e| e.relay_chain.clone()); - let base_path = para_config.base_path.path().join("rialto-bridge-node"); - Self { - base_path: Some(base_path), - chain_id, - base: polkadot_cli::RunCmd::parse_from(relay_chain_args), - } - } -} diff --git a/bin/rialto-parachain/node/src/command.rs b/bin/rialto-parachain/node/src/command.rs deleted file mode 100644 index 50c1857f1c9c8..0000000000000 --- a/bin/rialto-parachain/node/src/command.rs +++ /dev/null @@ -1,372 +0,0 @@ -// Copyright 2020-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use crate::{ - chain_spec, - cli::{Cli, RelayChainCli, Subcommand}, - service::new_partial, -}; -use cumulus_primitives_core::ParaId; -use frame_benchmarking_cli::BenchmarkCmd; -use log::info; -use rialto_parachain_runtime::{Block, RuntimeApi}; -use sc_cli::{ - ChainSpec, CliConfiguration, DefaultConfigurationValues, ImportParams, KeystoreParams, - NetworkParams, Result, SharedParams, SubstrateCli, -}; -use sc_service::config::{BasePath, PrometheusConfig}; -use std::net::SocketAddr; - -fn load_spec( - id: &str, - para_id: ParaId, -) -> std::result::Result, String> { - Ok(match id { - "dev" => Box::new(chain_spec::development_config(para_id)), - "" | "local" => Box::new(chain_spec::local_testnet_config(para_id)), - path => Box::new(chain_spec::ChainSpec::from_json_file(std::path::PathBuf::from(path))?), - }) -} - -impl SubstrateCli for Cli { - fn impl_name() -> String { - "Parachain Collator Template".into() - } - - fn impl_version() -> String { - env!("SUBSTRATE_CLI_IMPL_VERSION").into() - } - - fn description() -> String { - format!( - "Parachain Collator Template\n\nThe command-line arguments provided first will be \ - passed to the parachain node, while the arguments provided after -- will be passed \ - to the relaychain node.\n\n\ - {} [parachain-args] -- [relaychain-args]", - Self::executable_name() - ) - } - - fn author() -> String { - env!("CARGO_PKG_AUTHORS").into() - } - - fn support_url() -> String { - "https://github.com/substrate-developer-hub/substrate-parachain-template/issues/new".into() - } - - fn copyright_start_year() -> i32 { - 2017 - } - - fn load_spec(&self, id: &str) -> std::result::Result, String> { - load_spec(id, self.parachain_id.unwrap_or(2000).into()) - } -} - -impl SubstrateCli for RelayChainCli { - fn impl_name() -> String { - "Parachain Collator Template".into() - } - - fn impl_version() -> String { - env!("SUBSTRATE_CLI_IMPL_VERSION").into() - } - - fn description() -> String { - "Parachain Collator Template\n\nThe command-line arguments provided first will be \ - passed to the parachain node, while the arguments provided after -- will be passed \ - to the relaychain node.\n\n\ - parachain-collator [parachain-args] -- [relaychain-args]" - .into() - } - - fn author() -> String { - env!("CARGO_PKG_AUTHORS").into() - } - - fn support_url() -> String { - "https://github.com/substrate-developer-hub/substrate-parachain-template/issues/new".into() - } - - fn copyright_start_year() -> i32 { - 2017 - } - - fn load_spec(&self, id: &str) -> std::result::Result, String> { - polkadot_cli::Cli::from_iter([RelayChainCli::executable_name()].iter()).load_spec(id) - } -} - -macro_rules! construct_async_run { - (|$components:ident, $cli:ident, $cmd:ident, $config:ident| $( $code:tt )* ) => {{ - let runner = $cli.create_runner($cmd)?; - runner.async_run(|$config| { - let $components = new_partial::< - RuntimeApi, - _ - >( - &$config, - crate::service::parachain_build_import_queue, - )?; - let task_manager = $components.task_manager; - { $( $code )* }.map(|v| (v, task_manager)) - }) - }} -} - -/// Parse command line arguments into service configuration. -pub fn run() -> Result<()> { - let cli = Cli::from_args(); - sp_core::crypto::set_default_ss58_version(sp_core::crypto::Ss58AddressFormat::custom( - rialto_parachain_runtime::SS58Prefix::get() as u16, - )); - - match &cli.subcommand { - Some(Subcommand::BuildSpec(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.sync_run(|config| cmd.run(config.chain_spec, config.network)) - }, - Some(Subcommand::CheckBlock(cmd)) => { - construct_async_run!(|components, cli, cmd, config| { - Ok(cmd.run(components.client, components.import_queue)) - }) - }, - Some(Subcommand::ExportBlocks(cmd)) => { - construct_async_run!(|components, cli, cmd, config| Ok( - cmd.run(components.client, config.database) - )) - }, - Some(Subcommand::ExportState(cmd)) => { - construct_async_run!(|components, cli, cmd, config| Ok( - cmd.run(components.client, config.chain_spec) - )) - }, - Some(Subcommand::ImportBlocks(cmd)) => { - construct_async_run!(|components, cli, cmd, config| { - Ok(cmd.run(components.client, components.import_queue)) - }) - }, - Some(Subcommand::PurgeChain(cmd)) => { - let runner = cli.create_runner(cmd)?; - - runner.sync_run(|config| { - let polkadot_cli = RelayChainCli::new( - &config, - [RelayChainCli::executable_name()].iter().chain(cli.relaychain_args.iter()), - ); - - let polkadot_config = SubstrateCli::create_configuration( - &polkadot_cli, - &polkadot_cli, - config.tokio_handle.clone(), - ) - .map_err(|err| format!("Relay chain argument error: {err}"))?; - - cmd.run(config, polkadot_config) - }) - }, - Some(Subcommand::Revert(cmd)) => { - construct_async_run!(|components, cli, cmd, config| Ok(cmd.run( - components.client, - components.backend, - None - ))) - }, - Some(Subcommand::ExportGenesisState(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.sync_run(|config| { - let partials = new_partial::( - &config, - crate::service::parachain_build_import_queue, - )?; - - cmd.run(&*config.chain_spec, &*partials.client) - }) - }, - Some(Subcommand::ExportGenesisWasm(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.sync_run(|_config| { - let spec = cli.load_spec(&cmd.shared_params.chain.clone().unwrap_or_default())?; - cmd.run(&*spec) - }) - }, - Some(Subcommand::Benchmark(cmd)) => { - let runner = cli.create_runner(cmd)?; - match cmd { - BenchmarkCmd::Pallet(cmd) => - if cfg!(feature = "runtime-benchmarks") { - runner.sync_run(|config| cmd.run::(config)) - } else { - println!( - "Benchmarking wasn't enabled when building the node. \ - You can enable it with `--features runtime-benchmarks`." - ); - Ok(()) - }, - _ => Err("Unsupported benchmarking subcommand".into()), - } - }, - None => { - let runner = cli.create_runner(&cli.run.normalize())?; - let collator_options = cli.run.collator_options(); - - runner.run_node_until_exit(|config| async move { - let para_id = - chain_spec::Extensions::try_get(&*config.chain_spec).map(|e| e.para_id); - - let polkadot_cli = RelayChainCli::new( - &config, - [RelayChainCli::executable_name()].iter().chain(cli.relaychain_args.iter()), - ); - - let id = ParaId::from(cli.parachain_id.or(para_id).expect("Missing ParaId")); - - let polkadot_config = SubstrateCli::create_configuration( - &polkadot_cli, - &polkadot_cli, - config.tokio_handle.clone(), - ) - .map_err(|err| format!("Relay chain argument error: {err}"))?; - - info!("Parachain id: {:?}", id); - info!("Is collating: {}", if config.role.is_authority() { "yes" } else { "no" }); - - crate::service::start_node(config, polkadot_config, collator_options, id) - .await - .map(|r| r.0) - .map_err(Into::into) - }) - }, - } -} - -impl DefaultConfigurationValues for RelayChainCli { - fn p2p_listen_port() -> u16 { - 30334 - } - - fn rpc_listen_port() -> u16 { - 9945 - } - - fn prometheus_listen_port() -> u16 { - 9616 - } -} - -impl CliConfiguration for RelayChainCli { - fn shared_params(&self) -> &SharedParams { - self.base.base.shared_params() - } - - fn import_params(&self) -> Option<&ImportParams> { - self.base.base.import_params() - } - - fn network_params(&self) -> Option<&NetworkParams> { - self.base.base.network_params() - } - - fn keystore_params(&self) -> Option<&KeystoreParams> { - self.base.base.keystore_params() - } - - fn base_path(&self) -> Result> { - Ok(self - .shared_params() - .base_path()? - .or_else(|| self.base_path.clone().map(Into::into))) - } - - fn rpc_addr(&self, default_listen_port: u16) -> Result> { - self.base.base.rpc_addr(default_listen_port) - } - - fn prometheus_config( - &self, - default_listen_port: u16, - chain_spec: &Box, - ) -> Result> { - self.base.base.prometheus_config(default_listen_port, chain_spec) - } - - fn init( - &self, - _support_url: &String, - _impl_version: &String, - _logger_hook: F, - _config: &sc_service::Configuration, - ) -> Result<()> - where - F: FnOnce(&mut sc_cli::LoggerBuilder, &sc_service::Configuration), - { - unreachable!("PolkadotCli is never initialized; qed"); - } - - fn chain_id(&self, is_dev: bool) -> Result { - let chain_id = self.base.base.chain_id(is_dev)?; - - Ok(if chain_id.is_empty() { self.chain_id.clone().unwrap_or_default() } else { chain_id }) - } - - fn role(&self, is_dev: bool) -> Result { - self.base.base.role(is_dev) - } - - fn transaction_pool(&self, is_dev: bool) -> Result { - self.base.base.transaction_pool(is_dev) - } - - fn rpc_methods(&self) -> Result { - self.base.base.rpc_methods() - } - - fn rpc_max_connections(&self) -> Result { - self.base.base.rpc_max_connections() - } - - fn rpc_cors(&self, is_dev: bool) -> Result>> { - self.base.base.rpc_cors(is_dev) - } - - fn default_heap_pages(&self) -> Result> { - self.base.base.default_heap_pages() - } - - fn force_authoring(&self) -> Result { - self.base.base.force_authoring() - } - - fn disable_grandpa(&self) -> Result { - self.base.base.disable_grandpa() - } - - fn max_runtime_instances(&self) -> Result> { - self.base.base.max_runtime_instances() - } - - fn announce_block(&self) -> Result { - self.base.base.announce_block() - } - - fn telemetry_endpoints( - &self, - chain_spec: &Box, - ) -> Result> { - self.base.base.telemetry_endpoints(chain_spec) - } -} diff --git a/bin/rialto-parachain/node/src/lib.rs b/bin/rialto-parachain/node/src/lib.rs deleted file mode 100644 index 5dd2a8af861b1..0000000000000 --- a/bin/rialto-parachain/node/src/lib.rs +++ /dev/null @@ -1,19 +0,0 @@ -// Copyright 2020-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -pub mod chain_spec; -#[allow(deprecated)] -pub mod service; diff --git a/bin/rialto-parachain/node/src/main.rs b/bin/rialto-parachain/node/src/main.rs deleted file mode 100644 index ca93efa067cc9..0000000000000 --- a/bin/rialto-parachain/node/src/main.rs +++ /dev/null @@ -1,30 +0,0 @@ -// Copyright 2020-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Substrate Parachain Node Template CLI - -#![warn(missing_docs)] - -mod chain_spec; -#[macro_use] -#[allow(deprecated)] -mod service; -mod cli; -mod command; - -fn main() -> sc_cli::Result<()> { - command::run() -} diff --git a/bin/rialto-parachain/node/src/service.rs b/bin/rialto-parachain/node/src/service.rs deleted file mode 100644 index 86c5a7615901c..0000000000000 --- a/bin/rialto-parachain/node/src/service.rs +++ /dev/null @@ -1,505 +0,0 @@ -// Copyright 2020-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Rialto parachain node service. -//! -//! The code is mostly copy of `polkadot-parachains/src/service.rs` file from Cumulus -//! repository with some parts removed. We have added two RPC extensions to the original -//! service: `pallet_transaction_payment_rpc::TransactionPaymentApi` and -//! `substrate_frame_rpc_system::SystemApi`. - -// std -use std::{sync::Arc, time::Duration}; - -// Local Runtime Types -use rialto_parachain_runtime::RuntimeApi; - -// Cumulus Imports -use cumulus_client_cli::CollatorOptions; -use cumulus_client_consensus_aura::{AuraConsensus, BuildAuraConsensusParams, SlotProportion}; -use cumulus_client_consensus_common::{ - ParachainBlockImport as TParachainBlockImport, ParachainConsensus, -}; -use cumulus_client_network::RequireSecondedInBlockAnnounce; -use cumulus_client_service::{ - prepare_node_config, start_collator, start_full_node, StartCollatorParams, StartFullNodeParams, -}; -use cumulus_primitives_core::ParaId; -use cumulus_relay_chain_interface::RelayChainInterface; -use sc_consensus::ImportQueue; -// Substrate Imports -use sc_executor::{ - HeapAllocStrategy, NativeElseWasmExecutor, NativeExecutionDispatch, WasmExecutor, - DEFAULT_HEAP_ALLOC_STRATEGY, -}; -use sc_network::{config::FullNetworkConfiguration, NetworkBlock}; -use sc_network_sync::SyncingService; -use sc_service::{Configuration, PartialComponents, TFullBackend, TFullClient, TaskManager}; -use sc_telemetry::{Telemetry, TelemetryHandle, TelemetryWorker, TelemetryWorkerHandle}; -use sp_api::ConstructRuntimeApi; -use sp_keystore::KeystorePtr; -use sp_runtime::traits::BlakeTwo256; -use substrate_prometheus_endpoint::Registry; - -// Runtime type overrides -type BlockNumber = u32; -type Header = sp_runtime::generic::Header; -pub type Block = sp_runtime::generic::Block; - -type ParachainClient = - TFullClient>; -type ParachainBackend = TFullBackend; -type ParachainBlockImport = - TParachainBlockImport>, ParachainBackend>; - -pub type ParachainRuntimeExecutor = ExecutorDispatch; - -// Our native executor instance. -pub struct ExecutorDispatch; - -impl NativeExecutionDispatch for ExecutorDispatch { - type ExtendHostFunctions = frame_benchmarking::benchmarking::HostFunctions; - - fn dispatch(method: &str, data: &[u8]) -> Option> { - rialto_parachain_runtime::api::dispatch(method, data) - } - - fn native_version() -> sc_executor::NativeVersion { - rialto_parachain_runtime::native_version() - } -} - -/// Starts a `ServiceBuilder` for a full service. -/// -/// Use this macro if you don't actually need the full service, but just the builder in order to -/// be able to perform chain operations. -#[allow(clippy::type_complexity)] -pub fn new_partial( - config: &Configuration, - build_import_queue: BIQ, -) -> Result< - PartialComponents< - ParachainClient, - ParachainBackend, - (), - sc_consensus::DefaultImportQueue, - sc_transaction_pool::FullPool>, - (ParachainBlockImport, Option, Option), - >, - sc_service::Error, -> -where - RuntimeApi: ConstructRuntimeApi> + Send + Sync + 'static, - RuntimeApi::RuntimeApi: sp_transaction_pool::runtime_api::TaggedTransactionQueue - + sp_api::Metadata - + sp_session::SessionKeys - + sp_api::ApiExt - + sp_offchain::OffchainWorkerApi - + sp_block_builder::BlockBuilder, - sc_client_api::StateBackendFor: sp_api::StateBackend, - BIQ: FnOnce( - Arc>, - ParachainBlockImport, - &Configuration, - Option, - &TaskManager, - ) -> Result, sc_service::Error>, -{ - let telemetry = config - .telemetry_endpoints - .clone() - .filter(|x| !x.is_empty()) - .map(|endpoints| -> Result<_, sc_telemetry::Error> { - let worker = TelemetryWorker::new(16)?; - let telemetry = worker.handle().new_telemetry(endpoints); - Ok((worker, telemetry)) - }) - .transpose()?; - - let heap_pages = config - .default_heap_pages - .map_or(DEFAULT_HEAP_ALLOC_STRATEGY, |h| HeapAllocStrategy::Static { extra_pages: h as _ }); - let executor = - sc_executor::NativeElseWasmExecutor::::new_with_wasm_executor( - WasmExecutor::builder() - .with_execution_method(config.wasm_method) - .with_onchain_heap_alloc_strategy(heap_pages) - .with_offchain_heap_alloc_strategy(heap_pages) - .with_max_runtime_instances(config.max_runtime_instances) - .with_runtime_cache_size(config.runtime_cache_size) - .build(), - ); - - let (client, backend, keystore_container, task_manager) = - sc_service::new_full_parts::( - config, - telemetry.as_ref().map(|(_, telemetry)| telemetry.handle()), - executor, - )?; - let client = Arc::new(client); - - let telemetry_worker_handle = telemetry.as_ref().map(|(worker, _)| worker.handle()); - - let telemetry = telemetry.map(|(worker, telemetry)| { - task_manager.spawn_handle().spawn("telemetry", None, worker.run()); - telemetry - }); - - let transaction_pool = sc_transaction_pool::BasicPool::new_full( - config.transaction_pool.clone(), - config.role.is_authority().into(), - config.prometheus_registry(), - task_manager.spawn_essential_handle(), - client.clone(), - ); - - let block_import = ParachainBlockImport::new(client.clone(), backend.clone()); - - let import_queue = build_import_queue( - client.clone(), - block_import.clone(), - config, - telemetry.as_ref().map(|telemetry| telemetry.handle()), - &task_manager, - )?; - - let params = PartialComponents { - backend, - client, - import_queue, - keystore_container, - task_manager, - transaction_pool, - select_chain: (), - other: (block_import, telemetry, telemetry_worker_handle), - }; - - Ok(params) -} - -/// Start a node with the given parachain `Configuration` and relay chain `Configuration`. -/// -/// This is the actual implementation that is abstract over the executor and the runtime api. -#[sc_tracing::logging::prefix_logs_with("Parachain")] -async fn start_node_impl( - parachain_config: Configuration, - polkadot_config: Configuration, - collator_options: CollatorOptions, - id: ParaId, - rpc_ext_builder: RB, - build_import_queue: BIQ, - build_consensus: BIC, -) -> sc_service::error::Result<(TaskManager, Arc>)> -where - RuntimeApi: ConstructRuntimeApi> + Send + Sync + 'static, - RuntimeApi::RuntimeApi: sp_transaction_pool::runtime_api::TaggedTransactionQueue - + sp_api::Metadata - + sp_session::SessionKeys - + sp_api::ApiExt - + sp_offchain::OffchainWorkerApi - + sp_block_builder::BlockBuilder - + cumulus_primitives_core::CollectCollationInfo, - sc_client_api::StateBackendFor: sp_api::StateBackend, - RB: Fn( - sc_rpc_api::DenyUnsafe, - Arc>, - Arc>>, - ) -> Result, sc_service::Error> - + Send - + Clone - + 'static, - BIQ: FnOnce( - Arc>, - ParachainBlockImport, - &Configuration, - Option, - &TaskManager, - ) -> Result, sc_service::Error>, - BIC: FnOnce( - Arc>, - ParachainBlockImport, - Option<&Registry>, - Option, - &TaskManager, - Arc, - Arc>>, - Arc>, - KeystorePtr, - bool, - ) -> Result>, sc_service::Error>, -{ - let parachain_config = prepare_node_config(parachain_config); - - let params = new_partial::(¶chain_config, build_import_queue)?; - let (block_import, mut telemetry, telemetry_worker_handle) = params.other; - - let mut task_manager = params.task_manager; - let (relay_chain_interface, collator_key) = - cumulus_client_service::build_relay_chain_interface( - polkadot_config, - ¶chain_config, - telemetry_worker_handle, - &mut task_manager, - collator_options, - None, - ) - .await - .map_err(|e| sc_service::Error::Application(Box::new(e) as Box<_>))?; - - let client = params.client.clone(); - let backend = params.backend.clone(); - let block_announce_validator = - RequireSecondedInBlockAnnounce::new(relay_chain_interface.clone(), id); - - let force_authoring = parachain_config.force_authoring; - let validator = parachain_config.role.is_authority(); - let prometheus_registry = parachain_config.prometheus_registry().cloned(); - let transaction_pool = params.transaction_pool.clone(); - let import_queue_service = params.import_queue.service(); - let net_config = FullNetworkConfiguration::new(¶chain_config.network); - - let (network, system_rpc_tx, tx_handler_controller, start_network, sync_service) = - sc_service::build_network(sc_service::BuildNetworkParams { - config: ¶chain_config, - net_config, - client: client.clone(), - transaction_pool: transaction_pool.clone(), - spawn_handle: task_manager.spawn_handle(), - import_queue: params.import_queue, - block_announce_validator_builder: Some(Box::new(|_| { - Box::new(block_announce_validator) - })), - warp_sync_params: None, - block_relay: None, - })?; - - let rpc_client = client.clone(); - let rpc_transaction_pool = transaction_pool.clone(); - let rpc_extensions_builder = Box::new(move |deny_unsafe, _| { - rpc_ext_builder(deny_unsafe, rpc_client.clone(), rpc_transaction_pool.clone()) - }); - - sc_service::spawn_tasks(sc_service::SpawnTasksParams { - rpc_builder: rpc_extensions_builder.clone(), - client: client.clone(), - transaction_pool: transaction_pool.clone(), - task_manager: &mut task_manager, - config: parachain_config, - keystore: params.keystore_container.keystore(), - backend: backend.clone(), - network: network.clone(), - sync_service: sync_service.clone(), - system_rpc_tx, - tx_handler_controller, - telemetry: telemetry.as_mut(), - })?; - - let announce_block = { - let sync_service = sync_service.clone(); - Arc::new(move |hash, data| sync_service.announce_block(hash, data)) - }; - - let relay_chain_slot_duration = Duration::from_secs(6); - - let overseer_handle = relay_chain_interface - .overseer_handle() - .map_err(|e| sc_service::Error::Application(Box::new(e)))?; - - if validator { - let parachain_consensus = build_consensus( - client.clone(), - block_import, - prometheus_registry.as_ref(), - telemetry.as_ref().map(|t| t.handle()), - &task_manager, - relay_chain_interface.clone(), - transaction_pool, - sync_service.clone(), - params.keystore_container.keystore(), - force_authoring, - )?; - - let spawner = task_manager.spawn_handle(); - - let params = StartCollatorParams { - para_id: id, - block_status: client.clone(), - announce_block, - client: client.clone(), - task_manager: &mut task_manager, - relay_chain_interface, - spawner, - parachain_consensus, - import_queue: import_queue_service, - collator_key: collator_key.expect("Command line arguments do not allow this. qed"), - relay_chain_slot_duration, - recovery_handle: Box::new(overseer_handle), - sync_service, - }; - - start_collator(params).await?; - } else { - let params = StartFullNodeParams { - client: client.clone(), - announce_block, - task_manager: &mut task_manager, - para_id: id, - relay_chain_interface, - relay_chain_slot_duration, - import_queue: import_queue_service, - recovery_handle: Box::new(overseer_handle), - sync_service, - }; - - start_full_node(params)?; - } - - start_network.start_network(); - - Ok((task_manager, client)) -} - -/// Build the import queue for the the parachain runtime. -#[allow(clippy::type_complexity)] -pub fn parachain_build_import_queue( - client: Arc>, - block_import: ParachainBlockImport, - config: &Configuration, - telemetry: Option, - task_manager: &TaskManager, -) -> Result, sc_service::Error> { - let slot_duration = cumulus_client_consensus_aura::slot_duration(&*client)?; - - cumulus_client_consensus_aura::import_queue::< - sp_consensus_aura::sr25519::AuthorityPair, - _, - _, - _, - _, - _, - >(cumulus_client_consensus_aura::ImportQueueParams { - block_import, - client, - create_inherent_data_providers: move |_, _| async move { - let timestamp = sp_timestamp::InherentDataProvider::from_system_time(); - - let slot = - sp_consensus_aura::inherents::InherentDataProvider::from_timestamp_and_slot_duration( - *timestamp, - slot_duration, - ); - - Ok((slot, timestamp)) - }, - registry: config.prometheus_registry(), - spawner: &task_manager.spawn_essential_handle(), - telemetry, - }) - .map_err(Into::into) -} - -/// Start a normal parachain node. -pub async fn start_node( - parachain_config: Configuration, - polkadot_config: Configuration, - collator_options: CollatorOptions, - id: ParaId, -) -> sc_service::error::Result<(TaskManager, Arc>)> { - start_node_impl::( - parachain_config, - polkadot_config, - collator_options, - id, - |_deny_unsafe, client, pool| { - use pallet_transaction_payment_rpc::{TransactionPayment, TransactionPaymentApiServer}; - use sc_rpc::DenyUnsafe; - use substrate_frame_rpc_system::{System, SystemApiServer}; - - let mut io = jsonrpsee::RpcModule::new(()); - let map_err = |e| sc_service::Error::Other(format!("{e}")); - io.merge(System::new(client.clone(), pool, DenyUnsafe::No).into_rpc()) - .map_err(map_err)?; - io.merge(TransactionPayment::new(client).into_rpc()).map_err(map_err)?; - Ok(io) - }, - parachain_build_import_queue, - |client, - block_import, - prometheus_registry, - telemetry, - task_manager, - relay_chain_interface, - transaction_pool, - sync_oracle, - keystore, - force_authoring| { - let client2 = client.clone(); - let block_import2 = block_import; - let slot_duration = cumulus_client_consensus_aura::slot_duration(&*client)?; - - let proposer_factory = sc_basic_authorship::ProposerFactory::with_proof_recording( - task_manager.spawn_handle(), - client, - transaction_pool, - prometheus_registry, - telemetry.clone(), - ); - - Ok(AuraConsensus::build::( - BuildAuraConsensusParams { - proposer_factory, - create_inherent_data_providers: move |_, (relay_parent, validation_data)| { - let relay_chain_interface = relay_chain_interface.clone(); - async move { - let parachain_inherent = - cumulus_primitives_parachain_inherent::ParachainInherentData::create_at( - relay_parent, - &relay_chain_interface, - &validation_data, - id, - ).await; - let time = sp_timestamp::InherentDataProvider::from_system_time(); - - let slot = sp_consensus_aura::inherents::InherentDataProvider::from_timestamp_and_slot_duration( - *time, - slot_duration, - ); - - let parachain_inherent = parachain_inherent.ok_or_else(|| { - Box::::from( - "Failed to create parachain inherent", - ) - })?; - Ok((slot, time, parachain_inherent)) - } - }, - block_import: block_import2, - para_client: client2, - backoff_authoring_blocks: Option::<()>::None, - sync_oracle, - keystore, - force_authoring, - slot_duration, - // We got around 1000ms for proposing - block_proposal_slot_portion: SlotProportion::new(1f32 / 12f32), - telemetry, - max_block_proposal_slot_portion: None, - }, - )) - }, - ) - .await -} diff --git a/bin/rialto-parachain/runtime/Cargo.toml b/bin/rialto-parachain/runtime/Cargo.toml deleted file mode 100644 index 0715e7a2927ae..0000000000000 --- a/bin/rialto-parachain/runtime/Cargo.toml +++ /dev/null @@ -1,146 +0,0 @@ -[package] -name = "rialto-parachain-runtime" -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -repository = "https://github.com/paritytech/parity-bridges-common/" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[build-dependencies] -substrate-wasm-builder = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -[dependencies] -codec = { package = 'parity-scale-codec', version = '3.1.5', default-features = false, features = ['derive']} -hex-literal = "0.4" -scale-info = { version = "2.10.0", default-features = false, features = ["derive"] } - -# Bridge depedencies - -bp-header-chain = { path = "../../../primitives/header-chain", default-features = false } -bp-messages = { path = "../../../primitives/messages", default-features = false } -bp-millau = { path = "../../../primitives/chain-millau", default-features = false } -bp-polkadot-core = { path = "../../../primitives/polkadot-core", default-features = false } -bp-relayers = { path = "../../../primitives/relayers", default-features = false } -bp-runtime = { path = "../../../primitives/runtime", default-features = false } -bp-rialto-parachain = { path = "../../../primitives/chain-rialto-parachain", default-features = false } -bridge-runtime-common = { path = "../../runtime-common", default-features = false } -pallet-bridge-grandpa = { path = "../../../modules/grandpa", default-features = false } -pallet-bridge-messages = { path = "../../../modules/messages", default-features = false } -pallet-bridge-relayers = { path = "../../../modules/relayers", default-features = false } - -# Substrate Dependencies -## Substrate Primitive Dependencies -sp-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-block-builder = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-consensus-aura = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-inherents = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-io = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-offchain = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-session = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-std = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-transaction-pool = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-version = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -## Substrate FRAME Dependencies -frame-executive = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-benchmarking = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false, optional = true } -frame-support = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-system-benchmarking = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false, optional = true } -frame-system-rpc-runtime-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -## Substrate Pallet Dependencies -pallet-aura = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-balances = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-sudo = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-timestamp = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-transaction-payment = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-transaction-payment-rpc-runtime-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -# Cumulus Dependencies -cumulus-pallet-aura-ext = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -cumulus-pallet-parachain-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -cumulus-pallet-dmp-queue = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -cumulus-pallet-xcm = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -cumulus-pallet-xcmp-queue = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -cumulus-primitives-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -cumulus-primitives-timestamp = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -parachain-info = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -# Polkadot Dependencies -polkadot-parachain-primitives = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -xcm = { package = "staging-xcm", git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -xcm-builder = { package = "staging-xcm-builder", git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -xcm-executor = { package = "staging-xcm-executor", git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-xcm = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -[dev-dependencies] -bridge-runtime-common = { path = "../../runtime-common", features = ["integrity-test"] } -static_assertions = "1.1" - -[features] -default = [ 'std' ] -runtime-benchmarks = [ - 'bridge-runtime-common/runtime-benchmarks', - 'frame-benchmarking', - 'frame-support/runtime-benchmarks', - 'frame-system-benchmarking/runtime-benchmarks', - 'frame-system/runtime-benchmarks', - 'pallet-balances/runtime-benchmarks', - 'pallet-bridge-grandpa/runtime-benchmarks', - 'pallet-bridge-messages/runtime-benchmarks', - 'pallet-bridge-relayers/runtime-benchmarks', - 'pallet-timestamp/runtime-benchmarks', - 'pallet-xcm/runtime-benchmarks', - 'sp-runtime/runtime-benchmarks', - 'xcm-builder/runtime-benchmarks', -] -std = [ - "bp-messages/std", - "bp-millau/std", - "bp-relayers/std", - "bp-rialto-parachain/std", - "bp-runtime/std", - "bridge-runtime-common/std", - "codec/std", - "cumulus-pallet-aura-ext/std", - "cumulus-pallet-parachain-system/std", - "cumulus-pallet-xcm/std", - "cumulus-pallet-xcmp-queue/std", - "cumulus-primitives-core/std", - "cumulus-primitives-timestamp/std", - "frame-executive/std", - "frame-support/std", - "frame-system-rpc-runtime-api/std", - "frame-system/std", - "pallet-aura/std", - "pallet-balances/std", - "pallet-bridge-grandpa/std", - "pallet-bridge-messages/std", - "pallet-bridge-relayers/std", - "pallet-sudo/std", - "pallet-timestamp/std", - "pallet-transaction-payment-rpc-runtime-api/std", - "pallet-transaction-payment/std", - "pallet-xcm/std", - "parachain-info/std", - "polkadot-parachain-primitives/std", - "scale-info/std", - "sp-api/std", - "sp-block-builder/std", - "sp-consensus-aura/std", - "sp-core/std", - "sp-inherents/std", - "sp-io/std", - "sp-offchain/std", - "sp-runtime/std", - "sp-session/std", - "sp-std/std", - "sp-transaction-pool/std", - "sp-version/std", - "xcm-builder/std", - "xcm-executor/std", - "xcm/std", -] diff --git a/bin/rialto-parachain/runtime/build.rs b/bin/rialto-parachain/runtime/build.rs deleted file mode 100644 index 692e270bbbae3..0000000000000 --- a/bin/rialto-parachain/runtime/build.rs +++ /dev/null @@ -1,26 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use substrate_wasm_builder::WasmBuilder; - -fn main() { - WasmBuilder::new() - .with_current_project() - .export_heap_base() - .import_memory() - .disable_runtime_version_section_check() - .build() -} diff --git a/bin/rialto-parachain/runtime/src/lib.rs b/bin/rialto-parachain/runtime/src/lib.rs deleted file mode 100644 index e64932d1a443f..0000000000000 --- a/bin/rialto-parachain/runtime/src/lib.rs +++ /dev/null @@ -1,975 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! The Rialto parachain runtime. This can be compiled with `#[no_std]`, ready for Wasm. -//! -//! Originally a copy of runtime from . - -#![cfg_attr(not(feature = "std"), no_std)] -// `construct_runtime!` does a lot of recursion and requires us to increase the limit to 256. -#![recursion_limit = "256"] - -// Make the WASM binary available. -#[cfg(feature = "std")] -include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs")); - -use bridge_runtime_common::generate_bridge_reject_obsolete_headers_and_messages; -use codec::{Decode, Encode}; -use cumulus_pallet_parachain_system::AnyRelayNumber; -use scale_info::TypeInfo; -use sp_api::impl_runtime_apis; -use sp_core::{crypto::KeyTypeId, OpaqueMetadata}; -use sp_runtime::{ - create_runtime_str, generic, impl_opaque_keys, - traits::{AccountIdLookup, Block as BlockT, DispatchInfoOf, SignedExtension}, - transaction_validity::{TransactionSource, TransactionValidity, TransactionValidityError}, - ApplyExtrinsicResult, -}; - -use sp_std::prelude::*; -#[cfg(feature = "std")] -use sp_version::NativeVersion; -use sp_version::RuntimeVersion; - -// A few exports that help ease life for downstream crates. -use bp_runtime::HeaderId; -pub use frame_support::{ - construct_runtime, - dispatch::DispatchClass, - match_types, parameter_types, - traits::{ConstBool, ConstU32, Everything, IsInVec, Nothing, Randomness}, - weights::{ - constants::{ - BlockExecutionWeight, ExtrinsicBaseWeight, RocksDbWeight, WEIGHT_REF_TIME_PER_SECOND, - }, - IdentityFee, Weight, - }, - StorageValue, -}; -pub use frame_system::{Call as SystemCall, EnsureRoot}; -pub use pallet_balances::Call as BalancesCall; -pub use pallet_sudo::Call as SudoCall; -pub use pallet_timestamp::Call as TimestampCall; -pub use sp_consensus_aura::sr25519::AuthorityId as AuraId; -#[cfg(any(feature = "std", test))] -pub use sp_runtime::BuildStorage; -pub use sp_runtime::{MultiAddress, Perbill, Permill}; - -pub use bp_rialto_parachain::{ - AccountId, Balance, BlockLength, BlockNumber, BlockWeights, Hash, Hasher as Hashing, Header, - Nonce, Signature, MAXIMUM_BLOCK_WEIGHT, -}; - -pub use pallet_bridge_grandpa::Call as BridgeGrandpaCall; -pub use pallet_bridge_messages::Call as MessagesCall; -pub use pallet_xcm::Call as XcmCall; - -// Polkadot & XCM imports -use bridge_runtime_common::CustomNetworkId; -use pallet_xcm::XcmPassthrough; -use polkadot_parachain_primitives::primitives::Sibling; -use xcm::latest::prelude::*; -use xcm_builder::{ - AccountId32Aliases, CurrencyAdapter, EnsureXcmOrigin, FixedWeightBounds, IsConcrete, - NativeAsset, ParentAsSuperuser, ParentIsPreset, RelayChainAsNative, SiblingParachainAsNative, - SiblingParachainConvertsVia, SignedAccountId32AsNative, SignedToAccountId32, - SovereignSignedViaLocation, TakeWeightCredit, UsingComponents, -}; -use xcm_executor::{Config, XcmExecutor}; - -pub mod millau_messages; - -// generate signed extension that rejects obsolete bridge transactions -generate_bridge_reject_obsolete_headers_and_messages! { - RuntimeCall, AccountId, - // Grandpa - BridgeMillauGrandpa, - // Messages - BridgeMillauMessages -} - -/// Dummy signed extension that does nothing. -/// -/// We're using it to have the same set of signed extensions on all parachains with bridge pallets -/// deployed (bridge hubs and rialto parachain). -#[derive(Encode, Decode, Debug, PartialEq, Eq, Clone, TypeInfo)] -pub struct DummyBridgeRefundMillauMessages; - -impl SignedExtension for DummyBridgeRefundMillauMessages { - const IDENTIFIER: &'static str = "DummyBridgeRefundMillauMessages"; - type AccountId = AccountId; - type Call = RuntimeCall; - type AdditionalSigned = (); - type Pre = (); - - fn additional_signed(&self) -> Result { - Ok(()) - } - - fn pre_dispatch( - self, - _who: &Self::AccountId, - _call: &Self::Call, - _info: &DispatchInfoOf, - _len: usize, - ) -> Result { - Ok(()) - } -} - -/// The address format for describing accounts. -pub type Address = MultiAddress; -/// Block type as expected by this runtime. -pub type Block = generic::Block; -/// A Block signed with a Justification -pub type SignedBlock = generic::SignedBlock; -/// BlockId type as expected by this runtime. -pub type BlockId = generic::BlockId; -/// The SignedExtension to the basic transaction logic. -pub type SignedExtra = ( - frame_system::CheckNonZeroSender, - frame_system::CheckSpecVersion, - frame_system::CheckTxVersion, - frame_system::CheckGenesis, - frame_system::CheckEra, - frame_system::CheckNonce, - frame_system::CheckWeight, - pallet_transaction_payment::ChargeTransactionPayment, - BridgeRejectObsoleteHeadersAndMessages, - DummyBridgeRefundMillauMessages, -); -/// Unchecked extrinsic type as expected by this runtime. -pub type UncheckedExtrinsic = - generic::UncheckedExtrinsic; -/// Extrinsic type that has already been checked. -pub type CheckedExtrinsic = generic::CheckedExtrinsic; -/// Executive: handles dispatch to the various modules. -pub type Executive = frame_executive::Executive< - Runtime, - Block, - frame_system::ChainContext, - Runtime, - AllPalletsWithSystem, ->; - -impl_opaque_keys! { - pub struct SessionKeys { - pub aura: Aura, - } -} - -/// This runtime version. -#[sp_version::runtime_version] -pub const VERSION: RuntimeVersion = RuntimeVersion { - spec_name: create_runtime_str!("template-parachain"), - impl_name: create_runtime_str!("template-parachain"), - authoring_version: 1, - spec_version: 1, - impl_version: 0, - apis: RUNTIME_API_VERSIONS, - transaction_version: 1, - state_version: 0, -}; - -/// This determines the average expected block time that we are targeting. -/// Blocks will be produced at a minimum duration defined by `SLOT_DURATION`. -/// `SLOT_DURATION` is picked up by `pallet_timestamp` which is in turn picked -/// up by `pallet_aura` to implement `fn slot_duration()`. -/// -/// Change this to adjust the block time. -pub const MILLISECS_PER_BLOCK: u64 = 12000; - -pub const SLOT_DURATION: u64 = MILLISECS_PER_BLOCK; - -pub const EPOCH_DURATION_IN_BLOCKS: u32 = 10 * MINUTES; - -// Time is measured by number of blocks. -pub const MINUTES: BlockNumber = 60_000 / (MILLISECS_PER_BLOCK as BlockNumber); -pub const HOURS: BlockNumber = MINUTES * 60; -pub const DAYS: BlockNumber = HOURS * 24; - -// Unit = the base number of indivisible units for balances -pub const UNIT: Balance = 1_000_000_000_000; -pub const MILLIUNIT: Balance = 1_000_000_000; -pub const MICROUNIT: Balance = 1_000_000; - -// 1 in 4 blocks (on average, not counting collisions) will be primary babe blocks. -pub const PRIMARY_PROBABILITY: (u64, u64) = (1, 4); - -/// The version information used to identify this runtime when compiled natively. -#[cfg(feature = "std")] -pub fn native_version() -> NativeVersion { - NativeVersion { runtime_version: VERSION, can_author_with: Default::default() } -} - -parameter_types! { - pub const BlockHashCount: BlockNumber = 250; - pub const Version: RuntimeVersion = VERSION; - pub const SS58Prefix: u8 = 48; -} - -// Configure FRAME pallets to include in runtime. - -impl frame_system::Config for Runtime { - /// The identifier used to distinguish between accounts. - type AccountId = AccountId; - /// The aggregated dispatch type that is available for extrinsics. - type RuntimeCall = RuntimeCall; - /// The lookup mechanism to get account ID from whatever is passed in dispatchers. - type Lookup = AccountIdLookup; - /// The index type for storing how many extrinsics an account has signed. - type Nonce = Nonce; - /// The type for hashing blocks and tries. - type Hash = Hash; - /// The hashing algorithm used. - type Hashing = Hashing; - /// The header type. - type Block = Block; - /// The ubiquitous event type. - type RuntimeEvent = RuntimeEvent; - /// The ubiquitous origin type. - type RuntimeOrigin = RuntimeOrigin; - /// Maximum number of block number to block hash mappings to keep (oldest pruned first). - type BlockHashCount = BlockHashCount; - /// Runtime version. - type Version = Version; - /// Converts a module to an index of this module in the runtime. - type PalletInfo = PalletInfo; - type AccountData = pallet_balances::AccountData; - /// What to do if a new account is created. - type OnNewAccount = (); - /// What to do if an account is fully reaped from the system. - type OnKilledAccount = (); - /// The weight of database operations that the runtime can invoke. - type DbWeight = (); - /// The basic call filter to use in dispatchable. - type BaseCallFilter = Everything; - /// Weight information for the extrinsics of this pallet. - type SystemWeightInfo = (); - /// Block & extrinsics weights: base values and limits. - type BlockWeights = BlockWeights; - /// The maximum length of a block (in bytes). - type BlockLength = BlockLength; - /// This is used as an identifier of the chain. 42 is the generic substrate prefix. - type SS58Prefix = SS58Prefix; - /// The action to take on a Runtime Upgrade - type OnSetCode = cumulus_pallet_parachain_system::ParachainSetCode; - type MaxConsumers = frame_support::traits::ConstU32<16>; -} - -parameter_types! { - pub const MinimumPeriod: u64 = SLOT_DURATION / 2; -} - -impl pallet_timestamp::Config for Runtime { - /// A timestamp: milliseconds since the Unix epoch. - type Moment = u64; - type OnTimestampSet = (); - type MinimumPeriod = MinimumPeriod; - type WeightInfo = (); -} - -parameter_types! { - pub const ExistentialDeposit: u128 = MILLIUNIT; - pub const TransferFee: u128 = MILLIUNIT; - pub const CreationFee: u128 = MILLIUNIT; - pub const TransactionByteFee: u128 = MICROUNIT; - pub const OperationalFeeMultiplier: u8 = 5; -} - -impl pallet_balances::Config for Runtime { - /// The type for recording an account's balance. - type Balance = Balance; - /// The ubiquitous event type. - type RuntimeEvent = RuntimeEvent; - type DustRemoval = (); - type ExistentialDeposit = ExistentialDeposit; - type AccountStore = System; - type WeightInfo = pallet_balances::weights::SubstrateWeight; - type MaxLocks = ConstU32<50>; - type MaxReserves = ConstU32<50>; - type ReserveIdentifier = [u8; 8]; - type RuntimeHoldReason = RuntimeHoldReason; - type FreezeIdentifier = (); - type MaxHolds = ConstU32<0>; - type MaxFreezes = ConstU32<0>; -} - -impl pallet_transaction_payment::Config for Runtime { - type OnChargeTransaction = pallet_transaction_payment::CurrencyAdapter; - type OperationalFeeMultiplier = OperationalFeeMultiplier; - type WeightToFee = IdentityFee; - type LengthToFee = IdentityFee; - type FeeMultiplierUpdate = (); - type RuntimeEvent = RuntimeEvent; -} - -impl pallet_sudo::Config for Runtime { - type RuntimeCall = RuntimeCall; - type RuntimeEvent = RuntimeEvent; - type WeightInfo = pallet_sudo::weights::SubstrateWeight; -} - -parameter_types! { - pub const ReservedXcmpWeight: Weight = MAXIMUM_BLOCK_WEIGHT.saturating_div(4); - pub const ReservedDmpWeight: Weight = MAXIMUM_BLOCK_WEIGHT.saturating_div(4); -} - -impl cumulus_pallet_parachain_system::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type OnSystemEvent = (); - type SelfParaId = parachain_info::Pallet; - type OutboundXcmpMessageSource = XcmpQueue; - type DmpMessageHandler = DmpQueue; - type ReservedDmpWeight = ReservedDmpWeight; - type XcmpMessageHandler = XcmpQueue; - type ReservedXcmpWeight = ReservedXcmpWeight; - type CheckAssociatedRelayNumber = AnyRelayNumber; -} - -impl parachain_info::Config for Runtime {} - -impl cumulus_pallet_aura_ext::Config for Runtime {} - -parameter_types! { - pub const RelayLocation: MultiLocation = MultiLocation::parent(); - pub const RelayNetwork: NetworkId = CustomNetworkId::Rialto.as_network_id(); - pub RelayOrigin: RuntimeOrigin = cumulus_pallet_xcm::Origin::Relay.into(); - pub UniversalLocation: InteriorMultiLocation = ThisNetwork::get().into(); - /// The Millau network ID. - pub const MillauNetwork: NetworkId = CustomNetworkId::Millau.as_network_id(); - /// The RialtoParachain network ID. - pub const ThisNetwork: NetworkId = CustomNetworkId::RialtoParachain.as_network_id(); -} - -/// Type for specifying how a `MultiLocation` can be converted into an `AccountId`. This is used -/// when determining ownership of accounts for asset transacting and when attempting to use XCM -/// `Transact` in order to determine the dispatch Origin. -pub type LocationToAccountId = ( - // The parent (Relay-chain) origin converts to the default `AccountId`. - ParentIsPreset, - // Sibling parachain origins convert to AccountId via the `ParaId::into`. - SiblingParachainConvertsVia, - // Straight up local `AccountId32` origins just alias directly to `AccountId`. - AccountId32Aliases, -); - -/// Means for transacting assets on this chain. -pub type LocalAssetTransactor = CurrencyAdapter< - // Use this currency: - Balances, - // Use this currency when it is a fungible asset matching the given location or name: - IsConcrete, - // Do a simple punn to convert an AccountId32 MultiLocation into a native chain account ID: - LocationToAccountId, - // Our chain's account ID type (we can't get away without mentioning it explicitly): - AccountId, - // We don't track any teleports. - (), ->; - -/// This is the type we use to convert an (incoming) XCM origin into a local `Origin` instance, -/// ready for dispatching a transaction with XCM `Transact`. There is an `OriginKind` which can -/// biases the kind of local `Origin` it will become. -pub type XcmOriginToTransactDispatchOrigin = ( - // Sovereign account converter; this attempts to derive an `AccountId` from the origin location - // using `LocationToAccountId` and then turn that into the usual `Signed` origin. Useful for - // foreign chains who want to have a local sovereign account on this chain which they control. - SovereignSignedViaLocation, - // Native converter for Relay-chain (Parent) location; will convert to a `Relay` origin when - // recognised. - RelayChainAsNative, - // Native converter for sibling Parachains; will convert to a `SiblingPara` origin when - // recognised. - SiblingParachainAsNative, - // Superuser converter for the Relay-chain (Parent) location. This will allow it to issue a - // transaction from the Root origin. - ParentAsSuperuser, - // Native signed account converter; this just converts an `AccountId32` origin into a normal - // `Origin::Signed` origin of the same 32-byte value. - SignedAccountId32AsNative, - // Xcm origins can be represented natively under the Xcm pallet's Xcm origin. - XcmPassthrough, -); - -// TODO: until https://github.com/paritytech/parity-bridges-common/issues/1417 is fixed (in either way), -// the following constant must match the similar constant in the Millau runtime. - -parameter_types! { - /// The amount of weight an XCM operation takes. We don't care much about those values as we're on testnet. - pub const UnitWeightCost: Weight = Weight::from_parts(1_000_000, 1024); - // One UNIT buys 1 second of weight. - pub const WeightPrice: (MultiLocation, u128) = (MultiLocation::parent(), UNIT); - pub const MaxInstructions: u32 = 100; - pub const MaxAuthorities: u32 = 100_000; - pub MaxAssetsIntoHolding: u32 = 64; -} - -match_types! { - pub type ParentOrParentsUnitPlurality: impl Contains = { - MultiLocation { parents: 1, interior: Here } | - MultiLocation { parents: 1, interior: X1(Plurality { id: BodyId::Unit, .. }) } - }; -} - -pub type Barrier = TakeWeightCredit; - -/// Dispatches received XCM messages from other chain. -pub type OnRialtoParachainBlobDispatcher = - xcm_builder::BridgeBlobDispatcher; - -/// XCM weigher type. -pub type XcmWeigher = FixedWeightBounds; - -pub struct XcmConfig; -impl Config for XcmConfig { - type RuntimeCall = RuntimeCall; - type XcmSender = (); - type AssetTransactor = LocalAssetTransactor; - type OriginConverter = XcmOriginToTransactDispatchOrigin; - type IsReserve = NativeAsset; - type IsTeleporter = NativeAsset; // <- should be enough to allow teleportation of UNIT - type UniversalLocation = UniversalLocation; - type Barrier = Barrier; - type Weigher = XcmWeigher; - type Trader = UsingComponents, RelayLocation, AccountId, Balances, ()>; - type ResponseHandler = PolkadotXcm; - type AssetTrap = PolkadotXcm; - type AssetClaims = PolkadotXcm; - type SubscriptionService = PolkadotXcm; - type PalletInstancesInfo = (); - type MaxAssetsIntoHolding = MaxAssetsIntoHolding; - type AssetLocker = (); - type AssetExchanger = (); - type FeeManager = (); - type MessageExporter = millau_messages::ToMillauBlobExporter; - type UniversalAliases = Nothing; - type CallDispatcher = RuntimeCall; - type SafeCallFilter = Everything; - type Aliasers = Nothing; -} - -/// No local origins on this chain are allowed to dispatch XCM sends/executions. -pub type LocalOriginToLocation = SignedToAccountId32; - -/// The XCM router. We are not sending messages to sibling/parent/child chains here. -pub type XcmRouter = (); - -#[cfg(feature = "runtime-benchmarks")] -parameter_types! { - pub ReachableDest: Option = None; -} - -impl pallet_xcm::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type SendXcmOrigin = EnsureXcmOrigin; - type XcmRouter = XcmRouter; - type ExecuteXcmOrigin = EnsureXcmOrigin; - type XcmExecuteFilter = Everything; - type XcmExecutor = XcmExecutor; - type XcmTeleportFilter = Everything; - type XcmReserveTransferFilter = Everything; - type Weigher = XcmWeigher; - type RuntimeOrigin = RuntimeOrigin; - type RuntimeCall = RuntimeCall; - const VERSION_DISCOVERY_QUEUE_SIZE: u32 = 100; - type AdvertisedXcmVersion = pallet_xcm::CurrentXcmVersion; - type Currency = Balances; - type CurrencyMatcher = (); - type TrustedLockers = (); - type SovereignAccountOf = (); - type MaxLockers = frame_support::traits::ConstU32<8>; - type UniversalLocation = UniversalLocation; - type WeightInfo = pallet_xcm::TestWeightInfo; - #[cfg(feature = "runtime-benchmarks")] - type ReachableDest = ReachableDest; - type AdminOrigin = frame_system::EnsureRoot; - type MaxRemoteLockConsumers = ConstU32<0>; - type RemoteLockConsumerIdentifier = (); -} - -impl cumulus_pallet_xcm::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type XcmExecutor = XcmExecutor; -} - -impl cumulus_pallet_xcmp_queue::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type XcmExecutor = XcmExecutor; - type ChannelInfo = ParachainSystem; - type VersionWrapper = (); - type ExecuteOverweightOrigin = EnsureRoot; - type ControllerOrigin = EnsureRoot; - type ControllerOriginConverter = XcmOriginToTransactDispatchOrigin; - type WeightInfo = (); - type PriceForSiblingDelivery = (); -} - -impl cumulus_pallet_dmp_queue::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type XcmExecutor = XcmExecutor; - type ExecuteOverweightOrigin = frame_system::EnsureRoot; -} - -impl pallet_aura::Config for Runtime { - type AuthorityId = AuraId; - type DisabledValidators = (); - type MaxAuthorities = MaxAuthorities; - type AllowMultipleBlocksPerSlot = ConstBool; -} - -impl pallet_bridge_relayers::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type Reward = Balance; - type PaymentProcedure = - bp_relayers::PayRewardFromAccount, AccountId>; - type StakeAndSlash = (); - type WeightInfo = (); -} - -pub type MillauGrandpaInstance = (); -impl pallet_bridge_grandpa::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type BridgedChain = bp_millau::Millau; - type MaxFreeMandatoryHeadersPerBlock = ConstU32<4>; - type HeadersToKeep = ConstU32<{ bp_millau::DAYS as u32 }>; - type WeightInfo = pallet_bridge_grandpa::weights::BridgeWeight; -} - -parameter_types! { - pub const MaxMessagesToPruneAtOnce: bp_messages::MessageNonce = 8; - pub const MaxUnrewardedRelayerEntriesAtInboundLane: bp_messages::MessageNonce = - bp_millau::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX; - pub const MaxUnconfirmedMessagesAtInboundLane: bp_messages::MessageNonce = - bp_millau::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX; - pub const RootAccountForPayments: Option = None; - pub const BridgedChainId: bp_runtime::ChainId = bp_runtime::MILLAU_CHAIN_ID; - pub ActiveOutboundLanes: &'static [bp_messages::LaneId] = &[millau_messages::XCM_LANE]; -} - -/// Instance of the messages pallet used to relay messages to/from Millau chain. -pub type WithMillauMessagesInstance = (); - -impl pallet_bridge_messages::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type WeightInfo = pallet_bridge_messages::weights::BridgeWeight; - type ActiveOutboundLanes = ActiveOutboundLanes; - type MaxUnrewardedRelayerEntriesAtInboundLane = MaxUnrewardedRelayerEntriesAtInboundLane; - type MaxUnconfirmedMessagesAtInboundLane = MaxUnconfirmedMessagesAtInboundLane; - - type MaximalOutboundPayloadSize = crate::millau_messages::ToMillauMaximalOutboundPayloadSize; - type OutboundPayload = crate::millau_messages::ToMillauMessagePayload; - - type InboundPayload = crate::millau_messages::FromMillauMessagePayload; - type InboundRelayer = bp_millau::AccountId; - type DeliveryPayments = (); - - type TargetHeaderChain = crate::millau_messages::MillauAsTargetHeaderChain; - type LaneMessageVerifier = crate::millau_messages::ToMillauMessageVerifier; - type DeliveryConfirmationPayments = pallet_bridge_relayers::DeliveryConfirmationPaymentsAdapter< - Runtime, - WithMillauMessagesInstance, - frame_support::traits::ConstU128<100_000>, - >; - type OnMessagesDelivered = (); - - type SourceHeaderChain = crate::millau_messages::MillauAsSourceHeaderChain; - type MessageDispatch = crate::millau_messages::FromMillauMessageDispatch; - type BridgedChainId = BridgedChainId; -} - -// Create the runtime by composing the FRAME pallets that were previously configured. -construct_runtime!( - pub enum Runtime { - System: frame_system::{Pallet, Call, Storage, Config, Event}, - Timestamp: pallet_timestamp::{Pallet, Call, Storage, Inherent}, - Sudo: pallet_sudo::{Pallet, Call, Storage, Config, Event}, - TransactionPayment: pallet_transaction_payment::{Pallet, Storage, Event}, - - ParachainSystem: cumulus_pallet_parachain_system::{Pallet, Call, Storage, Inherent, Event} = 20, - ParachainInfo: parachain_info::{Pallet, Storage, Config} = 21, - - Balances: pallet_balances::{Pallet, Call, Storage, Config, Event} = 30, - - Aura: pallet_aura::{Pallet, Config}, - AuraExt: cumulus_pallet_aura_ext::{Pallet, Config}, - - // XCM helpers. - XcmpQueue: cumulus_pallet_xcmp_queue::{Pallet, Call, Storage, Event} = 50, - PolkadotXcm: pallet_xcm::{Pallet, Call, Event, Origin} = 51, - CumulusXcm: cumulus_pallet_xcm::{Pallet, Call, Event, Origin} = 52, - DmpQueue: cumulus_pallet_dmp_queue::{Pallet, Call, Storage, Event} = 53, - - // Millau bridge modules. - BridgeRelayers: pallet_bridge_relayers::{Pallet, Call, Storage, Event}, - BridgeMillauGrandpa: pallet_bridge_grandpa::{Pallet, Call, Storage, Event}, - BridgeMillauMessages: pallet_bridge_messages::{Pallet, Call, Storage, Event, Config}, - } -); - -impl_runtime_apis! { - impl sp_api::Core for Runtime { - fn version() -> RuntimeVersion { - VERSION - } - - fn execute_block(block: Block) { - Executive::execute_block(block) - } - - fn initialize_block(header: &::Header) { - Executive::initialize_block(header) - } - } - - impl sp_api::Metadata for Runtime { - fn metadata() -> OpaqueMetadata { - OpaqueMetadata::new(Runtime::metadata().into()) - } - - fn metadata_at_version(version: u32) -> Option { - Runtime::metadata_at_version(version) - } - - fn metadata_versions() -> sp_std::vec::Vec { - Runtime::metadata_versions() - } - } - - impl sp_block_builder::BlockBuilder for Runtime { - fn apply_extrinsic( - extrinsic: ::Extrinsic, - ) -> ApplyExtrinsicResult { - Executive::apply_extrinsic(extrinsic) - } - - fn finalize_block() -> ::Header { - Executive::finalize_block() - } - - fn inherent_extrinsics(data: sp_inherents::InherentData) -> Vec<::Extrinsic> { - data.create_extrinsics() - } - - fn check_inherents( - block: Block, - data: sp_inherents::InherentData, - ) -> sp_inherents::CheckInherentsResult { - data.check_extrinsics(&block) - } - } - - impl sp_transaction_pool::runtime_api::TaggedTransactionQueue for Runtime { - fn validate_transaction( - source: TransactionSource, - tx: ::Extrinsic, - block_hash: ::Hash, - ) -> TransactionValidity { - Executive::validate_transaction(source, tx, block_hash) - } - } - - impl sp_offchain::OffchainWorkerApi for Runtime { - fn offchain_worker(header: &::Header) { - Executive::offchain_worker(header) - } - } - - impl sp_session::SessionKeys for Runtime { - fn decode_session_keys( - encoded: Vec, - ) -> Option, KeyTypeId)>> { - SessionKeys::decode_into_raw_public_keys(&encoded) - } - - fn generate_session_keys(seed: Option>) -> Vec { - SessionKeys::generate(seed) - } - } - - impl sp_consensus_aura::AuraApi for Runtime { - fn slot_duration() -> sp_consensus_aura::SlotDuration { - sp_consensus_aura::SlotDuration::from_millis(Aura::slot_duration()) - } - - fn authorities() -> Vec { - Aura::authorities().to_vec() - } - } - - impl cumulus_primitives_core::CollectCollationInfo for Runtime { - fn collect_collation_info(header: &::Header) -> cumulus_primitives_core::CollationInfo { - ParachainSystem::collect_collation_info(header) - } - } - - impl frame_system_rpc_runtime_api::AccountNonceApi for Runtime { - fn account_nonce(account: AccountId) -> Nonce { - System::account_nonce(account) - } - } - - impl pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi for Runtime { - fn query_info( - uxt: ::Extrinsic, - len: u32, - ) -> pallet_transaction_payment_rpc_runtime_api::RuntimeDispatchInfo { - TransactionPayment::query_info(uxt, len) - } - fn query_fee_details( - uxt: ::Extrinsic, - len: u32, - ) -> pallet_transaction_payment::FeeDetails { - TransactionPayment::query_fee_details(uxt, len) - } - fn query_weight_to_fee(weight: Weight) -> Balance { - TransactionPayment::weight_to_fee(weight) - } - fn query_length_to_fee(length: u32) -> Balance { - TransactionPayment::length_to_fee(length) - } - } - - impl bp_millau::MillauFinalityApi for Runtime { - fn best_finalized() -> Option> { - BridgeMillauGrandpa::best_finalized() - } - - fn synced_headers_grandpa_info( - ) -> Vec> { - BridgeMillauGrandpa::synced_headers_grandpa_info() - } - } - - impl bp_millau::ToMillauOutboundLaneApi for Runtime { - fn message_details( - lane: bp_messages::LaneId, - begin: bp_messages::MessageNonce, - end: bp_messages::MessageNonce, - ) -> Vec { - bridge_runtime_common::messages_api::outbound_message_details::< - Runtime, - WithMillauMessagesInstance, - >(lane, begin, end) - } - } - - impl bp_millau::FromMillauInboundLaneApi for Runtime { - fn message_details( - lane: bp_messages::LaneId, - messages: Vec<(bp_messages::MessagePayload, bp_messages::OutboundMessageDetails)>, - ) -> Vec { - bridge_runtime_common::messages_api::inbound_message_details::< - Runtime, - WithMillauMessagesInstance, - >(lane, messages) - } - } - - #[cfg(feature = "runtime-benchmarks")] - impl frame_benchmarking::Benchmark for Runtime { - fn benchmark_metadata(_extra: bool) -> ( - Vec, - Vec, - ) { - todo!("TODO: fix or remove") - } - - fn dispatch_benchmark( - config: frame_benchmarking::BenchmarkConfig - ) -> Result, sp_runtime::RuntimeString> { - use frame_benchmarking::{Benchmarking, BenchmarkBatch, add_benchmark}; - use frame_support::traits::TrackedStorageKey; - - use frame_system_benchmarking::Pallet as SystemBench; - impl frame_system_benchmarking::Config for Runtime {} - - let whitelist: Vec = vec![ - // Block Number - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac").to_vec().into(), - // Total Issuance - hex_literal::hex!("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80").to_vec().into(), - // Execution Phase - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a").to_vec().into(), - // Event Count - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850").to_vec().into(), - // System Events - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7").to_vec().into(), - ]; - - let mut batches = Vec::::new(); - let params = (&config, &whitelist); - - add_benchmark!(params, batches, frame_system, SystemBench::); - add_benchmark!(params, batches, pallet_balances, Balances); - add_benchmark!(params, batches, pallet_timestamp, Timestamp); - - Ok(batches) - } - } -} - -struct CheckInherents; - -impl cumulus_pallet_parachain_system::CheckInherents for CheckInherents { - fn check_inherents( - block: &Block, - relay_state_proof: &cumulus_pallet_parachain_system::RelayChainStateProof, - ) -> sp_inherents::CheckInherentsResult { - let relay_chain_slot = relay_state_proof - .read_slot() - .expect("Could not read the relay chain slot from the proof"); - - let inherent_data = - cumulus_primitives_timestamp::InherentDataProvider::from_relay_chain_slot_and_duration( - relay_chain_slot, - sp_std::time::Duration::from_secs(6), - ) - .create_inherent_data() - .expect("Could not create the timestamp inherent data"); - - inherent_data.check_extrinsics(block) - } -} - -cumulus_pallet_parachain_system::register_validate_block!( - Runtime = Runtime, - BlockExecutor = cumulus_pallet_aura_ext::BlockExecutor::, - CheckInherents = CheckInherents, -); - -#[cfg(test)] -mod tests { - use super::*; - use crate::millau_messages::{FromMillauMessageDispatch, XCM_LANE}; - use bp_messages::{ - target_chain::{DispatchMessage, DispatchMessageData, MessageDispatch}, - LaneId, MessageKey, - }; - use bridge_runtime_common::messages_xcm_extension::XcmBlobMessageDispatchResult; - use codec::Encode; - use pallet_bridge_messages::OutboundLanes; - use sp_runtime::{generic::Era, traits::Zero}; - use xcm_executor::XcmExecutor; - - fn new_test_ext() -> sp_io::TestExternalities { - sp_io::TestExternalities::new( - frame_system::GenesisConfig::::default().build_storage().unwrap(), - ) - } - - fn prepare_outbound_xcm_message(destination: NetworkId) -> Xcm { - vec![ExportMessage { - network: destination, - destination: destination.into(), - xcm: vec![Instruction::Trap(42)].into(), - }] - .into() - } - - #[test] - fn xcm_messages_to_millau_are_sent_using_bridge_exporter() { - new_test_ext().execute_with(|| { - // ensure that the there are no messages queued - assert_eq!( - OutboundLanes::::get(XCM_LANE) - .latest_generated_nonce, - 0, - ); - - // export message instruction "sends" message to Rialto - XcmExecutor::::execute_xcm_in_credit( - Here, - prepare_outbound_xcm_message(MillauNetwork::get()), - Default::default(), - Weight::MAX, - Weight::MAX, - ) - .ensure_complete() - .expect("runtime configuration must be correct"); - - // ensure that the message has been queued - assert_eq!( - OutboundLanes::::get(XCM_LANE) - .latest_generated_nonce, - 1, - ); - }) - } - - fn prepare_inbound_bridge_message() -> DispatchMessage> { - let xcm = xcm::VersionedXcm::::V3(vec![Instruction::Trap(42)].into()); - let location = - xcm::VersionedInteriorMultiLocation::V3(X1(GlobalConsensus(ThisNetwork::get()))); - // this is the `BridgeMessage` from polkadot xcm builder, but it has no constructor - // or public fields, so just tuple - let bridge_message = (location, xcm).encode(); - DispatchMessage { - key: MessageKey { lane_id: LaneId([0, 0, 0, 0]), nonce: 1 }, - data: DispatchMessageData { payload: Ok(bridge_message) }, - } - } - - #[test] - fn xcm_messages_from_millau_are_dispatched() { - new_test_ext().execute_with(|| { - let incoming_message = prepare_inbound_bridge_message(); - - // we care only about handing message to the XCM dispatcher, so we don't care about its - // actual dispatch - let dispatch_result = FromMillauMessageDispatch::dispatch(incoming_message); - assert!(matches!( - dispatch_result.dispatch_level_result, - XcmBlobMessageDispatchResult::NotDispatched(_), - )); - }); - } - - #[test] - fn ensure_signed_extension_definition_is_correct() { - use bp_polkadot_core::SuffixedCommonSignedExtensionExt; - - sp_io::TestExternalities::default().execute_with(|| { - frame_system::BlockHash::::insert(BlockNumber::zero(), Hash::default()); - let payload: SignedExtra = ( - frame_system::CheckNonZeroSender::new(), - frame_system::CheckSpecVersion::new(), - frame_system::CheckTxVersion::new(), - frame_system::CheckGenesis::new(), - frame_system::CheckEra::from(Era::Immortal), - frame_system::CheckNonce::from(10), - frame_system::CheckWeight::new(), - pallet_transaction_payment::ChargeTransactionPayment::from(10), - BridgeRejectObsoleteHeadersAndMessages, - DummyBridgeRefundMillauMessages, - ); - let indirect_payload = bp_rialto_parachain::SignedExtension::from_params( - VERSION.spec_version, - VERSION.transaction_version, - bp_runtime::TransactionEra::Immortal, - System::block_hash(BlockNumber::zero()), - 10, - 10, - (((), ()), ((), ())), - ); - assert_eq!(payload.encode(), indirect_payload.encode()); - assert_eq!( - payload.additional_signed().unwrap().encode(), - indirect_payload.additional_signed().unwrap().encode() - ) - }); - } -} diff --git a/bin/rialto-parachain/runtime/src/millau_messages.rs b/bin/rialto-parachain/runtime/src/millau_messages.rs deleted file mode 100644 index b75a3d520b78a..0000000000000 --- a/bin/rialto-parachain/runtime/src/millau_messages.rs +++ /dev/null @@ -1,206 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Everything required to serve Millau <-> RialtoParachain messages. - -// TODO: this is almost exact copy of `millau_messages.rs` from Rialto runtime. -// Should be extracted to a separate crate and reused here. - -use crate::{MillauGrandpaInstance, Runtime, RuntimeOrigin, WithMillauMessagesInstance}; - -use bp_messages::LaneId; -use bridge_runtime_common::{ - messages::{ - self, source::TargetHeaderChainAdapter, target::SourceHeaderChainAdapter, MessageBridge, - }, - messages_xcm_extension::{SenderAndLane, XcmBlobHauler, XcmBlobHaulerAdapter}, -}; -use frame_support::{parameter_types, weights::Weight}; -use sp_runtime::RuntimeDebug; -use xcm::latest::prelude::*; -use xcm_builder::HaulBlobExporter; - -/// Default lane that is used to send messages to Millau. -pub const XCM_LANE: LaneId = LaneId([0, 0, 0, 0]); -/// Weight of 2 XCM instructions is for simple `Trap(42)` program, coming through bridge -/// (it is prepended with `UniversalOrigin` instruction). It is used just for simplest manual -/// tests, confirming that we don't break encoding somewhere between. -pub const BASE_XCM_WEIGHT_TWICE: Weight = crate::UnitWeightCost::get().saturating_mul(2); - -parameter_types! { - /// Weight credit for our test messages. - /// - /// 2 XCM instructions is for simple `Trap(42)` program, coming through bridge - /// (it is prepended with `UniversalOrigin` instruction). - pub const WeightCredit: Weight = BASE_XCM_WEIGHT_TWICE; - /// Lane used by the with-Millau bridge. - pub MullauSenderAndLane: SenderAndLane = SenderAndLane::new(Here.into(), XCM_LANE); - - /// Dummy message used in configuration. - pub DummyXcmMessage: Xcm<()> = Xcm::new(); -} - -/// Message payload for RialtoParachain -> Millau messages. -pub type ToMillauMessagePayload = messages::source::FromThisChainMessagePayload; - -/// Message verifier for RialtoParachain -> Millau messages. -pub type ToMillauMessageVerifier = - messages::source::FromThisChainMessageVerifier; - -/// Message payload for Millau -> RialtoParachain messages. -pub type FromMillauMessagePayload = messages::target::FromBridgedChainMessagePayload; - -/// Call-dispatch based message dispatch for Millau -> RialtoParachain messages. -pub type FromMillauMessageDispatch = - bridge_runtime_common::messages_xcm_extension::XcmBlobMessageDispatch< - crate::OnRialtoParachainBlobDispatcher, - (), - (), - >; - -/// Messages proof for Millau -> RialtoParachain messages. -pub type FromMillauMessagesProof = messages::target::FromBridgedChainMessagesProof; - -/// Messages delivery proof for RialtoParachain -> Millau messages. -pub type ToMillauMessagesDeliveryProof = - messages::source::FromBridgedChainMessagesDeliveryProof; - -/// Maximal outbound payload size of Rialto -> Millau messages. -pub type ToMillauMaximalOutboundPayloadSize = - messages::source::FromThisChainMaximalOutboundPayloadSize; - -/// Millau <-> RialtoParachain message bridge. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct WithMillauMessageBridge; - -impl MessageBridge for WithMillauMessageBridge { - const BRIDGED_MESSAGES_PALLET_NAME: &'static str = - bp_rialto_parachain::WITH_RIALTO_PARACHAIN_MESSAGES_PALLET_NAME; - - type ThisChain = RialtoParachain; - type BridgedChain = Millau; - type BridgedHeaderChain = - pallet_bridge_grandpa::GrandpaChainHeaders; -} - -/// RialtoParachain chain from message lane point of view. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct RialtoParachain; - -impl messages::UnderlyingChainProvider for RialtoParachain { - type Chain = bp_rialto_parachain::RialtoParachain; -} - -impl messages::ThisChainWithMessages for RialtoParachain { - type RuntimeOrigin = RuntimeOrigin; -} - -/// Millau chain from message lane point of view. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct Millau; -/// Millau as source header chain. -pub type MillauAsSourceHeaderChain = SourceHeaderChainAdapter; -/// Millau as target header chain. -pub type MillauAsTargetHeaderChain = TargetHeaderChainAdapter; - -impl messages::UnderlyingChainProvider for Millau { - type Chain = bp_millau::Millau; -} - -impl messages::BridgedChainWithMessages for Millau {} - -/// Export XCM messages to be relayed to Millau. -pub type ToMillauBlobExporter = - HaulBlobExporter, crate::MillauNetwork, ()>; - -/// To-Millau XCM hauler. -pub struct ToMillauXcmBlobHauler; - -impl XcmBlobHauler for ToMillauXcmBlobHauler { - type Runtime = Runtime; - type MessagesInstance = WithMillauMessagesInstance; - type SenderAndLane = MullauSenderAndLane; - - type ToSourceChainSender = crate::XcmRouter; - type CongestedMessage = DummyXcmMessage; - type UncongestedMessage = DummyXcmMessage; -} - -#[cfg(test)] -mod tests { - use super::*; - use crate::{MillauGrandpaInstance, Runtime, WithMillauMessagesInstance}; - use bridge_runtime_common::{ - assert_complete_bridge_types, - integrity::{ - assert_complete_bridge_constants, check_message_lane_weights, - AssertBridgeMessagesPalletConstants, AssertBridgePalletNames, AssertChainConstants, - AssertCompleteBridgeConstants, - }, - }; - - #[test] - fn ensure_millau_message_lane_weights_are_correct() { - check_message_lane_weights::< - bp_rialto_parachain::RialtoParachain, - Runtime, - WithMillauMessagesInstance, - >( - bp_millau::EXTRA_STORAGE_PROOF_SIZE, - bp_rialto_parachain::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX, - bp_rialto_parachain::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX, - false, - ); - } - - #[test] - fn ensure_bridge_integrity() { - assert_complete_bridge_types!( - runtime: Runtime, - with_bridged_chain_grandpa_instance: MillauGrandpaInstance, - with_bridged_chain_messages_instance: WithMillauMessagesInstance, - bridge: WithMillauMessageBridge, - this_chain: bp_rialto_parachain::RialtoParachain, - bridged_chain: bp_millau::Millau, - ); - - assert_complete_bridge_constants::< - Runtime, - MillauGrandpaInstance, - WithMillauMessagesInstance, - WithMillauMessageBridge, - >(AssertCompleteBridgeConstants { - this_chain_constants: AssertChainConstants { - block_length: bp_rialto_parachain::BlockLength::get(), - block_weights: bp_rialto_parachain::BlockWeights::get(), - }, - messages_pallet_constants: AssertBridgeMessagesPalletConstants { - max_unrewarded_relayers_in_bridged_confirmation_tx: - bp_millau::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX, - max_unconfirmed_messages_in_bridged_confirmation_tx: - bp_millau::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX, - bridged_chain_id: bp_runtime::MILLAU_CHAIN_ID, - }, - pallet_names: AssertBridgePalletNames { - with_this_chain_messages_pallet_name: - bp_rialto_parachain::WITH_RIALTO_PARACHAIN_MESSAGES_PALLET_NAME, - with_bridged_chain_grandpa_pallet_name: bp_millau::WITH_MILLAU_GRANDPA_PALLET_NAME, - with_bridged_chain_messages_pallet_name: - bp_millau::WITH_MILLAU_MESSAGES_PALLET_NAME, - }, - }); - } -} diff --git a/bin/rialto/node/Cargo.toml b/bin/rialto/node/Cargo.toml deleted file mode 100644 index b2d54e5160983..0000000000000 --- a/bin/rialto/node/Cargo.toml +++ /dev/null @@ -1,61 +0,0 @@ -[[bin]] -name = "rialto-bridge-node-execute-worker" -path = "src/workers/execute-worker.rs" - -[[bin]] -name = "rialto-bridge-node-prepare-worker" -path = "src/workers/prepare-worker.rs" - -[package] -name = "rialto-bridge-node" -description = "Substrate node compatible with Rialto runtime" -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -build = "build.rs" -repository = "https://github.com/paritytech/parity-bridges-common/" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[dependencies] -clap = { version = "4.4.8", features = ["derive"] } -serde_json = "1.0.108" - -# Bridge dependencies - -rialto-runtime = { path = "../runtime" } - -# Substrate Dependencies - -sp-consensus-beefy = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -frame-benchmarking = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -frame-benchmarking-cli = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -frame-support = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -node-inspect = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-cli = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master"} -sc-executor = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sc-service = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-authority-discovery = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-consensus-babe = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-consensus-grandpa = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -# Polkadot Dependencies -polkadot-node-core-pvf = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -polkadot-node-core-pvf-common = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -polkadot-node-core-pvf-execute-worker = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -polkadot-node-core-pvf-prepare-worker = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -polkadot-primitives = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -polkadot-runtime-parachains = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -polkadot-service = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false, features = [ "full-node" ] } - -[build-dependencies] -substrate-build-script-utils = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -frame-benchmarking-cli = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -[features] -default = [] -runtime-benchmarks = [ - "polkadot-service/runtime-benchmarks", - "rialto-runtime/runtime-benchmarks", -] diff --git a/bin/rialto/node/build.rs b/bin/rialto/node/build.rs deleted file mode 100644 index d9b50049e2628..0000000000000 --- a/bin/rialto/node/build.rs +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use substrate_build_script_utils::{generate_cargo_keys, rerun_if_git_head_changed}; - -fn main() { - generate_cargo_keys(); - - rerun_if_git_head_changed(); -} diff --git a/bin/rialto/node/src/chain_spec.rs b/bin/rialto/node/src/chain_spec.rs deleted file mode 100644 index 6d1180d12a985..0000000000000 --- a/bin/rialto/node/src/chain_spec.rs +++ /dev/null @@ -1,282 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use polkadot_primitives::v6::{AssignmentId, ValidatorId}; -use rialto_runtime::{ - AccountId, BabeConfig, BalancesConfig, BeefyConfig, BridgeMillauMessagesConfig, - ConfigurationConfig, GrandpaConfig, RuntimeGenesisConfig, SessionConfig, SessionKeys, - Signature, SudoConfig, SystemConfig, WASM_BINARY, -}; -use serde_json::json; -use sp_authority_discovery::AuthorityId as AuthorityDiscoveryId; -use sp_consensus_babe::AuthorityId as BabeId; -use sp_consensus_beefy::ecdsa_crypto::AuthorityId as BeefyId; -use sp_consensus_grandpa::AuthorityId as GrandpaId; -use sp_core::{sr25519, Pair, Public}; -use sp_runtime::traits::{IdentifyAccount, Verify}; - -/// "Names" of the authorities accounts at local testnet. -const LOCAL_AUTHORITIES_ACCOUNTS: [&str; 5] = ["Alice", "Bob", "Charlie", "Dave", "Eve"]; -/// "Names" of the authorities accounts at development testnet. -const DEV_AUTHORITIES_ACCOUNTS: [&str; 1] = [LOCAL_AUTHORITIES_ACCOUNTS[0]]; -/// "Names" of all possible authorities accounts. -const ALL_AUTHORITIES_ACCOUNTS: [&str; 5] = LOCAL_AUTHORITIES_ACCOUNTS; -/// "Name" of the `sudo` account. -const SUDO_ACCOUNT: &str = "Sudo"; -/// "Name" of the account, which owns the with-Millau messages pallet. -const MILLAU_MESSAGES_PALLET_OWNER: &str = "Millau.MessagesOwner"; - -/// Specialized `ChainSpec`. This is a specialization of the general Substrate ChainSpec type. -pub type ChainSpec = - sc_service::GenericChainSpec; - -/// The chain specification option. This is expected to come in from the CLI and -/// is little more than one of a number of alternatives which can easily be converted -/// from a string (`--chain=...`) into a `ChainSpec`. -#[derive(Clone, Debug)] -pub enum Alternative { - /// Whatever the current runtime is, with just Alice as an auth. - Development, - /// Whatever the current runtime is, with simple Alice/Bob/Charlie/Dave/Eve auths. - LocalTestnet, -} - -/// Helper function to generate a crypto pair from seed -pub fn get_from_seed(seed: &str) -> ::Public { - TPublic::Pair::from_string(&format!("//{seed}"), None) - .expect("static values are valid; qed") - .public() -} - -type AccountPublic = ::Signer; - -/// Helper function to generate an account ID from seed -pub fn get_account_id_from_seed(seed: &str) -> AccountId -where - AccountPublic: From<::Public>, -{ - AccountPublic::from(get_from_seed::(seed)).into_account() -} - -/// Helper function to generate authority keys. -pub fn get_authority_keys_from_seed( - s: &str, -) -> (AccountId, BabeId, BeefyId, GrandpaId, ValidatorId, AssignmentId, AuthorityDiscoveryId) { - ( - get_account_id_from_seed::(s), - get_from_seed::(s), - get_from_seed::(s), - get_from_seed::(s), - get_from_seed::(s), - get_from_seed::(s), - get_from_seed::(s), - ) -} - -impl Alternative { - /// Get an actual chain config from one of the alternatives. - pub(crate) fn load(self) -> ChainSpec { - let properties = Some( - json!({ - "tokenDecimals": 9, - "tokenSymbol": "RLT" - }) - .as_object() - .expect("Map given; qed") - .clone(), - ); - match self { - Alternative::Development => ChainSpec::from_genesis( - "Rialto Development", - "rialto_dev", - sc_service::ChainType::Development, - || { - testnet_genesis( - DEV_AUTHORITIES_ACCOUNTS - .into_iter() - .map(get_authority_keys_from_seed) - .collect(), - get_account_id_from_seed::(SUDO_ACCOUNT), - endowed_accounts(), - true, - ) - }, - vec![], - None, - None, - None, - properties, - Default::default(), - ), - Alternative::LocalTestnet => ChainSpec::from_genesis( - "Rialto Local", - "rialto_local", - sc_service::ChainType::Local, - || { - testnet_genesis( - LOCAL_AUTHORITIES_ACCOUNTS - .into_iter() - .map(get_authority_keys_from_seed) - .collect(), - get_account_id_from_seed::(SUDO_ACCOUNT), - endowed_accounts(), - true, - ) - }, - vec![], - None, - None, - None, - properties, - Default::default(), - ), - } - } -} - -/// We're using the same set of endowed accounts on all Millau chains (dev/local) to make -/// sure that all accounts, required for bridge to be functional (e.g. relayers fund account, -/// accounts used by relayers in our test deployments, accounts used for demonstration -/// purposes), are all available on these chains. -fn endowed_accounts() -> Vec { - let all_authorities = ALL_AUTHORITIES_ACCOUNTS.iter().flat_map(|x| { - [ - get_account_id_from_seed::(x), - get_account_id_from_seed::(&format!("{x}//stash")), - ] - }); - vec![ - // Sudo account - get_account_id_from_seed::(SUDO_ACCOUNT), - // Regular (unused) accounts - get_account_id_from_seed::("Ferdie"), - get_account_id_from_seed::("Ferdie//stash"), - // Accounts, used by Rialto<>Millau bridge - get_account_id_from_seed::(MILLAU_MESSAGES_PALLET_OWNER), - get_account_id_from_seed::("Millau.HeadersAndMessagesRelay"), - get_account_id_from_seed::("Millau.OutboundMessagesRelay.Lane00000001"), - get_account_id_from_seed::("Millau.InboundMessagesRelay.Lane00000001"), - get_account_id_from_seed::("Millau.MessagesSender"), - ] - .into_iter() - .chain(all_authorities) - .collect() -} - -fn session_keys( - babe: BabeId, - beefy: BeefyId, - grandpa: GrandpaId, - para_validator: ValidatorId, - para_assignment: AssignmentId, - authority_discovery: AuthorityDiscoveryId, -) -> SessionKeys { - SessionKeys { babe, beefy, grandpa, para_validator, para_assignment, authority_discovery } -} - -fn testnet_genesis( - initial_authorities: Vec<( - AccountId, - BabeId, - BeefyId, - GrandpaId, - ValidatorId, - AssignmentId, - AuthorityDiscoveryId, - )>, - root_key: AccountId, - endowed_accounts: Vec, - _enable_println: bool, -) -> RuntimeGenesisConfig { - RuntimeGenesisConfig { - system: SystemConfig { - code: WASM_BINARY.expect("Rialto development WASM not available").to_vec(), - ..Default::default() - }, - balances: BalancesConfig { - balances: endowed_accounts.iter().cloned().map(|k| (k, 1 << 50)).collect(), - }, - babe: BabeConfig { - authorities: Vec::new(), - epoch_config: Some(rialto_runtime::BABE_GENESIS_EPOCH_CONFIG), - ..Default::default() - }, - beefy: BeefyConfig::default(), - grandpa: GrandpaConfig { authorities: Vec::new(), ..Default::default() }, - sudo: SudoConfig { key: Some(root_key) }, - session: SessionConfig { - keys: initial_authorities - .iter() - .map(|x| { - ( - x.0.clone(), - x.0.clone(), - session_keys( - x.1.clone(), - x.2.clone(), - x.3.clone(), - x.4.clone(), - x.5.clone(), - x.6.clone(), - ), - ) - }) - .collect::>(), - }, - authority_discovery: Default::default(), - hrmp: Default::default(), - // this configuration is exact copy of configuration from Polkadot repo - // (see /node/service/src/chain_spec.rs:default_parachains_host_configuration) - configuration: ConfigurationConfig { - config: polkadot_runtime_parachains::configuration::HostConfiguration { - validation_upgrade_cooldown: 2u32, - validation_upgrade_delay: 2, - code_retention_period: 1200, - max_code_size: polkadot_primitives::v6::MAX_CODE_SIZE, - max_pov_size: polkadot_primitives::v6::MAX_POV_SIZE, - max_head_data_size: 32 * 1024, - group_rotation_frequency: 20, - max_upward_queue_count: 8, - max_upward_queue_size: 1024 * 1024, - max_downward_message_size: 1024 * 1024, - max_upward_message_size: 50 * 1024, - max_upward_message_num_per_candidate: 5, - hrmp_sender_deposit: 0, - hrmp_recipient_deposit: 0, - hrmp_channel_max_capacity: 8, - hrmp_channel_max_total_size: 8 * 1024, - hrmp_max_parachain_inbound_channels: 4, - hrmp_channel_max_message_size: 1024 * 1024, - hrmp_max_parachain_outbound_channels: 4, - hrmp_max_message_num_per_candidate: 5, - dispute_period: 6, - no_show_slots: 2, - n_delay_tranches: 25, - needed_approvals: 2, - relay_vrf_modulo_samples: 2, - zeroth_delay_tranche_width: 0, - minimum_validation_upgrade_delay: 5, - ..Default::default() - }, - }, - paras: Default::default(), - bridge_millau_messages: BridgeMillauMessagesConfig { - owner: Some(get_account_id_from_seed::(MILLAU_MESSAGES_PALLET_OWNER)), - ..Default::default() - }, - xcm_pallet: Default::default(), - } -} diff --git a/bin/rialto/node/src/cli.rs b/bin/rialto/node/src/cli.rs deleted file mode 100644 index 521f2268bdc5e..0000000000000 --- a/bin/rialto/node/src/cli.rs +++ /dev/null @@ -1,84 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use clap::Parser; -use sc_cli::RunCmd; - -#[derive(Debug, Parser)] -pub struct Cli { - #[structopt(subcommand)] - pub subcommand: Option, - - #[structopt(flatten)] - pub run: RunCmd, -} - -/// Possible subcommands of the main binary. -#[derive(Debug, Parser)] -#[allow(clippy::large_enum_variant)] -pub enum Subcommand { - /// Key management CLI utilities - #[clap(subcommand)] - Key(sc_cli::KeySubcommand), - - /// Verify a signature for a message, provided on `STDIN`, with a given (public or secret) key. - Verify(sc_cli::VerifyCmd), - - /// Generate a seed that provides a vanity address. - Vanity(sc_cli::VanityCmd), - - /// Sign a message, with a given (secret) key. - Sign(sc_cli::SignCmd), - - /// Build a chain specification. - BuildSpec(sc_cli::BuildSpecCmd), - - /// Validate blocks. - CheckBlock(sc_cli::CheckBlockCmd), - - /// Export blocks. - ExportBlocks(sc_cli::ExportBlocksCmd), - - /// Export the state of a given block into a chain spec. - ExportState(sc_cli::ExportStateCmd), - - /// Import blocks. - ImportBlocks(sc_cli::ImportBlocksCmd), - - /// Remove the whole chain. - PurgeChain(sc_cli::PurgeChainCmd), - - /// Revert the chain to a previous state. - Revert(sc_cli::RevertCmd), - - /// Inspect blocks or extrinsics. - Inspect(node_inspect::cli::InspectCmd), - - /// Benchmark runtime pallets. - #[command(subcommand)] - Benchmark(frame_benchmarking_cli::BenchmarkCmd), -} - -/// Validation worker command. -#[derive(Debug, Parser)] -pub struct ValidationWorkerCommand { - /// The path to the validation host's socket. - #[arg(long)] - pub socket_path: String, - /// Calling node implementation version - #[arg(long)] - pub node_impl_version: String, -} diff --git a/bin/rialto/node/src/command.rs b/bin/rialto/node/src/command.rs deleted file mode 100644 index 397f8a3e24e9b..0000000000000 --- a/bin/rialto/node/src/command.rs +++ /dev/null @@ -1,193 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use crate::cli::{Cli, Subcommand}; -use frame_benchmarking_cli::BenchmarkCmd; -use rialto_runtime::{Block, RuntimeApi}; -use sc_cli::SubstrateCli; - -impl SubstrateCli for Cli { - fn impl_name() -> String { - "Rialto Bridge Node".into() - } - - fn impl_version() -> String { - env!("CARGO_PKG_VERSION").into() - } - - fn description() -> String { - "Rialto Bridge Node".into() - } - - fn author() -> String { - "Parity Technologies".into() - } - - fn support_url() -> String { - "https://github.com/paritytech/parity-bridges-common/".into() - } - - fn copyright_start_year() -> i32 { - 2019 - } - - fn executable_name() -> String { - "rialto-bridge-node".into() - } - - fn load_spec(&self, id: &str) -> Result, String> { - Ok(Box::new( - match id { - "" | "dev" => crate::chain_spec::Alternative::Development, - "local" => crate::chain_spec::Alternative::LocalTestnet, - _ => return Err(format!("Unsupported chain specification: {id}")), - } - .load(), - )) - } -} - -// Rialto native executor instance. -pub struct ExecutorDispatch; - -impl sc_executor::NativeExecutionDispatch for ExecutorDispatch { - type ExtendHostFunctions = frame_benchmarking::benchmarking::HostFunctions; - - fn dispatch(method: &str, data: &[u8]) -> Option> { - rialto_runtime::api::dispatch(method, data) - } - - fn native_version() -> sc_executor::NativeVersion { - rialto_runtime::native_version() - } -} - -/// Parse and run command line arguments -pub fn run() -> sc_cli::Result<()> { - let cli = Cli::from_args(); - sp_core::crypto::set_default_ss58_version(sp_core::crypto::Ss58AddressFormat::custom( - rialto_runtime::SS58Prefix::get() as u16, - )); - - match &cli.subcommand { - Some(Subcommand::Benchmark(cmd)) => { - let runner = cli.create_runner(cmd)?; - match cmd { - BenchmarkCmd::Pallet(cmd) => - if cfg!(feature = "runtime-benchmarks") { - runner.sync_run(|config| cmd.run::(config)) - } else { - println!( - "Benchmarking wasn't enabled when building the node. \ - You can enable it with `--features runtime-benchmarks`." - ); - Ok(()) - }, - _ => Err("Unsupported benchmarking subcommand".into()), - } - }, - Some(Subcommand::Key(cmd)) => cmd.run(&cli), - Some(Subcommand::Sign(cmd)) => cmd.run(), - Some(Subcommand::Verify(cmd)) => cmd.run(), - Some(Subcommand::Vanity(cmd)) => cmd.run(), - Some(Subcommand::BuildSpec(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.sync_run(|config| cmd.run(config.chain_spec, config.network)) - }, - Some(Subcommand::CheckBlock(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.async_run(|mut config| { - let (client, _, import_queue, task_manager) = - polkadot_service::new_chain_ops(&mut config, None).map_err(service_error)?; - Ok((cmd.run(client, import_queue), task_manager)) - }) - }, - Some(Subcommand::ExportBlocks(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.async_run(|mut config| { - let (client, _, _, task_manager) = - polkadot_service::new_chain_ops(&mut config, None).map_err(service_error)?; - Ok((cmd.run(client, config.database), task_manager)) - }) - }, - Some(Subcommand::ExportState(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.async_run(|mut config| { - let (client, _, _, task_manager) = - polkadot_service::new_chain_ops(&mut config, None).map_err(service_error)?; - Ok((cmd.run(client, config.chain_spec), task_manager)) - }) - }, - Some(Subcommand::ImportBlocks(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.async_run(|mut config| { - let (client, _, import_queue, task_manager) = - polkadot_service::new_chain_ops(&mut config, None).map_err(service_error)?; - Ok((cmd.run(client, import_queue), task_manager)) - }) - }, - Some(Subcommand::PurgeChain(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.sync_run(|config| cmd.run(config.database)) - }, - Some(Subcommand::Revert(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.async_run(|mut config| { - let (client, backend, _, task_manager) = - polkadot_service::new_chain_ops(&mut config, None).map_err(service_error)?; - Ok((cmd.run(client, backend, None), task_manager)) - }) - }, - Some(Subcommand::Inspect(cmd)) => { - let runner = cli.create_runner(cmd)?; - runner.sync_run(|config| cmd.run::(config)) - }, - None => { - let runner = cli.create_runner(&cli.run)?; - - runner.run_node_until_exit(|config| async move { - polkadot_service::new_full( - config, - polkadot_service::NewFullParams { - is_parachain_node: polkadot_service::IsParachainNode::No, - grandpa_pause: None, - enable_beefy: true, - jaeger_agent: None, - telemetry_worker_handle: None, - node_version: None, - workers_path: None, - workers_names: Some(( - "rialto-bridge-node-prepare-worker".to_string(), - "rialto-bridge-node-execute-worker".to_string(), - )), - overseer_gen: polkadot_service::overseer::RealOverseerGen, - overseer_message_channel_capacity_override: None, - malus_finality_delay: None, - hwbench: None, - }, - ) - .map(|full| full.task_manager) - .map_err(service_error) - }) - }, - } -} - -// We don't want to change 'service.rs' too much to ease future updates => it'll keep using -// its own error enum like original polkadot service does. -fn service_error(err: polkadot_service::Error) -> sc_cli::Error { - sc_cli::Error::Application(Box::new(err)) -} diff --git a/bin/rialto/node/src/main.rs b/bin/rialto/node/src/main.rs deleted file mode 100644 index 6dea84a309b26..0000000000000 --- a/bin/rialto/node/src/main.rs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Rialto bridge node. - -#![warn(missing_docs)] - -mod chain_spec; -mod cli; -mod command; - -/// Run the Rialto Node -fn main() -> sc_cli::Result<()> { - command::run() -} diff --git a/bin/rialto/node/src/workers/execute-worker.rs b/bin/rialto/node/src/workers/execute-worker.rs deleted file mode 100644 index 72cab799d753e..0000000000000 --- a/bin/rialto/node/src/workers/execute-worker.rs +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright (C) Parity Technologies (UK) Ltd. -// This file is part of Polkadot. - -// Polkadot 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. - -// Polkadot 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 Polkadot. If not, see . - -//! Execute worker. - -polkadot_node_core_pvf_common::decl_worker_main!( - "execute-worker", - polkadot_node_core_pvf_execute_worker::worker_entrypoint, - env!("SUBSTRATE_CLI_IMPL_VERSION") -); diff --git a/bin/rialto/node/src/workers/prepare-worker.rs b/bin/rialto/node/src/workers/prepare-worker.rs deleted file mode 100644 index 695f66cc7b7d3..0000000000000 --- a/bin/rialto/node/src/workers/prepare-worker.rs +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright (C) Parity Technologies (UK) Ltd. -// This file is part of Polkadot. - -// Polkadot 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. - -// Polkadot 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 Polkadot. If not, see . - -//! Prepare worker. - -polkadot_node_core_pvf_common::decl_worker_main!( - "prepare-worker", - polkadot_node_core_pvf_prepare_worker::worker_entrypoint, - env!("SUBSTRATE_CLI_IMPL_VERSION") -); diff --git a/bin/rialto/runtime/Cargo.toml b/bin/rialto/runtime/Cargo.toml deleted file mode 100644 index 5ef7d53bed4a1..0000000000000 --- a/bin/rialto/runtime/Cargo.toml +++ /dev/null @@ -1,153 +0,0 @@ -[package] -name = "rialto-runtime" -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -repository = "https://github.com/paritytech/parity-bridges-common/" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[dependencies] -codec = { package = "parity-scale-codec", version = "3.1.5", default-features = false, features = ["derive"] } -scale-info = { version = "2.10.0", default-features = false, features = ["derive"] } - -# Bridge dependencies - -bp-header-chain = { path = "../../../primitives/header-chain", default-features = false } -bp-messages = { path = "../../../primitives/messages", default-features = false } -bp-millau = { path = "../../../primitives/chain-millau", default-features = false } -bp-relayers = { path = "../../../primitives/relayers", default-features = false } -bp-rialto = { path = "../../../primitives/chain-rialto", default-features = false } -bp-runtime = { path = "../../../primitives/runtime", default-features = false } -bridge-runtime-common = { path = "../../runtime-common", default-features = false } -pallet-bridge-beefy = { path = "../../../modules/beefy", default-features = false } -pallet-bridge-grandpa = { path = "../../../modules/grandpa", default-features = false } -pallet-bridge-messages = { path = "../../../modules/messages", default-features = false } -pallet-bridge-relayers = { path = "../../../modules/relayers", default-features = false } -pallet-shift-session-manager = { path = "../../../modules/shift-session-manager", default-features = false } - -# Substrate Dependencies - -sp-consensus-beefy = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false, optional = true } -frame-benchmarking = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false, optional = true } -frame-executive = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-support = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-system-rpc-runtime-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-authority-discovery = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-authorship = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-babe = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-balances = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-beefy = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-beefy-mmr = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-grandpa = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-message-queue = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-mmr = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-offences = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-session = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false, features = ["historical"]} -pallet-sudo = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-timestamp = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-transaction-payment = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-transaction-payment-rpc-runtime-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-authority-discovery = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-block-builder = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-consensus-babe = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-inherents = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-io = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-offchain = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-session = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-std = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-transaction-pool = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-version = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -# Polkadot (parachain) Dependencies -pallet-xcm = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -polkadot-primitives = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -polkadot-runtime-common = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -polkadot-runtime-parachains = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -xcm = { package = "staging-xcm", git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -xcm-builder = { package = "staging-xcm-builder", git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -xcm-executor = { package = "staging-xcm-executor", git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -[dev-dependencies] -bridge-runtime-common = { path = "../../runtime-common", features = ["integrity-test"] } -env_logger = "0.10" -static_assertions = "1.1" - -[build-dependencies] -substrate-wasm-builder = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -[features] -default = [ "std" ] -std = [ - "bp-messages/std", - "bp-millau/std", - "bp-relayers/std", - "bp-rialto/std", - "bp-runtime/std", - "bridge-runtime-common/std", - "codec/std", - "frame-benchmarking/std", - "frame-executive/std", - "frame-support/std", - "frame-system-rpc-runtime-api/std", - "frame-system/std", - "pallet-authority-discovery/std", - "pallet-authorship/std", - "pallet-babe/std", - "pallet-balances/std", - "pallet-beefy-mmr/std", - "pallet-beefy/std", - "pallet-bridge-beefy/std", - "pallet-bridge-grandpa/std", - "pallet-bridge-messages/std", - "pallet-bridge-relayers/std", - "pallet-grandpa/std", - "pallet-message-queue/std", - "pallet-mmr/std", - "pallet-offences/std", - "pallet-session/std", - "pallet-shift-session-manager/std", - "pallet-sudo/std", - "pallet-timestamp/std", - "pallet-transaction-payment-rpc-runtime-api/std", - "pallet-transaction-payment/std", - "pallet-xcm/std", - "polkadot-primitives/std", - "polkadot-runtime-common/std", - "polkadot-runtime-parachains/std", - "scale-info/std", - "sp-api/std", - "sp-authority-discovery/std", - "sp-block-builder/std", - "sp-consensus-babe/std", - "sp-consensus-beefy/std", - "sp-core/std", - "sp-inherents/std", - "sp-io/std", - "sp-offchain/std", - "sp-runtime/std", - "sp-session/std", - "sp-std/std", - "sp-transaction-pool/std", - "sp-version/std", - "xcm-builder/std", - "xcm-executor/std", - "xcm/std", -] -runtime-benchmarks = [ - "bridge-runtime-common/runtime-benchmarks", - "frame-benchmarking/runtime-benchmarks", - "frame-support/runtime-benchmarks", - "frame-system/runtime-benchmarks", - "pallet-bridge-grandpa/runtime-benchmarks", - "pallet-bridge-messages/runtime-benchmarks", - "pallet-bridge-relayers/runtime-benchmarks", - "pallet-message-queue/runtime-benchmarks", - "pallet-xcm/runtime-benchmarks", - "polkadot-runtime-common/runtime-benchmarks", - "sp-runtime/runtime-benchmarks", - "xcm-builder/runtime-benchmarks", -] diff --git a/bin/rialto/runtime/build.rs b/bin/rialto/runtime/build.rs deleted file mode 100644 index 25e220e46fc3b..0000000000000 --- a/bin/rialto/runtime/build.rs +++ /dev/null @@ -1,26 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use substrate_wasm_builder::WasmBuilder; - -fn main() { - WasmBuilder::new() - .with_current_project() - .import_memory() - .export_heap_base() - .disable_runtime_version_section_check() - .build() -} diff --git a/bin/rialto/runtime/src/lib.rs b/bin/rialto/runtime/src/lib.rs deleted file mode 100644 index 684b3e5bf466f..0000000000000 --- a/bin/rialto/runtime/src/lib.rs +++ /dev/null @@ -1,1074 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! The Rialto runtime. This can be compiled with `#[no_std]`, ready for Wasm. - -#![cfg_attr(not(feature = "std"), no_std)] -// `construct_runtime!` does a lot of recursion and requires us to increase the limit to 256. -#![recursion_limit = "256"] -// Runtime-generated enums -#![allow(clippy::large_enum_variant)] -// From construct_runtime macro -#![allow(clippy::from_over_into)] - -// Make the WASM binary available. -#[cfg(feature = "std")] -include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs")); - -pub mod millau_messages; -pub mod parachains; -pub mod xcm_config; - -use bp_runtime::HeaderId; -use pallet_grandpa::{ - fg_primitives, AuthorityId as GrandpaId, AuthorityList as GrandpaAuthorityList, -}; -use pallet_transaction_payment::{FeeDetails, Multiplier, RuntimeDispatchInfo}; -use polkadot_primitives::Id as ParaId; -use polkadot_runtime_parachains::runtime_api_impl::{ - v7 as parachains_runtime_api_impl, vstaging as parachains_staging_runtime_api_impl, -}; -use sp_api::impl_runtime_apis; -use sp_authority_discovery::AuthorityId as AuthorityDiscoveryId; -use sp_consensus_beefy::{ecdsa_crypto::AuthorityId as BeefyId, mmr::MmrLeafVersion, ValidatorSet}; -use sp_core::OpaqueMetadata; -use sp_runtime::{ - create_runtime_str, generic, impl_opaque_keys, - traits::{AccountIdLookup, Block as BlockT, Keccak256, NumberFor, OpaqueKeys}, - transaction_validity::{TransactionSource, TransactionValidity}, - ApplyExtrinsicResult, FixedPointNumber, KeyTypeId, Perquintill, -}; -use sp_std::{collections::btree_map::BTreeMap, prelude::*}; -#[cfg(feature = "std")] -use sp_version::NativeVersion; -use sp_version::RuntimeVersion; - -// A few exports that help ease life for downstream crates. -pub use frame_support::{ - construct_runtime, - dispatch::DispatchClass, - parameter_types, - traits::{ - ConstU32, ConstU64, ConstU8, Currency, ExistenceRequirement, Imbalance, KeyOwnerProofSystem, - }, - weights::{constants::WEIGHT_REF_TIME_PER_SECOND, IdentityFee, RuntimeDbWeight, Weight}, - StorageValue, -}; - -pub use frame_system::Call as SystemCall; -pub use pallet_balances::Call as BalancesCall; -pub use pallet_bridge_beefy::Call as BridgeBeefyCall; -pub use pallet_bridge_grandpa::Call as BridgeGrandpaCall; -pub use pallet_bridge_messages::Call as MessagesCall; -pub use pallet_sudo::Call as SudoCall; -pub use pallet_timestamp::Call as TimestampCall; -pub use pallet_xcm::Call as XcmCall; - -#[cfg(any(feature = "std", test))] -pub use sp_runtime::BuildStorage; -pub use sp_runtime::{Perbill, Permill}; - -/// An index to a block. -pub type BlockNumber = bp_rialto::BlockNumber; - -/// Alias to 512-bit hash when used in the context of a transaction signature on the chain. -pub type Signature = bp_rialto::Signature; - -/// Some way of identifying an account on the chain. We intentionally make it equivalent -/// to the public key of our transaction signing scheme. -pub type AccountId = bp_rialto::AccountId; - -/// The type for looking up accounts. We don't expect more than 4 billion of them, but you -/// never know... -pub type AccountIndex = u32; - -/// Balance of an account. -pub type Balance = bp_rialto::Balance; - -/// Nonce of a transaction in the chain. -pub type Nonce = bp_rialto::Nonce; - -/// A hash of some data used by the chain. -pub type Hash = bp_rialto::Hash; - -/// Hashing algorithm used by the chain. -pub type Hashing = bp_rialto::Hasher; - -/// Opaque types. These are used by the CLI to instantiate machinery that don't need to know -/// the specifics of the runtime. They can then be made to be agnostic over specific formats -/// of data like extrinsics, allowing for them to continue syncing the network through upgrades -/// to even the core data structures. -pub mod opaque { - use super::*; - - pub use sp_runtime::OpaqueExtrinsic as UncheckedExtrinsic; - - /// Opaque block header type. - pub type Header = generic::Header; - /// Opaque block type. - pub type Block = generic::Block; - /// Opaque block identifier type. - pub type BlockId = generic::BlockId; -} - -impl_opaque_keys! { - pub struct SessionKeys { - pub babe: Babe, - pub grandpa: Grandpa, - pub beefy: Beefy, - pub para_validator: Initializer, - pub para_assignment: SessionInfo, - pub authority_discovery: AuthorityDiscovery, - } -} - -/// This runtime version. -#[sp_version::runtime_version] -pub const VERSION: RuntimeVersion = RuntimeVersion { - spec_name: create_runtime_str!("rialto-runtime"), - impl_name: create_runtime_str!("rialto-runtime"), - authoring_version: 1, - spec_version: 1, - impl_version: 1, - apis: RUNTIME_API_VERSIONS, - transaction_version: 1, - state_version: 1, -}; - -/// The version information used to identify this runtime when compiled natively. -#[cfg(feature = "std")] -pub fn native_version() -> NativeVersion { - NativeVersion { runtime_version: VERSION, can_author_with: Default::default() } -} - -parameter_types! { - pub const BlockHashCount: BlockNumber = 250; - pub const Version: RuntimeVersion = VERSION; - pub const DbWeight: RuntimeDbWeight = RuntimeDbWeight { - read: 60_000_000, // ~0.06 ms = ~60 µs - write: 200_000_000, // ~0.2 ms = 200 µs - }; - pub const SS58Prefix: u8 = 48; -} - -impl frame_system::Config for Runtime { - /// The basic call filter to use in dispatchable. - type BaseCallFilter = frame_support::traits::Everything; - /// The identifier used to distinguish between accounts. - type AccountId = AccountId; - /// The aggregated dispatch type that is available for extrinsics. - type RuntimeCall = RuntimeCall; - /// The lookup mechanism to get account ID from whatever is passed in dispatchers. - type Lookup = AccountIdLookup; - /// The index type for storing how many extrinsics an account has signed. - type Nonce = Nonce; - /// The type for hashing blocks and tries. - type Hash = Hash; - /// The hashing algorithm used. - type Hashing = Hashing; - /// The header type. - type Block = Block; - /// The ubiquitous event type. - type RuntimeEvent = RuntimeEvent; - /// The ubiquitous origin type. - type RuntimeOrigin = RuntimeOrigin; - /// Maximum number of block number to block hash mappings to keep (oldest pruned first). - type BlockHashCount = BlockHashCount; - /// Version of the runtime. - type Version = Version; - /// Provides information about the pallet setup in the runtime. - type PalletInfo = PalletInfo; - /// What to do if a new account is created. - type OnNewAccount = (); - /// What to do if an account is fully reaped from the system. - type OnKilledAccount = (); - /// The data to be stored in an account. - type AccountData = pallet_balances::AccountData; - // TODO: update me (https://github.com/paritytech/parity-bridges-common/issues/78) - /// Weight information for the extrinsics of this pallet. - type SystemWeightInfo = (); - /// Block and extrinsics weights: base values and limits. - type BlockWeights = bp_rialto::BlockWeights; - /// The maximum length of a block (in bytes). - type BlockLength = bp_rialto::BlockLength; - /// The weight of database operations that the runtime can invoke. - type DbWeight = DbWeight; - /// The designated SS58 prefix of this chain. - type SS58Prefix = SS58Prefix; - /// The set code logic, just the default since we're not a parachain. - type OnSetCode = (); - type MaxConsumers = frame_support::traits::ConstU32<16>; -} - -/// The BABE epoch configuration at genesis. -pub const BABE_GENESIS_EPOCH_CONFIG: sp_consensus_babe::BabeEpochConfiguration = - sp_consensus_babe::BabeEpochConfiguration { - c: bp_rialto::time_units::PRIMARY_PROBABILITY, - allowed_slots: sp_consensus_babe::AllowedSlots::PrimaryAndSecondaryVRFSlots, - }; - -parameter_types! { - pub const EpochDuration: u64 = bp_rialto::EPOCH_DURATION_IN_SLOTS as u64; - pub const ExpectedBlockTime: bp_rialto::Moment = bp_rialto::time_units::MILLISECS_PER_BLOCK; - pub ReportLongevity: u64 = EpochDuration::get() * 10; -} - -impl pallet_babe::Config for Runtime { - type EpochDuration = EpochDuration; - type ExpectedBlockTime = ExpectedBlockTime; - // session module is the trigger - type EpochChangeTrigger = pallet_babe::ExternalTrigger; - - type DisabledValidators = (); - - type WeightInfo = (); - - type MaxAuthorities = ConstU32<10>; - - // equivocation related configuration - we don't expect any equivocations in our testnets - type KeyOwnerProof = sp_core::Void; - type EquivocationReportSystem = (); - - type MaxNominators = ConstU32<256>; -} - -impl pallet_beefy::Config for Runtime { - type BeefyId = BeefyId; - type MaxAuthorities = ConstU32<10>; - type MaxSetIdSessionEntries = ConstU64<0>; - type OnNewValidatorSet = MmrLeaf; - type WeightInfo = (); - type KeyOwnerProof = sp_core::Void; - type EquivocationReportSystem = (); - type MaxNominators = ConstU32<256>; -} - -impl pallet_grandpa::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - // TODO: update me (https://github.com/paritytech/parity-bridges-common/issues/78) - type WeightInfo = (); - type MaxAuthorities = ConstU32<10>; - type MaxSetIdSessionEntries = ConstU64<0>; - type KeyOwnerProof = >::Proof; - type EquivocationReportSystem = - pallet_grandpa::EquivocationReportSystem; - type MaxNominators = ConstU32<256>; -} - -impl pallet_mmr::Config for Runtime { - const INDEXING_PREFIX: &'static [u8] = b"mmr"; - type Hashing = Keccak256; - type LeafData = pallet_beefy_mmr::Pallet; - type OnNewRoot = pallet_beefy_mmr::DepositBeefyDigest; - type WeightInfo = (); -} - -parameter_types! { - /// Version of the produced MMR leaf. - /// - /// The version consists of two parts; - /// - `major` (3 bits) - /// - `minor` (5 bits) - /// - /// `major` should be updated only if decoding the previous MMR Leaf format from the payload - /// is not possible (i.e. backward incompatible change). - /// `minor` should be updated if fields are added to the previous MMR Leaf, which given SCALE - /// encoding does not prevent old leafs from being decoded. - /// - /// Hence we expect `major` to be changed really rarely (think never). - /// See [`MmrLeafVersion`] type documentation for more details. - pub LeafVersion: MmrLeafVersion = MmrLeafVersion::new(0, 0); -} - -pub struct BeefyDummyDataProvider; - -impl sp_consensus_beefy::mmr::BeefyDataProvider<()> for BeefyDummyDataProvider { - fn extra_data() {} -} - -impl pallet_beefy_mmr::Config for Runtime { - type LeafVersion = LeafVersion; - type BeefyAuthorityToMerkleLeaf = pallet_beefy_mmr::BeefyEcdsaToEthereum; - type LeafExtra = (); - type BeefyDataProvider = BeefyDummyDataProvider; -} - -parameter_types! { - pub const MinimumPeriod: u64 = bp_rialto::SLOT_DURATION / 2; -} - -impl pallet_timestamp::Config for Runtime { - /// A timestamp: milliseconds since the UNIX epoch. - type Moment = bp_rialto::Moment; - type OnTimestampSet = Babe; - type MinimumPeriod = MinimumPeriod; - // TODO: update me (https://github.com/paritytech/parity-bridges-common/issues/78) - type WeightInfo = (); -} - -parameter_types! { - pub const ExistentialDeposit: bp_rialto::Balance = 500; -} - -impl pallet_balances::Config for Runtime { - /// The type for recording an account's balance. - type Balance = Balance; - /// The ubiquitous event type. - type RuntimeEvent = RuntimeEvent; - type DustRemoval = (); - type ExistentialDeposit = ExistentialDeposit; - type AccountStore = System; - // TODO: update me (https://github.com/paritytech/parity-bridges-common/issues/78) - type WeightInfo = (); - // For weight estimation, we assume that the most locks on an individual account will be 50. - // This number may need to be adjusted in the future if this assumption no longer holds true. - type MaxLocks = ConstU32<50>; - type MaxReserves = ConstU32<50>; - type ReserveIdentifier = [u8; 8]; - type RuntimeHoldReason = RuntimeHoldReason; - type FreezeIdentifier = (); - type MaxHolds = ConstU32<0>; - type MaxFreezes = ConstU32<0>; -} - -parameter_types! { - pub const TransactionBaseFee: Balance = 0; - pub const TransactionByteFee: Balance = 1; - // values for following parameters are copied from polkadot repo, but it is fine - // not to sync them - we're not going to make Rialto a full copy of one of Polkadot-like chains - pub const TargetBlockFullness: Perquintill = Perquintill::from_percent(25); - pub AdjustmentVariable: Multiplier = Multiplier::saturating_from_rational(3, 100_000); - pub MinimumMultiplier: Multiplier = Multiplier::saturating_from_rational(1, 1_000_000u128); - pub MaximumMultiplier: Multiplier = sp_runtime::traits::Bounded::max_value(); -} - -impl pallet_transaction_payment::Config for Runtime { - type OnChargeTransaction = pallet_transaction_payment::CurrencyAdapter; - type OperationalFeeMultiplier = ConstU8<5>; - type WeightToFee = bp_rialto::WeightToFee; - type LengthToFee = bp_rialto::WeightToFee; - type FeeMultiplierUpdate = pallet_transaction_payment::TargetedFeeAdjustment< - Runtime, - TargetBlockFullness, - AdjustmentVariable, - MinimumMultiplier, - MaximumMultiplier, - >; - type RuntimeEvent = RuntimeEvent; -} - -impl pallet_sudo::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type RuntimeCall = RuntimeCall; - type WeightInfo = pallet_sudo::weights::SubstrateWeight; -} - -impl pallet_session::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type ValidatorId = ::AccountId; - type ValidatorIdOf = (); - type ShouldEndSession = Babe; - type NextSessionRotation = Babe; - type SessionManager = pallet_shift_session_manager::Pallet; - type SessionHandler = ::KeyTypeIdProviders; - type Keys = SessionKeys; - // TODO: update me (https://github.com/paritytech/parity-bridges-common/issues/78) - type WeightInfo = (); -} - -impl pallet_authorship::Config for Runtime { - type FindAuthor = pallet_session::FindAccountFromAuthorIndex; - type EventHandler = (); -} - -pub struct FullIdentificationOf; -impl sp_runtime::traits::Convert> for FullIdentificationOf { - fn convert(_: AccountId) -> Option<()> { - Some(()) - } -} - -impl pallet_session::historical::Config for Runtime { - type FullIdentification = (); - type FullIdentificationOf = FullIdentificationOf; -} - -impl pallet_offences::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type IdentificationTuple = pallet_session::historical::IdentificationTuple; - type OnOffenceHandler = (); -} - -impl pallet_authority_discovery::Config for Runtime { - type MaxAuthorities = ConstU32<10>; -} - -impl pallet_bridge_relayers::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type Reward = Balance; - type PaymentProcedure = - bp_relayers::PayRewardFromAccount, AccountId>; - type StakeAndSlash = (); - type WeightInfo = (); -} - -pub type MillauGrandpaInstance = (); -impl pallet_bridge_grandpa::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type BridgedChain = bp_millau::Millau; - type MaxFreeMandatoryHeadersPerBlock = ConstU32<4>; - type HeadersToKeep = ConstU32<{ bp_millau::DAYS as u32 }>; - type WeightInfo = pallet_bridge_grandpa::weights::BridgeWeight; -} - -impl pallet_shift_session_manager::Config for Runtime {} - -parameter_types! { - pub const MaxMessagesToPruneAtOnce: bp_messages::MessageNonce = 8; - pub const MaxUnrewardedRelayerEntriesAtInboundLane: bp_messages::MessageNonce = - bp_millau::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX; - pub const MaxUnconfirmedMessagesAtInboundLane: bp_messages::MessageNonce = - bp_millau::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX; - pub const RootAccountForPayments: Option = None; - pub const BridgedChainId: bp_runtime::ChainId = bp_runtime::MILLAU_CHAIN_ID; - pub ActiveOutboundLanes: &'static [bp_messages::LaneId] = &[millau_messages::XCM_LANE]; -} - -/// Instance of the messages pallet used to relay messages to/from Millau chain. -pub type WithMillauMessagesInstance = (); - -impl pallet_bridge_messages::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type WeightInfo = pallet_bridge_messages::weights::BridgeWeight; - type ActiveOutboundLanes = ActiveOutboundLanes; - type MaxUnrewardedRelayerEntriesAtInboundLane = MaxUnrewardedRelayerEntriesAtInboundLane; - type MaxUnconfirmedMessagesAtInboundLane = MaxUnconfirmedMessagesAtInboundLane; - - type MaximalOutboundPayloadSize = crate::millau_messages::ToMillauMaximalOutboundPayloadSize; - type OutboundPayload = crate::millau_messages::ToMillauMessagePayload; - - type InboundPayload = crate::millau_messages::FromMillauMessagePayload; - type InboundRelayer = bp_millau::AccountId; - type DeliveryPayments = (); - - type TargetHeaderChain = crate::millau_messages::MillauAsTargetHeaderChain; - type LaneMessageVerifier = crate::millau_messages::ToMillauMessageVerifier; - type DeliveryConfirmationPayments = pallet_bridge_relayers::DeliveryConfirmationPaymentsAdapter< - Runtime, - WithMillauMessagesInstance, - frame_support::traits::ConstU128<100_000>, - >; - type OnMessagesDelivered = (); - - type SourceHeaderChain = crate::millau_messages::MillauAsSourceHeaderChain; - type MessageDispatch = crate::millau_messages::FromMillauMessageDispatch; - type BridgedChainId = BridgedChainId; -} - -pub type MillauBeefyInstance = (); -impl pallet_bridge_beefy::Config for Runtime { - type MaxRequests = frame_support::traits::ConstU32<16>; - type CommitmentsToKeep = frame_support::traits::ConstU32<8>; - type BridgedChain = bp_millau::Millau; -} - -construct_runtime!( - pub enum Runtime { - System: frame_system::{Pallet, Call, Config, Storage, Event}, - Sudo: pallet_sudo::{Pallet, Call, Config, Storage, Event}, - - // Must be before session. - Babe: pallet_babe::{Pallet, Call, Storage, Config, ValidateUnsigned}, - - Timestamp: pallet_timestamp::{Pallet, Call, Storage, Inherent}, - Balances: pallet_balances::{Pallet, Call, Storage, Config, Event}, - TransactionPayment: pallet_transaction_payment::{Pallet, Storage, Event}, - - // Consensus support. - // Authorship must be before session in order to note author in the correct session and era - // for im-online. - Authorship: pallet_authorship::{Pallet, Storage}, - Offences: pallet_offences::{Pallet, Storage, Event}, - Historical: pallet_session::historical::{Pallet}, - - AuthorityDiscovery: pallet_authority_discovery::{Pallet, Config}, - Session: pallet_session::{Pallet, Call, Storage, Event, Config}, - Grandpa: pallet_grandpa::{Pallet, Call, Storage, Config, Event}, - ShiftSessionManager: pallet_shift_session_manager::{Pallet}, - - // BEEFY Bridges support. - Beefy: pallet_beefy::{Pallet, Storage, Config}, - Mmr: pallet_mmr::{Pallet, Storage}, - MmrLeaf: pallet_beefy_mmr::{Pallet, Storage}, - - // Millau bridge modules. - BridgeRelayers: pallet_bridge_relayers::{Pallet, Call, Storage, Event}, - BridgeMillauGrandpa: pallet_bridge_grandpa::{Pallet, Call, Storage, Event}, - BridgeMillauMessages: pallet_bridge_messages::{Pallet, Call, Storage, Event, Config}, - - // Millau bridge modules (BEEFY based). - BridgeMillauBeefy: pallet_bridge_beefy::{Pallet, Call, Storage}, - - // Parachain modules. - ParachainsOrigin: polkadot_runtime_parachains::origin::{Pallet, Origin}, - Configuration: polkadot_runtime_parachains::configuration::{Pallet, Call, Storage, Config}, - Shared: polkadot_runtime_parachains::shared::{Pallet, Call, Storage}, - ParaInclusion: polkadot_runtime_parachains::inclusion::{Pallet, Call, Storage, Event}, - ParasInherent: polkadot_runtime_parachains::paras_inherent::{Pallet, Call, Storage, Inherent}, - Scheduler: polkadot_runtime_parachains::scheduler::{Pallet, Storage}, - Paras: polkadot_runtime_parachains::paras::{Pallet, Call, Storage, Event, Config, ValidateUnsigned}, - Initializer: polkadot_runtime_parachains::initializer::{Pallet, Call, Storage}, - Dmp: polkadot_runtime_parachains::dmp::{Pallet, Storage}, - Hrmp: polkadot_runtime_parachains::hrmp::{Pallet, Call, Storage, Event, Config}, - SessionInfo: polkadot_runtime_parachains::session_info::{Pallet, Storage}, - ParaSessionInfo: polkadot_runtime_parachains::session_info::{Pallet, Storage}, - ParasDisputes: polkadot_runtime_parachains::disputes::{Pallet, Call, Storage, Event}, - ParasSlashing: polkadot_runtime_parachains::disputes::slashing::{Pallet, Call, Storage, ValidateUnsigned}, - ParaAssignmentProvider: polkadot_runtime_parachains::assigner_parachains::{Pallet}, - MessageQueue: pallet_message_queue::{Pallet, Call, Storage, Event}, - - // Parachain Onboarding Pallets - Registrar: polkadot_runtime_common::paras_registrar::{Pallet, Call, Storage, Event}, - Slots: polkadot_runtime_common::slots::{Pallet, Call, Storage, Event}, - ParasSudoWrapper: polkadot_runtime_common::paras_sudo_wrapper::{Pallet, Call}, - - // Pallet for sending XCM. - XcmPallet: pallet_xcm::{Pallet, Call, Storage, Event, Origin, Config} = 99, - } -); - -/// The address format for describing accounts. -pub type Address = sp_runtime::MultiAddress; -/// Block header type as expected by this runtime. -pub type Header = generic::Header; -/// Block type as expected by this runtime. -pub type Block = generic::Block; -/// A Block signed with a Justification -pub type SignedBlock = generic::SignedBlock; -/// BlockId type as expected by this runtime. -pub type BlockId = generic::BlockId; -/// The SignedExtension to the basic transaction logic. -pub type SignedExtra = ( - frame_system::CheckNonZeroSender, - frame_system::CheckSpecVersion, - frame_system::CheckTxVersion, - frame_system::CheckGenesis, - frame_system::CheckEra, - frame_system::CheckNonce, - frame_system::CheckWeight, - pallet_transaction_payment::ChargeTransactionPayment, -); -/// The payload being signed in transactions. -pub type SignedPayload = generic::SignedPayload; -/// Unchecked extrinsic type as expected by this runtime. -pub type UncheckedExtrinsic = - generic::UncheckedExtrinsic; -/// Extrinsic type that has already been checked. -pub type CheckedExtrinsic = generic::CheckedExtrinsic; -/// Executive: handles dispatch to the various modules. -pub type Executive = frame_executive::Executive< - Runtime, - Block, - frame_system::ChainContext, - Runtime, - AllPalletsWithSystem, ->; - -/// MMR helper types. -mod mmr { - use super::Runtime; - pub use pallet_mmr::primitives::*; - - pub type Leaf = <::LeafData as LeafDataProvider>::LeafData; - pub type Hashing = ::Hashing; - pub type Hash = ::Output; -} - -impl_runtime_apis! { - impl sp_api::Core for Runtime { - fn version() -> RuntimeVersion { - VERSION - } - - fn execute_block(block: Block) { - Executive::execute_block(block); - } - - fn initialize_block(header: &::Header) { - Executive::initialize_block(header) - } - } - - impl sp_api::Metadata for Runtime { - fn metadata() -> OpaqueMetadata { - OpaqueMetadata::new(Runtime::metadata().into()) - } - - fn metadata_at_version(version: u32) -> Option { - Runtime::metadata_at_version(version) - } - - fn metadata_versions() -> sp_std::vec::Vec { - Runtime::metadata_versions() - } - } - - impl sp_block_builder::BlockBuilder for Runtime { - fn apply_extrinsic(extrinsic: ::Extrinsic) -> ApplyExtrinsicResult { - Executive::apply_extrinsic(extrinsic) - } - - fn finalize_block() -> ::Header { - Executive::finalize_block() - } - - fn inherent_extrinsics(data: sp_inherents::InherentData) -> Vec<::Extrinsic> { - data.create_extrinsics() - } - - fn check_inherents( - block: Block, - data: sp_inherents::InherentData, - ) -> sp_inherents::CheckInherentsResult { - data.check_extrinsics(&block) - } - } - - impl frame_system_rpc_runtime_api::AccountNonceApi for Runtime { - fn account_nonce(account: AccountId) -> Nonce { - System::account_nonce(account) - } - } - - impl sp_consensus_beefy::BeefyApi for Runtime { - fn beefy_genesis() -> Option { - Beefy::genesis_block() - } - - fn validator_set() -> Option> { - Beefy::validator_set() - } - - fn submit_report_equivocation_unsigned_extrinsic( - _equivocation_proof: sp_consensus_beefy::EquivocationProof< - NumberFor, - sp_consensus_beefy::ecdsa_crypto::AuthorityId, - sp_consensus_beefy::ecdsa_crypto::Signature - >, - _key_owner_proof: sp_consensus_beefy::OpaqueKeyOwnershipProof, - ) -> Option<()> { None } - - fn generate_key_ownership_proof( - _set_id: sp_consensus_beefy::ValidatorSetId, - _authority_id: sp_consensus_beefy::ecdsa_crypto::AuthorityId, - ) -> Option { None } - } - - impl pallet_mmr::primitives::MmrApi< - Block, - mmr::Hash, - BlockNumber, - > for Runtime { - fn mmr_root() -> Result { - Ok(Mmr::mmr_root()) - } - - fn mmr_leaf_count() -> Result { - Ok(Mmr::mmr_leaves()) - } - - fn generate_proof( - block_numbers: Vec, - best_known_block_number: Option, - ) -> Result<(Vec, mmr::Proof), mmr::Error> { - Mmr::generate_proof(block_numbers, best_known_block_number).map( - |(leaves, proof)| { - ( - leaves - .into_iter() - .map(|leaf| mmr::EncodableOpaqueLeaf::from_leaf(&leaf)) - .collect(), - proof, - ) - }, - ) - } - - fn verify_proof(leaves: Vec, proof: mmr::Proof) - -> Result<(), mmr::Error> - { - let leaves = leaves.into_iter().map(|leaf| - leaf.into_opaque_leaf() - .try_decode() - .ok_or(mmr::Error::Verify)).collect::, mmr::Error>>()?; - Mmr::verify_leaves(leaves, proof) - } - - fn verify_proof_stateless( - root: mmr::Hash, - leaves: Vec, - proof: mmr::Proof - ) -> Result<(), mmr::Error> { - let nodes = leaves.into_iter().map(|leaf|mmr::DataOrHash::Data(leaf.into_opaque_leaf())).collect(); - pallet_mmr::verify_leaves_proof::(root, nodes, proof) - } - } - - impl bp_millau::MillauFinalityApi for Runtime { - fn best_finalized() -> Option> { - BridgeMillauGrandpa::best_finalized() - } - - fn synced_headers_grandpa_info( - ) -> Vec> { - BridgeMillauGrandpa::synced_headers_grandpa_info() - } - } - - impl sp_transaction_pool::runtime_api::TaggedTransactionQueue for Runtime { - fn validate_transaction( - source: TransactionSource, - tx: ::Extrinsic, - block_hash: ::Hash, - ) -> TransactionValidity { - Executive::validate_transaction(source, tx, block_hash) - } - } - - impl sp_offchain::OffchainWorkerApi for Runtime { - fn offchain_worker(header: &::Header) { - Executive::offchain_worker(header) - } - } - - impl sp_consensus_babe::BabeApi for Runtime { - fn configuration() -> sp_consensus_babe::BabeConfiguration { - // The choice of `c` parameter (where `1 - c` represents the - // probability of a slot being empty), is done in accordance to the - // slot duration and expected target block time, for safely - // resisting network delays of maximum two seconds. - // - sp_consensus_babe::BabeConfiguration { - slot_duration: Babe::slot_duration(), - epoch_length: EpochDuration::get(), - c: BABE_GENESIS_EPOCH_CONFIG.c, - authorities: Babe::authorities().to_vec(), - randomness: Babe::randomness(), - allowed_slots: BABE_GENESIS_EPOCH_CONFIG.allowed_slots, - } - } - - fn current_epoch_start() -> sp_consensus_babe::Slot { - Babe::current_epoch_start() - } - - fn current_epoch() -> sp_consensus_babe::Epoch { - Babe::current_epoch() - } - - fn next_epoch() -> sp_consensus_babe::Epoch { - Babe::next_epoch() - } - - fn generate_key_ownership_proof( - _slot: sp_consensus_babe::Slot, - _authority_id: sp_consensus_babe::AuthorityId, - ) -> Option { - None - } - - fn submit_report_equivocation_unsigned_extrinsic( - equivocation_proof: sp_consensus_babe::EquivocationProof<::Header>, - key_owner_proof: sp_consensus_babe::OpaqueKeyOwnershipProof, - ) -> Option<()> { - let key_owner_proof = key_owner_proof.decode()?; - - Babe::submit_unsigned_equivocation_report( - equivocation_proof, - key_owner_proof, - ) - } - } - - #[api_version(8)] - impl polkadot_primitives::runtime_api::ParachainHost for Runtime { - fn validators() -> Vec { - parachains_runtime_api_impl::validators::() - } - - fn validator_groups() -> (Vec>, polkadot_primitives::GroupRotationInfo) { - parachains_runtime_api_impl::validator_groups::() - } - - fn availability_cores() -> Vec> { - parachains_runtime_api_impl::availability_cores::() - } - - fn persisted_validation_data(para_id: ParaId, assumption: polkadot_primitives::OccupiedCoreAssumption) - -> Option> { - parachains_runtime_api_impl::persisted_validation_data::(para_id, assumption) - } - - fn assumed_validation_data( - para_id: ParaId, - expected_persisted_validation_data_hash: Hash, - ) -> Option<(polkadot_primitives::PersistedValidationData, polkadot_primitives::ValidationCodeHash)> { - parachains_runtime_api_impl::assumed_validation_data::( - para_id, - expected_persisted_validation_data_hash, - ) - } - - fn check_validation_outputs( - para_id: ParaId, - outputs: polkadot_primitives::CandidateCommitments, - ) -> bool { - parachains_runtime_api_impl::check_validation_outputs::(para_id, outputs) - } - - fn session_index_for_child() -> polkadot_primitives::SessionIndex { - parachains_runtime_api_impl::session_index_for_child::() - } - - fn validation_code(para_id: ParaId, assumption: polkadot_primitives::OccupiedCoreAssumption) - -> Option { - parachains_runtime_api_impl::validation_code::(para_id, assumption) - } - - fn candidate_pending_availability(para_id: ParaId) -> Option> { - parachains_runtime_api_impl::candidate_pending_availability::(para_id) - } - - fn candidate_events() -> Vec> { - parachains_runtime_api_impl::candidate_events::(|ev| { - match ev { - RuntimeEvent::ParaInclusion(ev) => { - Some(ev) - } - _ => None, - } - }) - } - - fn session_info(index: polkadot_primitives::SessionIndex) -> Option { - parachains_runtime_api_impl::session_info::(index) - } - - fn session_executor_params(session_index: polkadot_primitives::SessionIndex) -> Option { - parachains_runtime_api_impl::session_executor_params::(session_index) - } - - fn dmq_contents(recipient: ParaId) -> Vec> { - parachains_runtime_api_impl::dmq_contents::(recipient) - } - - fn inbound_hrmp_channels_contents( - recipient: ParaId - ) -> BTreeMap>> { - parachains_runtime_api_impl::inbound_hrmp_channels_contents::(recipient) - } - - fn validation_code_by_hash(hash: polkadot_primitives::ValidationCodeHash) -> Option { - parachains_runtime_api_impl::validation_code_by_hash::(hash) - } - - fn on_chain_votes() -> Option> { - parachains_runtime_api_impl::on_chain_votes::() - } - - fn submit_pvf_check_statement( - stmt: polkadot_primitives::PvfCheckStatement, - signature: polkadot_primitives::ValidatorSignature - ) { - parachains_runtime_api_impl::submit_pvf_check_statement::(stmt, signature) - } - - fn pvfs_require_precheck() -> Vec { - parachains_runtime_api_impl::pvfs_require_precheck::() - } - - fn validation_code_hash(para_id: ParaId, assumption: polkadot_primitives::OccupiedCoreAssumption) - -> Option - { - parachains_runtime_api_impl::validation_code_hash::(para_id, assumption) - } - - fn disputes() -> Vec<(polkadot_primitives::SessionIndex, polkadot_primitives::CandidateHash, polkadot_primitives::DisputeState)> { - parachains_runtime_api_impl::get_session_disputes::() - } - - fn unapplied_slashes( - ) -> Vec<(polkadot_primitives::SessionIndex, polkadot_primitives::CandidateHash, polkadot_primitives::slashing::PendingSlashes)> { - parachains_runtime_api_impl::unapplied_slashes::() - } - - fn key_ownership_proof( - validator_id: polkadot_primitives::ValidatorId, - ) -> Option { - use codec::Encode; - - Historical::prove((polkadot_primitives::PARACHAIN_KEY_TYPE_ID, validator_id)) - .map(|p| p.encode()) - .map(polkadot_primitives::slashing::OpaqueKeyOwnershipProof::new) - } - - fn submit_report_dispute_lost( - dispute_proof: polkadot_primitives::slashing::DisputeProof, - key_ownership_proof: polkadot_primitives::slashing::OpaqueKeyOwnershipProof, - ) -> Option<()> { - parachains_runtime_api_impl::submit_unsigned_slashing_report::( - dispute_proof, - key_ownership_proof, - ) - } - - fn minimum_backing_votes() -> u32 { - parachains_runtime_api_impl::minimum_backing_votes::() - } - - fn para_backing_state(para_id: ParaId) -> Option { - parachains_runtime_api_impl::backing_state::(para_id) - } - - fn async_backing_params() -> polkadot_primitives::AsyncBackingParams { - parachains_runtime_api_impl::async_backing_params::() - } - - fn disabled_validators() -> Vec { - parachains_staging_runtime_api_impl::disabled_validators::() - } - - } - - impl sp_authority_discovery::AuthorityDiscoveryApi for Runtime { - fn authorities() -> Vec { - parachains_runtime_api_impl::relevant_authority_ids::() - } - } - - impl pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi< - Block, - Balance, - > for Runtime { - fn query_info(uxt: ::Extrinsic, len: u32) -> RuntimeDispatchInfo { - TransactionPayment::query_info(uxt, len) - } - fn query_fee_details(uxt: ::Extrinsic, len: u32) -> FeeDetails { - TransactionPayment::query_fee_details(uxt, len) - } - fn query_weight_to_fee(weight: Weight) -> Balance { - TransactionPayment::weight_to_fee(weight) - } - fn query_length_to_fee(length: u32) -> Balance { - TransactionPayment::length_to_fee(length) - } - } - - impl sp_session::SessionKeys for Runtime { - fn generate_session_keys(seed: Option>) -> Vec { - SessionKeys::generate(seed) - } - - fn decode_session_keys( - encoded: Vec, - ) -> Option, sp_core::crypto::KeyTypeId)>> { - SessionKeys::decode_into_raw_public_keys(&encoded) - } - } - - impl fg_primitives::GrandpaApi for Runtime { - fn current_set_id() -> fg_primitives::SetId { - Grandpa::current_set_id() - } - - fn grandpa_authorities() -> GrandpaAuthorityList { - Grandpa::grandpa_authorities() - } - - fn submit_report_equivocation_unsigned_extrinsic( - equivocation_proof: fg_primitives::EquivocationProof< - ::Hash, - NumberFor, - >, - key_owner_proof: fg_primitives::OpaqueKeyOwnershipProof, - ) -> Option<()> { - let key_owner_proof = key_owner_proof.decode()?; - - Grandpa::submit_unsigned_equivocation_report( - equivocation_proof, - key_owner_proof, - ) - } - - fn generate_key_ownership_proof( - _set_id: fg_primitives::SetId, - _authority_id: GrandpaId, - ) -> Option { - // NOTE: this is the only implementation possible since we've - // defined our key owner proof type as a bottom type (i.e. a type - // with no values). - None - } - } - - impl bp_millau::ToMillauOutboundLaneApi for Runtime { - fn message_details( - lane: bp_messages::LaneId, - begin: bp_messages::MessageNonce, - end: bp_messages::MessageNonce, - ) -> Vec { - bridge_runtime_common::messages_api::outbound_message_details::< - Runtime, - WithMillauMessagesInstance, - >(lane, begin, end) - } - } - - impl bp_millau::FromMillauInboundLaneApi for Runtime { - fn message_details( - lane: bp_messages::LaneId, - messages: Vec<(bp_messages::MessagePayload, bp_messages::OutboundMessageDetails)>, - ) -> Vec { - bridge_runtime_common::messages_api::inbound_message_details::< - Runtime, - WithMillauMessagesInstance, - >(lane, messages) - } - } -} - -#[cfg(test)] -mod tests { - use super::*; - - #[test] - fn call_size() { - const BRIDGES_PALLETS_MAX_CALL_SIZE: usize = 200; - assert!( - core::mem::size_of::>() <= - BRIDGES_PALLETS_MAX_CALL_SIZE - ); - assert!( - core::mem::size_of::>() <= - BRIDGES_PALLETS_MAX_CALL_SIZE - ); - // Largest inner Call is `pallet_session::Call` with a size of 224 bytes. This size is a - // result of large `SessionKeys` struct. - // Total size of Rialto runtime Call is 232. - const MAX_CALL_SIZE: usize = 232; - assert!(core::mem::size_of::() <= MAX_CALL_SIZE); - } -} diff --git a/bin/rialto/runtime/src/millau_messages.rs b/bin/rialto/runtime/src/millau_messages.rs deleted file mode 100644 index 03e4c494cf2a4..0000000000000 --- a/bin/rialto/runtime/src/millau_messages.rs +++ /dev/null @@ -1,200 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Everything required to serve Millau <-> Rialto messages. - -use crate::{MillauGrandpaInstance, Runtime, RuntimeOrigin, WithMillauMessagesInstance}; - -use bp_messages::LaneId; -use bridge_runtime_common::{ - messages::{ - self, source::TargetHeaderChainAdapter, target::SourceHeaderChainAdapter, MessageBridge, - }, - messages_xcm_extension::{SenderAndLane, XcmBlobHauler, XcmBlobHaulerAdapter}, -}; -use frame_support::{parameter_types, weights::Weight}; -use sp_runtime::RuntimeDebug; -use xcm::latest::prelude::*; -use xcm_builder::HaulBlobExporter; - -/// Lane that is used for XCM messages exchange. -pub const XCM_LANE: LaneId = LaneId([0, 0, 0, 0]); -/// Weight of 2 XCM instructions is for simple `Trap(42)` program, coming through bridge -/// (it is prepended with `UniversalOrigin` instruction). It is used just for simplest manual -/// tests, confirming that we don't break encoding somewhere between. -pub const BASE_XCM_WEIGHT_TWICE: Weight = crate::xcm_config::BaseXcmWeight::get().saturating_mul(2); - -parameter_types! { - /// Weight credit for our test messages. - /// - /// 2 XCM instructions is for simple `Trap(42)` program, coming through bridge - /// (it is prepended with `UniversalOrigin` instruction). - pub const WeightCredit: Weight = BASE_XCM_WEIGHT_TWICE; - /// Lane used by the with-Millau bridge. - pub MullauSenderAndLane: SenderAndLane = SenderAndLane::new(Here.into(), XCM_LANE); - - /// Dummy message used in configuration. - pub DummyXcmMessage: Xcm<()> = Xcm::new(); -} - -/// Message payload for Rialto -> Millau messages. -pub type ToMillauMessagePayload = messages::source::FromThisChainMessagePayload; - -/// Message verifier for Rialto -> Millau messages. -pub type ToMillauMessageVerifier = - messages::source::FromThisChainMessageVerifier; - -/// Message payload for Millau -> Rialto messages. -pub type FromMillauMessagePayload = messages::target::FromBridgedChainMessagePayload; - -/// Call-dispatch based message dispatch for Millau -> Rialto messages. -pub type FromMillauMessageDispatch = - bridge_runtime_common::messages_xcm_extension::XcmBlobMessageDispatch< - crate::xcm_config::OnRialtoBlobDispatcher, - (), - (), - >; - -/// Messages proof for Millau -> Rialto messages. -pub type FromMillauMessagesProof = messages::target::FromBridgedChainMessagesProof; - -/// Messages delivery proof for Rialto -> Millau messages. -pub type ToMillauMessagesDeliveryProof = - messages::source::FromBridgedChainMessagesDeliveryProof; - -/// Maximal outbound payload size of Rialto -> Millau messages. -pub type ToMillauMaximalOutboundPayloadSize = - messages::source::FromThisChainMaximalOutboundPayloadSize; - -/// Millau <-> Rialto message bridge. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct WithMillauMessageBridge; - -impl MessageBridge for WithMillauMessageBridge { - const BRIDGED_MESSAGES_PALLET_NAME: &'static str = bp_rialto::WITH_RIALTO_MESSAGES_PALLET_NAME; - - type ThisChain = Rialto; - type BridgedChain = Millau; - type BridgedHeaderChain = - pallet_bridge_grandpa::GrandpaChainHeaders; -} - -/// Rialto chain from message lane point of view. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct Rialto; - -impl messages::UnderlyingChainProvider for Rialto { - type Chain = bp_rialto::Rialto; -} - -impl messages::ThisChainWithMessages for Rialto { - type RuntimeOrigin = RuntimeOrigin; -} - -/// Millau chain from message lane point of view. -#[derive(RuntimeDebug, Clone, Copy)] -pub struct Millau; -/// Millau as source header chain. -pub type MillauAsSourceHeaderChain = SourceHeaderChainAdapter; -/// Millau as target header chain. -pub type MillauAsTargetHeaderChain = TargetHeaderChainAdapter; - -impl messages::UnderlyingChainProvider for Millau { - type Chain = bp_millau::Millau; -} - -impl messages::BridgedChainWithMessages for Millau {} - -/// Export XCM messages to be relayed to Millau. -pub type ToMillauBlobExporter = HaulBlobExporter< - XcmBlobHaulerAdapter, - crate::xcm_config::MillauNetwork, - (), ->; - -/// To-Millau XCM hauler. -pub struct ToMillauXcmBlobHauler; - -impl XcmBlobHauler for ToMillauXcmBlobHauler { - type Runtime = Runtime; - type MessagesInstance = WithMillauMessagesInstance; - type SenderAndLane = MullauSenderAndLane; - - type ToSourceChainSender = crate::xcm_config::XcmRouter; - type CongestedMessage = DummyXcmMessage; - type UncongestedMessage = DummyXcmMessage; -} - -#[cfg(test)] -mod tests { - use super::*; - use crate::{MillauGrandpaInstance, Runtime, WithMillauMessagesInstance}; - use bridge_runtime_common::{ - assert_complete_bridge_types, - integrity::{ - assert_complete_bridge_constants, check_message_lane_weights, - AssertBridgeMessagesPalletConstants, AssertBridgePalletNames, AssertChainConstants, - AssertCompleteBridgeConstants, - }, - }; - - #[test] - fn ensure_millau_message_lane_weights_are_correct() { - check_message_lane_weights::( - bp_millau::EXTRA_STORAGE_PROOF_SIZE, - bp_rialto::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX, - bp_rialto::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX, - false, - ); - } - - #[test] - fn ensure_bridge_integrity() { - assert_complete_bridge_types!( - runtime: Runtime, - with_bridged_chain_grandpa_instance: MillauGrandpaInstance, - with_bridged_chain_messages_instance: WithMillauMessagesInstance, - bridge: WithMillauMessageBridge, - this_chain: bp_rialto::Rialto, - bridged_chain: bp_millau::Millau, - ); - - assert_complete_bridge_constants::< - Runtime, - MillauGrandpaInstance, - WithMillauMessagesInstance, - WithMillauMessageBridge, - >(AssertCompleteBridgeConstants { - this_chain_constants: AssertChainConstants { - block_length: bp_rialto::BlockLength::get(), - block_weights: bp_rialto::BlockWeights::get(), - }, - messages_pallet_constants: AssertBridgeMessagesPalletConstants { - max_unrewarded_relayers_in_bridged_confirmation_tx: - bp_millau::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX, - max_unconfirmed_messages_in_bridged_confirmation_tx: - bp_millau::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX, - bridged_chain_id: bp_runtime::MILLAU_CHAIN_ID, - }, - pallet_names: AssertBridgePalletNames { - with_this_chain_messages_pallet_name: bp_rialto::WITH_RIALTO_MESSAGES_PALLET_NAME, - with_bridged_chain_grandpa_pallet_name: bp_millau::WITH_MILLAU_GRANDPA_PALLET_NAME, - with_bridged_chain_messages_pallet_name: - bp_millau::WITH_MILLAU_MESSAGES_PALLET_NAME, - }, - }); - } -} diff --git a/bin/rialto/runtime/src/parachains.rs b/bin/rialto/runtime/src/parachains.rs deleted file mode 100644 index 972edbf35286e..0000000000000 --- a/bin/rialto/runtime/src/parachains.rs +++ /dev/null @@ -1,274 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Parachains support in Rialto runtime. - -use crate::{ - xcm_config, AccountId, Babe, Balance, Balances, BlockNumber, ParaAssignmentProvider, Registrar, - Runtime, RuntimeCall, RuntimeEvent, RuntimeOrigin, ShiftSessionManager, Slots, - UncheckedExtrinsic, -}; - -use frame_support::{ - parameter_types, - traits::{KeyOwnerProofSystem, ProcessMessage, ProcessMessageError}, - weights::{Weight, WeightMeter}, -}; -use frame_system::EnsureRoot; -use polkadot_primitives::v6::{ValidatorId, ValidatorIndex}; -use polkadot_runtime_common::{paras_registrar, paras_sudo_wrapper, slots}; -use polkadot_runtime_parachains::{ - configuration as parachains_configuration, disputes as parachains_disputes, - disputes::slashing as parachains_slashing, - dmp as parachains_dmp, hrmp as parachains_hrmp, inclusion as parachains_inclusion, - inclusion::{AggregateMessageOrigin, UmpQueueId}, - initializer as parachains_initializer, origin as parachains_origin, paras as parachains_paras, - paras_inherent as parachains_paras_inherent, scheduler as parachains_scheduler, - session_info as parachains_session_info, shared as parachains_shared, -}; -use sp_core::crypto::KeyTypeId; -use sp_runtime::transaction_validity::TransactionPriority; -use xcm::latest::Junction; - -impl frame_system::offchain::SendTransactionTypes for Runtime -where - RuntimeCall: From, -{ - type Extrinsic = UncheckedExtrinsic; - type OverarchingCall = RuntimeCall; -} - -/// Special `RewardValidators` that does nothing ;) -pub struct RewardValidators; -impl polkadot_runtime_parachains::inclusion::RewardValidators for RewardValidators { - fn reward_backing(_: impl IntoIterator) {} - fn reward_bitfields(_: impl IntoIterator) {} -} - -// all required parachain modules from `polkadot-runtime-parachains` crate - -impl parachains_configuration::Config for Runtime { - type WeightInfo = parachains_configuration::TestWeightInfo; -} - -impl parachains_dmp::Config for Runtime {} - -impl parachains_hrmp::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type RuntimeOrigin = RuntimeOrigin; - type ChannelManager = EnsureRoot; - type Currency = Balances; - type WeightInfo = parachains_hrmp::TestWeightInfo; -} - -impl parachains_inclusion::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type RewardValidators = RewardValidators; - type DisputesHandler = (); - type MessageQueue = crate::MessageQueue; - type WeightInfo = (); -} - -impl parachains_initializer::Config for Runtime { - type Randomness = pallet_babe::RandomnessFromOneEpochAgo; - type ForceOrigin = EnsureRoot; - type WeightInfo = (); -} - -impl parachains_disputes::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type RewardValidators = (); - type SlashingHandler = (); - type WeightInfo = parachains_disputes::TestWeightInfo; -} - -impl parachains_slashing::Config for Runtime { - type KeyOwnerProofSystem = (); - type KeyOwnerProof = - >::Proof; - type KeyOwnerIdentification = >::IdentificationTuple; - type HandleReports = (); - type WeightInfo = parachains_slashing::TestWeightInfo; - type BenchmarkingConfig = parachains_slashing::BenchConfig<200>; -} - -impl parachains_origin::Config for Runtime {} - -parameter_types! { - pub const ParasUnsignedPriority: TransactionPriority = TransactionPriority::max_value(); -} - -impl parachains_paras::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type WeightInfo = ParasWeightInfo; - type UnsignedPriority = ParasUnsignedPriority; - type QueueFootprinter = crate::ParaInclusion; - type NextSessionRotation = Babe; - type OnNewHead = Registrar; -} - -/// Test weight for the `Paras` pallet. -/// -/// We can't use `parachains_paras::TestWeightInfo` anymore, because it returns `Weight::MAX` -/// where we need some real-world weights. We'll use zero weights here, though to avoid -/// adding benchmarks to Rialto runtime. -pub struct ParasWeightInfo; - -impl parachains_paras::WeightInfo for ParasWeightInfo { - fn force_set_current_code(_c: u32) -> Weight { - Weight::zero() - } - fn force_set_current_head(_s: u32) -> Weight { - Weight::zero() - } - - fn force_set_most_recent_context() -> Weight { - Weight::zero() - } - - fn force_schedule_code_upgrade(_c: u32) -> Weight { - Weight::zero() - } - fn force_note_new_head(_s: u32) -> Weight { - Weight::zero() - } - fn force_queue_action() -> Weight { - Weight::zero() - } - fn add_trusted_validation_code(_c: u32) -> Weight { - Weight::zero() - } - fn poke_unused_validation_code() -> Weight { - Weight::zero() - } - fn include_pvf_check_statement_finalize_upgrade_accept() -> Weight { - Weight::zero() - } - fn include_pvf_check_statement_finalize_upgrade_reject() -> Weight { - Weight::zero() - } - fn include_pvf_check_statement_finalize_onboarding_accept() -> Weight { - Weight::zero() - } - fn include_pvf_check_statement_finalize_onboarding_reject() -> Weight { - Weight::zero() - } - fn include_pvf_check_statement() -> Weight { - Weight::zero() - } -} - -impl parachains_paras_inherent::Config for Runtime { - type WeightInfo = parachains_paras_inherent::TestWeightInfo; -} - -impl polkadot_runtime_parachains::assigner_parachains::Config for Runtime {} - -impl parachains_scheduler::Config for Runtime { - type AssignmentProvider = ParaAssignmentProvider; -} - -impl parachains_session_info::Config for Runtime { - type ValidatorSet = ShiftSessionManager; -} - -impl parachains_shared::Config for Runtime {} - -parameter_types! { - /// Amount of weight that can be spent per block to service messages. - /// - /// # WARNING - /// - /// This is not a good value for para-chains since the `Scheduler` - /// already uses up to 80 percent block weight. - pub MessageQueueServiceWeight: Weight = crate::Perbill::from_percent(20) * bp_rialto::BlockWeights::get().max_block; - pub const MessageQueueHeapSize: u32 = 32 * 1024; - pub const MessageQueueMaxStale: u32 = 96; -} - -/// Message processor to handle any messages that were enqueued into the `MessageQueue` pallet. -pub struct MessageProcessor; -impl ProcessMessage for MessageProcessor { - type Origin = AggregateMessageOrigin; - - fn process_message( - message: &[u8], - origin: Self::Origin, - meter: &mut WeightMeter, - id: &mut [u8; 32], - ) -> Result { - let para = match origin { - AggregateMessageOrigin::Ump(UmpQueueId::Para(para)) => para, - }; - xcm_builder::ProcessXcmMessage::< - Junction, - xcm_executor::XcmExecutor, - RuntimeCall, - >::process_message(message, Junction::Parachain(para.into()), meter, id) - } -} - -impl pallet_message_queue::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type Size = u32; - type HeapSize = MessageQueueHeapSize; - type MaxStale = MessageQueueMaxStale; - type ServiceWeight = MessageQueueServiceWeight; - #[cfg(not(feature = "runtime-benchmarks"))] - type MessageProcessor = MessageProcessor; - #[cfg(feature = "runtime-benchmarks")] - type MessageProcessor = - pallet_message_queue::mock_helpers::NoopMessageProcessor; - type QueueChangeHandler = crate::ParaInclusion; - type WeightInfo = (); - type QueuePausedQuery = (); -} - -// required onboarding pallets. We're not going to use auctions or crowdloans, so they're missing - -parameter_types! { - pub const ParaDeposit: Balance = 0; - pub const DataDepositPerByte: Balance = 0; -} - -impl paras_registrar::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type RuntimeOrigin = RuntimeOrigin; - type Currency = Balances; - type OnSwap = Slots; - type ParaDeposit = ParaDeposit; - type DataDepositPerByte = DataDepositPerByte; - type WeightInfo = paras_registrar::TestWeightInfo; -} - -parameter_types! { - pub const LeasePeriod: BlockNumber = 10 * bp_rialto::MINUTES; -} - -impl slots::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type Currency = Balances; - type Registrar = Registrar; - type LeasePeriod = LeasePeriod; - type WeightInfo = slots::TestWeightInfo; - type LeaseOffset = (); - type ForceOrigin = EnsureRoot; -} - -impl paras_sudo_wrapper::Config for Runtime {} diff --git a/bin/rialto/runtime/src/xcm_config.rs b/bin/rialto/runtime/src/xcm_config.rs deleted file mode 100644 index caac064f81534..0000000000000 --- a/bin/rialto/runtime/src/xcm_config.rs +++ /dev/null @@ -1,280 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! XCM configurations for the Rialto runtime. - -use super::{ - millau_messages::ToMillauBlobExporter, AccountId, AllPalletsWithSystem, Balances, Runtime, - RuntimeCall, RuntimeEvent, RuntimeOrigin, XcmPallet, -}; -use bp_rialto::WeightToFee; -use bridge_runtime_common::CustomNetworkId; -use frame_support::{ - parameter_types, - traits::{ConstU32, Everything, Nothing}, - weights::Weight, -}; -use frame_system::EnsureRoot; -use xcm::latest::prelude::*; -use xcm_builder::{ - AccountId32Aliases, CurrencyAdapter as XcmCurrencyAdapter, IsConcrete, MintLocation, - SignedAccountId32AsNative, SignedToAccountId32, SovereignSignedViaLocation, TakeWeightCredit, - UsingComponents, -}; - -parameter_types! { - /// The location of the `MLAU` token, from the context of this chain. Since this token is native to this - /// chain, we make it synonymous with it and thus it is the `Here` location, which means "equivalent to - /// the context". - pub const TokenLocation: MultiLocation = Here.into_location(); - /// The Rialto network ID. - pub const ThisNetwork: NetworkId = CustomNetworkId::Rialto.as_network_id(); - /// The Millau network ID. - pub const MillauNetwork: NetworkId = CustomNetworkId::Millau.as_network_id(); - - /// Our XCM location ancestry - i.e. our location within the Consensus Universe. - /// - /// Since Polkadot is a top-level relay-chain with its own consensus, it's just our network ID. - pub UniversalLocation: InteriorMultiLocation = ThisNetwork::get().into(); - /// The check account, which holds any native assets that have been teleported out and not back in (yet). - pub CheckAccount: (AccountId, MintLocation) = (XcmPallet::check_account(), MintLocation::Local); -} - -/// The canonical means of converting a `MultiLocation` into an `AccountId`, used when we want to -/// determine the sovereign account controlled by a location. -pub type SovereignAccountOf = ( - // We can directly alias an `AccountId32` into a local account. - AccountId32Aliases, -); - -/// Our asset transactor. This is what allows us to interest with the runtime facilities from the -/// point of view of XCM-only concepts like `MultiLocation` and `MultiAsset`. -/// -/// Ours is only aware of the Balances pallet, which is mapped to `TokenLocation`. -pub type LocalAssetTransactor = XcmCurrencyAdapter< - // Use this currency: - Balances, - // Use this currency when it is a fungible asset matching the given location or name: - IsConcrete, - // We can convert the MultiLocations with our converter above: - SovereignAccountOf, - // Our chain's account ID type (we can't get away without mentioning it explicitly): - AccountId, - // We track our teleports in/out to keep total issuance correct. - CheckAccount, ->; - -/// The means that we convert the XCM message origin location into a local dispatch origin. -type LocalOriginConverter = ( - // A `Signed` origin of the sovereign account that the original location controls. - SovereignSignedViaLocation, - // The AccountId32 location type can be expressed natively as a `Signed` origin. - SignedAccountId32AsNative, -); - -parameter_types! { - /// The amount of weight an XCM operation takes. This is a safe overestimate. - pub const BaseXcmWeight: Weight = Weight::from_parts(1_000_000_000, 64 * 1024); - /// Maximum number of instructions in a single XCM fragment. A sanity check against weight - /// calculations getting too crazy. - pub const MaxInstructions: u32 = 100; -} - -/// The XCM router. We are not sending messages to sibling/parent/child chains here. -pub type XcmRouter = (); - -/// The barriers one of which must be passed for an XCM message to be executed. -pub type Barrier = ( - // Weight that is paid for may be consumed. - TakeWeightCredit, -); - -/// Dispatches received XCM messages from other chain. -pub type OnRialtoBlobDispatcher = xcm_builder::BridgeBlobDispatcher< - crate::xcm_config::XcmRouter, - crate::xcm_config::UniversalLocation, - (), ->; - -/// Incoming XCM weigher type. -pub type XcmWeigher = xcm_builder::FixedWeightBounds; - -pub struct XcmConfig; -impl xcm_executor::Config for XcmConfig { - type RuntimeCall = RuntimeCall; - type XcmSender = (); - type AssetTransactor = LocalAssetTransactor; - type OriginConverter = LocalOriginConverter; - type IsReserve = (); - type IsTeleporter = (); - type UniversalLocation = UniversalLocation; - type Barrier = Barrier; - type Weigher = XcmWeigher; - // The weight trader piggybacks on the existing transaction-fee conversion logic. - type Trader = UsingComponents; - type ResponseHandler = XcmPallet; - type AssetTrap = XcmPallet; - type AssetLocker = (); - type AssetExchanger = (); - type AssetClaims = XcmPallet; - type SubscriptionService = XcmPallet; - type PalletInstancesInfo = AllPalletsWithSystem; - type MaxAssetsIntoHolding = ConstU32<64>; - type FeeManager = (); - type MessageExporter = ToMillauBlobExporter; - type UniversalAliases = Nothing; - type CallDispatcher = RuntimeCall; - type SafeCallFilter = Everything; - type Aliasers = Nothing; -} - -/// Type to convert an `Origin` type value into a `MultiLocation` value which represents an interior -/// location of this chain. -pub type LocalOriginToLocation = ( - // Usual Signed origin to be used in XCM as a corresponding AccountId32 - SignedToAccountId32, -); - -#[cfg(feature = "runtime-benchmarks")] -parameter_types! { - pub ReachableDest: Option = None; -} - -impl pallet_xcm::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - // We don't allow any messages to be sent via the transaction yet. This is basically safe to - // enable, (safe the possibility of someone spamming the parachain if they're willing to pay - // the DOT to send from the Relay-chain). But it's useless until we bring in XCM v3 which will - // make `DescendOrigin` a bit more useful. - type SendXcmOrigin = xcm_builder::EnsureXcmOrigin; - type XcmRouter = XcmRouter; - // Anyone can execute XCM messages locally. - type ExecuteXcmOrigin = xcm_builder::EnsureXcmOrigin; - type XcmExecuteFilter = Everything; - type XcmExecutor = xcm_executor::XcmExecutor; - // Anyone is able to use teleportation regardless of who they are and what they want to - // teleport. - type XcmTeleportFilter = Everything; - // Anyone is able to use reserve transfers regardless of who they are and what they want to - // transfer. - type XcmReserveTransferFilter = Everything; - type Weigher = XcmWeigher; - type UniversalLocation = UniversalLocation; - type RuntimeOrigin = RuntimeOrigin; - type RuntimeCall = RuntimeCall; - const VERSION_DISCOVERY_QUEUE_SIZE: u32 = 100; - type AdvertisedXcmVersion = pallet_xcm::CurrentXcmVersion; - type Currency = Balances; - type CurrencyMatcher = (); - type TrustedLockers = (); - type SovereignAccountOf = SovereignAccountOf; - type MaxLockers = frame_support::traits::ConstU32<8>; - type WeightInfo = pallet_xcm::TestWeightInfo; - #[cfg(feature = "runtime-benchmarks")] - type ReachableDest = ReachableDest; - type AdminOrigin = EnsureRoot; - type MaxRemoteLockConsumers = ConstU32<0>; - type RemoteLockConsumerIdentifier = (); -} - -#[cfg(test)] -mod tests { - use super::*; - use crate::{ - millau_messages::{FromMillauMessageDispatch, XCM_LANE}, - WithMillauMessagesInstance, - }; - use bp_messages::{ - target_chain::{DispatchMessage, DispatchMessageData, MessageDispatch}, - LaneId, MessageKey, - }; - use bridge_runtime_common::messages_xcm_extension::XcmBlobMessageDispatchResult; - use codec::Encode; - use pallet_bridge_messages::OutboundLanes; - use sp_runtime::BuildStorage; - use xcm_executor::XcmExecutor; - - fn new_test_ext() -> sp_io::TestExternalities { - sp_io::TestExternalities::new( - frame_system::GenesisConfig::::default().build_storage().unwrap(), - ) - } - - fn prepare_outbound_xcm_message(destination: NetworkId) -> Xcm { - vec![ExportMessage { - network: destination, - destination: destination.into(), - xcm: vec![Instruction::Trap(42)].into(), - }] - .into() - } - - #[test] - fn xcm_messages_to_millau_are_sent_using_bridge_exporter() { - new_test_ext().execute_with(|| { - // ensure that the there are no messages queued - assert_eq!( - OutboundLanes::::get(XCM_LANE) - .latest_generated_nonce, - 0, - ); - - // export message instruction "sends" message to Rialto - XcmExecutor::::execute_xcm_in_credit( - Here, - prepare_outbound_xcm_message(MillauNetwork::get()), - Default::default(), - Weight::MAX, - Weight::MAX, - ) - .ensure_complete() - .expect("runtime configuration must be correct"); - - // ensure that the message has been queued - assert_eq!( - OutboundLanes::::get(XCM_LANE) - .latest_generated_nonce, - 1, - ); - }) - } - - fn prepare_inbound_bridge_message() -> DispatchMessage> { - let xcm = xcm::VersionedXcm::::V3(vec![Instruction::Trap(42)].into()); - let location = - xcm::VersionedInteriorMultiLocation::V3(X1(GlobalConsensus(ThisNetwork::get()))); - // this is the `BridgeMessage` from polkadot xcm builder, but it has no constructor - // or public fields, so just tuple - let bridge_message = (location, xcm).encode(); - DispatchMessage { - key: MessageKey { lane_id: LaneId([0, 0, 0, 0]), nonce: 1 }, - data: DispatchMessageData { payload: Ok(bridge_message) }, - } - } - - #[test] - fn xcm_messages_from_millau_are_dispatched() { - let incoming_message = prepare_inbound_bridge_message(); - - // we care only about handing message to the XCM dispatcher, so we don't care about its - // actual dispatch - let dispatch_result = FromMillauMessageDispatch::dispatch(incoming_message); - assert!(matches!( - dispatch_result.dispatch_level_result, - XcmBlobMessageDispatchResult::NotDispatched(_), - )); - } -} diff --git a/bin/runtime-common/src/lib.rs b/bin/runtime-common/src/lib.rs index ae6f40b142145..d3b3b21061d05 100644 --- a/bin/runtime-common/src/lib.rs +++ b/bin/runtime-common/src/lib.rs @@ -22,7 +22,6 @@ use crate::messages_call_ext::MessagesCallSubType; use pallet_bridge_grandpa::CallSubType as GrandpaCallSubType; use pallet_bridge_parachains::CallSubType as ParachainsCallSubtype; use sp_runtime::transaction_validity::TransactionValidity; -use xcm::v3::NetworkId; pub mod messages; pub mod messages_api; @@ -92,8 +91,8 @@ where /// ```nocompile /// generate_bridge_reject_obsolete_headers_and_messages!{ /// Call, AccountId -/// BridgeRialtoGrandpa, BridgeWestendGrandpa, -/// BridgeRialtoParachains +/// BridgeRococoGrandpa, BridgeRococoMessages, +/// BridgeRococoParachains /// } /// ``` /// @@ -147,42 +146,6 @@ macro_rules! generate_bridge_reject_obsolete_headers_and_messages { }; } -/// A mapping over `NetworkId`. -/// Since `NetworkId` doesn't include `Millau`, `Rialto` and `RialtoParachain`, we create some -/// synthetic associations between these chains and `NetworkId` chains. -pub enum CustomNetworkId { - /// The Millau network ID, associated with Kusama. - Millau, - /// The Rialto network ID, associated with Polkadot. - Rialto, - /// The RialtoParachain network ID, associated with Westend. - RialtoParachain, -} - -impl TryFrom for CustomNetworkId { - type Error = (); - - fn try_from(chain: bp_runtime::ChainId) -> Result { - Ok(match chain { - bp_runtime::MILLAU_CHAIN_ID => Self::Millau, - bp_runtime::RIALTO_CHAIN_ID => Self::Rialto, - bp_runtime::RIALTO_PARACHAIN_CHAIN_ID => Self::RialtoParachain, - _ => return Err(()), - }) - } -} - -impl CustomNetworkId { - /// Converts self to XCM' network id. - pub const fn as_network_id(&self) -> NetworkId { - match *self { - CustomNetworkId::Millau => NetworkId::Kusama, - CustomNetworkId::Rialto => NetworkId::Polkadot, - CustomNetworkId::RialtoParachain => NetworkId::Westend, - } - } -} - #[cfg(test)] mod tests { use crate::BridgeRuntimeFilterCall; diff --git a/bin/runtime-common/src/mock.rs b/bin/runtime-common/src/mock.rs index 45ef790d74482..943a98284a5e7 100644 --- a/bin/runtime-common/src/mock.rs +++ b/bin/runtime-common/src/mock.rs @@ -14,12 +14,7 @@ // You should have received a copy of the GNU General Public License // along with Parity Bridges Common. If not, see . -//! A mock runtime for testing different stuff in the crate. We've been using Millau -//! runtime for that before, but it has two drawbacks: -//! -//! - circular dependencies between this crate and Millau runtime; -//! -//! - we can't use (e.g. as git subtree or by copying) this crate in repo without Millau. +//! A mock runtime for testing different stuff in the crate. #![cfg(test)] diff --git a/bin/runtime-common/src/priority_calculator.rs b/bin/runtime-common/src/priority_calculator.rs index fd10344812517..a597fb9e2f492 100644 --- a/bin/runtime-common/src/priority_calculator.rs +++ b/bin/runtime-common/src/priority_calculator.rs @@ -27,6 +27,7 @@ use frame_support::traits::Get; use sp_runtime::transaction_validity::TransactionPriority; // reexport everything from `integrity_tests` module +#[allow(unused_imports)] pub use integrity_tests::*; /// Compute priority boost for message delivery transaction that delivers diff --git a/deployments/README.md b/deployments/README.md deleted file mode 100644 index 9747ed519fc29..0000000000000 --- a/deployments/README.md +++ /dev/null @@ -1,270 +0,0 @@ -# Bridge Deployments - -## Requirements - -Make sure to install `docker` and `docker-compose` to be able to run and test bridge deployments. If -for whatever reason you can't or don't want to use Docker, you can find some scripts for running the -bridge [here](./local-scripts/). - -## Networks - -One of the building blocks we use for our deployments are _networks_. A network is a collection of -homogenous blockchain nodes. We have Docker Compose files for each network that we want to bridge. -Each of the compose files found in the `./networks` folder is able to independently spin up a -network like so: - -```bash -docker-compose -f ./networks/rialto.yml up -``` - -After running this command we would have a network of several nodes producing blocks. - -## Bridges - -A _bridge_ is a way for several _networks_ to connect to one another. Bridge deployments have their -own Docker Compose files which can be found in the `./bridges` folder. These Compose files typically -contain bridge relayers, which are services external to blockchain nodes, and other components such -as testing infrastructure, or user interfaces. - -Unlike the network Compose files, these *cannot* be deployed on their own. They must be combined -with different networks. - -In general, we can deploy the bridge using `docker-compose up` in the following way: - -```bash -docker-compose -f .yml \ - -f .yml \ - -f .yml \ - -f .yml up -``` - -If you want to see how the Compose commands are actually run, check out the source code of the -[`./run.sh`](./run.sh). - -One thing worth noting is that we have a _monitoring_ Compose file. This adds support for Prometheus -and Grafana. We cover these in more details in the [Monitoring](#monitoring) section. At the moment -the monitoring Compose file is _not_ optional, and must be included for bridge deployments. - -### Running and Updating Deployments - -We currently support three bridge deployments -1. Rialto Substrate to Millau Substrate -2. Rialto Parachain Substrate to Millau Substrate -2. Westend Substrate to Millau Substrate (only finality bridge) - -These bridges can be deployed using our [`./run.sh`](./run.sh) script. - -The first argument it takes is the name of the bridge you want to run. Right now we only support three -bridges: `rialto-millau`, `rialto-parachain-millau` and `westend-millau`. - -```bash -./run.sh rialto-millau -``` - -If you add a second `update` argument to the script it will pull the latest images from Docker Hub -and restart the deployment. - -```bash -./run.sh rialto-millau update -``` - -You can also bring down a deployment using the script with the `stop` argument. - -```bash -./run.sh rialto-millau stop -``` - -### Adding Deployments - -We need two main things when adding a new deployment. First, the new network which we want to -bridge. A compose file for the network should be added in the `/networks/` folder. Secondly we'll -need a new bridge Compose file in `./bridges/`. This should configure the bridge relayer nodes -correctly for the two networks, and add any additional components needed for the deployment. If you -want you can also add support in the `./run.sh` script for the new deployment. While recommended it's -not strictly required. - -## General Notes - -Rialto authorities are named: `Alice`, `Bob`, `Charlie`, `Dave`, `Eve`. -Millau authorities are named: `Alice`, `Bob`, `Charlie`, `Dave`, `Eve`. -RialtoParachain authorities are named: `Alice`, `Bob`. - -`Sudo` is a sudo account on all chains. - -Both authorities and following accounts have enough funds (for test purposes) on corresponding Substrate chains: - -- on Rialto: `Ferdie`. -- on Millau: `Ferdie`. -- on RialtoParachain: `Charlie`, `Dave`, `Eve`, `Ferdie`. - -Names of accounts on Substrate (Rialto and Millau) chains may be prefixed with `//` and used as -seeds for the `sr25519` keys. This seed may also be used in the signer argument in Substrate relays. -Example: - -```bash -./substrate-relay relay-headers rialto-to-millau \ - --source-host rialto-node-alice \ - --source-port 9944 \ - --target-host millau-node-alice \ - --target-port 9944 \ - --source-signer //Ferdie \ - --prometheus-host=0.0.0.0 -``` - -Some accounts are used by bridge components. Using these accounts to sign other transactions -is not recommended, because this may lead to nonces conflict. - -Following accounts are used when `rialto-millau` bridge is running: - -- Millau's `Rialto.HeadersAndMessagesRelay1` signs complex headers+messages relay transactions on Millau chain; -- Rialto's `Millau.HeadersAndMessagesRelay1` signs complex headers+messages relay transactions on Rialto chain; -- Millau's `Rialto.MessagesSender` signs Millau transactions which contain messages for Rialto; -- Rialto's `Millau.MessagesSender` signs Rialto transactions which contain messages for Millau; -- Millau's `Rialto.OutboundMessagesRelay.Lane00000001` signs relay transactions with message delivery confirmations (lane 00000001) from Rialto to Millau; -- Rialto's `Millau.InboundMessagesRelay.Lane00000001` signs relay transactions with messages (lane 00000001) from Millau to Rialto; -- Millau's `Millau.OutboundMessagesRelay.Lane00000001` signs relay transactions with messages (lane 00000001) from Rialto to Millau; -- Rialto's `Rialto.InboundMessagesRelay.Lane00000001` signs relay transactions with message delivery confirmations (lane 00000001) from Millau to Rialto; -- Millau's `Rialto.MessagesOwner` signs relay transactions with updated Rialto -> Millau conversion rate; -- Rialto's `Millau.MessagesOwner` signs relay transactions with updated Millau -> Rialto conversion rate. - -Following accounts are used when `westend-millau` bridge is running: - -- Millau's `Westend.GrandpaOwner` is signing with-Westend GRANDPA pallet initialization transaction. -- Millau's `Westend.HeadersRelay1` and `Westend.HeadersRelay2` are signing transactions with new Westend headers. -- Millau's `Westend.AssetHubWestendHeaders1` and `Westend.AssetHubWestendHeaders2` is signing transactions with new Westming headers. - -Following accounts are used when `rialto-parachain-millau` bridge is running: - -- RialtoParachain's `Millau.MessagesSender` signs RialtoParachain transactions which contain messages for Millau; -- Millau's `RialtoParachain.MessagesSender` signs Millau transactions which contain messages for RialtoParachain; -- Millau's `RialtoParachain.HeadersAndMessagesRelay` signs complex headers+parachains+messages relay transactions on Millau chain; -- RialtoParachain's `Millau.HeadersAndMessagesRelay` signs complex headers+messages relay transactions on RialtoParachain chain. - -### Docker Usage - -When the network is running you can query logs from individual nodes using: - -```bash -docker logs rialto_millau-node-charlie_1 -f -``` - -You may use the [dump-logs.sh](../scripts/dump-logs.sh) to dump logs of most of running containers. - -To kill all leftover containers and start the network from scratch next time: -```bash -docker ps -a --format "{{.ID}}" | xargs docker rm # This removes all containers! -``` - -### Docker Compose Usage - -If you're not familiar with how to use `docker-compose` here are some useful commands you'll need -when interacting with the bridge deployments: - -```bash -docker-compose pull # Get the latest images from the Docker Hub -docker-compose build # This is going to build images -docker-compose up # Start all the nodes -docker-compose up -d # Start the nodes in detached mode. -docker-compose down # Stop the network. -``` - -Note that you'll also need to add the appropriate `-f` arguments that were mentioned in the -[Bridges](#bridges) section. You can read more about using multiple Compose files -[here](https://docs.docker.com/compose/extends/#multiple-compose-files). One thing worth noting is -that the _order_ the compose files are specified in matters. A different order will result in a -different configuration. - -You can sanity check the final config like so: - -```bash -docker-compose -f docker-compose.yml -f docker-compose.override.yml config > docker-compose.merged.yml -``` - -## Docker and Git Deployment - -It is also possible to avoid using images from the Docker Hub and instead build -containers from Git. There are two ways to build the images this way. - -### Git Repo - -If you have cloned the bridges repo you can build local Docker images by running the following -command at the top level of the repo: - -```bash -docker build . -t local/ --build-arg=PROJECT= -``` - -This will build a local image of a particular component with a tag of -`local/`. This tag can be used in Docker Compose files. - -You can configure the build using Docker -[build arguments](https://docs.docker.com/engine/reference/commandline/build/#set-build-time-variables---build-arg). -Here are the arguments currently supported: - - `PROJECT`: Project to build withing bridges repo. Can be one of: - - `rialto-bridge-node` - - `millau-bridge-node` - - `rialto-parachain-collator` - - `substrate-relay` - -You may use the [build-containers.sh](../scripts/build-containers.sh) script to build all available -containers. - -### GitHub Actions - -We have a nightly job which runs and publishes Docker images for the different nodes and relayers to -the [ParityTech Docker Hub](https://hub.docker.com/u/paritytech) organization. These images are used -for our ephemeral (temporary) test networks. Additionally, any time a tag in the form of `v*` is -pushed to GitHub the publishing job is run. This will build all the components (nodes, relayers) and -publish them. - -With images built using either method, all you have to do to use them in a deployment is change the -`image` field in the existing Docker Compose files to point to the tag of the image you want to use. - -### Monitoring - -[Prometheus](https://prometheus.io/) is used by the bridge relay to monitor information such as system -resource use, and block data (e.g the best blocks it knows about). In order to visualize this data -a [Grafana](https://grafana.com/) dashboard can be used. - -As part of the Rialto `docker-compose` setup we spin up a Prometheus server and Grafana dashboard. The -Prometheus server connects to the Prometheus data endpoint exposed by the bridge relay. The Grafana -dashboard uses the Prometheus server as its data source. - -The default port for the bridge relay's Prometheus data is `9616`. The host and port can be -configured though the `--prometheus-host` and `--prometheus-port` flags. The Prometheus server's -dashboard can be accessed at `http://localhost:9090`. The Grafana dashboard can be accessed at -`http://localhost:3000`. Note that the default log-in credentials for Grafana are `admin:admin`. - -### Environment Variables - -Here is an example `.env` file which is used for production deployments and network updates. For -security reasons it is not kept as part of version control. When deploying a network this -file should be correctly populated and kept in the appropriate [`bridges`](`./bridges`) deployment -folder. - -The `UI_SUBSTRATE_PROVIDER` variable lets you define the url of the Substrate node that the user -interface will connect to. `UI_ETHEREUM_PROVIDER` is used only as a guidance for users to connect -Metamask to the right Ethereum network. `UI_EXPECTED_ETHEREUM_NETWORK_ID` is used by -the user interface as a fail safe to prevent users from connecting their Metamask extension to an -unexpected network. - -```bash -GRAFANA_ADMIN_PASS=admin_pass -GRAFANA_SERVER_ROOT_URL=%(protocol)s://%(domain)s:%(http_port)s/ -GRAFANA_SERVER_DOMAIN=server.domain.io -MATRIX_ACCESS_TOKEN="access-token" -WITH_PROXY=1 # Optional -UI_SUBSTRATE_PROVIDER=ws://localhost:9944 -UI_ETHEREUM_PROVIDER=http://localhost:8545 -UI_EXPECTED_ETHEREUM_NETWORK_ID=105 -``` - -### UI - -Use [wss://wss.rialto.brucke.link](https://polkadot.js.org/apps/) as a custom endpoint for -[https://polkadot.js.org/apps/](https://polkadot.js.org/apps/). - -## Scripts - -There are some bash scripts in `scripts` folder that allow testing `Relay` -without running the entire network within docker. Use if needed for development. diff --git a/deployments/bridges/common/generate_messages.sh b/deployments/bridges/common/generate_messages.sh deleted file mode 100755 index 0987ff8987e71..0000000000000 --- a/deployments/bridges/common/generate_messages.sh +++ /dev/null @@ -1,65 +0,0 @@ -#!/bin/bash - -# Script for generating messages from a source chain to a target chain. -# Prerequisites: mounting the common folder in the docker container (Adding the following volume entry): -# - ./bridges/common:/common -# It can be used by executing `source /common/generate_messages.sh` in a different script, -# after setting the following variables: -# SOURCE_CHAIN -# TARGET_CHAIN -# MAX_SUBMIT_DELAY_S -# SEND_MESSAGE - the command that is executed to send a message -# SECONDARY_EXTRA_ARGS - optional, for example "--use-xcm-pallet" -# EXTRA_ARGS - for example "--use-xcm-pallet" -# REGULAR_PAYLOAD -# MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE - -SECONDARY_EXTRA_ARGS=${SECONDARY_EXTRA_ARGS:-""} - -trap "echo Exiting... TERM; exit $?" TERM - -# Sleep a bit between messages -rand_sleep() { - SUBMIT_DELAY_S=`shuf -i 0-$MAX_SUBMIT_DELAY_S -n 1` - echo "Sleeping $SUBMIT_DELAY_S seconds..." - sleep $SUBMIT_DELAY_S & wait $! - NOW=`date "+%Y-%m-%d %H:%M:%S"` - echo "Woke up at $NOW" -} - -# start sending large messages immediately -LARGE_MESSAGES_TIME=0 -# start sending message packs in a hour -BUNCH_OF_MESSAGES_TIME=3600 - -while true -do - rand_sleep - - # send regular message - echo "Sending Message from $SOURCE_CHAIN to $TARGET_CHAIN" - $SEND_MESSAGE $EXTRA_ARGS raw $REGULAR_PAYLOAD - - # every other hour we're sending 3 large (size, weight, size+weight) messages - if [ $SECONDS -ge $LARGE_MESSAGES_TIME ]; then - LARGE_MESSAGES_TIME=$((SECONDS + 7200)) - - rand_sleep - echo "Sending Maximal Size Message from $SOURCE_CHAIN to $TARGET_CHAIN" - $SEND_MESSAGE \ - sized max - fi - - # every other hour we're sending a bunch of small messages - if [ $SECONDS -ge $BUNCH_OF_MESSAGES_TIME ]; then - BUNCH_OF_MESSAGES_TIME=$((SECONDS + 7200)) - - for i in $(seq 0 $MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE); - do - $SEND_MESSAGE \ - $EXTRA_ARGS \ - raw $REGULAR_PAYLOAD - done - - fi -done diff --git a/deployments/bridges/rialto-millau/dashboard/grafana/relay-millau-to-rialto-messages-dashboard.json b/deployments/bridges/rialto-millau/dashboard/grafana/relay-millau-to-rialto-messages-dashboard.json deleted file mode 100644 index af8749325deb6..0000000000000 --- a/deployments/bridges/rialto-millau/dashboard/grafana/relay-millau-to-rialto-messages-dashboard.json +++ /dev/null @@ -1,1153 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "type": "dashboard" - } - ] - }, - "editable": true, - "gnetId": null, - "graphTooltip": 0, - "links": [], - "panels": [ - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 9, - "w": 12, - "x": 0, - "y": 0 - }, - "hiddenSeries": false, - "id": 2, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "Millau_to_Rialto_MessageLane_00000000_best_target_block_number", - "instant": false, - "interval": "", - "legendFormat": "At Rialto", - "refId": "A" - }, - { - "expr": "Millau_to_Rialto_MessageLane_00000000_best_target_at_source_block_number", - "instant": false, - "interval": "", - "legendFormat": "At Millau", - "refId": "B" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Best finalized Rialto headers", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 9, - "w": 12, - "x": 12, - "y": 0 - }, - "hiddenSeries": false, - "id": 4, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "Millau_to_Rialto_MessageLane_00000000_best_source_block_number", - "interval": "", - "legendFormat": "At Millau", - "refId": "A" - }, - { - "expr": "Millau_to_Rialto_MessageLane_00000000_best_source_at_target_block_number", - "interval": "", - "legendFormat": "At Rialto", - "refId": "B" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Best finalized Millau headers", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "Millau -> Rialto messages are not detected by relay", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 11, - "w": 12, - "x": 0, - "y": 9 - }, - "hiddenSeries": false, - "id": 6, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "label_replace(label_replace(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=~\"source_latest_generated|target_latest_received\"}, \"type\", \"Latest message sent from Rialto\", \"type\", \"source_latest_generated\"), \"type\", \"Latest Rialto message received by Millau\", \"type\", \"target_latest_received\")", - "interval": "", - "legendFormat": "{{type}}", - "refId": "A" - }, - { - "expr": "increase(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"source_latest_generated\"}[10m]) OR on() vector(0)", - "hide": true, - "interval": "", - "legendFormat": "Messages generated in last 5 minutes (Millau -> Rialto, 00000000)", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1, - "yaxis": "left" - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Delivery race (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 11, - "w": 12, - "x": 12, - "y": 9 - }, - "hiddenSeries": false, - "id": 8, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "label_replace(label_replace(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=~\"source_latest_confirmed|target_latest_received\"}, \"type\", \"Latest message confirmed by Rialto to Millau\", \"type\", \"source_latest_confirmed\"), \"type\", \"Latest Rialto message received by Millau\", \"type\", \"target_latest_received\")", - "interval": "", - "legendFormat": "{{type}}", - "refId": "A" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Confirmations race (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "1m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "sum" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "7m", - "frequency": "1m", - "handler": 1, - "name": "Messages from Millau to Rialto are not being delivered", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 0, - "y": 20 - }, - "hiddenSeries": false, - "id": 10, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"source_latest_generated\"}[2m])) - scalar(max_over_time(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"target_latest_received\"}[2m]))", - "format": "time_series", - "instant": false, - "interval": "", - "legendFormat": "Undelivered messages at Rialto", - "refId": "A" - }, - { - "expr": "increase(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"target_latest_received\"}[5m]) OR on() vector(0)", - "interval": "", - "legendFormat": "Millau Messages delivered to Rialto in last 5m", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1, - "yaxis": "left" - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Delivery race lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 50 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "Too many unconfirmed messages (Millau -> Rialto)", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 8, - "y": 20 - }, - "hiddenSeries": false, - "id": 12, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"target_latest_received\"}[2m]) OR on() vector(0)) - scalar(max_over_time(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"source_latest_confirmed\"}[2m]) OR on() vector(0))", - "interval": "", - "legendFormat": "Unconfirmed messages at Millau", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 10, - "yaxis": "left" - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Confirmations race lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 10 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "Rewards are not being confirmed (Millau -> Rialto messages)", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 16, - "y": 20 - }, - "hiddenSeries": false, - "id": 14, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"source_latest_confirmed\"}[2m])) - scalar(max_over_time(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"target_latest_confirmed\"}[2m]))", - "interval": "", - "legendFormat": "Unconfirmed rewards at Rialto", - "refId": "A" - }, - { - "expr": "(scalar(max_over_time(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"source_latest_confirmed\"}[2m]) OR on() vector(0)) - scalar(max_over_time(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"target_latest_confirmed\"}[2m]) OR on() vector(0))) * (max_over_time(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"target_latest_received\"}[2m]) > bool min_over_time(Millau_to_Rialto_MessageLane_00000000_lane_state_nonces{type=\"target_latest_received\"}[2m]))", - "interval": "", - "legendFormat": "Unconfirmed rewards at Millau->Rialto (zero if messages are not being delivered to Rialto)", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 10, - "yaxis": "left" - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Reward lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 8, - "x": 0, - "y": 38 - }, - "id": 16, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true - }, - "pluginVersion": "7.1.3", - "targets": [ - { - "expr": "avg_over_time(process_cpu_usage_percentage{instance='relay-millau-rialto:9616'}[1m])", - "instant": true, - "interval": "", - "legendFormat": "1 CPU = 100", - "refId": "A" - } - ], - "timeFrom": null, - "timeShift": null, - "title": "Relay process CPU usage (1 CPU = 100)", - "type": "gauge" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 8, - "x": 8, - "y": 38 - }, - "hiddenSeries": false, - "id": 18, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "system_average_load{instance='relay-millau-rialto:9616'}", - "interval": "", - "legendFormat": "Average system load in last {{over}}", - "refId": "A" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "System load average", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 8, - "x": 16, - "y": 38 - }, - "hiddenSeries": false, - "id": 20, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "process_memory_usage_bytes{instance='relay-millau-rialto:9616'} / 1024 / 1024", - "interval": "", - "legendFormat": "Process memory, MB", - "refId": "A" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Memory used by relay process", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - } - ], - "refresh": "5s", - "schemaVersion": 26, - "style": "dark", - "tags": [], - "templating": { - "list": [] - }, - "time": { - "from": "now-5m", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "Millau to Rialto Message Sync Dashboard", - "uid": "relay-millau-to-rialto-messages", - "version": 1 -} diff --git a/deployments/bridges/rialto-millau/dashboard/grafana/relay-rialto-to-millau-messages-dashboard.json b/deployments/bridges/rialto-millau/dashboard/grafana/relay-rialto-to-millau-messages-dashboard.json deleted file mode 100644 index efee749c5c15c..0000000000000 --- a/deployments/bridges/rialto-millau/dashboard/grafana/relay-rialto-to-millau-messages-dashboard.json +++ /dev/null @@ -1,1145 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "type": "dashboard" - } - ] - }, - "editable": true, - "gnetId": null, - "graphTooltip": 0, - "id": 4, - "links": [], - "panels": [ - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 9, - "w": 12, - "x": 0, - "y": 0 - }, - "hiddenSeries": false, - "id": 2, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "Rialto_to_Millau_MessageLane_00000000_best_target_block_number", - "instant": false, - "interval": "", - "legendFormat": "At Millau", - "refId": "A" - }, - { - "expr": "Rialto_to_Millau_MessageLane_00000000_best_target_at_source_block_number", - "instant": false, - "interval": "", - "legendFormat": "At Rialto", - "refId": "B" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Best finalized Millau headers", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 9, - "w": 12, - "x": 12, - "y": 0 - }, - "hiddenSeries": false, - "id": 4, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "Rialto_to_Millau_MessageLane_00000000_best_source_block_number", - "interval": "", - "legendFormat": "At Rialto", - "refId": "A" - }, - { - "expr": "Rialto_to_Millau_MessageLane_00000000_best_source_at_target_block_number", - "interval": "", - "legendFormat": "At Millau", - "refId": "B" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Best finalized Rialto headers", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "Rialto -> Millau messages are not detected by relay", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 11, - "w": 12, - "x": 0, - "y": 9 - }, - "hiddenSeries": false, - "id": 6, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "label_replace(label_replace(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=~\"source_latest_generated|target_latest_received\"}, \"type\", \"Latest message sent from Millau\", \"type\", \"source_latest_generated\"), \"type\", \"Latest message received by Rialto\", \"type\", \"target_latest_received\")", - "interval": "", - "legendFormat": "{{type}}", - "refId": "A" - }, - { - "expr": "increase(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"source_latest_generated\"}[10m]) OR on() vector(0)", - "hide": true, - "interval": "", - "legendFormat": "Messages generated in last 5 minutes (Rialto -> Millau, 00000000)", - "refId": "B" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Delivery race (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 11, - "w": 12, - "x": 12, - "y": 9 - }, - "hiddenSeries": false, - "id": 8, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "label_replace(label_replace(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=~\"source_latest_confirmed|target_latest_received\"}, \"type\", \"Latest message confirmed by Millau to Rialto\", \"type\", \"source_latest_confirmed\"), \"type\", \"Latest message received by Rialto\", \"type\", \"target_latest_received\")", - "interval": "", - "legendFormat": "{{type}}", - "refId": "A" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Confirmations race (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "1m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "sum" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "7m", - "frequency": "1m", - "handler": 1, - "name": "Messages from Rialto to Millau are not being delivered", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 0, - "y": 20 - }, - "hiddenSeries": false, - "id": 10, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"source_latest_generated\"}[2m])) - scalar(max_over_time(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"target_latest_received\"}[2m]))", - "format": "time_series", - "instant": false, - "interval": "", - "legendFormat": "Undelivered messages at Millau", - "refId": "A" - }, - { - "expr": "increase(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"target_latest_received\"}[5m]) OR on() vector(0)", - "interval": "", - "legendFormat": "Rialto Messages delivered to Millau in last 5m", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1, - "yaxis": "left" - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Delivery race lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 50 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "Too many unconfirmed messages (Rialto -> Millau)", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 8, - "y": 20 - }, - "hiddenSeries": false, - "id": 12, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"target_latest_received\"}[2m]) OR on() vector(0)) - scalar(max_over_time(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"source_latest_confirmed\"}[2m]) OR on() vector(0))", - "interval": "", - "legendFormat": "Unconfirmed messages at Rialto", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 10, - "yaxis": "left" - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Confirmations race lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 10 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "Rewards are not being confirmed (Rialto -> Millau messages)", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 16, - "y": 20 - }, - "hiddenSeries": false, - "id": 14, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"source_latest_confirmed\"}[2m])) - scalar(max_over_time(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"target_latest_confirmed\"}[2m]))", - "interval": "", - "legendFormat": "Unconfirmed rewards at Millau", - "refId": "A" - }, - { - "expr": "(scalar(max_over_time(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"source_latest_confirmed\"}[2m]) OR on() vector(0)) - scalar(max_over_time(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"target_latest_confirmed\"}[2m]) OR on() vector(0))) * (max_over_time(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"target_latest_received\"}[2m]) > bool min_over_time(Rialto_to_Millau_MessageLane_00000000_lane_state_nonces{type=\"target_latest_received\"}[2m]))", - "interval": "", - "legendFormat": "Unconfirmed rewards at Millau (zero if messages are not being delivered to Millau)", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 10, - "yaxis": "left" - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Reward lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 8, - "x": 0, - "y": 38 - }, - "id": 16, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true - }, - "pluginVersion": "7.1.3", - "targets": [ - { - "expr": "avg_over_time(process_cpu_usage_percentage{instance='relay-millau-rialto:9616'}[1m])", - "instant": true, - "interval": "", - "legendFormat": "1 CPU = 100", - "refId": "A" - } - ], - "timeFrom": null, - "timeShift": null, - "title": "Relay process CPU usage (1 CPU = 100)", - "type": "gauge" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 8, - "x": 8, - "y": 38 - }, - "hiddenSeries": false, - "id": 18, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "system_average_load{instance='relay-millau-rialto:9616'}", - "interval": "", - "legendFormat": "Average system load in last {{over}}", - "refId": "A" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "System load average", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 8, - "x": 16, - "y": 38 - }, - "hiddenSeries": false, - "id": 20, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "process_memory_usage_bytes{instance='relay-millau-rialto:9616'} / 1024 / 1024", - "interval": "", - "legendFormat": "Process memory, MB", - "refId": "A" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Memory used by relay process", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - } - ], - "refresh": "5s", - "schemaVersion": 26, - "style": "dark", - "tags": [], - "templating": { - "list": [] - }, - "time": { - "from": "now-5m", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "Rialto to Millau Message Sync Dashboard", - "uid": "relay-rialto-to-millau-messages", - "version": 2 -} diff --git a/deployments/bridges/rialto-millau/dashboard/grafana/rialto-millau-maintenance-dashboard.json b/deployments/bridges/rialto-millau/dashboard/grafana/rialto-millau-maintenance-dashboard.json deleted file mode 100644 index 4f134914f708c..0000000000000 --- a/deployments/bridges/rialto-millau/dashboard/grafana/rialto-millau-maintenance-dashboard.json +++ /dev/null @@ -1,635 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "editable": true, - "fiscalYearStartMonth": 0, - "gnetId": null, - "graphTooltip": 0, - "links": [], - "liveNow": false, - "panels": [ - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1000 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "last" - }, - "type": "query" - }, - { - "evaluator": { - "params": [ - 1000 - ], - "type": "lt" - }, - "operator": { - "type": "or" - }, - "query": { - "params": [ - "B", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "last" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "At-Rialto relay balances are too low", - "noDataState": "ok", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 0 - }, - "hiddenSeries": false, - "id": 8, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "at_Rialto_relay_MillauHeaders_balance", - "interval": "", - "legendFormat": "With-Millau headers relay account balance", - "refId": "A" - }, - { - "expr": "at_Rialto_relay_MillauMessages_balance", - "interval": "", - "legendFormat": "With-Millau messages relay account balance", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1000, - "visible": true - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Rialto relay balances", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1000 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "last" - }, - "type": "query" - }, - { - "evaluator": { - "params": [ - 1000 - ], - "type": "lt" - }, - "operator": { - "type": "or" - }, - "query": { - "params": [ - "B", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "last" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "At-Millau relay balances are too low", - "noDataState": "ok", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 0 - }, - "hiddenSeries": false, - "id": 9, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "at_Millau_relay_RialtoHeaders_balance{instance=\"relay-millau-rialto:9616\"}", - "interval": "", - "legendFormat": "With-Rialto headers relay account balance", - "refId": "A" - }, - { - "expr": "at_Millau_relay_RialtoMessages_balance", - "interval": "", - "legendFormat": "With-Rialto messages relay account balance", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1000, - "visible": true - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Millau relay balances", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "Whether with-Rialto-grandpa-pallet and Rialto itself are on different forks alert", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 8 - }, - "hiddenSeries": false, - "id": 11, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "Rialto_to_Millau_MessageLane_00000000_is_source_and_source_at_target_using_different_forks OR on() vector(0)", - "interval": "", - "legendFormat": "On different forks?", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 0, - "visible": true - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Whether with-Rialto-grandpa-pallet and Rialto itself are on different forks", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "Whether with-Rialto-grandpa-pallet and Rialto itself are on different forks alert", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 8 - }, - "hiddenSeries": false, - "id": 12, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "Millau_to_Rialto_MessageLane_00000000_is_source_and_source_at_target_using_different_forks OR on() vector(0)", - "interval": "", - "legendFormat": "On different forks?", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 0, - "visible": true - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Whether with-Millau-grandpa-pallet and Millau itself are on different forks", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - } - ], - "refresh": "10s", - "schemaVersion": 32, - "style": "dark", - "tags": [], - "templating": { - "list": [] - }, - "time": { - "from": "now-15m", - "to": "now" - }, - "timepicker": {}, - "timezone": "", - "title": "Rialto+Millau maintenance dashboard", - "uid": "7AuyrjlMz", - "version": 1 -} diff --git a/deployments/bridges/rialto-millau/dashboard/prometheus/targets.yml b/deployments/bridges/rialto-millau/dashboard/prometheus/targets.yml deleted file mode 100644 index dab53624b6143..0000000000000 --- a/deployments/bridges/rialto-millau/dashboard/prometheus/targets.yml +++ /dev/null @@ -1,4 +0,0 @@ -- targets: - - relay-millau-rialto:9616 - - detect-millau-to-rialto-equivocations:9616 - - detect-rialto-to-millau-equivocations:9616 diff --git a/deployments/bridges/rialto-millau/docker-compose.yml b/deployments/bridges/rialto-millau/docker-compose.yml deleted file mode 100644 index 17225f60db24d..0000000000000 --- a/deployments/bridges/rialto-millau/docker-compose.yml +++ /dev/null @@ -1,109 +0,0 @@ -# Exposed ports: 10000-10005 - -version: '3.5' -services: - # We provide overrides for these particular nodes since they are public facing - # nodes which we use to connect from things like Polkadot JS Apps. - rialto-node-charlie: - environment: - VIRTUAL_HOST: wss.rialto.brucke.link - VIRTUAL_PORT: 9944 - LETSENCRYPT_HOST: wss.rialto.brucke.link - LETSENCRYPT_EMAIL: admin@parity.io - - millau-node-charlie: - environment: - VIRTUAL_HOST: wss.millau.brucke.link - VIRTUAL_PORT: 9944 - LETSENCRYPT_HOST: wss.millau.brucke.link - LETSENCRYPT_EMAIL: admin@parity.io - - relay-millau-rialto: &sub-bridge-relay - image: ${SUBSTRATE_RELAY_IMAGE:-paritytech/substrate-relay} - entrypoint: /entrypoints/relay-millau-rialto-entrypoint.sh - volumes: - - ./bridges/common:/common - - ./bridges/rialto-millau/entrypoints:/entrypoints - environment: - RUST_LOG: rpc=trace,bridge=trace - GLOBAL_DEPLOYMENTS: $GLOBAL_DEPLOYMENTS - ports: - - "10000:9616" - depends_on: &all-nodes - - millau-node-alice - - millau-node-bob - - millau-node-charlie - - millau-node-dave - - millau-node-eve - - rialto-node-alice - - rialto-node-bob - - rialto-node-charlie - - rialto-node-dave - - rialto-node-eve - - rialto-node-ferdie - - relay-messages-millau-to-rialto-generator: - <<: *sub-bridge-relay - environment: - RUST_LOG: bridge=trace - entrypoint: /entrypoints/relay-messages-to-rialto-generator-entrypoint.sh - ports: - - "10001:9616" - depends_on: - - relay-millau-rialto - - relay-messages-millau-to-rialto-resubmitter: - <<: *sub-bridge-relay - environment: - RUST_LOG: bridge=trace - entrypoint: /entrypoints/relay-messages-to-rialto-resubmitter-entrypoint.sh - ports: - - "10002:9616" - depends_on: - - relay-messages-millau-to-rialto-generator - - relay-messages-rialto-to-millau-generator: - <<: *sub-bridge-relay - environment: - RUST_LOG: bridge=trace - entrypoint: /entrypoints/relay-messages-to-millau-generator-entrypoint.sh - ports: - - "10003:9616" - depends_on: - - relay-millau-rialto - - detect-millau-to-rialto-equivocations: - <<: *sub-bridge-relay - environment: - RUST_LOG: bridge=trace - entrypoint: /entrypoints/detect-millau-to-rialto-equivocations-entrypoint.sh - ports: - - "10004:9616" - depends_on: - - relay-millau-rialto - - detect-rialto-to-millau-equivocations: - <<: *sub-bridge-relay - environment: - RUST_LOG: bridge=trace - entrypoint: /entrypoints/detect-rialto-to-millau-equivocations-entrypoint.sh - ports: - - "10005:9616" - depends_on: - - relay-millau-rialto - - # Note: These are being overridden from the top level `monitoring` compose file. - grafana-dashboard: - environment: - VIRTUAL_HOST: grafana.millau.brucke.link,grafana.rialto.brucke.link - VIRTUAL_PORT: 3000 - LETSENCRYPT_HOST: grafana.millau.brucke.link,grafana.rialto.brucke.link - LETSENCRYPT_EMAIL: admin@parity.io - volumes: - - ./bridges/rialto-millau/dashboard/grafana:/etc/grafana/dashboards/rialto-millau:ro - - ./networks/dashboard/grafana/beefy-dashboard.json:/etc/grafana/dashboards/beefy.json - - prometheus-metrics: - volumes: - - ./bridges/rialto-millau/dashboard/prometheus/targets.yml:/etc/prometheus/targets-rialto-millau.yml - depends_on: *all-nodes diff --git a/deployments/bridges/rialto-millau/entrypoints/detect-millau-to-rialto-equivocations-entrypoint.sh b/deployments/bridges/rialto-millau/entrypoints/detect-millau-to-rialto-equivocations-entrypoint.sh deleted file mode 100755 index 71498fc0295a6..0000000000000 --- a/deployments/bridges/rialto-millau/entrypoints/detect-millau-to-rialto-equivocations-entrypoint.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/bin/bash -set -eu - -sleep 15 - -exec /home/user/substrate-relay detect-equivocations millau-to-rialto \ - --source-host millau-node-alice \ - --source-port 9944 \ - --source-signer //Rialto.HeadersAndMessagesRelay \ - --source-transactions-mortality=64 \ - --target-host rialto-node-alice \ - --target-port 9944 \ - --prometheus-host=0.0.0.0 diff --git a/deployments/bridges/rialto-millau/entrypoints/detect-rialto-to-millau-equivocations-entrypoint.sh b/deployments/bridges/rialto-millau/entrypoints/detect-rialto-to-millau-equivocations-entrypoint.sh deleted file mode 100755 index 158a99c0af950..0000000000000 --- a/deployments/bridges/rialto-millau/entrypoints/detect-rialto-to-millau-equivocations-entrypoint.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/bin/bash -set -eu - -sleep 15 - -exec /home/user/substrate-relay detect-equivocations rialto-to-millau \ - --source-host rialto-node-alice \ - --source-port 9944 \ - --source-signer //Millau.HeadersAndMessagesRelay \ - --source-transactions-mortality=64 \ - --target-host millau-node-alice \ - --target-port 9944 \ - --prometheus-host=0.0.0.0 diff --git a/deployments/bridges/rialto-millau/entrypoints/relay-messages-millau-to-rialto-entrypoint.sh b/deployments/bridges/rialto-millau/entrypoints/relay-messages-millau-to-rialto-entrypoint.sh deleted file mode 100755 index 3a55cc782caa7..0000000000000 --- a/deployments/bridges/rialto-millau/entrypoints/relay-messages-millau-to-rialto-entrypoint.sh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/bash -set -xeu - -sleep 15 - -MESSAGE_LANE=${MSG_EXCHANGE_GEN_LANE:-00000000} - -/home/user/substrate-relay relay-messages millau-to-rialto \ - --lane $MESSAGE_LANE \ - --source-host millau-node-bob \ - --source-port 9944 \ - --source-signer //Rialto.OutboundMessagesRelay.Lane00000001 \ - --target-host rialto-node-bob \ - --target-port 9944 \ - --target-signer //Millau.InboundMessagesRelay.Lane00000001 \ - --prometheus-host=0.0.0.0 diff --git a/deployments/bridges/rialto-millau/entrypoints/relay-messages-rialto-to-millau-entrypoint.sh b/deployments/bridges/rialto-millau/entrypoints/relay-messages-rialto-to-millau-entrypoint.sh deleted file mode 100755 index 145cd20100d2b..0000000000000 --- a/deployments/bridges/rialto-millau/entrypoints/relay-messages-rialto-to-millau-entrypoint.sh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/bash -set -xeu - -sleep 15 - -MESSAGE_LANE=${MSG_EXCHANGE_GEN_LANE:-00000000} - -/home/user/substrate-relay relay-messages rialto-to-millau \ - --lane $MESSAGE_LANE \ - --source-host rialto-node-bob \ - --source-port 9944 \ - --source-signer //Millau.OutboundMessagesRelay.Lane00000001 \ - --target-host millau-node-bob \ - --target-port 9944 \ - --target-signer //Rialto.InboundMessagesRelay.Lane00000001 \ - --prometheus-host=0.0.0.0 diff --git a/deployments/bridges/rialto-millau/entrypoints/relay-messages-to-millau-generator-entrypoint.sh b/deployments/bridges/rialto-millau/entrypoints/relay-messages-to-millau-generator-entrypoint.sh deleted file mode 100755 index a36538ea5155d..0000000000000 --- a/deployments/bridges/rialto-millau/entrypoints/relay-messages-to-millau-generator-entrypoint.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/bash - -# THIS SCRIPT IS NOT INTENDED FOR USE IN PRODUCTION ENVIRONMENT -# -# This scripts periodically calls the Substrate relay binary to generate messages. These messages -# are sent from the Rialto network to the Millau network. - -set -eu - -# Max delay before submitting transactions (s) -MAX_SUBMIT_DELAY_S=${MSG_EXCHANGE_GEN_MAX_SUBMIT_DELAY_S:-30} -MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE=1024 - -SHARED_CMD="/home/user/substrate-relay send-message rialto-to-millau" -SHARED_HOST="--source-host rialto-node-bob --source-port 9944" -SOURCE_SIGNER="--source-signer //Millau.MessagesSender" - -SEND_MESSAGE="$SHARED_CMD $SHARED_HOST $SOURCE_SIGNER" - -SOURCE_CHAIN="Rialto" -TARGET_CHAIN="Millau" -EXTRA_ARGS="" -# It is the encoded `xcm::VersionedXcm::V3(prepare_outbound_xcm_message(MillauNetwork::get())` -# from the `xcm_messages_to_millau_are_sent_using_bridge_exporter` test in the `rialto-runtime` -REGULAR_PAYLOAD="030426030109030419a8" - -source /common/generate_messages.sh diff --git a/deployments/bridges/rialto-millau/entrypoints/relay-messages-to-rialto-generator-entrypoint.sh b/deployments/bridges/rialto-millau/entrypoints/relay-messages-to-rialto-generator-entrypoint.sh deleted file mode 100755 index dacb5615229cc..0000000000000 --- a/deployments/bridges/rialto-millau/entrypoints/relay-messages-to-rialto-generator-entrypoint.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/bash - -# THIS SCRIPT IS NOT INTENDED FOR USE IN PRODUCTION ENVIRONMENT -# -# This scripts periodically calls the Substrate relay binary to generate messages. These messages -# are sent from the Millau network to the Rialto network. - -set -eu - -# Max delay before submitting transactions (s) -MAX_SUBMIT_DELAY_S=${MSG_EXCHANGE_GEN_MAX_SUBMIT_DELAY_S:-30} -MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE=128 - -SHARED_CMD=" /home/user/substrate-relay send-message millau-to-rialto" -SHARED_HOST="--source-host millau-node-bob --source-port 9944" -SOURCE_SIGNER="--source-signer //Rialto.MessagesSender" - -SEND_MESSAGE="$SHARED_CMD $SHARED_HOST $SOURCE_SIGNER" - -SOURCE_CHAIN="Millau" -TARGET_CHAIN="Rialto" -EXTRA_ARGS="" -# It is the encoded `xcm::VersionedXcm::V3(prepare_outbound_xcm_message(RialtoNetwork::get())` -# from the `xcm_messages_to_rialto_are_sent_using_bridge_exporter` test in the `millau-runtime` -REGULAR_PAYLOAD="030426020109020419a8" - -source /common/generate_messages.sh diff --git a/deployments/bridges/rialto-millau/entrypoints/relay-messages-to-rialto-resubmitter-entrypoint.sh b/deployments/bridges/rialto-millau/entrypoints/relay-messages-to-rialto-resubmitter-entrypoint.sh deleted file mode 100755 index bd9bf800ad48b..0000000000000 --- a/deployments/bridges/rialto-millau/entrypoints/relay-messages-to-rialto-resubmitter-entrypoint.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/bash -set -xeu - -sleep 15 - -# //Rialto.MessagesSender is signing Millau -> Rialto message-send transactions, which are causing problems. -# -# When large message is being sent from Millau to Rialto AND other transactions are -# blocking it from being mined, we'll see something like this in logs: -# -# Millau transaction priority with tip=0: 17800827994. Target priority: -# 526186677695 -# -# So since fee multiplier in Millau is `1` and `WeightToFee` is `IdentityFee`, then -# we need tip around `526186677695 - 17800827994 = 508_385_849_701`. Let's round it -# up to `1_000_000_000_000`. - -/home/user/substrate-relay resubmit-transactions millau \ - --target-host millau-node-alice \ - --target-port 9944 \ - --target-signer //Rialto.MessagesSender \ - --stalled-blocks 5 \ - --tip-limit 1000000000000 \ - --tip-step 1000000000 \ - make-it-best-transaction diff --git a/deployments/bridges/rialto-millau/entrypoints/relay-millau-rialto-entrypoint.sh b/deployments/bridges/rialto-millau/entrypoints/relay-millau-rialto-entrypoint.sh deleted file mode 100755 index a1306984bca5c..0000000000000 --- a/deployments/bridges/rialto-millau/entrypoints/relay-millau-rialto-entrypoint.sh +++ /dev/null @@ -1,37 +0,0 @@ -#!/bin/bash -set -xeu - -sleep 15 - -/home/user/substrate-relay init-bridge millau-to-rialto \ - --source-host millau-node-alice \ - --source-port 9944 \ - --target-host rialto-node-alice \ - --target-port 9944 \ - --target-signer //Sudo - -/home/user/substrate-relay init-bridge rialto-to-millau \ - --source-host rialto-node-alice \ - --source-port 9944 \ - --target-host millau-node-alice \ - --target-port 9944 \ - --target-signer //Sudo - -# Give chain a little bit of time to process initialization transaction -sleep 6 - -RIALTO_NODE_CONNECTION_PARAMS=$([ -z ${GLOBAL_DEPLOYMENTS} ] && \ - echo "--rialto-host rialto-node-alice --rialto-port 9944" \ - || \ - echo "--rialto-host wss.rialto.brucke.link --rialto-port 443 --rialto-secure" ) - -/home/user/substrate-relay relay-headers-and-messages millau-rialto \ - --millau-host millau-node-alice \ - --millau-port 9944 \ - --millau-signer //Rialto.HeadersAndMessagesRelay \ - --millau-transactions-mortality=64 \ - $RIALTO_NODE_CONNECTION_PARAMS \ - --rialto-signer //Millau.HeadersAndMessagesRelay \ - --rialto-transactions-mortality=64 \ - --lane=00000000 \ - --prometheus-host=0.0.0.0 diff --git a/deployments/bridges/rialto-parachain-millau/dashboard/grafana/relay-millau-to-rialto-parachain-messages-dashboard.json b/deployments/bridges/rialto-parachain-millau/dashboard/grafana/relay-millau-to-rialto-parachain-messages-dashboard.json deleted file mode 100644 index b20348cc51311..0000000000000 --- a/deployments/bridges/rialto-parachain-millau/dashboard/grafana/relay-millau-to-rialto-parachain-messages-dashboard.json +++ /dev/null @@ -1,910 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "type": "dashboard" - } - ] - }, - "editable": true, - "gnetId": null, - "graphTooltip": 0, - "links": [], - "panels": [ - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 9, - "w": 12, - "x": 0, - "y": 0 - }, - "hiddenSeries": false, - "id": 2, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "Millau_to_RialtoParachain_MessageLane_00000000_best_target_block_number{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "instant": false, - "interval": "", - "legendFormat": "At RialtoParachain", - "refId": "A" - }, - { - "expr": "Millau_to_RialtoParachain_MessageLane_00000000_best_target_at_source_block_number{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "instant": false, - "interval": "", - "legendFormat": "At Millau", - "refId": "B" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Best finalized RialtoParachain headers", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 9, - "w": 12, - "x": 12, - "y": 0 - }, - "hiddenSeries": false, - "id": 4, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "Millau_to_RialtoParachain_MessageLane_00000000_best_source_block_number{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "interval": "", - "legendFormat": "At Millau", - "refId": "A" - }, - { - "expr": "Millau_to_RialtoParachain_MessageLane_00000000_best_source_at_target_block_number{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "interval": "", - "legendFormat": "At RialtoParachain", - "refId": "B" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Best finalized Millau headers", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "Millau -> RialtoParachain messages are not detected by relay", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 11, - "w": 12, - "x": 0, - "y": 9 - }, - "hiddenSeries": false, - "id": 6, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "label_replace(label_replace(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=~\"source_latest_generated|target_latest_received\"}, \"type\", \"Latest message sent from RialtoParachain\", \"type\", \"source_latest_generated\"), \"type\", \"Latest RialtoParachain message received by Millau\", \"type\", \"target_latest_received\")", - "interval": "", - "legendFormat": "{{type}}", - "refId": "A" - }, - { - "expr": "increase(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"source_latest_generated\"}[10m]) OR on() vector(0)", - "hide": true, - "interval": "", - "legendFormat": "Messages generated in last 5 minutes (Millau -> RialtoParachain, 00000000)", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1, - "yaxis": "left" - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Delivery race (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 11, - "w": 12, - "x": 12, - "y": 9 - }, - "hiddenSeries": false, - "id": 8, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "label_replace(label_replace(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=~\"source_latest_confirmed|target_latest_received\"}, \"type\", \"Latest message confirmed by RialtoParachain to Millau\", \"type\", \"source_latest_confirmed\"), \"type\", \"Latest RialtoParachain message received by Millau\", \"type\", \"target_latest_received\")", - "interval": "", - "legendFormat": "{{type}}", - "refId": "A" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Confirmations race (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "1m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "sum" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "7m", - "frequency": "1m", - "handler": 1, - "name": "Messages from Millau to RialtoParachain are not being delivered", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 0, - "y": 20 - }, - "hiddenSeries": false, - "id": 10, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"source_latest_generated\"}[2m])) - scalar(max_over_time(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_received\"}[2m]))", - "format": "time_series", - "instant": false, - "interval": "", - "legendFormat": "Undelivered messages at RialtoParachain", - "refId": "A" - }, - { - "expr": "increase(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_received\"}[5m]) OR on() vector(0)", - "interval": "", - "legendFormat": "Millau Messages delivered to RialtoParachain in last 5m", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1 - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Delivery race lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 50 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "Too many unconfirmed messages (Millau -> RialtoParachain)", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 8, - "y": 20 - }, - "hiddenSeries": false, - "id": 12, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_received\"}[2m]) OR on() vector(0)) - scalar(max_over_time(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"source_latest_confirmed\"}[2m]) OR on() vector(0))", - "interval": "", - "legendFormat": "Unconfirmed messages at Millau", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 10 - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Confirmations race lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 10 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "Rewards are not being confirmed (Millau -> RialtoParachain messages)", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 16, - "y": 20 - }, - "hiddenSeries": false, - "id": 14, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"source_latest_confirmed\"}[2m])) - scalar(max_over_time(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_confirmed\"}[2m]))", - "interval": "", - "legendFormat": "Unconfirmed rewards at RialtoParachain", - "refId": "A" - }, - { - "expr": "(scalar(max_over_time(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"source_latest_confirmed\"}[2m]) OR on() vector(0)) - scalar(max_over_time(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_confirmed\"}[2m]) OR on() vector(0))) * (max_over_time(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_received\"}[2m]) > bool min_over_time(Millau_to_RialtoParachain_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_received\"}[2m]))", - "interval": "", - "legendFormat": "Unconfirmed rewards at Millau->RaltoParachain (zero if messages are not being delivered to RialtoParachain)", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 10, - "yaxis": "left" - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Reward lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - } - ], - "refresh": "5s", - "schemaVersion": 26, - "style": "dark", - "tags": [], - "templating": { - "list": [] - }, - "time": { - "from": "now-5m", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "Millau to RialtoParachain Message Sync Dashboard", - "uid": "C61e-797z", - "version": 1 -} diff --git a/deployments/bridges/rialto-parachain-millau/dashboard/grafana/relay-rialto-parachain-to-millau-messages-dashboard.json b/deployments/bridges/rialto-parachain-millau/dashboard/grafana/relay-rialto-parachain-to-millau-messages-dashboard.json deleted file mode 100644 index 064436145de30..0000000000000 --- a/deployments/bridges/rialto-parachain-millau/dashboard/grafana/relay-rialto-parachain-to-millau-messages-dashboard.json +++ /dev/null @@ -1,908 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "type": "dashboard" - } - ] - }, - "editable": true, - "gnetId": null, - "graphTooltip": 0, - "links": [], - "panels": [ - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 9, - "w": 12, - "x": 0, - "y": 0 - }, - "hiddenSeries": false, - "id": 2, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "RialtoParachain_to_Millau_MessageLane_00000000_best_target_block_number{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "instant": false, - "interval": "", - "legendFormat": "At Millau", - "refId": "A" - }, - { - "expr": "RialtoParachain_to_Millau_MessageLane_00000000_best_target_at_source_block_number{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "instant": false, - "interval": "", - "legendFormat": "At RialtoParachain", - "refId": "B" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Best finalized Millau headers", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 9, - "w": 12, - "x": 12, - "y": 0 - }, - "hiddenSeries": false, - "id": 4, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "RialtoParachain_to_Millau_MessageLane_00000000_best_source_block_number{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "interval": "", - "legendFormat": "At RialtoParachain", - "refId": "A" - }, - { - "expr": "RialtoParachain_to_Millau_MessageLane_00000000_best_source_at_target_block_number{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "interval": "", - "legendFormat": "At Millau", - "refId": "B" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Best finalized RialtoParachain headers", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "RialtoParachain -> Millau messages are not detected by relay", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 11, - "w": 12, - "x": 0, - "y": 9 - }, - "hiddenSeries": false, - "id": 6, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "label_replace(label_replace(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=~\"source_latest_generated|target_latest_received\"}, \"type\", \"Latest message sent from Millau\", \"type\", \"source_latest_generated\"), \"type\", \"Latest Millau message received by RialtoParachain\", \"type\", \"target_latest_received\")", - "interval": "", - "legendFormat": "{{type}}", - "refId": "A" - }, - { - "expr": "increase(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"source_latest_generated\"}[10m]) OR on() vector(0)", - "hide": true, - "interval": "", - "legendFormat": "Messages generated in last 5 minutes (RialtoParachain -> Millau, 00000000)", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1 - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Delivery race (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 11, - "w": 12, - "x": 12, - "y": 9 - }, - "hiddenSeries": false, - "id": 8, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "label_replace(label_replace(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=~\"source_latest_confirmed|target_latest_received\"}, \"type\", \"Latest message confirmed by Millau to RialtoParachain\", \"type\", \"source_latest_confirmed\"), \"type\", \"Latest Millau message received by RialtoParachain\", \"type\", \"target_latest_received\")", - "interval": "", - "legendFormat": "{{type}}", - "refId": "A" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Confirmations race (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "1m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "sum" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "7m", - "frequency": "1m", - "handler": 1, - "name": "Messages from RialtoParachain to Millau are not being delivered", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 0, - "y": 20 - }, - "hiddenSeries": false, - "id": 10, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"source_latest_generated\"}[2m])) - scalar(max_over_time(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_received\"}[2m]))", - "format": "time_series", - "instant": false, - "interval": "", - "legendFormat": "Undelivered messages at Millau", - "refId": "A" - }, - { - "expr": "increase(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_received\"}[5m]) OR on() vector(0)", - "interval": "", - "legendFormat": "RialtoParachain Messages delivered to Millau in last 5m", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1 - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Delivery race lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 50 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "Too many unconfirmed messages (RialtoParachain -> Millau)", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 8, - "y": 20 - }, - "hiddenSeries": false, - "id": 12, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_received\"}[2m]) OR on() vector(0)) - scalar(max_over_time(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"source_latest_confirmed\"}[2m]) OR on() vector(0))", - "interval": "", - "legendFormat": "Unconfirmed messages at RialtoParachain", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 10 - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Confirmations race lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 10 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "20m", - "frequency": "1m", - "handler": 1, - "name": "Rewards are not being confirmed (RialtoParachain -> Millau messages)", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 16, - "y": 20 - }, - "hiddenSeries": false, - "id": 14, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "scalar(max_over_time(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"source_latest_confirmed\"}[2m])) - scalar(max_over_time(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_confirmed\"}[2m]))", - "interval": "", - "legendFormat": "Unconfirmed rewards at Millau", - "refId": "A" - }, - { - "expr": "(scalar(max_over_time(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"source_latest_confirmed\"}[2m]) OR on() vector(0)) - scalar(max_over_time(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_confirmed\"}[2m]) OR on() vector(0))) * (max_over_time(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_received\"}[2m]) > bool min_over_time(RialtoParachain_to_Millau_MessageLane_00000000_lane_state_nonces{instance=\"relay-millau-rialto-parachain-1:9616\",type=\"target_latest_received\"}[2m]))", - "interval": "", - "legendFormat": "Unconfirmed rewards at Millau (zero if messages are not being delivered to Millau)", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 10 - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Reward lags (00000000)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - } - ], - "refresh": "5s", - "schemaVersion": 26, - "style": "dark", - "tags": [], - "templating": { - "list": [] - }, - "time": { - "from": "now-5m", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "RialtoParachain to Millau Message Sync Dashboard", - "uid": "-l61a7r7k", - "version": 1 -} diff --git a/deployments/bridges/rialto-parachain-millau/dashboard/grafana/rialto-parachain-millau-maintenance-dashboard.json b/deployments/bridges/rialto-parachain-millau/dashboard/grafana/rialto-parachain-millau-maintenance-dashboard.json deleted file mode 100644 index ca22a6dadd07a..0000000000000 --- a/deployments/bridges/rialto-parachain-millau/dashboard/grafana/rialto-parachain-millau-maintenance-dashboard.json +++ /dev/null @@ -1,627 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "editable": true, - "fiscalYearStartMonth": 0, - "gnetId": null, - "graphTooltip": 0, - "links": [], - "liveNow": false, - "panels": [ - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1000 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "last" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "At-Rialto relay balances are too low", - "noDataState": "ok", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 0 - }, - "hiddenSeries": false, - "id": 10, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "exemplar": true, - "expr": "at_RialtoParachain_relay_MillauMessages_balance{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "instant": false, - "interval": "", - "legendFormat": "With-Millau relay account balance", - "refId": "A" - }, - { - "exemplar": true, - "expr": "at_RialtoParachain_relay_MillauMessages_reward_for_msgs_from_Millau_on_lane_00000000{instance=\"relay-millau-rialto-parachain-1:9616\"} + at_RialtoParachain_relay_MillauMessages_reward_for_msgs_to_Millau_on_lane_00000000{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "hide": false, - "instant": false, - "interval": "", - "legendFormat": "With-Millau relay account reward", - "refId": "B" - }, - { - "exemplar": true, - "expr": "at_RialtoParachain_relay_MillauMessages_balance{instance=\"relay-millau-rialto-parachain-1:9616\"} + at_RialtoParachain_relay_MillauMessages_reward_for_msgs_from_Millau_on_lane_00000000{instance=\"relay-millau-rialto-parachain-1:9616\"} + at_RialtoParachain_relay_MillauMessages_reward_for_msgs_to_Millau_on_lane_00000000{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "hide": false, - "interval": "", - "legendFormat": "With-Millau relay account total balance (balance + reward)", - "refId": "C" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1000, - "visible": true - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "RialtoParachain relay balances", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1000 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "last" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "At-Millau relay balances are too low", - "noDataState": "ok", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 0 - }, - "hiddenSeries": false, - "id": 12, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "exemplar": true, - "expr": "at_Millau_relay_RialtoParachainMessages_balance{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "interval": "", - "legendFormat": "With-Rialto relay account balance", - "refId": "A" - }, - { - "exemplar": true, - "expr": "at_Millau_relay_RialtoParachainMessages_reward_for_msgs_from_RialtoParachain_on_lane_00000000{instance=\"relay-millau-rialto-parachain-1:9616\"} + at_Millau_relay_RialtoParachainMessages_reward_for_msgs_to_RialtoParachain_on_lane_00000000{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "hide": false, - "interval": "", - "legendFormat": "With-Rialto relay account reward", - "refId": "B" - }, - { - "exemplar": true, - "expr": "at_Millau_relay_RialtoParachainMessages_balance{instance=\"relay-millau-rialto-parachain-1:9616\"} + at_Millau_relay_RialtoParachainMessages_reward_for_msgs_from_RialtoParachain_on_lane_00000000{instance=\"relay-millau-rialto-parachain-1:9616\"} + at_Millau_relay_RialtoParachainMessages_reward_for_msgs_to_RialtoParachain_on_lane_00000000{instance=\"relay-millau-rialto-parachain-1:9616\"}", - "hide": false, - "interval": "", - "legendFormat": "With-Rialto relay account total balance (balance + reward)", - "refId": "C" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1000, - "visible": true - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Millau relay balances", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "Whether with-RialtoParachain-parachains-pallet and Rialto itself are on different forks alert", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 8 - }, - "hiddenSeries": false, - "id": 14, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "RialtoParachain_to_Millau_MessageLane_00000000_is_source_and_source_at_target_using_different_forks{instance=\"relay-millau-rialto-parachain-1:9616\"} OR on() vector(0)", - "instant": false, - "interval": "", - "legendFormat": "On different forks?", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 0, - "visible": true - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Whether with-RialtoParachain-parachains-pallet and RialtoParachain itself are on different forks", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "Whether with-Millau-grandpa-pallet and Millau itself are on different forks", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 8 - }, - "hiddenSeries": false, - "id": 16, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "Millau_to_RialtoParachain_MessageLane_00000000_is_source_and_source_at_target_using_different_forks{instance=\"relay-millau-rialto-parachain-1:9616\"} OR on() vector(0)", - "interval": "", - "legendFormat": "On different forks?", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 0, - "visible": true - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Whether with-Millau-grandpa-pallet and Millau itself are on different forks", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - } - ], - "refresh": "5s", - "schemaVersion": 32, - "style": "dark", - "tags": [], - "templating": { - "list": [] - }, - "time": { - "from": "now-15m", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "RialtoParachain+Millau maintenance dashboard", - "uid": "WALc3ajnk", - "version": 1 -} diff --git a/deployments/bridges/rialto-parachain-millau/dashboard/prometheus/targets.yml b/deployments/bridges/rialto-parachain-millau/dashboard/prometheus/targets.yml deleted file mode 100644 index 9dd79afe6911d..0000000000000 --- a/deployments/bridges/rialto-parachain-millau/dashboard/prometheus/targets.yml +++ /dev/null @@ -1,5 +0,0 @@ -- targets: - - relay-millau-rialto-parachain-1:9616 - - relay-millau-rialto-parachain-2:9616 - - detect-millau-to-rialto-parachain-equivocations:9616 - - detect-rialto-to-millau-equivocations:9616 diff --git a/deployments/bridges/rialto-parachain-millau/docker-compose.yml b/deployments/bridges/rialto-parachain-millau/docker-compose.yml deleted file mode 100644 index 0efa05c2ab523..0000000000000 --- a/deployments/bridges/rialto-parachain-millau/docker-compose.yml +++ /dev/null @@ -1,110 +0,0 @@ -# Exposed ports: 10100-10106 - -version: '3.5' -services: - # We provide overrides for these particular nodes since they are public facing - # nodes which we use to connect from things like Polkadot JS Apps. - rialto-parachain-collator-charlie: - environment: - VIRTUAL_HOST: wss.rialto-parachain.brucke.link - VIRTUAL_PORT: 9944 - LETSENCRYPT_HOST: wss.rialto-parachain.brucke.link - LETSENCRYPT_EMAIL: admin@parity.io - - millau-node-charlie: - environment: - VIRTUAL_HOST: wss.millau.brucke.link - VIRTUAL_PORT: 9944 - LETSENCRYPT_HOST: wss.millau.brucke.link - LETSENCRYPT_EMAIL: admin@parity.io - - relay-millau-rialto-parachain-1: &sub-bridge-relay - image: ${SUBSTRATE_RELAY_IMAGE:-paritytech/substrate-relay} - entrypoint: /entrypoints/relay-millau-rialto-parachain-entrypoint.sh - volumes: - - ./bridges/common:/common - - ./bridges/rialto-parachain-millau/entrypoints:/entrypoints - environment: - RUST_LOG: rpc=trace,bridge=trace - ports: - - "10100:9616" - depends_on: &all-nodes - - millau-node-alice - - millau-node-bob - - millau-node-charlie - - millau-node-dave - - millau-node-eve - - rialto-parachain-collator-alice - - rialto-parachain-collator-bob - - rialto-parachain-collator-charlie - - relay-millau-rialto-parachain-2: - <<: *sub-bridge-relay - environment: - RUST_LOG: rpc=trace,bridge=trace - EXT_MILLAU_RELAY_ACCOUNT: //RialtoParachain.HeadersAndMessagesRelay2 - EXT_MILLAU_RELAY_ACCOUNT_HEADERS_OVERRIDE: //RialtoParachain.RialtoHeadersRelay2 - EXT_RIALTO_PARACHAIN_RELAY_ACCOUNT: //Millau.HeadersAndMessagesRelay2 - ports: - - "10101:9616" - relay-messages-millau-to-rialto-parachain-generator: - <<: *sub-bridge-relay - ports: - - "10102:9616" - entrypoint: /entrypoints/relay-messages-to-rialto-parachain-generator-entrypoint.sh - depends_on: - - relay-millau-rialto-parachain-1 - - relay-messages-rialto-parachain-to-millau-generator: - <<: *sub-bridge-relay - entrypoint: /entrypoints/relay-messages-to-millau-generator-entrypoint.sh - ports: - - "10103:9616" - depends_on: - - relay-millau-rialto-parachain-1 - - relay-messages-millau-to-rialto-parachain-resubmitter: - <<: *sub-bridge-relay - environment: - RUST_LOG: bridge=trace - entrypoint: /entrypoints/relay-messages-to-rialto-parachain-resubmitter-entrypoint.sh - ports: - - "10104:9616" - depends_on: - - relay-messages-millau-to-rialto-parachain-generator - - detect-millau-to-rialto-parachain-equivocations: - <<: *sub-bridge-relay - environment: - RUST_LOG: bridge=trace - entrypoint: /entrypoints/detect-millau-to-rialto-parachain-equivocations-entrypoint.sh - ports: - - "10105:9616" - depends_on: - - relay-millau-rialto-parachain-1 - - detect-rialto-to-millau-equivocations: - <<: *sub-bridge-relay - environment: - RUST_LOG: bridge=trace - entrypoint: /entrypoints/detect-rialto-to-millau-equivocations-entrypoint.sh - ports: - - "10106:9616" - depends_on: - - relay-millau-rialto-parachain-1 - - # Note: These are being overridden from the top level `monitoring` compose file. - grafana-dashboard: - environment: - VIRTUAL_HOST: grafana.millau.brucke.link,grafana.rialto.brucke.link - VIRTUAL_PORT: 3000 - LETSENCRYPT_HOST: grafana.millau.brucke.link,grafana.rialto.brucke.link - LETSENCRYPT_EMAIL: admin@parity.io - volumes: - - ./bridges/rialto-parachain-millau/dashboard/grafana:/etc/grafana/dashboards/rialto-parachain-millau:ro - - ./networks/dashboard/grafana/beefy-dashboard.json:/etc/grafana/dashboards/beefy.json - - prometheus-metrics: - volumes: - - ./bridges/rialto-parachain-millau/dashboard/prometheus/targets.yml:/etc/prometheus/targets-rialto-parachain-millau.yml - depends_on: *all-nodes diff --git a/deployments/bridges/rialto-parachain-millau/entrypoints/detect-millau-to-rialto-parachain-equivocations-entrypoint.sh b/deployments/bridges/rialto-parachain-millau/entrypoints/detect-millau-to-rialto-parachain-equivocations-entrypoint.sh deleted file mode 100755 index 366e4222a8c19..0000000000000 --- a/deployments/bridges/rialto-parachain-millau/entrypoints/detect-millau-to-rialto-parachain-equivocations-entrypoint.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/bin/bash -set -eu - -sleep 15 - -exec /home/user/substrate-relay detect-equivocations millau-to-rialto-parachain \ - --source-host millau-node-alice \ - --source-port 9944 \ - --source-signer //RialtoParachain.HeadersAndMessagesRelay1 \ - --source-transactions-mortality=64 \ - --target-host rialto-parachain-collator-charlie \ - --target-port 9944 \ - --prometheus-host=0.0.0.0 diff --git a/deployments/bridges/rialto-parachain-millau/entrypoints/detect-rialto-to-millau-equivocations-entrypoint.sh b/deployments/bridges/rialto-parachain-millau/entrypoints/detect-rialto-to-millau-equivocations-entrypoint.sh deleted file mode 100755 index 158a99c0af950..0000000000000 --- a/deployments/bridges/rialto-parachain-millau/entrypoints/detect-rialto-to-millau-equivocations-entrypoint.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/bin/bash -set -eu - -sleep 15 - -exec /home/user/substrate-relay detect-equivocations rialto-to-millau \ - --source-host rialto-node-alice \ - --source-port 9944 \ - --source-signer //Millau.HeadersAndMessagesRelay \ - --source-transactions-mortality=64 \ - --target-host millau-node-alice \ - --target-port 9944 \ - --prometheus-host=0.0.0.0 diff --git a/deployments/bridges/rialto-parachain-millau/entrypoints/relay-messages-to-millau-generator-entrypoint.sh b/deployments/bridges/rialto-parachain-millau/entrypoints/relay-messages-to-millau-generator-entrypoint.sh deleted file mode 100755 index c09116a16146f..0000000000000 --- a/deployments/bridges/rialto-parachain-millau/entrypoints/relay-messages-to-millau-generator-entrypoint.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/bash - -# THIS SCRIPT IS NOT INTENDED FOR USE IN PRODUCTION ENVIRONMENT -# -# This scripts periodically calls the Substrate relay binary to generate messages. These messages -# are sent from the Rialto network to the Millau network. - -set -eu - -# Max delay before submitting transactions (s) -MAX_SUBMIT_DELAY_S=${MSG_EXCHANGE_GEN_MAX_SUBMIT_DELAY_S:-30} -MESSAGE_LANE=${MSG_EXCHANGE_GEN_LANE:-00000000} -MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE=1024 - -SHARED_CMD="/home/user/substrate-relay send-message rialto-parachain-to-millau" -SHARED_HOST="--source-host rialto-parachain-collator-bob --source-port 9944" -SOURCE_SIGNER="--source-signer //Millau.MessagesSender" - -SEND_MESSAGE="$SHARED_CMD $SHARED_HOST $SOURCE_SIGNER" - -SOURCE_CHAIN="RialtoParachain" -TARGET_CHAIN="Millau" -EXTRA_ARGS="" -# It is the encoded `xcm::VersionedXcm::V3(prepare_outbound_xcm_message(MillauNetwork::get())` -# from the `xcm_messages_to_millau_are_sent_using_bridge_exporter` test in the `rialto-parachain-runtime` -REGULAR_PAYLOAD="030426030109030419a8" - -source /common/generate_messages.sh diff --git a/deployments/bridges/rialto-parachain-millau/entrypoints/relay-messages-to-rialto-parachain-generator-entrypoint.sh b/deployments/bridges/rialto-parachain-millau/entrypoints/relay-messages-to-rialto-parachain-generator-entrypoint.sh deleted file mode 100755 index dbf14ef18bcdd..0000000000000 --- a/deployments/bridges/rialto-parachain-millau/entrypoints/relay-messages-to-rialto-parachain-generator-entrypoint.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/bash - -# THIS SCRIPT IS NOT INTENDED FOR USE IN PRODUCTION ENVIRONMENT -# -# This scripts periodically calls the Substrate relay binary to generate messages. These messages -# are sent from the Millau network to the Rialto network. - -set -eu - -# Max delay before submitting transactions (s) -MAX_SUBMIT_DELAY_S=${MSG_EXCHANGE_GEN_MAX_SUBMIT_DELAY_S:-30} -MAX_UNCONFIRMED_MESSAGES_AT_INBOUND_LANE=1024 - -SHARED_CMD=" /home/user/substrate-relay send-message millau-to-rialto-parachain" -SHARED_HOST="--source-host millau-node-bob --source-port 9944" -SOURCE_SIGNER="--source-signer //RialtoParachain.MessagesSender" - -SEND_MESSAGE="$SHARED_CMD $SHARED_HOST $SOURCE_SIGNER" - -SOURCE_CHAIN="Millau" -TARGET_CHAIN="RialtoParachain" -EXTRA_ARGS="" -# It is the encoded `xcm::VersionedXcm::V3(prepare_outbound_xcm_message(RialtoParachainNetwork::get())` -# from the `xcm_messages_to_rialto_parachain_are_sent_using_bridge_exporter` test in the `millau-runtime` -REGULAR_PAYLOAD="030426040109040419a8" - -source /common/generate_messages.sh diff --git a/deployments/bridges/rialto-parachain-millau/entrypoints/relay-messages-to-rialto-parachain-resubmitter-entrypoint.sh b/deployments/bridges/rialto-parachain-millau/entrypoints/relay-messages-to-rialto-parachain-resubmitter-entrypoint.sh deleted file mode 100755 index 4653ae396c6d4..0000000000000 --- a/deployments/bridges/rialto-parachain-millau/entrypoints/relay-messages-to-rialto-parachain-resubmitter-entrypoint.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/bash -set -xeu - -sleep 15 - -# //RialtoParachain.MessagesSender is signing Millau -> RialtoParachain message-send transactions, which are causing problems. -# -# When large message is being sent from Millau to RialtoParachain AND other transactions are -# blocking it from being mined, we'll see something like this in logs: -# -# Millau transaction priority with tip=0: 17800827994. Target priority: -# 526186677695 -# -# So since fee multiplier in Millau is `1` and `WeightToFee` is `IdentityFee`, then -# we need tip around `526186677695 - 17800827994 = 508_385_849_701`. Let's round it -# up to `1_000_000_000_000`. - -exec /home/user/substrate-relay resubmit-transactions millau \ - --target-host millau-node-alice \ - --target-port 9944 \ - --target-signer //RialtoParachain.MessagesSender \ - --stalled-blocks 7 \ - --tip-limit 1000000000000 \ - --tip-step 1000000000 \ - make-it-best-transaction diff --git a/deployments/bridges/rialto-parachain-millau/entrypoints/relay-millau-rialto-parachain-entrypoint.sh b/deployments/bridges/rialto-parachain-millau/entrypoints/relay-millau-rialto-parachain-entrypoint.sh deleted file mode 100755 index 7685f5f5ec2b9..0000000000000 --- a/deployments/bridges/rialto-parachain-millau/entrypoints/relay-millau-rialto-parachain-entrypoint.sh +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/bash -set -xeu - -sleep 15 - -MILLAU_RELAY_ACCOUNT=${EXT_MILLAU_RELAY_ACCOUNT:-//RialtoParachain.HeadersAndMessagesRelay1} -MILLAU_RELAY_ACCOUNT_HEADERS_OVERRIDE=${EXT_MILLAU_RELAY_ACCOUNT_HEADERS_OVERRIDE:-//RialtoParachain.RialtoHeadersRelay1} -RIALTO_PARACHAIN_RELAY_ACCOUNT=${EXT_RIALTO_PARACHAIN_RELAY_ACCOUNT:-//Millau.HeadersAndMessagesRelay1} - -/home/user/substrate-relay init-bridge millau-to-rialto-parachain \ - --source-host millau-node-alice \ - --source-port 9944 \ - --target-host rialto-parachain-collator-alice \ - --target-port 9944 \ - --target-signer //Sudo - -/home/user/substrate-relay init-bridge rialto-to-millau \ - --source-host rialto-node-alice \ - --source-port 9944 \ - --target-host millau-node-alice \ - --target-port 9944 \ - --target-signer //Sudo - -# Give chain a little bit of time to process initialization transaction -sleep 6 - -exec /home/user/substrate-relay relay-headers-and-messages millau-rialto-parachain \ - --millau-host millau-node-alice \ - --millau-port 9944 \ - --millau-signer $MILLAU_RELAY_ACCOUNT \ - --millau-transactions-mortality=64 \ - --rialto-parachain-host rialto-parachain-collator-charlie \ - --rialto-parachain-port 9944 \ - --rialto-parachain-signer $RIALTO_PARACHAIN_RELAY_ACCOUNT \ - --rialto-parachain-transactions-mortality=64 \ - --rialto-host rialto-node-alice \ - --rialto-port 9944 \ - --lane=00000000 \ - --prometheus-host=0.0.0.0 diff --git a/deployments/bridges/westend-millau/dashboard/grafana/relay-westend-to-millau-headers-dashboard.json b/deployments/bridges/westend-millau/dashboard/grafana/relay-westend-to-millau-headers-dashboard.json deleted file mode 100644 index 8f740d2ba5e4c..0000000000000 --- a/deployments/bridges/westend-millau/dashboard/grafana/relay-westend-to-millau-headers-dashboard.json +++ /dev/null @@ -1,781 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "type": "dashboard" - } - ] - }, - "editable": true, - "gnetId": null, - "graphTooltip": 0, - "links": [], - "panels": [ - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 32 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "60m", - "frequency": "5m", - "handler": 1, - "message": "", - "name": "Synced Header Difference is Over 32 (Westend to Millau)", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "description": "Shows how many headers behind the target chain is from the source chain.", - "fieldConfig": { - "defaults": { - "custom": {} - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 0 - }, - "hiddenSeries": false, - "id": 14, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "max(Westend_to_Millau_Sync_best_source_block_number) - max(Westend_to_Millau_Sync_best_source_at_target_block_number)", - "format": "table", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 5 - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Difference Between Source and Target Headers", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 32 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "2m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "60m", - "frequency": "5m", - "handler": 1, - "name": "No New Headers (Westend to Millau)", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "description": "How many headers has the relay synced from the source node in the last 2 mins?", - "fieldConfig": { - "defaults": { - "custom": {} - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 0 - }, - "hiddenSeries": false, - "id": 16, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "max_over_time(Westend_to_Millau_Sync_best_source_block_number[10m])-min_over_time(Westend_to_Millau_Sync_best_source_block_number[10m])", - "interval": "", - "legendFormat": "Number of new Headers on Westend (Last 10 Mins)", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 5 - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Headers Synced on Millau (Last 2 Mins)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": { - "align": null - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 8 - }, - "id": 2, - "interval": "5s", - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "7.1.3", - "targets": [ - { - "expr": "Westend_to_Millau_Sync_best_source_block_number", - "format": "time_series", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Best Known Westend Header at Westend", - "refId": "A" - }, - { - "expr": "Westend_to_Millau_Sync_best_source_at_target_block_number", - "format": "time_series", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Best Known Westend Header at Millau", - "refId": "B" - } - ], - "timeFrom": null, - "timeShift": null, - "title": "Best Blocks according to Relay", - "type": "stat" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "description": "", - "fieldConfig": { - "defaults": { - "custom": {} - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 6, - "x": 12, - "y": 8 - }, - "hiddenSeries": false, - "id": 6, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "system_average_load{instance='relay-headers-westend-to-millau-1:9616'}", - "interval": "", - "legendFormat": "Average system load in last {{over}}", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": null - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Average System Load", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {}, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 6, - "x": 18, - "y": 8 - }, - "id": 12, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true - }, - "pluginVersion": "7.1.3", - "targets": [ - { - "expr": "avg_over_time(process_cpu_usage_percentage{instance='relay-headers-westend-to-millau-1:9616'}[1m])", - "instant": true, - "interval": "", - "legendFormat": "1 CPU = 100", - "refId": "A" - } - ], - "timeFrom": null, - "timeShift": null, - "title": "Relay Process CPU Usage ", - "type": "gauge" - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "Whether with-Westend-grandpa-pallet and Westend itself are on different forks alert", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {} - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 10, - "w": 12, - "x": 0, - "y": 14 - }, - "hiddenSeries": false, - "id": 18, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "Westend_to_Millau_Sync_is_source_and_source_at_target_using_different_forks", - "interval": "", - "legendFormat": "On different forks?", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 0 - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Whether with-Westend-grandpa-pallet and Westend itself are on different forks", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "description": "", - "fieldConfig": { - "defaults": { - "custom": {} - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 16 - }, - "hiddenSeries": false, - "id": 10, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "process_memory_usage_bytes{instance='relay-headers-westend-to-millau-1:9616'} / 1024 / 1024", - "interval": "", - "legendFormat": "Process memory, MB", - "refId": "A" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Memory Usage for Relay Process", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - } - ], - "refresh": "5s", - "schemaVersion": 26, - "style": "dark", - "tags": [], - "templating": { - "list": [] - }, - "time": { - "from": "now-5m", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "Westend to Millau Header Sync Dashboard", - "uid": "relay-westend-to-millau-headers", - "version": 1 -} diff --git a/deployments/bridges/westend-millau/dashboard/grafana/relay-westend-to-millau-parachains-dashboard.json b/deployments/bridges/westend-millau/dashboard/grafana/relay-westend-to-millau-parachains-dashboard.json deleted file mode 100644 index 1ab05d6d8273f..0000000000000 --- a/deployments/bridges/westend-millau/dashboard/grafana/relay-westend-to-millau-parachains-dashboard.json +++ /dev/null @@ -1,200 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "type": "dashboard" - } - ] - }, - "editable": true, - "gnetId": null, - "graphTooltip": 0, - "id": 9, - "links": [], - "panels": [ - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 32 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "C", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "Too many AssetHubWestend headers are missing at Millau", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "custom": {} - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 9, - "w": 12, - "x": 0, - "y": 0 - }, - "hiddenSeries": false, - "id": 2, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "percentage": false, - "pluginVersion": "7.1.3", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "Westend_to_Millau_Parachains_1000_best_parachain_block_number_at_source", - "interval": "", - "legendFormat": "At Westend", - "refId": "A" - }, - { - "expr": "Westend_to_Millau_Parachains_1000_best_parachain_block_number_at_target", - "interval": "", - "legendFormat": "At Millau", - "refId": "B" - }, - { - "expr": "Westend_to_Millau_Parachains_1000_best_parachain_block_number_at_source - Westend_to_Millau_Parachains_1000_best_parachain_block_number_at_target", - "hide": true, - "interval": "", - "legendFormat": "Missing AssetHubWestend headers at Millau", - "refId": "C" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 32 - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "AssetHubWestend headers", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - } - ], - "refresh": "5s", - "schemaVersion": 26, - "style": "dark", - "tags": [], - "templating": { - "list": [] - }, - "time": { - "from": "now-5m", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "Westend parachains at Millau", - "uid": "vUMhOlq7k", - "version": 1 - } - \ No newline at end of file diff --git a/deployments/bridges/westend-millau/dashboard/prometheus/targets.yml b/deployments/bridges/westend-millau/dashboard/prometheus/targets.yml deleted file mode 100644 index aed2d49458251..0000000000000 --- a/deployments/bridges/westend-millau/dashboard/prometheus/targets.yml +++ /dev/null @@ -1,3 +0,0 @@ -- targets: - - relay-headers-westend-to-millau-1:9616 - - relay-parachains-westend-to-millau-1:9616 \ No newline at end of file diff --git a/deployments/bridges/westend-millau/docker-compose.yml b/deployments/bridges/westend-millau/docker-compose.yml deleted file mode 100644 index f339c61f69469..0000000000000 --- a/deployments/bridges/westend-millau/docker-compose.yml +++ /dev/null @@ -1,72 +0,0 @@ -# Exposed ports: 10200-10203 - -version: '3.5' -services: - relay-headers-westend-to-millau-1: - image: ${SUBSTRATE_RELAY_IMAGE:-paritytech/substrate-relay} - entrypoint: /entrypoints/relay-headers-westend-to-millau-entrypoint.sh - volumes: - - ./bridges/westend-millau/entrypoints:/entrypoints - environment: - RUST_LOG: rpc=trace,bridge=trace - ports: - - "10200:9616" - depends_on: - - millau-node-alice - - relay-headers-westend-to-millau-2: - image: ${SUBSTRATE_RELAY_IMAGE:-paritytech/substrate-relay} - entrypoint: /entrypoints/relay-headers-westend-to-millau-entrypoint.sh - volumes: - - ./bridges/westend-millau/entrypoints:/entrypoints - environment: - RUST_LOG: rpc=trace,bridge=trace - EXT_RELAY_ACCOUNT: //Westend.HeadersRelay2 - ports: - - "10201:9616" - depends_on: - - millau-node-alice - - relay-parachains-westend-to-millau-1: - image: ${SUBSTRATE_RELAY_IMAGE:-paritytech/substrate-relay} - entrypoint: /entrypoints/relay-parachains-westend-to-millau-entrypoint.sh - volumes: - - ./bridges/westend-millau/entrypoints:/entrypoints - environment: - RUST_LOG: rpc=trace,bridge=trace - ports: - - "10202:9616" - depends_on: - - millau-node-alice - - relay-parachains-westend-to-millau-2: - image: ${SUBSTRATE_RELAY_IMAGE:-paritytech/substrate-relay} - entrypoint: /entrypoints/relay-parachains-westend-to-millau-entrypoint.sh - volumes: - - ./bridges/westend-millau/entrypoints:/entrypoints - environment: - RUST_LOG: rpc=trace,bridge=trace - EXT_RELAY_ACCOUNT: //Westend.AssetHubWestendHeaders2 - ports: - - "10203:9616" - depends_on: - - millau-node-alice - - # Note: These are being overridden from the top level `monitoring` compose file. - grafana-dashboard: - environment: - VIRTUAL_HOST: grafana.millau.brucke.link,grafana.rialto.brucke.link - VIRTUAL_PORT: 3000 - LETSENCRYPT_HOST: grafana.millau.brucke.link,grafana.rialto.brucke.link - LETSENCRYPT_EMAIL: admin@parity.io - volumes: - - ./bridges/westend-millau/dashboard/grafana:/etc/grafana/dashboards/westend-millau:ro - - prometheus-metrics: - volumes: - - ./bridges/westend-millau/dashboard/prometheus/targets.yml:/etc/prometheus/targets-westend-millau.yml - depends_on: - - relay-headers-westend-to-millau-1 - - relay-headers-westend-to-millau-2 - - relay-parachains-westend-to-millau-1 - - relay-parachains-westend-to-millau-2 diff --git a/deployments/bridges/westend-millau/entrypoints/relay-headers-westend-to-millau-entrypoint.sh b/deployments/bridges/westend-millau/entrypoints/relay-headers-westend-to-millau-entrypoint.sh deleted file mode 100755 index 8548e9f5a41cc..0000000000000 --- a/deployments/bridges/westend-millau/entrypoints/relay-headers-westend-to-millau-entrypoint.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/bash -set -xeu - -sleep 15 - -RELAY_ACCOUNT=${EXT_RELAY_ACCOUNT:-//Westend.HeadersRelay1} - -/home/user/substrate-relay init-bridge westend-to-millau \ - --source-host westend-rpc.polkadot.io \ - --source-port 443 \ - --source-secure \ - --target-host millau-node-alice \ - --target-port 9944 \ - --target-signer //Westend.GrandpaOwner - -# Give chain a little bit of time to process initialization transaction -sleep 6 -/home/user/substrate-relay relay-headers westend-to-millau \ - --source-host westend-rpc.polkadot.io \ - --source-port 443 \ - --source-secure \ - --target-host millau-node-alice \ - --target-port 9944 \ - --target-signer $RELAY_ACCOUNT \ - --target-transactions-mortality=4\ - --prometheus-host=0.0.0.0 diff --git a/deployments/bridges/westend-millau/entrypoints/relay-parachains-westend-to-millau-entrypoint.sh b/deployments/bridges/westend-millau/entrypoints/relay-parachains-westend-to-millau-entrypoint.sh deleted file mode 100755 index 4a2c11d9af1f3..0000000000000 --- a/deployments/bridges/westend-millau/entrypoints/relay-parachains-westend-to-millau-entrypoint.sh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/bash -set -xeu - -sleep 15 - -RELAY_ACCOUNT=${EXT_RELAY_ACCOUNT:-//Westend.AssetHubWestendHeaders1} - -/home/user/substrate-relay relay-parachains westend-to-millau \ - --source-host westend-rpc.polkadot.io \ - --source-port 443 \ - --source-secure \ - --target-host millau-node-alice \ - --target-port 9944 \ - --target-signer $RELAY_ACCOUNT \ - --target-transactions-mortality=4\ - --prometheus-host=0.0.0.0 diff --git a/deployments/local-scripts/bridge-entrypoint.sh b/deployments/local-scripts/bridge-entrypoint.sh index 5c1b6e90ec27f..da099222bac20 100755 --- a/deployments/local-scripts/bridge-entrypoint.sh +++ b/deployments/local-scripts/bridge-entrypoint.sh @@ -3,5 +3,5 @@ set -xeu # This will allow us to run whichever binary the user wanted # with arguments passed through `docker run` -# e.g `docker run -it rialto-bridge-node-dev --dev --tmp` +# e.g `docker run -it substrate-relay --dev --tmp` /home/user/$PROJECT $@ diff --git a/deployments/local-scripts/relay-messages-millau-to-rialto.sh b/deployments/local-scripts/relay-messages-millau-to-rialto.sh deleted file mode 100755 index d420dc56c263f..0000000000000 --- a/deployments/local-scripts/relay-messages-millau-to-rialto.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/bash -# A script for relaying Millau messages to the Rialto chain. -# -# Will not work unless both the Rialto and Millau are running (see `run-rialto-node.sh` -# and `run-millau-node.sh). -set -xeu - -MILLAU_PORT="${MILLAU_PORT:-9945}" -RIALTO_PORT="${RIALTO_PORT:-9944}" - -RUST_LOG=bridge=debug \ -./target/debug/substrate-relay relay-messages millau-to-rialto \ - --lane 00000000 \ - --source-host localhost \ - --source-port $MILLAU_PORT \ - --source-signer //Bob \ - --target-host localhost \ - --target-port $RIALTO_PORT \ - --target-signer //Bob \ - --prometheus-host=0.0.0.0 diff --git a/deployments/local-scripts/relay-messages-rialto-to-millau.sh b/deployments/local-scripts/relay-messages-rialto-to-millau.sh deleted file mode 100755 index 0cd73c00454d9..0000000000000 --- a/deployments/local-scripts/relay-messages-rialto-to-millau.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/bash -# A script for relaying Rialto messages to the Millau chain. -# -# Will not work unless both the Rialto and Millau are running (see `run-rialto-node.sh` -# and `run-millau-node.sh). -set -xeu - -MILLAU_PORT="${MILLAU_PORT:-9945}" -RIALTO_PORT="${RIALTO_PORT:-9944}" - -RUST_LOG=bridge=debug \ -./target/debug/substrate-relay relay-messages rialto-to-millau \ - --lane 00000000 \ - --source-host localhost \ - --source-port $RIALTO_PORT \ - --source-signer //Bob \ - --target-host localhost \ - --target-port $MILLAU_PORT \ - --target-signer //Bob \ - --prometheus-host=0.0.0.0 diff --git a/deployments/local-scripts/relay-millau-to-rialto.sh b/deployments/local-scripts/relay-millau-to-rialto.sh deleted file mode 100755 index 4758173f72f72..0000000000000 --- a/deployments/local-scripts/relay-millau-to-rialto.sh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/bash - -# A script for relaying Millau headers to the Rialto chain. -# -# Will not work unless both the Rialto and Millau are running (see `run-rialto-node.sh` -# and `run-millau-node.sh). - -MILLAU_PORT="${MILLAU_PORT:-9945}" -RIALTO_PORT="${RIALTO_PORT:-9944}" - -RUST_LOG=bridge=debug \ -./target/debug/substrate-relay init-bridge millau-to-rialto \ - --source-host localhost \ - --source-port $MILLAU_PORT \ - --target-host localhost \ - --target-port $RIALTO_PORT \ - --target-signer //Sudo \ - --source-version-mode Bundle \ - --target-version-mode Bundle - -sleep 5 -RUST_LOG=bridge=debug \ -./target/debug/substrate-relay relay-headers millau-to-rialto \ - --source-host localhost \ - --source-port $MILLAU_PORT \ - --target-host localhost \ - --target-port $RIALTO_PORT \ - --target-signer //Alice \ - --prometheus-host=0.0.0.0 diff --git a/deployments/local-scripts/relay-rialto-to-millau.sh b/deployments/local-scripts/relay-rialto-to-millau.sh deleted file mode 100755 index 5fd2784021452..0000000000000 --- a/deployments/local-scripts/relay-rialto-to-millau.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/bash - -# A script for relaying Rialto headers to the Millau chain. -# -# Will not work unless both the Rialto and Millau are running (see `run-rialto-node.sh` -# and `run-millau-node.sh). - -MILLAU_PORT="${MILLAU_PORT:-9945}" -RIALTO_PORT="${RIALTO_PORT:-9944}" - -RUST_LOG=bridge=debug \ -./target/debug/substrate-relay init-bridge rialto-to-millau \ - --target-host localhost \ - --target-port $MILLAU_PORT \ - --source-host localhost \ - --source-port $RIALTO_PORT \ - --target-signer //Sudo \ - -sleep 5 -RUST_LOG=bridge=debug \ -./target/debug/substrate-relay relay-headers rialto-to-millau \ - --target-host localhost \ - --target-port $MILLAU_PORT \ - --source-host localhost \ - --source-port $RIALTO_PORT \ - --target-signer //Alice \ - --prometheus-host=0.0.0.0 diff --git a/deployments/local-scripts/run-millau-node.sh b/deployments/local-scripts/run-millau-node.sh deleted file mode 100755 index be3e50872ea14..0000000000000 --- a/deployments/local-scripts/run-millau-node.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/bash - -# Run a development instance of the Millau Substrate bridge node. -# To override the default port just export MILLAU_PORT=9945 - -MILLAU_PORT="${MILLAU_PORT:-9945}" - -RUST_LOG=runtime=trace \ -./target/debug/millau-bridge-node --dev --tmp \ - --rpc-cors=all --unsafe-rpc-external --unsafe-rpc-external \ - --port 33044 --rpc-port $MILLAU_PORT \ diff --git a/deployments/local-scripts/run-rialto-node.sh b/deployments/local-scripts/run-rialto-node.sh deleted file mode 100755 index d57ce9477fda0..0000000000000 --- a/deployments/local-scripts/run-rialto-node.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/bash - -# Run a development instance of the Rialto Substrate bridge node. -# To override the default port just export RIALTO_PORT=9944 - -RIALTO_PORT="${RIALTO_PORT:-9944}" - -RUST_LOG=runtime=trace \ - ./target/debug/rialto-bridge-node --dev --tmp \ - --rpc-cors=all --unsafe-rpc-external \ - --port 33033 --rpc-port $RIALTO_PORT \ diff --git a/deployments/local-scripts/run-westend-node.sh b/deployments/local-scripts/run-westend-node.sh deleted file mode 100755 index 30f7c413af301..0000000000000 --- a/deployments/local-scripts/run-westend-node.sh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/bash - -# Run a development instance of the Westend Substrate bridge node. -# To override the default port just export WESTEND_PORT=9945 -# -# Note: This script will not work out of the box with the bridges -# repo since it relies on a Polkadot binary. - -WESTEND_PORT="${WESTEND_PORT:-9944}" - -RUST_LOG=runtime=trace,runtime::bridge=trace \ -./target/debug/polkadot --chain=westend-dev --alice --tmp \ - --rpc-cors=all --unsafe-rpc-external \ - --port 33033 --rpc-port $WESTEND_PORT \ diff --git a/deployments/monitoring/GrafanaMatrix.Dockerfile b/deployments/monitoring/GrafanaMatrix.Dockerfile deleted file mode 100644 index be1c80d405912..0000000000000 --- a/deployments/monitoring/GrafanaMatrix.Dockerfile +++ /dev/null @@ -1,15 +0,0 @@ -FROM ruby:alpine3.13 - -RUN apk add --no-cache git - -ENV APP_HOME /app -ENV RACK_ENV production -RUN mkdir $APP_HOME -WORKDIR $APP_HOME - -RUN git clone https://github.com/ananace/ruby-grafana-matrix.git $APP_HOME -RUN bundle install --without development - -RUN mkdir /config && touch /config/config.yml && ln -s /config/config.yml ./config.yml - -CMD ["bundle", "exec", "rackup", "-p4567"] diff --git a/deployments/monitoring/disabled.yml b/deployments/monitoring/disabled.yml deleted file mode 100644 index a0b4ed3aad039..0000000000000 --- a/deployments/monitoring/disabled.yml +++ /dev/null @@ -1,15 +0,0 @@ -# A disabled version of monitoring. -# -# We replace each service with a no-op container. We can't simply not include this file, -# cause the bridge-specific compose files might have overrides. -version: '3.5' -services: - prometheus-metrics: - image: alpine - - grafana-dashboard: - image: alpine - - grafana-matrix-notifier: - image: alpine - diff --git a/deployments/monitoring/docker-compose.yml b/deployments/monitoring/docker-compose.yml deleted file mode 100644 index 4f7d958da4a86..0000000000000 --- a/deployments/monitoring/docker-compose.yml +++ /dev/null @@ -1,36 +0,0 @@ -version: '3.5' -services: - prometheus-metrics: - image: prom/prometheus:v2.38.0 - volumes: - - ./monitoring/prometheus/prometheus.yml:/etc/prometheus/prometheus.yml - ports: - - "9090:9090" - - grafana-dashboard: - image: grafana/grafana:8.2.6 - environment: - GF_SECURITY_ADMIN_PASSWORD: ${GRAFANA_ADMIN_PASS:-admin} - GF_SERVER_ROOT_URL: ${GRAFANA_SERVER_ROOT_URL} - GF_SERVER_DOMAIN: ${GRAFANA_SERVER_DOMAIN} - volumes: - - ./monitoring/grafana/provisioning/:/etc/grafana/provisioning/:ro - - ./monitoring/grafana/dashboards/:/etc/grafana/dashboards/common:ro - ports: - - "3000:3000" - depends_on: - - prometheus-metrics - # SIGTERM won't work because of our custom entrypoint. Should be ok to use SIGKILL. - stop_signal: SIGKILL - entrypoint: sh -c "${NO_GRAFANA_STARTUP_DELAY:-echo 'sleeping for 10m' && sleep 600} && /run.sh" - - grafana-matrix-notifier: - build: - context: . - dockerfile: ./monitoring/GrafanaMatrix.Dockerfile - volumes: - - ./monitoring/grafana-matrix:/config - ports: - - "4567:4567" - depends_on: - - grafana-dashboard diff --git a/deployments/monitoring/grafana-matrix/config.yml b/deployments/monitoring/grafana-matrix/config.yml deleted file mode 100644 index 662d7aa14d70a..0000000000000 --- a/deployments/monitoring/grafana-matrix/config.yml +++ /dev/null @@ -1,47 +0,0 @@ ---- -# Webhook server configuration -# Or use the launch options `-o '::' -p 4567` - -# Set up your HS connections -matrix: -- name: matrix-parity-io - url: https://m.parity.io - # Create a user - log that user in using a post request - # curl -XPOST -d '{"type": "m.login.password", - # "user":"grafana", - # "password":"dummy-password"}' - # "https://my-matrix-server/_matrix/client/r0/login" - # Fill that access token in here - access_token: "" - #device_id: # Optional - -# The default message type for messages, should be either m.text or m.notice, -# defaults to m.text -msgtype: m.text - -# Set up notification ingress rules -rules: -- name: bridge # Name of the rule - room: "#bridges-rialto-millau-alerts:parity.io" # Room or ID - matrix: matrix-parity-io # The Matrix HS to use - defaults to first one - msgtype: m.notice - # The following values are optional: - image: true # Attach image to the notification? - embed_image: true # Upload and embed the image into the message? - #templates: - # Templates to use when rendering the notification, available placeholders: - # %TEMPLATES% - lib/grafana_matrix/templates - # $ - Environment variables - #html: "%TEMPLATES%/html.erb" # Path to HTML template - #plain: "%TEMPLATES%/plain.erb" # Path to plaintext template - #auth: - #user: example - #pass: any HTTP encodable string -#- name: other-hq -# room: "#hq:private.matrix.org -# matrix: matrix-priv - -# To use the webhook, you need to configure it into Grafana as: -# -# Url: http://:/hook?rule= -# Http Method: POST diff --git a/deployments/monitoring/grafana/dashboards/nodes.json b/deployments/monitoring/grafana/dashboards/nodes.json deleted file mode 100644 index db14c3cf1fa3c..0000000000000 --- a/deployments/monitoring/grafana/dashboards/nodes.json +++ /dev/null @@ -1,200 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "description": "Running nodes", - "editable": true, - "fiscalYearStartMonth": 0, - "gnetId": null, - "graphTooltip": 0, - "links": [], - "liveNow": false, - "panels": [ - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "15m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "min" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "3m", - "frequency": "1m", - "handler": 1, - "name": "Nodes are not running", - "noDataState": "alerting", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "description": "", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 9, - "w": 12, - "x": 0, - "y": 0 - }, - "hiddenSeries": false, - "id": 2, - "interval": null, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "maxDataPoints": null, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "exemplar": true, - "expr": "up", - "format": "time_series", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1, - "visible": true - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Running nodes", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:111", - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "$$hashKey": "object:112", - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - } - ], - "refresh": "", - "schemaVersion": 32, - "style": "dark", - "tags": [], - "templating": { - "list": [] - }, - "time": { - "from": "now-6h", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "Running nodes", - "uid": "DHl-xSW4z", - "version": 1 -} diff --git a/deployments/monitoring/grafana/provisioning/dashboards/grafana-dashboard.yaml b/deployments/monitoring/grafana/provisioning/dashboards/grafana-dashboard.yaml deleted file mode 100644 index d14ed2637d53a..0000000000000 --- a/deployments/monitoring/grafana/provisioning/dashboards/grafana-dashboard.yaml +++ /dev/null @@ -1,6 +0,0 @@ -- name: 'default' - orgId: 1 - folder: '' - type: file - options: - path: '/etc/grafana/dashboards' \ No newline at end of file diff --git a/deployments/monitoring/grafana/provisioning/datasources/grafana-datasource.yaml b/deployments/monitoring/grafana/provisioning/datasources/grafana-datasource.yaml deleted file mode 100644 index b85cf06e2bd53..0000000000000 --- a/deployments/monitoring/grafana/provisioning/datasources/grafana-datasource.yaml +++ /dev/null @@ -1,16 +0,0 @@ -# list of datasources to insert/update depending -# whats available in the database -datasources: - # name of the datasource. Required -- name: Prometheus - # datasource type. Required - type: prometheus - # access mode. direct or proxy. Required - access: proxy - # org id. will default to orgId 1 if not specified - orgId: 1 - # url - url: http://prometheus-metrics:9090 - # mark as default datasource. Max one per org - isDefault: true - version: 1 diff --git a/deployments/monitoring/grafana/provisioning/notifiers/grafana-notifier.yaml b/deployments/monitoring/grafana/provisioning/notifiers/grafana-notifier.yaml deleted file mode 100644 index 4eb6ea3863e97..0000000000000 --- a/deployments/monitoring/grafana/provisioning/notifiers/grafana-notifier.yaml +++ /dev/null @@ -1,15 +0,0 @@ -notifiers: - - name: Matrix - type: webhook - uid: notifier1 - is_default: true - send_reminder: true - frequency: 1h - disable_resolve_message: false - settings: - url: http://grafana-matrix-notifier:4567/hook?rule=bridge - http_method: POST - -delete_notifiers: - - name: Matrix - uid: notifier1 diff --git a/deployments/monitoring/prometheus/prometheus.yml b/deployments/monitoring/prometheus/prometheus.yml deleted file mode 100644 index 7092bd2731402..0000000000000 --- a/deployments/monitoring/prometheus/prometheus.yml +++ /dev/null @@ -1,7 +0,0 @@ -global: - scrape_interval: 15s -scrape_configs: - - job_name: dummy - file_sd_configs: - - files: - - /etc/prometheus/targets-*.yml diff --git a/deployments/networks/dashboard/grafana/beefy-dashboard.json b/deployments/networks/dashboard/grafana/beefy-dashboard.json deleted file mode 100644 index 5cd74861a8406..0000000000000 --- a/deployments/networks/dashboard/grafana/beefy-dashboard.json +++ /dev/null @@ -1,1505 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "editable": true, - "fiscalYearStartMonth": 0, - "gnetId": null, - "graphTooltip": 0, - "id": 5, - "links": [], - "liveNow": false, - "panels": [ - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 1 - ], - "type": "lt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "C", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - }, - { - "evaluator": { - "params": [ - 1 - ], - "type": "lt" - }, - "operator": { - "type": "or" - }, - "query": { - "params": [ - "D", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "Beefy best blocks not advancing", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 14, - "w": 12, - "x": 0, - "y": 0 - }, - "hiddenSeries": false, - "id": 2, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_best_block{chain=\"rialto_local\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - }, - { - "exemplar": true, - "expr": "substrate_beefy_best_block{chain=\"millau_local\"}", - "hide": false, - "interval": "", - "legendFormat": "", - "refId": "B" - }, - { - "exemplar": true, - "expr": "increase(substrate_beefy_best_block{chain=\"millau_local\"}[5m])", - "hide": true, - "interval": "", - "legendFormat": "Millau Best Beefy blocks count in last 5 minutes", - "refId": "C" - }, - { - "exemplar": true, - "expr": "increase(substrate_beefy_best_block{chain=\"rialto_local\"}[5m])", - "hide": true, - "interval": "", - "legendFormat": "Rialto Best Beefy blocks count in last 5 minutes", - "refId": "D" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 1, - "visible": true - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Beefy Best block", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "5m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "5m", - "frequency": "1m", - "handler": 1, - "name": "Beefy Lagging Sessions alert", - "noDataState": "no_data", - "notifications": [] - }, - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 14, - "w": 6, - "x": 12, - "y": 0 - }, - "hiddenSeries": false, - "id": 8, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_lagging_sessions{chain=\"rialto_local\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - }, - { - "exemplar": true, - "expr": "substrate_beefy_lagging_sessions{chain=\"millau_local\"}", - "interval": "", - "legendFormat": "", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "fill": true, - "line": true, - "op": "gt", - "value": 0, - "visible": true - } - ], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Beefy Lagging Sessions", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "10m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "10m", - "frequency": "5m", - "handler": 1, - "name": "Equivocation votes detected alert", - "noDataState": "no_data", - "notifications": [] - }, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 6, - "x": 0, - "y": 14 - }, - "id": 10, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_equivocation_votes", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "op": "gt", - "value": 0, - "visible": true - } - ], - "title": "Equivocation votes detected", - "type": "timeseries" - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "10m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "10m", - "frequency": "5m", - "handler": 1, - "name": "Invalid votes received alert", - "noDataState": "no_data", - "notifications": [] - }, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 6, - "x": 6, - "y": 14 - }, - "id": 12, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_invalid_votes", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "op": "gt", - "value": 0, - "visible": true - } - ], - "title": "Invalid votes received", - "type": "timeseries" - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "10m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "10m", - "frequency": "5m", - "handler": 1, - "name": "Dropped Buffered Justifications alert", - "noDataState": "no_data", - "notifications": [] - }, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 6, - "x": 12, - "y": 14 - }, - "id": 18, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_buffered_justifications_dropped", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "op": "gt", - "value": 0, - "visible": true - } - ], - "title": "Dropped Buffered Justifications", - "type": "timeseries" - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "A", - "10m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "10m", - "frequency": "5m", - "handler": 1, - "name": "OnDemand Justifications Engine alert", - "noDataState": "no_data", - "notifications": [] - }, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 6, - "x": 0, - "y": 21 - }, - "id": 26, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_on_demand_justification_invalid_proof", - "interval": "", - "legendFormat": "", - "refId": "A" - }, - { - "exemplar": true, - "expr": "substrate_beefy_on_demand_justification_good_proof", - "hide": false, - "interval": "", - "legendFormat": "", - "refId": "B" - }, - { - "exemplar": true, - "expr": "substrate_beefy_on_demand_justification_peer_error", - "hide": false, - "interval": "", - "legendFormat": "", - "refId": "C" - }, - { - "exemplar": true, - "expr": "beefy_on_demand_justification_peer_refused", - "hide": false, - "interval": "", - "legendFormat": "", - "refId": "D" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "op": "gt", - "value": 0, - "visible": true - } - ], - "title": "OnDemand Justifications Engine", - "type": "timeseries" - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "10m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "10m", - "frequency": "5m", - "handler": 1, - "name": "Incoming OnDemand Justifications alert", - "noDataState": "no_data", - "notifications": [] - }, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 6, - "x": 6, - "y": 21 - }, - "id": 24, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_successful_justification_responses", - "interval": "", - "legendFormat": "", - "refId": "A" - }, - { - "exemplar": true, - "expr": "substrate_beefy_failed_justification_responses", - "hide": false, - "interval": "", - "legendFormat": "", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "op": "gt", - "value": 0, - "visible": true - } - ], - "title": "Incoming OnDemand Justifications", - "type": "timeseries" - }, - { - "alert": { - "alertRuleTags": {}, - "conditions": [ - { - "evaluator": { - "params": [ - 0 - ], - "type": "gt" - }, - "operator": { - "type": "and" - }, - "query": { - "params": [ - "B", - "10m", - "now" - ] - }, - "reducer": { - "params": [], - "type": "max" - }, - "type": "query" - } - ], - "executionErrorState": "alerting", - "for": "10m", - "frequency": "5m", - "handler": 1, - "name": "Block-import Justifications alert", - "noDataState": "no_data", - "notifications": [] - }, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 6, - "x": 12, - "y": 21 - }, - "id": 22, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_good_justification_imports", - "interval": "", - "legendFormat": "", - "refId": "A" - }, - { - "exemplar": true, - "expr": "substrate_beefy_bad_justification_imports", - "hide": false, - "interval": "", - "legendFormat": "", - "refId": "B" - } - ], - "thresholds": [ - { - "colorMode": "critical", - "op": "gt", - "value": 0, - "visible": true - } - ], - "title": "Block-import Justifications", - "type": "timeseries" - }, - { - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 13, - "w": 6, - "x": 0, - "y": 28 - }, - "id": 16, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_buffered_justifications", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Buffered Justifications", - "type": "timeseries" - }, - { - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 13, - "w": 6, - "x": 6, - "y": 28 - }, - "id": 20, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_imported_justifications", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Imported Justifications", - "type": "timeseries" - }, - { - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 13, - "w": 6, - "x": 12, - "y": 28 - }, - "id": 14, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_stale_votes", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Stale votes received", - "type": "timeseries" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 13, - "w": 18, - "x": 0, - "y": 41 - }, - "hiddenSeries": false, - "id": 6, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.2.6", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "exemplar": true, - "expr": "substrate_beefy_votes_sent{chain=\"rialto_local\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - }, - { - "exemplar": true, - "expr": "substrate_beefy_votes_sent{chain=\"millau_local\"}", - "interval": "", - "legendFormat": "", - "refId": "B" - } - ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, - "title": "Beefy Votes Sent", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - } - ], - "refresh": "5s", - "schemaVersion": 32, - "style": "dark", - "tags": [], - "templating": { - "list": [] - }, - "time": { - "from": "now-30m", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "Beefy", - "uid": "j6cRDRh7z", - "version": 1 -} diff --git a/deployments/networks/dashboard/prometheus/millau-targets.yml b/deployments/networks/dashboard/prometheus/millau-targets.yml deleted file mode 100644 index 5890c8fb3fdf2..0000000000000 --- a/deployments/networks/dashboard/prometheus/millau-targets.yml +++ /dev/null @@ -1,6 +0,0 @@ -- targets: - - millau-node-alice:9615 - - millau-node-bob:9615 - - millau-node-charlie:9615 - - millau-node-dave:9615 - - millau-node-eve:9615 diff --git a/deployments/networks/dashboard/prometheus/rialto-targets.yml b/deployments/networks/dashboard/prometheus/rialto-targets.yml deleted file mode 100644 index 7ec194f99d7ab..0000000000000 --- a/deployments/networks/dashboard/prometheus/rialto-targets.yml +++ /dev/null @@ -1,7 +0,0 @@ -- targets: - - rialto-node-alice:9615 - - rialto-node-bob:9615 - - rialto-node-charlie:9615 - - rialto-node-dave:9615 - - rialto-node-eve:9615 - - rialto-node-ferdie:9615 diff --git a/deployments/networks/entrypoints/rialto-chainspec-exporter-entrypoint.sh b/deployments/networks/entrypoints/rialto-chainspec-exporter-entrypoint.sh deleted file mode 100755 index eac2a80de87bd..0000000000000 --- a/deployments/networks/entrypoints/rialto-chainspec-exporter-entrypoint.sh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/bash -set -xeu - -trap "echo Exiting... TERM; exit $?" TERM - -/home/user/rialto-bridge-node build-spec \ - --chain local \ - --raw \ - --disable-default-bootnode \ - > /rialto-share/rialto-relaychain-spec-raw.json - -# we're using local driver + tmpfs for shared `/rialto-share` volume, which is populated -# by the container running this script. If this script ends, the volume will be detached -# and our chain spec will be lost when it'll go online again. Hence the never-ending -# script which keeps volume online until container is stopped. -tail -f /dev/null & wait $! diff --git a/deployments/networks/entrypoints/rialto-parachain-registrar-entrypoint.sh b/deployments/networks/entrypoints/rialto-parachain-registrar-entrypoint.sh deleted file mode 100755 index 1c33dd0084160..0000000000000 --- a/deployments/networks/entrypoints/rialto-parachain-registrar-entrypoint.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/bash -set -xeu - -sleep 15 - -exec /home/user/substrate-relay register-parachain rialto-parachain \ - --parachain-host rialto-parachain-collator-alice \ - --parachain-port 9944 \ - --relaychain-host rialto-node-alice \ - --relaychain-port 9944 \ - --relaychain-signer //Sudo diff --git a/deployments/networks/millau.yml b/deployments/networks/millau.yml deleted file mode 100644 index 2c0eea23a2873..0000000000000 --- a/deployments/networks/millau.yml +++ /dev/null @@ -1,103 +0,0 @@ -# Compose file for quickly spinning up a local instance of the Millau Substrate network. -# -# Note that the Millau network is only used for testing, so the configuration settings you see here -# are *not* recommended for a production environment. -# -# For example, do *not* keep your `node-key` in version control, and unless you're _really_ sure you -# want to provide public access to your nodes do *not* publicly expose RPC methods. -version: '3.5' -services: - millau-node-alice: &millau-bridge-node - image: ${MILLAU_BRIDGE_NODE_IMAGE:-paritytech/millau-bridge-node} - entrypoint: - - /home/user/millau-bridge-node - - --chain=local - - --bootnodes=/dns4/millau-node-bob/tcp/30333/p2p/12D3KooWM5LFR5ne4yTQ4sBSXJ75M4bDo2MAhAW2GhL3i8fe5aRb - - --alice - - --node-key=0f900c89f4e626f4a217302ab8c7d213737d00627115f318ad6fb169717ac8e0 - - --rpc-cors=all - - --enable-offchain-indexing=true - - --unsafe-rpc-external - - --prometheus-external - environment: - RUST_LOG: runtime=trace,rpc=debug,txpool=trace,runtime::bridge=trace,sc_basic_authorship=trace,beefy=trace,xcm=trace - ports: - - "19933:9933" - - "19944:9944" - - "19615:9615" - - millau-node-bob: - <<: *millau-bridge-node - entrypoint: - - /home/user/millau-bridge-node - - --chain=local - - --bootnodes=/dns4/millau-node-alice/tcp/30333/p2p/12D3KooWFqiV73ipQ1jpfVmCfLqBCp8G9PLH3zPkY9EhmdrSGA4H - - --bob - - --node-key=db383639ff2905d79f8e936fd5dc4416ef46b514b2f83823ec3c42753d7557bb - - --rpc-cors=all - - --enable-offchain-indexing=true - - --unsafe-rpc-external - - --prometheus-external - ports: - - "20033:9933" - - "20044:9944" - - "20015:9615" - - millau-node-charlie: - <<: *millau-bridge-node - entrypoint: - - /home/user/millau-bridge-node - - --chain=local - - --bootnodes=/dns4/millau-node-alice/tcp/30333/p2p/12D3KooWFqiV73ipQ1jpfVmCfLqBCp8G9PLH3zPkY9EhmdrSGA4H - - --charlie - - --rpc-cors=all - - --enable-offchain-indexing=true - - --unsafe-rpc-external - - --prometheus-external - ports: - - "20133:9933" - - "20144:9944" - - "20115:9615" - - millau-node-dave: - <<: *millau-bridge-node - entrypoint: - - /home/user/millau-bridge-node - - --chain=local - - --bootnodes=/dns4/millau-node-alice/tcp/30333/p2p/12D3KooWFqiV73ipQ1jpfVmCfLqBCp8G9PLH3zPkY9EhmdrSGA4H - - --dave - - --rpc-cors=all - - --enable-offchain-indexing=true - - --unsafe-rpc-external - - --prometheus-external - ports: - - "20233:9933" - - "20244:9944" - - "20215:9615" - - millau-node-eve: - <<: *millau-bridge-node - entrypoint: - - /home/user/millau-bridge-node - - --chain=local - - --bootnodes=/dns4/millau-node-alice/tcp/30333/p2p/12D3KooWFqiV73ipQ1jpfVmCfLqBCp8G9PLH3zPkY9EhmdrSGA4H - - --eve - - --rpc-cors=all - - --enable-offchain-indexing=true - - --unsafe-rpc-external - - --prometheus-external - ports: - - "20333:9933" - - "20344:9944" - - "20315:9615" - - # Note: These are being overridden from the top level `monitoring` compose file. - prometheus-metrics: - volumes: - - ./networks/dashboard/prometheus/millau-targets.yml:/etc/prometheus/targets-millau-nodes.yml - depends_on: - - millau-node-alice - - millau-node-bob - - millau-node-charlie - - millau-node-dave - - millau-node-eve diff --git a/deployments/networks/rialto-parachain.yml b/deployments/networks/rialto-parachain.yml deleted file mode 100644 index 22b603b2044c4..0000000000000 --- a/deployments/networks/rialto-parachain.yml +++ /dev/null @@ -1,93 +0,0 @@ -# Compose file for quickly spinning up a local instance of the Rialto Parachain network. -# -# Since Rialto Parachain is unusable without Rialto, this file depends on some Rialto -# network nodes. -version: '3.5' -services: - rialto-parachain-collator-alice: &rialto-parachain-collator - image: ${RIALTO_PARACHAIN_COLLATOR_IMAGE:-paritytech/rialto-parachain-collator} - entrypoint: > - /home/user/rialto-parachain-collator - --alice - --node-key=80cf382988364291a7968ae7825c01f68c50d679796a8983237d07fe0ccf363b - --collator - --force-authoring - --parachain-id 2000 - --rpc-port 9944 - --rpc-cors=all - --unsafe-rpc-external - --bootnodes - /dns/rialto-parachain-collator-bob/tcp/30333/p2p/12D3KooWEEkzPUdahNXAtzJpkmornEZXHhyyPbTvDkJK383LFvdR - -- - --execution wasm - --chain /rialto-share/rialto-relaychain-spec-raw.json - --rpc-port 9945 - --bootnodes - /dns/rialto-node-alice/tcp/30333/p2p/12D3KooWMF6JvV319a7kJn5pqkKbhR3fcM2cvK5vCbYZHeQhYzFE - volumes: - - rialto-share:/rialto-share:z - environment: - RUST_LOG: runtime=trace,rpc=trace,txpool=trace,parachain=trace,parity_ws=trace,sc_basic_authorship=trace,xcm=trace - depends_on: - - rialto-chainspec-exporter - ports: - - "20444:9944" - - rialto-parachain-collator-bob: - <<: *rialto-parachain-collator - entrypoint: > - /home/user/rialto-parachain-collator - --bob - --node-key=90cf382988364291a7968ae7825c01f68c50d679796a8983237d07fe0ccf363b - --collator - --force-authoring - --parachain-id 2000 - --rpc-port 9944 - --rpc-cors=all - --unsafe-rpc-external - --bootnodes - /dns/rialto-parachain-collator-alice/tcp/30333/p2p/12D3KooWPoJr9Z2PyrFvTYCtto4iorLH11GKBwebJAyqAaFQxow5 - -- - --execution wasm - --chain /rialto-share/rialto-relaychain-spec-raw.json - --rpc-port 9945 - --bootnodes - /dns/rialto-node-alice/tcp/30333/p2p/12D3KooWMF6JvV319a7kJn5pqkKbhR3fcM2cvK5vCbYZHeQhYzFE - ports: - - "20544:9944" - - rialto-parachain-collator-charlie: - <<: *rialto-parachain-collator - entrypoint: > - /home/user/rialto-parachain-collator - --charlie - --node-key=42cf382988364291a7968ae7825c01f68c50d679796a8983237d07fe0ccf363b - --collator - --force-authoring - --parachain-id 2000 - --rpc-port 9944 - --rpc-cors=all - --unsafe-rpc-external - --bootnodes - /dns/rialto-parachain-collator-alice/tcp/30333/p2p/12D3KooWPoJr9Z2PyrFvTYCtto4iorLH11GKBwebJAyqAaFQxow5 - -- - --execution wasm - --chain /rialto-share/rialto-relaychain-spec-raw.json - --rpc-port 9945 - --bootnodes - /dns/rialto-node-alice/tcp/30333/p2p/12D3KooWMF6JvV319a7kJn5pqkKbhR3fcM2cvK5vCbYZHeQhYzFE - ports: - - "20644:9944" - - rialto-parachain-registrar: - image: ${SUBSTRATE_RELAY_IMAGE:-paritytech/substrate-relay} - entrypoint: /entrypoints/rialto-parachain-registrar-entrypoint.sh - volumes: - - ./networks/entrypoints:/entrypoints - - rialto-share:/rialto-share:z - environment: - RUST_LOG: bridge=trace - depends_on: - - rialto-node-alice - - rialto-parachain-collator-alice - diff --git a/deployments/networks/rialto.yml b/deployments/networks/rialto.yml deleted file mode 100644 index 3fb949af2b607..0000000000000 --- a/deployments/networks/rialto.yml +++ /dev/null @@ -1,137 +0,0 @@ -# Compose file for quickly spinning up a local instance of the Rialto Substrate network. -# -# Note that the Rialto network is only used for testing, so the configuration settings you see here -# are *not* recommended for a production environment. -# -# For example, do *not* keep your `node-key` in version control, and unless you're _really_ sure you -# want to provide public access to your nodes do *not* publicly expose RPC methods. -version: '3.5' -services: - rialto-node-alice: &rialto-bridge-node - image: ${RIALTO_BRIDGE_NODE_IMAGE:-paritytech/rialto-bridge-node} - entrypoint: - - /home/user/rialto-bridge-node - - --chain=local - - --bootnodes=/dns4/rialto-node-bob/tcp/30333/p2p/12D3KooWSEpHJj29HEzgPFcRYVc5X3sEuP3KgiUoqJNCet51NiMX - - --alice - - --node-key=79cf382988364291a7968ae7825c01f68c50d679796a8983237d07fe0ccf363b - - --rpc-cors=all - - --enable-offchain-indexing=true - - --unsafe-rpc-external - - --prometheus-external - environment: - RUST_LOG: runtime=trace,rpc=debug,txpool=trace,runtime::bridge=trace,beefy=trace,xcm=trace - ports: - - "9933:9933" - - "9944:9944" - - "9915:9615" - - rialto-node-bob: - <<: *rialto-bridge-node - entrypoint: - - /home/user/rialto-bridge-node - - --chain=local - - --bootnodes=/dns4/rialto-node-alice/tcp/30333/p2p/12D3KooWMF6JvV319a7kJn5pqkKbhR3fcM2cvK5vCbYZHeQhYzFE - - --bob - - --node-key=4f9d0146dd9b7b3bf5a8089e3880023d1df92057f89e96e07bb4d8c2ead75bbd - - --rpc-cors=all - - --enable-offchain-indexing=true - - --unsafe-rpc-external - - --prometheus-external - ports: - - "10033:9933" - - "10044:9944" - - "10015:9615" - - rialto-node-charlie: - <<: *rialto-bridge-node - entrypoint: - - /home/user/rialto-bridge-node - - --chain=local - - --bootnodes=/dns4/rialto-node-alice/tcp/30333/p2p/12D3KooWMF6JvV319a7kJn5pqkKbhR3fcM2cvK5vCbYZHeQhYzFE - - --charlie - - --rpc-cors=all - - --enable-offchain-indexing=true - - --unsafe-rpc-external - - --prometheus-external - ports: - - "10133:9933" - - "10144:9944" - - "10115:9615" - - rialto-node-dave: - <<: *rialto-bridge-node - entrypoint: - - /home/user/rialto-bridge-node - - --chain=local - - --bootnodes=/dns4/rialto-node-alice/tcp/30333/p2p/12D3KooWMF6JvV319a7kJn5pqkKbhR3fcM2cvK5vCbYZHeQhYzFE - - --dave - - --rpc-cors=all - - --enable-offchain-indexing=true - - --unsafe-rpc-external - - --prometheus-external - ports: - - "10233:9933" - - "10244:9944" - - "10215:9615" - - rialto-node-eve: - <<: *rialto-bridge-node - entrypoint: - - /home/user/rialto-bridge-node - - --chain=local - - --bootnodes=/dns4/rialto-node-alice/tcp/30333/p2p/12D3KooWMF6JvV319a7kJn5pqkKbhR3fcM2cvK5vCbYZHeQhYzFE - - --eve - - --rpc-cors=all - - --enable-offchain-indexing=true - - --unsafe-rpc-external - - --prometheus-external - ports: - - "10333:9933" - - "10344:9944" - - "10315:9615" - - rialto-node-ferdie: - <<: *rialto-bridge-node - entrypoint: - - /home/user/rialto-bridge-node - - --chain=local - - --bootnodes=/dns4/rialto-node-alice/tcp/30333/p2p/12D3KooWMF6JvV319a7kJn5pqkKbhR3fcM2cvK5vCbYZHeQhYzFE - - --ferdie - - --rpc-cors=all - - --enable-offchain-indexing=true - - --unsafe-rpc-external - - --prometheus-external - ports: - - "10433:9933" - - "10444:9944" - - "10415:9615" - - rialto-chainspec-exporter: - image: ${RIALTO_BRIDGE_NODE_IMAGE:-paritytech/rialto-bridge-node} - entrypoint: /entrypoints/rialto-chainspec-exporter-entrypoint.sh - volumes: - - ./networks/entrypoints:/entrypoints - - rialto-share:/rialto-share:z - - # Note: These are being overridden from the top level `monitoring` compose file. - prometheus-metrics: - volumes: - - ./networks/dashboard/prometheus/rialto-targets.yml:/etc/prometheus/targets-rialto-nodes.yml - depends_on: - - rialto-node-alice - - rialto-node-bob - - rialto-node-charlie - - rialto-node-dave - - rialto-node-eve - - rialto-node-ferdie - -# we're using `/rialto-share` to expose Rialto chain spec to those who are interested. Right -# now it is Rialto Parachain collator nodes. Local + tmpfs combination allows sharing writable -# in-memory volumes, which are dropped when containers are stopped. -volumes: - rialto-share: - driver: local - driver_opts: - type: "tmpfs" - device: "tmpfs" diff --git a/deployments/reverse-proxy/README.md b/deployments/reverse-proxy/README.md deleted file mode 100644 index ded81f80a1b3c..0000000000000 --- a/deployments/reverse-proxy/README.md +++ /dev/null @@ -1,15 +0,0 @@ -# nginx-proxy - -This is a nginx reverse proxy configuration with Let's encrypt companion. -Main purpose is to be able to use `https://polkadot.js.org/apps` to connect to -a running network. - -## How to? - -In current directory: -```bash -docker-compose up -d -``` - -Then start `rialto` network with the same command (one folder up). `nginx` should -pick up new containers being created and automatically create a proxy setup for `Charlie`. diff --git a/deployments/reverse-proxy/docker-compose.yml b/deployments/reverse-proxy/docker-compose.yml deleted file mode 100644 index ee49e96afddc5..0000000000000 --- a/deployments/reverse-proxy/docker-compose.yml +++ /dev/null @@ -1,45 +0,0 @@ -version: '2' -services: - nginx-proxy: - image: jwilder/nginx-proxy - container_name: nginx-proxy - networks: - - nginx-proxy - - deployments_default - ports: - - "80:80" - - "443:443" - volumes: - - conf:/etc/nginx/conf.d - - vhost:/etc/nginx/vhost.d - - html:/usr/share/nginx/html - - dhparam:/etc/nginx/dhparam - - certs:/etc/nginx/certs:ro - - /var/run/docker.sock:/tmp/docker.sock:ro - - acme:/etc/acme.sh - - letsencrypt: - image: jrcs/letsencrypt-nginx-proxy-companion - container_name: nginx-proxy-le - networks: - - nginx-proxy - volumes_from: - - nginx-proxy - volumes: - - certs:/etc/nginx/certs:rw - - /var/run/docker.sock:/var/run/docker.sock:ro - - acme:/etc/acme.sh - -volumes: - conf: - vhost: - html: - dhparam: - certs: - acme: - -networks: - nginx-proxy: - driver: bridge - deployments_default: - external: true diff --git a/deployments/run.sh b/deployments/run.sh deleted file mode 100755 index a2a1900c1f031..0000000000000 --- a/deployments/run.sh +++ /dev/null @@ -1,217 +0,0 @@ -#!/bin/bash - -# Script used for running and updating bridge deployments. -# -# To deploy a network you can run this script with the name of the bridge (or multiple bridges) you want to run. -# -# `./run.sh westend-millau rialto-millau` -# -# To update a deployment to use the latest images available from the Docker Hub add the `update` -# argument after the bridge name. -# -# `./run.sh rialto-millau update` -# -# Once you've stopped having fun with your deployment you can take it down with: -# -# `./run.sh rialto-millau stop` -# -# Stopping the bridge will also bring down all networks that it uses. So if you have started multiple bridges -# that are using the same network (like Millau in rialto-millau and westend-millau bridges), then stopping one -# of these bridges will cause the other bridge to break. - -set -xeu - -# Since the Compose commands are using relative paths we need to `cd` into the `deployments` folder. -cd "$( dirname "${BASH_SOURCE[0]}" )" - -function show_help () { - set +x - echo " " - echo Error: $1 - echo " " - echo "Usage:" - echo " ./run.sh rialto-millau [stop|update] Run Rialto <> Millau Networks & Bridge" - echo " ./run.sh rialto-parachain-millau [stop|update] Run RialtoParachain <> Millau Networks & Bridge" - echo " ./run.sh westend-millau [stop|update] Run Westend -> Millau Networks & Bridge" - echo " ./run.sh everything|all [stop|update] Run all available Networks & Bridges" - echo " " - echo "Options:" - echo " --no-monitoring Disable monitoring" - echo " --no-ui Disable UI" - echo " --local Use prebuilt local images when starting relay and nodes" - echo " --local-substrate-relay Use prebuilt local/substrate-realy image when starting relay" - echo " --local-rialto Use prebuilt local/rialto-bridge-node image when starting nodes" - echo " --local-rialto-parachain Use prebuilt local/rialto-parachain-collator image when starting nodes" - echo " --local-millau Use prebuilt local/millau-bridge-node image when starting nodes" - echo " --no-grafana-startup-delay Start Grafana without any delay (you may see some false alerts during startup)" - echo " " - echo "You can start multiple bridges at once by passing several bridge names:" - echo " ./run.sh rialto-millau rialto-parachain-millau westend-millau [stop|update]" - exit 1 -} - -RIALTO=' -f ./networks/rialto.yml' -RIALTO_PARACHAIN=' -f ./networks/rialto-parachain.yml' -MILLAU=' -f ./networks/millau.yml' - -RIALTO_MILLAU='rialto-millau' -RIALTO_PARACHAIN_MILLAU='rialto-parachain-millau' -WESTEND_MILLAU='westend-millau' - -MONITORING=' -f ./monitoring/docker-compose.yml' -UI=' -f ./ui/docker-compose.yml' - -BRIDGES=() -NETWORKS='' -SUB_COMMAND='start' -for i in "$@" -do - case $i in - --no-monitoring) - MONITORING=" -f ./monitoring/disabled.yml" - shift - continue - ;; - --no-ui) - UI="" - shift - continue - ;; - --local) - export SUBSTRATE_RELAY_IMAGE=local/substrate-relay - export RIALTO_BRIDGE_NODE_IMAGE=local/rialto-bridge-node - export RIALTO_PARACHAIN_COLLATOR_IMAGE=local/rialto-parachain-collator - export MILLAU_BRIDGE_NODE_IMAGE=local/millau-bridge-node - export IMMEDIATE_ - shift - continue - ;; - --local-substrate-relay) - export SUBSTRATE_RELAY_IMAGE=local/substrate-relay - shift - continue - ;; - --local-rialto) - export RIALTO_BRIDGE_NODE_IMAGE=local/rialto-bridge-node - shift - continue - ;; - --local-rialto-parachain) - export RIALTO_PARACHAIN_COLLATOR_IMAGE=local/rialto-parachain-collator - shift - continue - ;; - --local-millau) - export MILLAU_BRIDGE_NODE_IMAGE=local/millau-bridge-node - shift - continue - ;; - --no-grafana-startup-delay) - export NO_GRAFANA_STARTUP_DELAY="echo 'No Grafana startup delay'" - shift - continue - ;; - everything|all) - BRIDGES=(${RIALTO_MILLAU:-} ${RIALTO_PARACHAIN_MILLAU:-} ${WESTEND_MILLAU:-}) - NETWORKS="${RIALTO:-} ${RIALTO_PARACHAIN:-} ${MILLAU:-}" - unset RIALTO RIALTO_PARACHAIN MILLAU RIALTO_MILLAU RIALTO_PARACHAIN_MILLAU WESTEND_MILLAU - shift - ;; - rialto-millau) - BRIDGES+=(${RIALTO_MILLAU:-}) - NETWORKS+="${RIALTO:-} ${MILLAU:-}" - unset RIALTO MILLAU RIALTO_MILLAU - shift - ;; - rialto-parachain-millau) - BRIDGES+=(${RIALTO_PARACHAIN_MILLAU:-}) - NETWORKS+="${RIALTO:-} ${RIALTO_PARACHAIN:-} ${MILLAU:-}" - unset RIALTO RIALTO_PARACHAIN MILLAU RIALTO_PARACHAIN_MILLAU - shift - ;; - westend-millau) - BRIDGES+=(${WESTEND_MILLAU:-}) - NETWORKS+=${MILLAU:-} - unset MILLAU WESTEND_MILLAU - shift - ;; - start|stop|update) - SUB_COMMAND=$i - shift - ;; - *) - show_help "Unknown option: $i" - ;; - esac -done - -if [ ${#BRIDGES[@]} -eq 0 ]; then - show_help "Missing bridge name." -fi - -COMPOSE_FILES=$NETWORKS$MONITORING$UI - -# Compose looks for .env files in the the current directory by default, we don't want that -COMPOSE_ARGS="--project-directory ." -# Path to env file that we want to use. Compose only accepts single `--env-file` argument, -# so we'll be using the last .env file we'll found. -COMPOSE_ENV_FILE='' - -for BRIDGE in "${BRIDGES[@]}" -do - BRIDGE_PATH="./bridges/$BRIDGE" - BRIDGE=" -f $BRIDGE_PATH/docker-compose.yml" - COMPOSE_FILES=$BRIDGE$COMPOSE_FILES - - # Remember .env file to use in docker-compose call - if [[ -f "$BRIDGE_PATH/.env" ]]; then - COMPOSE_ENV_FILE=" --env-file $BRIDGE_PATH/.env" - fi - - # Read and source variables from .env file so we can use them here - grep -e MATRIX_ACCESS_TOKEN -e WITH_PROXY $BRIDGE_PATH/.env > .env2 && . ./.env2 && rm .env2 - if [ ! -z ${MATRIX_ACCESS_TOKEN+x} ]; then - sed -i "s/access_token.*/access_token: \"$MATRIX_ACCESS_TOKEN\"/" ./monitoring/grafana-matrix/config.yml - fi -done - -# Final COMPOSE_ARGS -COMPOSE_ARGS="$COMPOSE_ARGS $COMPOSE_ENV_FILE" - -# Check the sub-command, perhaps we just mean to stop the network instead of starting it. -if [ "$SUB_COMMAND" == "stop" ]; then - - if [ ! -z ${WITH_PROXY+x} ]; then - cd ./reverse-proxy - docker-compose down - cd - - fi - - docker-compose $COMPOSE_ARGS $COMPOSE_FILES down - - exit 0 -fi - -# See if we want to update the docker images before starting the network. -if [ "$SUB_COMMAND" == "update" ]; then - - # Stop the proxy cause otherwise the network can't be stopped - if [ ! -z ${WITH_PROXY+x} ]; then - cd ./reverse-proxy - docker-compose down - cd - - fi - - - docker-compose $COMPOSE_ARGS $COMPOSE_FILES pull - docker-compose $COMPOSE_ARGS $COMPOSE_FILES down - docker-compose $COMPOSE_ARGS $COMPOSE_FILES build -fi - -docker-compose $COMPOSE_ARGS $COMPOSE_FILES up -d - -# Start the proxy if needed -if [ ! -z ${WITH_PROXY+x} ]; then - cd ./reverse-proxy - docker-compose up -d -fi diff --git a/deployments/types-millau.json b/deployments/types-millau.json deleted file mode 100644 index 88b67f70b0559..0000000000000 --- a/deployments/types-millau.json +++ /dev/null @@ -1,191 +0,0 @@ -{ - "--1": "Millau Types", - "MillauAddress": "AccountId", - "MillauLookupSource": "AccountId", - "MillauBalance": "u64", - "MillauBlockHash": "H512", - "MillauBlockNumber": "u64", - "MillauHeader": { - "parent_Hash": "MillauBlockHash", - "number": "Compact", - "state_root": "MillauBlockHash", - "extrinsics_root": "MillauBlockHash", - "digest": "MillauDigest" - }, - "MillauDigest": { - "logs": "Vec" - }, - "MillauDigestItem": { - "_enum": { - "Other": "Vec", - "AuthoritiesChange": "Vec", - "ChangesTrieRoot": "MillauBlockHash", - "SealV0": "SealV0", - "Consensus": "Consensus", - "Seal": "Seal", - "PreRuntime": "PreRuntime" - } - }, - "--2": "Rialto Types", - "RialtoAddress": "MultiAddress", - "RialtoLookupSource": "MultiAddress", - "RialtoBalance": "u128", - "RialtoBlockHash": "H256", - "RialtoBlockNumber": "u32", - "RialtoHeader": { - "parent_Hash": "RialtoBlockHash", - "number": "Compact", - "state_root": "RialtoBlockHash", - "extrinsics_root": "RialtoBlockHash", - "digest": "RialtoDigest" - }, - "RialtoDigest": { - "logs": "Vec" - }, - "RialtoDigestItem": { - "_enum": { - "Other": "Vec", - "AuthoritiesChange": "Vec", - "ChangesTrieRoot": "RialtoBlockHash", - "SealV0": "SealV0", - "Consensus": "Consensus", - "Seal": "Seal", - "PreRuntime": "PreRuntime" - } - }, - "--3": "Common types", - "AccountSigner": "MultiSigner", - "SpecVersion": "u32", - "RelayerId": "AccountId", - "SourceAccountId": "AccountId", - "ImportedHeader": { - "header": "BridgedHeader", - "requires_justification": "bool", - "is_finalized": "bool", - "signal_hash": "Option" - }, - "AuthoritySet": { - "authorities": "AuthorityList", - "set_id": "SetId" - }, - "Id": "[u8; 4]", - "ChainId": "Id", - "LaneId": "Id", - "MessageNonce": "u64", - "BridgeMessageId": "(Id, u64)", - "MessageKey": { - "lane_id": "LaneId", - "nonce:": "MessageNonce" - }, - "InboundRelayer": "AccountId", - "InboundLaneData": { - "relayers": "Vec", - "last_confirmed_nonce": "MessageNonce" - }, - "UnrewardedRelayer": { - "relayer": "RelayerId", - "messages": "DeliveredMessages" - }, - "DeliveredMessages": { - "begin": "MessageNonce", - "end": "MessageNonce" - }, - "OutboundLaneData": { - "oldest_unpruned_nonce": "MessageNonce", - "latest_received_nonce": "MessageNonce", - "latest_generated_nonce": "MessageNonce" - }, - "MessageData": { - "payload": "MessagePayload", - "fee": "Fee" - }, - "MessagePayload": "Vec", - "BridgedOpaqueCall": "Vec", - "OutboundMessageFee": "Fee", - "OutboundPayload": { - "spec_version": "SpecVersion", - "weight": "Weight", - "origin": "CallOrigin", - "dispatch_fee_payment": "DispatchFeePayment", - "call": "BridgedOpaqueCall" - }, - "CallOrigin": { - "_enum": { - "SourceRoot": "()", - "TargetAccount": "(SourceAccountId, MultiSigner, MultiSignature)", - "SourceAccount": "SourceAccountId" - } - }, - "DispatchFeePayment": { - "_enum": { - "AtSourceChain": "()", - "AtTargetChain": "()" - } - }, - "MultiSigner": { - "_enum": { - "Ed25519": "H256", - "Sr25519": "H256", - "Ecdsa": "[u8;33]" - } - }, - "MessagesProofOf": { - "bridged_header_hash": "BridgedBlockHash", - "storage_proof": "Vec", - "lane": "LaneId", - "nonces_start": "MessageNonce", - "nonces_end": "MessageNonce" - }, - "StorageProofItem": "Vec", - "MessagesDeliveryProofOf": { - "bridged_header_hash": "BridgedBlockHash", - "storage_proof": "Vec", - "lane": "LaneId" - }, - "UnrewardedRelayersState": { - "unrewarded_relayer_entries": "MessageNonce", - "messages_in_oldest_entry": "MessageNonce", - "total_messages": "MessageNonce" - }, - "AncestryProof": "()", - "MessageFeeData": { - "lane_id": "LaneId", - "payload": "OutboundPayload" - }, - "Precommit": { - "target_hash": "BridgedBlockHash", - "target_number": "BridgedBlockNumber" - }, - "AuthoritySignature": "[u8;64]", - "AuthorityId": "[u8;32]", - "SignedPrecommit": { - "precommit": "Precommit", - "signature": "AuthoritySignature", - "id": "AuthorityId" - }, - "Commit": { - "target_hash": "BridgedBlockHash", - "target_number": "BridgedBlockNumber", - "precommits": "Vec" - }, - "GrandpaJustification": { - "round": "u64", - "commit": "Commit", - "votes_ancestries": "Vec" - }, - "Address": "MillauAddress", - "LookupSource": "MillauLookupSource", - "Fee": "MillauBalance", - "Balance": "MillauBalance", - "Hash": "MillauBlockHash", - "BlockHash": "MillauBlockHash", - "BlockNumber": "MillauBlockNumber", - "BridgedBlockHash": "RialtoBlockHash", - "BridgedBlockNumber": "RialtoBlockNumber", - "BridgedHeader": "RialtoHeader", - "Parameter": { - "_enum": { - "MillauToRialtoConversionRate": "u128" - } - } -} diff --git a/deployments/types-rialto.json b/deployments/types-rialto.json deleted file mode 100644 index 02ceaf676d654..0000000000000 --- a/deployments/types-rialto.json +++ /dev/null @@ -1,191 +0,0 @@ -{ - "--1": "Millau Types", - "MillauAddress": "AccountId", - "MillauLookupSource": "AccountId", - "MillauBalance": "u64", - "MillauBlockHash": "H512", - "MillauBlockNumber": "u64", - "MillauHeader": { - "parent_Hash": "MillauBlockHash", - "number": "Compact", - "state_root": "MillauBlockHash", - "extrinsics_root": "MillauBlockHash", - "digest": "MillauDigest" - }, - "MillauDigest": { - "logs": "Vec" - }, - "MillauDigestItem": { - "_enum": { - "Other": "Vec", - "AuthoritiesChange": "Vec", - "ChangesTrieRoot": "MillauBlockHash", - "SealV0": "SealV0", - "Consensus": "Consensus", - "Seal": "Seal", - "PreRuntime": "PreRuntime" - } - }, - "--2": "Rialto Types", - "RialtoAddress": "MultiAddress", - "RialtoLookupSource": "MultiAddress", - "RialtoBalance": "u128", - "RialtoBlockHash": "H256", - "RialtoBlockNumber": "u32", - "RialtoHeader": { - "parent_Hash": "RialtoBlockHash", - "number": "Compact", - "state_root": "RialtoBlockHash", - "extrinsics_root": "RialtoBlockHash", - "digest": "RialtoDigest" - }, - "RialtoDigest": { - "logs": "Vec" - }, - "RialtoDigestItem": { - "_enum": { - "Other": "Vec", - "AuthoritiesChange": "Vec", - "ChangesTrieRoot": "RialtoBlockHash", - "SealV0": "SealV0", - "Consensus": "Consensus", - "Seal": "Seal", - "PreRuntime": "PreRuntime" - } - }, - "--3": "Common types", - "AccountSigner": "MultiSigner", - "SpecVersion": "u32", - "RelayerId": "AccountId", - "SourceAccountId": "AccountId", - "ImportedHeader": { - "header": "BridgedHeader", - "requires_justification": "bool", - "is_finalized": "bool", - "signal_hash": "Option" - }, - "AuthoritySet": { - "authorities": "AuthorityList", - "set_id": "SetId" - }, - "Id": "[u8; 4]", - "ChainId": "Id", - "LaneId": "Id", - "MessageNonce": "u64", - "BridgeMessageId": "(Id, u64)", - "MessageKey": { - "lane_id": "LaneId", - "nonce:": "MessageNonce" - }, - "InboundRelayer": "AccountId", - "InboundLaneData": { - "relayers": "Vec", - "last_confirmed_nonce": "MessageNonce" - }, - "UnrewardedRelayer": { - "relayer": "RelayerId", - "messages": "DeliveredMessages" - }, - "DeliveredMessages": { - "begin": "MessageNonce", - "end": "MessageNonce" - }, - "OutboundLaneData": { - "oldest_unpruned_nonce": "MessageNonce", - "latest_received_nonce": "MessageNonce", - "latest_generated_nonce": "MessageNonce" - }, - "MessageData": { - "payload": "MessagePayload", - "fee": "Fee" - }, - "MessagePayload": "Vec", - "BridgedOpaqueCall": "Vec", - "OutboundMessageFee": "Fee", - "OutboundPayload": { - "spec_version": "SpecVersion", - "weight": "Weight", - "origin": "CallOrigin", - "dispatch_fee_payment": "DispatchFeePayment", - "call": "BridgedOpaqueCall" - }, - "CallOrigin": { - "_enum": { - "SourceRoot": "()", - "TargetAccount": "(SourceAccountId, MultiSigner, MultiSignature)", - "SourceAccount": "SourceAccountId" - } - }, - "DispatchFeePayment": { - "_enum": { - "AtSourceChain": "()", - "AtTargetChain": "()" - } - }, - "MultiSigner": { - "_enum": { - "Ed25519": "H256", - "Sr25519": "H256", - "Ecdsa": "[u8;33]" - } - }, - "MessagesProofOf": { - "bridged_header_hash": "BridgedBlockHash", - "storage_proof": "Vec", - "lane": "LaneId", - "nonces_start": "MessageNonce", - "nonces_end": "MessageNonce" - }, - "StorageProofItem": "Vec", - "MessagesDeliveryProofOf": { - "bridged_header_hash": "BridgedBlockHash", - "storage_proof": "Vec", - "lane": "LaneId" - }, - "UnrewardedRelayersState": { - "unrewarded_relayer_entries": "MessageNonce", - "messages_in_oldest_entry": "MessageNonce", - "total_messages": "MessageNonce" - }, - "AncestryProof": "()", - "MessageFeeData": { - "lane_id": "LaneId", - "payload": "OutboundPayload" - }, - "Precommit": { - "target_hash": "BridgedBlockHash", - "target_number": "BridgedBlockNumber" - }, - "AuthoritySignature": "[u8;64]", - "AuthorityId": "[u8;32]", - "SignedPrecommit": { - "precommit": "Precommit", - "signature": "AuthoritySignature", - "id": "AuthorityId" - }, - "Commit": { - "target_hash": "BridgedBlockHash", - "target_number": "BridgedBlockNumber", - "precommits": "Vec" - }, - "GrandpaJustification": { - "round": "u64", - "commit": "Commit", - "votes_ancestries": "Vec" - }, - "Address": "RialtoAddress", - "LookupSource": "RialtoLookupSource", - "Fee": "RialtoBalance", - "Balance": "RialtoBalance", - "BlockHash": "RialtoBlockHash", - "BlockNumber": "RialtoBlockNumber", - "BridgedBlockHash": "MillauBlockHash", - "BridgedBlockNumber": "MillauBlockNumber", - "BridgedHeader": "MillauHeader", - "Parameter": { - "_enum": { - "RialtoToMillauConversionRate": "u128" - } - }, - "ValidationCodeHash": "H256" -} diff --git a/deployments/types/build.sh b/deployments/types/build.sh deleted file mode 100755 index be96459a6daaa..0000000000000 --- a/deployments/types/build.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/sh - -# The script generates JSON type definition files in `./deployment` directory to be used for -# JS clients. -# -# It works by creating definitions for each side of the different bridge pairs we support -# (Rialto<>Millau at the moment). -# -# To avoid duplication each bridge pair has a JSON file with common definitions, as well as a -# general JSON file with common definitions regardless of the bridge pair. These files are then -# merged with chain-specific type definitions. - -set -eux - -# Make sure we are in the right dir. -cd $(dirname $(realpath $0)) - -# Create types for our supported bridge pairs (Rialto<>Millau) -jq -s '.[0] * .[1] * .[2]' rialto-millau.json common.json rialto.json > ../types-rialto.json -jq -s '.[0] * .[1] * .[2]' rialto-millau.json common.json millau.json > ../types-millau.json diff --git a/deployments/types/common.json b/deployments/types/common.json deleted file mode 100644 index 7247e546bec9d..0000000000000 --- a/deployments/types/common.json +++ /dev/null @@ -1,123 +0,0 @@ -{ - "--3": "Common types", - "AccountSigner": "MultiSigner", - "SpecVersion": "u32", - "RelayerId": "AccountId", - "SourceAccountId": "AccountId", - "ImportedHeader": { - "header": "BridgedHeader", - "requires_justification": "bool", - "is_finalized": "bool", - "signal_hash": "Option" - }, - "AuthoritySet": { - "authorities": "AuthorityList", - "set_id": "SetId" - }, - "Id": "[u8; 4]", - "ChainId": "Id", - "LaneId": "Id", - "MessageNonce": "u64", - "BridgeMessageId": "(Id, u64)", - "MessageKey": { - "lane_id": "LaneId", - "nonce:": "MessageNonce" - }, - "InboundRelayer": "AccountId", - "InboundLaneData": { - "relayers": "Vec", - "last_confirmed_nonce": "MessageNonce" - }, - "UnrewardedRelayer": { - "relayer": "RelayerId", - "messages": "DeliveredMessages" - }, - "DeliveredMessages": { - "begin": "MessageNonce", - "end": "MessageNonce" - }, - "OutboundLaneData": { - "oldest_unpruned_nonce": "MessageNonce", - "latest_received_nonce": "MessageNonce", - "latest_generated_nonce": "MessageNonce" - - }, - "MessageData": { - "payload": "MessagePayload", - "fee": "Fee" - }, - "MessagePayload": "Vec", - "BridgedOpaqueCall": "Vec", - "OutboundMessageFee": "Fee", - "OutboundPayload": { - "spec_version": "SpecVersion", - "weight": "Weight", - "origin": "CallOrigin", - "dispatch_fee_payment": "DispatchFeePayment", - "call": "BridgedOpaqueCall" - }, - "CallOrigin": { - "_enum": { - "SourceRoot": "()", - "TargetAccount": "(SourceAccountId, MultiSigner, MultiSignature)", - "SourceAccount": "SourceAccountId" - } - }, - "DispatchFeePayment": { - "_enum": { - "AtSourceChain": "()", - "AtTargetChain": "()" - } - }, - "MultiSigner": { - "_enum": { - "Ed25519": "H256", - "Sr25519": "H256", - "Ecdsa": "[u8;33]" - } - }, - "MessagesProofOf": { - "bridged_header_hash": "BridgedBlockHash", - "storage_proof": "Vec", - "lane": "LaneId", - "nonces_start": "MessageNonce", - "nonces_end": "MessageNonce" - }, - "StorageProofItem": "Vec", - "MessagesDeliveryProofOf": { - "bridged_header_hash": "BridgedBlockHash", - "storage_proof": "Vec", - "lane": "LaneId" - }, - "UnrewardedRelayersState": { - "unrewarded_relayer_entries": "MessageNonce", - "messages_in_oldest_entry": "MessageNonce", - "total_messages": "MessageNonce" - }, - "AncestryProof": "()", - "MessageFeeData": { - "lane_id": "LaneId", - "payload": "OutboundPayload" - }, - "Precommit": { - "target_hash": "BridgedBlockHash", - "target_number": "BridgedBlockNumber" - }, - "AuthoritySignature": "[u8;64]", - "AuthorityId": "[u8;32]", - "SignedPrecommit": { - "precommit": "Precommit", - "signature": "AuthoritySignature", - "id": "AuthorityId" - }, - "Commit": { - "target_hash": "BridgedBlockHash", - "target_number": "BridgedBlockNumber", - "precommits": "Vec" - }, - "GrandpaJustification": { - "round": "u64", - "commit": "Commit", - "votes_ancestries": "Vec" - } -} diff --git a/deployments/types/millau.json b/deployments/types/millau.json deleted file mode 100644 index 589d5619df453..0000000000000 --- a/deployments/types/millau.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "Address": "MillauAddress", - "LookupSource": "MillauLookupSource", - "Fee": "MillauBalance", - "Balance": "MillauBalance", - "Hash": "MillauBlockHash", - "BlockHash": "MillauBlockHash", - "BlockNumber": "MillauBlockNumber", - "BridgedBlockHash": "RialtoBlockHash", - "BridgedBlockNumber": "RialtoBlockNumber", - "BridgedHeader": "RialtoHeader", - "Parameter": { - "_enum": { - "MillauToRialtoConversionRate": "u128" - } - } -} diff --git a/deployments/types/rialto-millau.json b/deployments/types/rialto-millau.json deleted file mode 100644 index 971cf666d479e..0000000000000 --- a/deployments/types/rialto-millau.json +++ /dev/null @@ -1,56 +0,0 @@ -{ - "--1": "Millau Types", - "MillauAddress": "AccountId", - "MillauLookupSource": "AccountId", - "MillauBalance": "u64", - "MillauBlockHash": "H512", - "MillauBlockNumber": "u64", - "MillauHeader": { - "parent_Hash": "MillauBlockHash", - "number": "Compact", - "state_root": "MillauBlockHash", - "extrinsics_root": "MillauBlockHash", - "digest": "MillauDigest" - }, - "MillauDigest": { - "logs": "Vec" - }, - "MillauDigestItem": { - "_enum": { - "Other": "Vec", - "AuthoritiesChange": "Vec", - "ChangesTrieRoot": "MillauBlockHash", - "SealV0": "SealV0", - "Consensus": "Consensus", - "Seal": "Seal", - "PreRuntime": "PreRuntime" - } - }, - "--2": "Rialto Types", - "RialtoAddress": "MultiAddress", - "RialtoLookupSource": "MultiAddress", - "RialtoBalance": "u128", - "RialtoBlockHash": "H256", - "RialtoBlockNumber": "u32", - "RialtoHeader": { - "parent_Hash": "RialtoBlockHash", - "number": "Compact", - "state_root": "RialtoBlockHash", - "extrinsics_root": "RialtoBlockHash", - "digest": "RialtoDigest" - }, - "RialtoDigest": { - "logs": "Vec" - }, - "RialtoDigestItem": { - "_enum": { - "Other": "Vec", - "AuthoritiesChange": "Vec", - "ChangesTrieRoot": "RialtoBlockHash", - "SealV0": "SealV0", - "Consensus": "Consensus", - "Seal": "Seal", - "PreRuntime": "PreRuntime" - } - } -} diff --git a/deployments/types/rialto.json b/deployments/types/rialto.json deleted file mode 100644 index 77c30b7cc2d7b..0000000000000 --- a/deployments/types/rialto.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "Address": "RialtoAddress", - "LookupSource": "RialtoLookupSource", - "Fee": "RialtoBalance", - "Balance": "RialtoBalance", - "BlockHash": "RialtoBlockHash", - "BlockNumber": "RialtoBlockNumber", - "BridgedBlockHash": "MillauBlockHash", - "BridgedBlockNumber": "MillauBlockNumber", - "BridgedHeader": "MillauHeader", - "Parameter": { - "_enum": { - "RialtoToMillauConversionRate": "u128" - } - }, - "ValidationCodeHash": "H256" -} diff --git a/deployments/ui/README.md b/deployments/ui/README.md deleted file mode 100644 index ad946fc699bf8..0000000000000 --- a/deployments/ui/README.md +++ /dev/null @@ -1,23 +0,0 @@ -# bridges-ui - -This is a Bridges UI docker configuration file. The source of the Bridges UI code -can be found in [the repository](https://github.com/paritytech/parity-bridges-ui). -The CI should create and publish a docker image that is used by this configuration -file, so that the code is always using the latest version. -The UI is configured to point to local Rialto and Millau nodes to retrieve the require -data. - -This image can be used together with `nginx-proxy` to expose the UI externally. See -`VIRTUAL_*` and `LETSENCRYPT_*` environment variables. - -After start the UI is available at `http://localhost:8080` - -## How to? - -In current directory: -```bash -docker-compose up -d -``` - -Then start `rialto` & `millau` networks with the same command (one folder up) or -run the full setup by using `../run.sh` script. diff --git a/deployments/ui/docker-compose.yml b/deployments/ui/docker-compose.yml deleted file mode 100644 index 2d400609c4428..0000000000000 --- a/deployments/ui/docker-compose.yml +++ /dev/null @@ -1,14 +0,0 @@ -version: '3.5' -services: - bridges-ui: - image: paritytech/parity-bridges-ui - environment: - VIRTUAL_HOST: ui.brucke.link - VIRTUAL_PORT: 80 - LETSENCRYPT_HOST: ui.brucke.link - LETSENCRYPT_EMAIL: admin@parity.io - CHAIN_1_SUBSTRATE_PROVIDER: ${UI_CHAIN_1:-ws://localhost:9944} - CHAIN_2_SUBSTRATE_PROVIDER: ${UI_CHAIN_2:-ws://localhost:19944} - stop_signal: SIGKILL - ports: - - "8080:80" diff --git a/docs/dockerhub-millau-bridge-node.README.md b/docs/dockerhub-millau-bridge-node.README.md deleted file mode 100644 index 481ad46b7c6f2..0000000000000 --- a/docs/dockerhub-millau-bridge-node.README.md +++ /dev/null @@ -1 +0,0 @@ -# millau-bridge-node diff --git a/docs/dockerhub-rialto-bridge-node.README.md b/docs/dockerhub-rialto-bridge-node.README.md deleted file mode 100644 index 2393e6f812954..0000000000000 --- a/docs/dockerhub-rialto-bridge-node.README.md +++ /dev/null @@ -1 +0,0 @@ -# rialto-bridge-node diff --git a/docs/dockerhub-rialto-parachain-collator.README.md b/docs/dockerhub-rialto-parachain-collator.README.md deleted file mode 100644 index a09f6b1561b06..0000000000000 --- a/docs/dockerhub-rialto-parachain-collator.README.md +++ /dev/null @@ -1 +0,0 @@ -# rialto-parachain-collator diff --git a/docs/high-level-overview.md b/docs/high-level-overview.md index 42efc8100bd08..d6d6fb3f0996d 100644 --- a/docs/high-level-overview.md +++ b/docs/high-level-overview.md @@ -1,7 +1,7 @@ # High-Level Bridge Documentation This document gives a brief, abstract description of main components that may be found in this repository. If you want -to see how we're using them to build Rococo <> Wococo (Kusama <> Polkadot) bridge, please refer to the [Polkadot <> +to see how we're using them to build Rococo <> Westend (Kusama <> Polkadot) bridge, please refer to the [Polkadot <> Kusama Bridge](./polkadot-kusama-bridge-overview.md). ## Purpose diff --git a/fuzz/storage-proof/Cargo.lock b/fuzz/storage-proof/Cargo.lock deleted file mode 100644 index 6eba720c4937e..0000000000000 --- a/fuzz/storage-proof/Cargo.lock +++ /dev/null @@ -1,2796 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "Inflector" -version = "0.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" -dependencies = [ - "lazy_static", - "regex", -] - -[[package]] -name = "addr2line" -version = "0.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9ecd88a8c8378ca913a680cd98f0f13ac67383d35993f86c90a70e3f137816b" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "ahash" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" -dependencies = [ - "getrandom 0.2.7", - "once_cell", - "version_check", -] - -[[package]] -name = "aho-corasick" -version = "0.7.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e37cfd5e7657ada45f742d6e99ca5788580b5c529dc78faf11ece6dc702656f" -dependencies = [ - "memchr", -] - -[[package]] -name = "ansi_term" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d52a9bb7ec0cf484c551830a7ce27bd20d67eac647e1befb56b0be4ee39a55d2" -dependencies = [ - "winapi", -] - -[[package]] -name = "anyhow" -version = "1.0.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "afddf7f520a80dbf76e6f50a35bca42a2331ef227a28b3b6dc5c2e2338d114b1" - -[[package]] -name = "arbitrary" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c38b6b6b79f671c25e1a3e785b7b82d7562ffc9cd3efdc98627e5668a2472490" - -[[package]] -name = "arrayref" -version = "0.3.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4c527152e37cf757a3f78aae5a06fbeefdb07ccc535c980a3208ee3060dd544" - -[[package]] -name = "arrayvec" -version = "0.4.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd9fd44efafa8690358b7408d253adf110036b88f55672a933f01d616ad9b1b9" -dependencies = [ - "nodrop", -] - -[[package]] -name = "arrayvec" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23b62fc65de8e4e7f52534fb52b0f3ed04746ae267519eef2a83941e8085068b" - -[[package]] -name = "arrayvec" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8da52d66c7071e2e3fa2a1e5c6d088fec47b593032b254f5e980de8ea54454d6" - -[[package]] -name = "async-trait" -version = "0.1.56" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96cf8829f67d2eab0b2dfa42c5d0ef737e0724e4a82b01b3e292456202b19716" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "autocfg" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" - -[[package]] -name = "backtrace" -version = "0.3.66" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cab84319d616cfb654d03394f38ab7e6f0919e181b1b57e1fd15e7fb4077d9a7" -dependencies = [ - "addr2line", - "cc", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - -[[package]] -name = "base16ct" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "349a06037c7bf932dd7e7d1f653678b2038b9ad46a74102f1fc7bd7872678cce" - -[[package]] -name = "base58" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6107fe1be6682a68940da878d9e9f5e90ca5745b3dec9fd1bb393c8777d4f581" - -[[package]] -name = "base64" -version = "0.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "904dfeac50f3cdaba28fc6f57fdcddb75f49ed61346676a78c4ffe55877802fd" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitvec" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1489fcb93a5bb47da0462ca93ad252ad6af2145cce58d10d46a83931ba9f016b" -dependencies = [ - "funty", - "radium", - "tap", - "wyz", -] - -[[package]] -name = "blake2" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9cf849ee05b2ee5fba5e36f97ff8ec2533916700fc0758d40d92136a42f3388" -dependencies = [ - "digest 0.10.3", -] - -[[package]] -name = "blake2-rfc" -version = "0.2.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d6d530bdd2d52966a6d03b7a964add7ae1a288d25214066fd4b600f0f796400" -dependencies = [ - "arrayvec 0.4.12", - "constant_time_eq", -] - -[[package]] -name = "block-buffer" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0940dc441f31689269e10ac70eb1002a3a1d3ad1390e030043662eb7fe4688b" -dependencies = [ - "block-padding", - "byte-tools", - "byteorder", - "generic-array 0.12.4", -] - -[[package]] -name = "block-buffer" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" -dependencies = [ - "generic-array 0.14.4", -] - -[[package]] -name = "block-buffer" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bf7fe51849ea569fd452f37822f606a5cabb684dc918707a0193fd4664ff324" -dependencies = [ - "generic-array 0.14.4", -] - -[[package]] -name = "block-padding" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa79dedbb091f449f1f39e53edf88d5dbe95f895dae6135a8d7b881fb5af73f5" -dependencies = [ - "byte-tools", -] - -[[package]] -name = "bp-runtime" -version = "0.1.0" -dependencies = [ - "frame-support", - "frame-system", - "hash-db", - "impl-trait-for-tuples", - "num-traits", - "parity-scale-codec", - "scale-info", - "serde", - "sp-core", - "sp-io", - "sp-runtime", - "sp-state-machine", - "sp-std", - "sp-trie", - "trie-db 0.24.0", -] - -[[package]] -name = "bumpalo" -version = "3.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d261e256854913907f67ed06efbc3338dfe6179796deefc1ff763fc1aee5535" - -[[package]] -name = "byte-slice-cast" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87c5fdd0166095e1d463fc6cc01aa8ce547ad77a4e84d42eb6762b084e28067e" - -[[package]] -name = "byte-tools" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7" - -[[package]] -name = "byteorder" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae44d1a3d5a19df61dd0c8beb138458ac2a53a7ac09eba97d55592540004306b" - -[[package]] -name = "cc" -version = "1.0.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fff2a6927b3bb87f9595d67196a70493f627687a71d87a0d692242c33f58c11" - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "chrono" -version = "0.4.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "670ad68c9088c2a963aaa298cb369688cf3f9465ce5e2d4ca10e6e0098a1ce73" -dependencies = [ - "libc", - "num-integer", - "num-traits", - "winapi", -] - -[[package]] -name = "const-oid" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4c78c047431fee22c1a7bb92e00ad095a02a983affe4d8a72e2a2c62c1b94f3" - -[[package]] -name = "constant_time_eq" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "245097e9a4535ee1e3e3931fcfcd55a796a44c643e8596ff6566d68f09b87bbc" - -[[package]] -name = "cpufeatures" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59a6001667ab124aebae2a495118e11d30984c3a653e99d86d58971708cf5e4b" -dependencies = [ - "libc", -] - -[[package]] -name = "crunchy" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" - -[[package]] -name = "crypto-bigint" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03c6a1d5fa1de37e071642dfa44ec552ca5b299adb128fab16138e24b548fd21" -dependencies = [ - "generic-array 0.14.4", - "rand_core 0.6.1", - "subtle", - "zeroize", -] - -[[package]] -name = "crypto-common" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ccfd8c0ee4cce11e45b3fd6f9d5e69e0cc62912aa6a0cb1bf4617b0eba5a12f" -dependencies = [ - "generic-array 0.14.4", - "typenum", -] - -[[package]] -name = "crypto-mac" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b584a330336237c1eecd3e94266efb216c56ed91225d634cb2991c5f3fd1aeab" -dependencies = [ - "generic-array 0.14.4", - "subtle", -] - -[[package]] -name = "crypto-mac" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1d1a86f49236c215f271d40892d5fc950490551400b02ef360692c29815c714" -dependencies = [ - "generic-array 0.14.4", - "subtle", -] - -[[package]] -name = "curve25519-dalek" -version = "2.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "434e1720189a637d44fe464f4df1e6eb900b4835255b14354497c78af37d9bb8" -dependencies = [ - "byteorder", - "digest 0.8.1", - "rand_core 0.5.1", - "subtle", - "zeroize", -] - -[[package]] -name = "curve25519-dalek" -version = "3.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f627126b946c25a4638eec0ea634fc52506dea98db118aae985118ce7c3d723f" -dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.5.1", - "subtle", - "zeroize", -] - -[[package]] -name = "der" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6919815d73839e7ad218de758883aae3a257ba6759ce7a9992501efbb53d705c" -dependencies = [ - "const-oid", -] - -[[package]] -name = "derive_more" -version = "0.99.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41cb0e6161ad61ed084a36ba71fbba9e3ac5aee3606fb607fe08da6acbcf3d8c" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "digest" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3d0c8c8752312f9713efd397ff63acb9f85585afbf179282e720e7704954dd5" -dependencies = [ - "generic-array 0.12.4", -] - -[[package]] -name = "digest" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" -dependencies = [ - "generic-array 0.14.4", -] - -[[package]] -name = "digest" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2fb860ca6fafa5552fb6d0e816a69c8e49f0908bf524e30a90d97c85892d506" -dependencies = [ - "block-buffer 0.10.2", - "crypto-common", - "subtle", -] - -[[package]] -name = "downcast-rs" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ea835d29036a4087793836fa931b08837ad5e957da9e23886b29586fb9b6650" - -[[package]] -name = "dyn-clonable" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e9232f0e607a262ceb9bd5141a3dfb3e4db6994b31989bbfd845878cba59fd4" -dependencies = [ - "dyn-clonable-impl", - "dyn-clone", -] - -[[package]] -name = "dyn-clonable-impl" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "558e40ea573c374cf53507fd240b7ee2f5477df7cfebdb97323ec61c719399c5" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "dyn-clone" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee2626afccd7561a06cf1367e2950c4718ea04565e20fb5029b6c7d8ad09abcf" - -[[package]] -name = "ecdsa" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0d69ae62e0ce582d56380743515fefaf1a8c70cec685d9677636d7e30ae9dc9" -dependencies = [ - "der", - "elliptic-curve", - "rfc6979", - "signature", -] - -[[package]] -name = "ed25519" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37c66a534cbb46ab4ea03477eae19d5c22c01da8258030280b7bd9d8433fb6ef" -dependencies = [ - "signature", -] - -[[package]] -name = "ed25519-dalek" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" -dependencies = [ - "curve25519-dalek 3.0.2", - "ed25519", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "zeroize", -] - -[[package]] -name = "either" -version = "1.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e78d4f1cc4ae33bbfc157ed5d5a5ef3bc29227303d595861deb238fcec4e9457" - -[[package]] -name = "elliptic-curve" -version = "0.11.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25b477563c2bfed38a3b7a60964c49e058b2510ad3f12ba3483fd8f62c2306d6" -dependencies = [ - "base16ct", - "crypto-bigint", - "der", - "ff", - "generic-array 0.14.4", - "group", - "rand_core 0.6.1", - "sec1", - "subtle", - "zeroize", -] - -[[package]] -name = "env_logger" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85cdab6a89accf66733ad5a1693a4dcced6aeff64602b634530dd73c1f3ee9f0" -dependencies = [ - "humantime", - "is-terminal", - "log", - "regex", - "termcolor", -] - -[[package]] -name = "environmental" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68b91989ae21441195d7d9b9993a2f9295c7e1a8c96255d8b729accddc124797" - -[[package]] -name = "errno" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f639046355ee4f37944e44f60642c6f3a7efa3cf6b78c78a0d989a8ce6c396a1" -dependencies = [ - "errno-dragonfly", - "libc", - "winapi", -] - -[[package]] -name = "errno-dragonfly" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" -dependencies = [ - "cc", - "libc", -] - -[[package]] -name = "fake-simd" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e88a8acf291dafb59c2d96e8f59828f3838bb1a70398823ade51a84de6a6deed" - -[[package]] -name = "ff" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "131655483be284720a17d74ff97592b8e76576dc25563148601df2d7c9080924" -dependencies = [ - "rand_core 0.6.1", - "subtle", -] - -[[package]] -name = "fixed-hash" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cfcf0ed7fe52a17a03854ec54a9f76d6d84508d1c0e66bc1793301c73fc8493c" -dependencies = [ - "byteorder", - "rand 0.8.2", - "rustc-hex", - "static_assertions", -] - -[[package]] -name = "frame-metadata" -version = "15.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df6bb8542ef006ef0de09a5c4420787d79823c0ed7924225822362fd2bf2ff2d" -dependencies = [ - "cfg-if", - "parity-scale-codec", - "scale-info", - "serde", -] - -[[package]] -name = "frame-support" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "bitflags", - "frame-metadata", - "frame-support-procedural", - "impl-trait-for-tuples", - "k256", - "log", - "once_cell", - "parity-scale-codec", - "paste", - "scale-info", - "serde", - "smallvec", - "sp-arithmetic", - "sp-core", - "sp-core-hashing-proc-macro", - "sp-inherents", - "sp-io", - "sp-runtime", - "sp-staking", - "sp-state-machine", - "sp-std", - "sp-tracing", - "tt-call", -] - -[[package]] -name = "frame-support-procedural" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "Inflector", - "frame-support-procedural-tools", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "frame-support-procedural-tools" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "frame-support-procedural-tools-derive", - "proc-macro-crate", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "frame-support-procedural-tools-derive" -version = "3.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "frame-system" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "frame-support", - "log", - "parity-scale-codec", - "scale-info", - "serde", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std", - "sp-version", -] - -[[package]] -name = "funty" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" - -[[package]] -name = "futures" -version = "0.3.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f73fe65f54d1e12b726f517d3e2135ca3125a437b6d998caf1962961f7172d9e" -dependencies = [ - "futures-channel", - "futures-core", - "futures-executor", - "futures-io", - "futures-sink", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-channel" -version = "0.3.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3083ce4b914124575708913bca19bfe887522d6e2e6d0952943f5eac4a74010" -dependencies = [ - "futures-core", - "futures-sink", -] - -[[package]] -name = "futures-core" -version = "0.3.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c09fd04b7e4073ac7156a9539b57a484a8ea920f79c7c675d05d289ab6110d3" - -[[package]] -name = "futures-executor" -version = "0.3.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9420b90cfa29e327d0429f19be13e7ddb68fa1cccb09d65e5706b8c7a749b8a6" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", - "num_cpus", -] - -[[package]] -name = "futures-io" -version = "0.3.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc4045962a5a5e935ee2fdedaa4e08284547402885ab326734432bed5d12966b" - -[[package]] -name = "futures-macro" -version = "0.3.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33c1e13800337f4d4d7a316bf45a567dbcb6ffe087f16424852d97e97a91f512" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "futures-sink" -version = "0.3.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21163e139fa306126e6eedaf49ecdb4588f939600f0b1e770f4205ee4b7fa868" - -[[package]] -name = "futures-task" -version = "0.3.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57c66a976bf5909d801bbef33416c41372779507e7a6b3a5e25e4749c58f776a" - -[[package]] -name = "futures-util" -version = "0.3.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8b7abd5d659d9b90c8cba917f6ec750a74e2dc23902ef9cd4cc8c8b22e6036a" -dependencies = [ - "futures-channel", - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "generic-array" -version = "0.12.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffdf9f34f1447443d37393cc6c2b8313aebddcd96906caf34e54c68d8e57d7bd" -dependencies = [ - "typenum", -] - -[[package]] -name = "generic-array" -version = "0.14.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "501466ecc8a30d1d3b7fc9229b122b2ce8ed6e9d9223f1138d4babb253e51817" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "js-sys", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", - "wasm-bindgen", -] - -[[package]] -name = "getrandom" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4eb1a864a501629691edf6c15a593b7a51eebaa1e8468e9ddc623de7c9b58ec6" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gimli" -version = "0.26.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78cc372d058dcf6d5ecd98510e7fbc9e5aec4d21de70f65fea8fecebcd881bd4" - -[[package]] -name = "group" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc5ac374b108929de78460075f3dc439fa66df9d8fc77e8f12caa5165fcf0c89" -dependencies = [ - "ff", - "rand_core 0.6.1", - "subtle", -] - -[[package]] -name = "hash-db" -version = "0.15.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d23bd4e7b5eda0d0f3a307e8b381fdc8ba9000f26fbe912250c0a4cc3956364a" - -[[package]] -name = "hash256-std-hasher" -version = "0.15.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92c171d55b98633f4ed3860808f004099b36c1cc29c42cfc53aa8591b21efcf2" -dependencies = [ - "crunchy", -] - -[[package]] -name = "hashbrown" -version = "0.12.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "607c8a29735385251a339424dd462993c0fed8fa09d378f259377df08c126022" -dependencies = [ - "ahash", -] - -[[package]] -name = "hermit-abi" -version = "0.1.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "322f4de77956e22ed0e5032c359a0f1273f1f7f0d79bfa3b8ffbc730d7fbcc5c" -dependencies = [ - "libc", -] - -[[package]] -name = "hermit-abi" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee512640fe35acbfb4bb779db6f0d80704c2cacfa2e39b601ef3e3f47d1ae4c7" -dependencies = [ - "libc", -] - -[[package]] -name = "hex" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "644f9158b2f133fd50f5fb3242878846d9eb792e445c893805ff0e3824006e35" - -[[package]] -name = "hmac" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "126888268dcc288495a26bf004b38c5fdbb31682f992c84ceb046a1f0fe38840" -dependencies = [ - "crypto-mac 0.8.0", - "digest 0.9.0", -] - -[[package]] -name = "hmac" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a2a2320eb7ec0ebe8da8f744d7812d9fc4cb4d09344ac01898dbcb6a20ae69b" -dependencies = [ - "crypto-mac 0.11.1", - "digest 0.9.0", -] - -[[package]] -name = "hmac-drbg" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17ea0a1394df5b6574da6e0c1ade9e78868c9fb0a4e5ef4428e32da4676b85b1" -dependencies = [ - "digest 0.9.0", - "generic-array 0.14.4", - "hmac 0.8.1", -] - -[[package]] -name = "honggfuzz" -version = "0.5.54" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bea09577d948a98a5f59b7c891e274c4fb35ad52f67782b3d0cb53b9c05301f1" -dependencies = [ - "arbitrary", - "lazy_static", - "memmap", -] - -[[package]] -name = "humantime" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" - -[[package]] -name = "impl-codec" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba6a270039626615617f3f36d15fc827041df3b78c439da2cadfa47455a77f2f" -dependencies = [ - "parity-scale-codec", -] - -[[package]] -name = "impl-serde" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b47ca4d2b6931707a55fce5cf66aff80e2178c8b63bbb4ecb5695cbc870ddf6f" -dependencies = [ - "serde", -] - -[[package]] -name = "impl-trait-for-tuples" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11d7a9f6330b71fea57921c9b61c47ee6e84f72d394754eff6163ae67e7395eb" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "integer-sqrt" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "276ec31bcb4a9ee45f58bec6f9ec700ae4cf4f4f8f2fa7e06cb406bd5ffdd770" -dependencies = [ - "num-traits", -] - -[[package]] -name = "io-lifetimes" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7d6c6f8c91b4b9ed43484ad1a938e393caf35960fce7f82a040497207bd8e9e" -dependencies = [ - "libc", - "windows-sys 0.42.0", -] - -[[package]] -name = "is-terminal" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28dfb6c8100ccc63462345b67d1bbc3679177c75ee4bf59bf29c8b1d110b8189" -dependencies = [ - "hermit-abi 0.2.6", - "io-lifetimes", - "rustix", - "windows-sys 0.42.0", -] - -[[package]] -name = "itoa" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd25036021b0de88a0aff6b850051563c6516d0bf53f8638938edbb9de732736" - -[[package]] -name = "itoa" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "112c678d4050afce233f4f2852bb2eb519230b3cf12f33585275537d7e41578d" - -[[package]] -name = "js-sys" -version = "0.3.58" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3fac17f7123a73ca62df411b1bf727ccc805daa070338fda671c86dac1bdc27" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "k256" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19c3a5e0a0b8450278feda242592512e09f61c72e018b8cd5c859482802daf2d" -dependencies = [ - "cfg-if", - "ecdsa", - "elliptic-curve", - "sec1", -] - -[[package]] -name = "keccak" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67c21572b4949434e4fc1e1978b99c5f77064153c59d998bf13ecd96fb5ecba7" - -[[package]] -name = "lazy_static" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" - -[[package]] -name = "libc" -version = "0.2.139" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "201de327520df007757c1f0adce6e827fe8562fbc28bfd9c15571c66ca1f5f79" - -[[package]] -name = "libsecp256k1" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0452aac8bab02242429380e9b2f94ea20cea2b37e2c1777a1358799bbe97f37" -dependencies = [ - "arrayref", - "base64", - "digest 0.9.0", - "hmac-drbg", - "libsecp256k1-core", - "libsecp256k1-gen-ecmult", - "libsecp256k1-gen-genmult", - "rand 0.8.2", - "serde", - "sha2 0.9.9", - "typenum", -] - -[[package]] -name = "libsecp256k1-core" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5be9b9bb642d8522a44d533eab56c16c738301965504753b03ad1de3425d5451" -dependencies = [ - "crunchy", - "digest 0.9.0", - "subtle", -] - -[[package]] -name = "libsecp256k1-gen-ecmult" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3038c808c55c87e8a172643a7d87187fc6c4174468159cb3090659d55bcb4809" -dependencies = [ - "libsecp256k1-core", -] - -[[package]] -name = "libsecp256k1-gen-genmult" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3db8d6ba2cec9eacc40e6e8ccc98931840301f1006e95647ceb2dd5c3aa06f7c" -dependencies = [ - "libsecp256k1-core", -] - -[[package]] -name = "linux-raw-sys" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f051f77a7c8e6957c0696eac88f26b0117e54f52d3fc682ab19397a8812846a4" - -[[package]] -name = "lock_api" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327fa5b6a6940e4699ec49a9beae1ea4845c6bab9314e4f84ac68742139d8c53" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "matchers" -version = "0.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f099785f7595cc4b4553a174ce30dd7589ef93391ff414dbb67f62392b9e0ce1" -dependencies = [ - "regex-automata", -] - -[[package]] -name = "memchr" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" - -[[package]] -name = "memmap" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6585fd95e7bb50d6cc31e20d4cf9afb4e2ba16c5846fc76793f11218da9c475b" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "memory-db" -version = "0.29.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6566c70c1016f525ced45d7b7f97730a2bafb037c788211d0c186ef5b2189f0a" -dependencies = [ - "hash-db", - "hashbrown", - "parity-util-mem", -] - -[[package]] -name = "memory_units" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "71d96e3f3c0b6325d8ccd83c33b28acb183edcb6c67938ba104ec546854b0882" - -[[package]] -name = "merlin" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e261cf0f8b3c42ded9f7d2bb59dea03aa52bc8a1cbc7482f9fc3fd1229d3b42" -dependencies = [ - "byteorder", - "keccak", - "rand_core 0.5.1", - "zeroize", -] - -[[package]] -name = "miniz_oxide" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f5c75688da582b8ffc1f1799e9db273f32133c49e048f614d22ec3256773ccc" -dependencies = [ - "adler", -] - -[[package]] -name = "nodrop" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" - -[[package]] -name = "num-bigint" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "090c7f9998ee0ff65aa5b723e4009f7b217707f1fb5ea551329cc4d6231fb304" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-format" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bafe4179722c2894288ee77a9f044f02811c86af699344c498b0840c698a2465" -dependencies = [ - "arrayvec 0.4.12", - "itoa 0.4.7", -] - -[[package]] -name = "num-integer" -version = "0.1.44" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2cc698a63b549a70bc047073d2949cce27cd1c7b0a4a862d08a8031bc2801db" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-rational" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c000134b5dbf44adc5cb772486d335293351644b801551abe8f75c84cfa4aef" -dependencies = [ - "autocfg", - "num-bigint", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a64b1ec5cda2586e284722486d802acf1f7dbdc623e2bfc57e65ca1cd099290" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05499f3756671c15885fee9034446956fff3f243d6077b91e5767df161f766b3" -dependencies = [ - "hermit-abi 0.1.18", - "libc", -] - -[[package]] -name = "object" -version = "0.29.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21158b2c33aa6d4561f1c0a6ea283ca92bc54802a93b263e910746d679a7eb53" -dependencies = [ - "memchr", -] - -[[package]] -name = "once_cell" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18a6dbe30758c9f83eb00cbea4ac95966305f5a7772f3f42ebfc7fc7eddbd8e1" - -[[package]] -name = "opaque-debug" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2839e79665f131bdb5782e51f2c6c9599c133c6098982a54c794358bf432529c" - -[[package]] -name = "opaque-debug" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" - -[[package]] -name = "parity-scale-codec" -version = "3.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7ab01d0f889e957861bc65888d5ccbe82c158d0270136ba46820d43837cdf72" -dependencies = [ - "arrayvec 0.7.2", - "bitvec", - "byte-slice-cast", - "impl-trait-for-tuples", - "parity-scale-codec-derive", - "serde", -] - -[[package]] -name = "parity-scale-codec-derive" -version = "3.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86b26a931f824dd4eca30b3e43bb4f31cd5f0d3a403c5f5ff27106b805bfde7b" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "parity-util-mem" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c32561d248d352148124f036cac253a644685a21dc9fea383eb4907d7bd35a8f" -dependencies = [ - "cfg-if", - "hashbrown", - "impl-trait-for-tuples", - "parity-util-mem-derive", - "parking_lot", - "primitive-types", - "winapi", -] - -[[package]] -name = "parity-util-mem-derive" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f557c32c6d268a07c921471619c0295f5efad3a0e76d4f97a05c091a51d110b2" -dependencies = [ - "proc-macro2", - "syn", - "synstructure", -] - -[[package]] -name = "parity-wasm" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be5e13c266502aadf83426d87d81a0f5d1ef45b8027f5a471c360abfe4bfae92" - -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09a279cbf25cb0757810394fbc1e359949b59e348145c643a939a525692e6929" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-sys 0.36.1", -] - -[[package]] -name = "paste" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c520e05135d6e763148b6426a837e239041653ba7becd2e538c076c738025fc" - -[[package]] -name = "pbkdf2" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "216eaa586a190f0a738f2f918511eecfa90f13295abec0e457cdebcceda80cbd" -dependencies = [ - "crypto-mac 0.8.0", -] - -[[package]] -name = "pbkdf2" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d95f5254224e617595d2cc3cc73ff0a5eaf2637519e25f03388154e9378b6ffa" -dependencies = [ - "crypto-mac 0.11.1", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "439697af366c49a6d0a010c56a0d97685bc140ce0d377b13a2ea2aa42d64a827" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "ppv-lite86" -version = "0.2.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac74c624d6b2d21f425f752262f42188365d7b8ff1aff74c82e45136510a4857" - -[[package]] -name = "primitive-types" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e28720988bff275df1f51b171e1b2a18c30d194c4d2b61defdacecd625a5d94a" -dependencies = [ - "fixed-hash", - "impl-codec", - "impl-serde", - "scale-info", - "uint", -] - -[[package]] -name = "proc-macro-crate" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e17d47ce914bf4de440332250b0edd23ce48c005f59fab39d3335866b114f11a" -dependencies = [ - "thiserror", - "toml", -] - -[[package]] -name = "proc-macro2" -version = "1.0.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd96a1e8ed2596c337f8eae5f24924ec83f5ad5ab21ea8e455d3566c69fbcaf7" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quote" -version = "1.0.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3bcdf212e9776fbcb2d23ab029360416bb1706b1aea2d1a5ba002727cbcab804" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "radium" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc 0.2.0", - "rand_pcg", -] - -[[package]] -name = "rand" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18519b42a40024d661e1714153e9ad0c3de27cd495760ceb09710920f1098b1e" -dependencies = [ - "libc", - "rand_chacha 0.3.0", - "rand_core 0.6.1", - "rand_hc 0.3.1", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e12735cf05c9e10bf21534da50a147b924d555dc7a547c42e6bb2d5b6017ae0d" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.1", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c026d7df8b298d90ccbbc5190bd04d85e159eaf5576caeacf8741da93ccbd2e5" -dependencies = [ - "getrandom 0.2.7", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -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.1", -] - -[[package]] -name = "rand_pcg" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16abd0c1b639e9eb4d7c50c0b8100b0d0f849be2349829c740fe8e6eb4816429" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "redox_syscall" -version = "0.2.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62f25bc4c7e55e0b0b7a1d43fb893f4fa1361d0abe38b9ce4f323c2adfe6ef42" -dependencies = [ - "bitflags", -] - -[[package]] -name = "ref-cast" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "300f2a835d808734ee295d45007adacb9ebb29dd3ae2424acfa17930cae541da" -dependencies = [ - "ref-cast-impl", -] - -[[package]] -name = "ref-cast-impl" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c38e3aecd2b21cb3959637b883bb3714bc7e43f0268b9a29d3743ee3e55cdd2" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "regex" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c4eb3267174b8c6c2f654116623910a0fef09c4753f8dd83db29c48a0df988b" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae1ded71d66a4a97f5e961fd0cb25a5f366a42a41570d16a763a69c092c26ae4" -dependencies = [ - "byteorder", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.6.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3f87b73ce11b1619a3c6332f45341e0047173771e8b8b73f87bfeefb7b56244" - -[[package]] -name = "rfc6979" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96ef608575f6392792f9ecf7890c00086591d29a83910939d430753f7c050525" -dependencies = [ - "crypto-bigint", - "hmac 0.11.0", - "zeroize", -] - -[[package]] -name = "rustc-demangle" -version = "0.1.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e3bad0ee36814ca07d7968269dd4b7ec89ec2da10c4bb613928d3077083c232" - -[[package]] -name = "rustc-hash" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" - -[[package]] -name = "rustc-hex" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e75f6a532d0fd9f7f13144f392b6ad56a32696bfcd9c78f797f16bbb6f072d6" - -[[package]] -name = "rustix" -version = "0.36.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4fdebc4b395b7fbb9ab11e462e20ed9051e7b16e42d24042c776eca0ac81b03" -dependencies = [ - "bitflags", - "errno", - "io-lifetimes", - "libc", - "linux-raw-sys", - "windows-sys 0.42.0", -] - -[[package]] -name = "ryu" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "71d301d4193d031abdd79ff7e3dd721168a9572ef3fe51a1517aba235bd8f86e" - -[[package]] -name = "scale-info" -version = "2.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c46be926081c9f4dd5dd9b6f1d3e3229f2360bc6502dd8836f84a93b7c75e99a" -dependencies = [ - "bitvec", - "cfg-if", - "derive_more", - "parity-scale-codec", - "scale-info-derive", - "serde", -] - -[[package]] -name = "scale-info-derive" -version = "2.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50e334bb10a245e28e5fd755cabcafd96cfcd167c99ae63a46924ca8d8703a3c" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "schnorrkel" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "021b403afe70d81eea68f6ea12f6b3c9588e5d536a94c3bf80f15e7faa267862" -dependencies = [ - "arrayref", - "arrayvec 0.5.2", - "curve25519-dalek 2.1.2", - "getrandom 0.1.16", - "merlin", - "rand 0.7.3", - "rand_core 0.5.1", - "sha2 0.8.2", - "subtle", - "zeroize", -] - -[[package]] -name = "scopeguard" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" - -[[package]] -name = "sec1" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08da66b8b0965a5555b6bd6639e68ccba85e1e2506f5fbb089e93f8a04e1a2d1" -dependencies = [ - "der", - "generic-array 0.14.4", - "subtle", - "zeroize", -] - -[[package]] -name = "secp256k1" -version = "0.21.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c42e6f1735c5f00f51e43e28d6634141f2bcad10931b2609ddd74a86d751260" -dependencies = [ - "secp256k1-sys", -] - -[[package]] -name = "secp256k1-sys" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "957da2573cde917463ece3570eab4a0b3f19de6f1646cde62e6fd3868f566036" -dependencies = [ - "cc", -] - -[[package]] -name = "secrecy" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9bd1c54ea06cfd2f6b63219704de0b9b4f72dcc2b8fdef820be6cd799780e91e" -dependencies = [ - "zeroize", -] - -[[package]] -name = "serde" -version = "1.0.139" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0171ebb889e45aa68b44aee0859b3eede84c6f5f5c228e6f140c0b2a0a46cad6" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.139" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc1d3230c1de7932af58ad8ffbe1d784bd55efd5a9d84ac24f69c72d83543dfb" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_json" -version = "1.0.82" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82c2c1fdcd807d1098552c5b9a36e425e42e9fbd7c6a37a8425f390f781f7fa7" -dependencies = [ - "itoa 1.0.2", - "ryu", - "serde", -] - -[[package]] -name = "sha2" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a256f46ea78a0c0d9ff00077504903ac881a1dafdc20da66545699e7776b3e69" -dependencies = [ - "block-buffer 0.7.3", - "digest 0.8.1", - "fake-simd", - "opaque-debug 0.2.3", -] - -[[package]] -name = "sha2" -version = "0.9.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" -dependencies = [ - "block-buffer 0.9.0", - "cfg-if", - "cpufeatures", - "digest 0.9.0", - "opaque-debug 0.3.0", -] - -[[package]] -name = "sha2" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "55deaec60f81eefe3cce0dc50bda92d6d8e88f2a27df7c5033b42afeb1ed2676" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.3", -] - -[[package]] -name = "sha3" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "881bf8156c87b6301fc5ca6b27f11eeb2761224c7081e69b409d5a1951a70c86" -dependencies = [ - "digest 0.10.3", - "keccak", -] - -[[package]] -name = "sharded-slab" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79c719719ee05df97490f80a45acfc99e5a30ce98a1e4fb67aee422745ae14e3" -dependencies = [ - "lazy_static", -] - -[[package]] -name = "signature" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02658e48d89f2bec991f9a78e69cfa4c316f8d6a6c4ec12fae1aeb263d486788" -dependencies = [ - "digest 0.9.0", - "rand_core 0.6.1", -] - -[[package]] -name = "slab" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c111b5bd5695e56cffe5129854aa230b39c93a305372fdbb2668ca2394eea9f8" - -[[package]] -name = "smallvec" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fd0db749597d91ff862fd1d55ea87f7855a744a8425a64695b6fca237d1dad1" - -[[package]] -name = "sp-application-crypto" -version = "6.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "parity-scale-codec", - "scale-info", - "serde", - "sp-core", - "sp-io", - "sp-std", -] - -[[package]] -name = "sp-arithmetic" -version = "5.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "integer-sqrt", - "num-traits", - "parity-scale-codec", - "scale-info", - "serde", - "sp-debug-derive", - "sp-std", - "static_assertions", -] - -[[package]] -name = "sp-core" -version = "6.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "base58", - "bitflags", - "blake2-rfc", - "byteorder", - "dyn-clonable", - "ed25519-dalek", - "futures", - "hash-db", - "hash256-std-hasher", - "hex", - "impl-serde", - "lazy_static", - "libsecp256k1", - "log", - "merlin", - "num-traits", - "parity-scale-codec", - "parity-util-mem", - "parking_lot", - "primitive-types", - "rand 0.7.3", - "regex", - "scale-info", - "schnorrkel", - "secp256k1", - "secrecy", - "serde", - "sp-core-hashing", - "sp-debug-derive", - "sp-externalities", - "sp-runtime-interface", - "sp-std", - "sp-storage", - "ss58-registry", - "substrate-bip39", - "thiserror", - "tiny-bip39", - "wasmi", - "zeroize", -] - -[[package]] -name = "sp-core-hashing" -version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "blake2", - "byteorder", - "digest 0.10.3", - "sha2 0.10.2", - "sha3", - "sp-std", - "twox-hash", -] - -[[package]] -name = "sp-core-hashing-proc-macro" -version = "5.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "proc-macro2", - "quote", - "sp-core-hashing", - "syn", -] - -[[package]] -name = "sp-debug-derive" -version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "sp-externalities" -version = "0.12.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "environmental", - "parity-scale-codec", - "sp-std", - "sp-storage", -] - -[[package]] -name = "sp-inherents" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "async-trait", - "impl-trait-for-tuples", - "parity-scale-codec", - "sp-core", - "sp-runtime", - "sp-std", - "thiserror", -] - -[[package]] -name = "sp-io" -version = "6.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "futures", - "hash-db", - "libsecp256k1", - "log", - "parity-scale-codec", - "parking_lot", - "secp256k1", - "sp-core", - "sp-externalities", - "sp-keystore", - "sp-runtime-interface", - "sp-state-machine", - "sp-std", - "sp-tracing", - "sp-trie", - "sp-wasm-interface", - "tracing", - "tracing-core", -] - -[[package]] -name = "sp-keystore" -version = "0.12.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "async-trait", - "futures", - "merlin", - "parity-scale-codec", - "parking_lot", - "schnorrkel", - "sp-core", - "sp-externalities", - "thiserror", -] - -[[package]] -name = "sp-panic-handler" -version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "backtrace", - "lazy_static", - "regex", -] - -[[package]] -name = "sp-runtime" -version = "6.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "either", - "hash256-std-hasher", - "impl-trait-for-tuples", - "log", - "parity-scale-codec", - "parity-util-mem", - "paste", - "rand 0.7.3", - "scale-info", - "serde", - "sp-application-crypto", - "sp-arithmetic", - "sp-core", - "sp-io", - "sp-std", -] - -[[package]] -name = "sp-runtime-interface" -version = "6.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "impl-trait-for-tuples", - "parity-scale-codec", - "primitive-types", - "sp-externalities", - "sp-runtime-interface-proc-macro", - "sp-std", - "sp-storage", - "sp-tracing", - "sp-wasm-interface", - "static_assertions", -] - -[[package]] -name = "sp-runtime-interface-proc-macro" -version = "5.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "Inflector", - "proc-macro-crate", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "sp-staking" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "parity-scale-codec", - "scale-info", - "sp-runtime", - "sp-std", -] - -[[package]] -name = "sp-state-machine" -version = "0.12.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "hash-db", - "log", - "num-traits", - "parity-scale-codec", - "parking_lot", - "rand 0.7.3", - "smallvec", - "sp-core", - "sp-externalities", - "sp-panic-handler", - "sp-std", - "sp-trie", - "thiserror", - "tracing", - "trie-root", -] - -[[package]] -name = "sp-std" -version = "4.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" - -[[package]] -name = "sp-storage" -version = "6.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "impl-serde", - "parity-scale-codec", - "ref-cast", - "serde", - "sp-debug-derive", - "sp-std", -] - -[[package]] -name = "sp-tracing" -version = "5.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "parity-scale-codec", - "sp-std", - "tracing", - "tracing-core", - "tracing-subscriber", -] - -[[package]] -name = "sp-trie" -version = "6.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "hash-db", - "memory-db", - "parity-scale-codec", - "scale-info", - "sp-core", - "sp-std", - "thiserror", - "trie-db 0.23.1", - "trie-root", -] - -[[package]] -name = "sp-version" -version = "5.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "impl-serde", - "parity-scale-codec", - "parity-wasm", - "scale-info", - "serde", - "sp-core-hashing-proc-macro", - "sp-runtime", - "sp-std", - "sp-version-proc-macro", - "thiserror", -] - -[[package]] -name = "sp-version-proc-macro" -version = "4.0.0-dev" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "parity-scale-codec", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "sp-wasm-interface" -version = "6.0.0" -source = "git+https://github.com/paritytech/substrate?branch=master#367dab0d4bd7fd7b6c222dd15c753169c057dd42" -dependencies = [ - "impl-trait-for-tuples", - "log", - "parity-scale-codec", - "sp-std", - "wasmi", -] - -[[package]] -name = "ss58-registry" -version = "1.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77ef98aedad3dc52e10995e7ed15f1279e11d4da35795f5dac7305742d0feb66" -dependencies = [ - "Inflector", - "num-format", - "proc-macro2", - "quote", - "serde", - "serde_json", - "unicode-xid", -] - -[[package]] -name = "static_assertions" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" - -[[package]] -name = "storage-proof-fuzzer" -version = "0.1.0" -dependencies = [ - "bp-runtime", - "env_logger", - "honggfuzz", - "log", - "sp-core", - "sp-runtime", - "sp-state-machine", - "sp-std", - "sp-trie", -] - -[[package]] -name = "substrate-bip39" -version = "0.4.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49eee6965196b32f882dd2ee85a92b1dbead41b04e53907f269de3b0dc04733c" -dependencies = [ - "hmac 0.11.0", - "pbkdf2 0.8.0", - "schnorrkel", - "sha2 0.9.9", - "zeroize", -] - -[[package]] -name = "subtle" -version = "2.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e81da0851ada1f3e9d4312c704aa4f8806f0f9d69faaf8df2f3464b4a9437c2" - -[[package]] -name = "syn" -version = "1.0.98" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c50aef8a904de4c23c788f104b7dddc7d6f79c647c7c8ce4cc8f73eb0ca773dd" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "synstructure" -version = "0.12.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b834f2d66f734cb897113e34aaff2f1ab4719ca946f9a7358dba8f8064148701" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "unicode-xid", -] - -[[package]] -name = "tap" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" - -[[package]] -name = "termcolor" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bab24d30b911b2376f3a13cc2cd443142f0c81dda04c118693e35b3835757755" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "thiserror" -version = "1.0.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd829fe32373d27f76265620b5309d0340cb8550f523c1dda251d6298069069a" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0396bc89e626244658bef819e22d0cc459e795a5ebe878e6ec336d1674a8d79a" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "thread_local" -version = "1.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5516c27b78311c50bf42c071425c560ac799b11c30b31f87e3081965fe5e0180" -dependencies = [ - "once_cell", -] - -[[package]] -name = "tiny-bip39" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffc59cb9dfc85bb312c3a78fd6aa8a8582e310b0fa885d5bb877f6dcc601839d" -dependencies = [ - "anyhow", - "hmac 0.8.1", - "once_cell", - "pbkdf2 0.4.0", - "rand 0.7.3", - "rustc-hash", - "sha2 0.9.9", - "thiserror", - "unicode-normalization", - "wasm-bindgen", - "zeroize", -] - -[[package]] -name = "tinyvec" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccf8dbc19eb42fba10e8feaaec282fb50e2c14b2726d6301dbfeed0f73306a6f" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cda74da7e1a664f795bb1f8a87ec406fb89a02522cf6e50620d016add6dbbf5c" - -[[package]] -name = "toml" -version = "0.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a31142970826733df8241ef35dc040ef98c679ab14d7c3e54d827099b3acecaa" -dependencies = [ - "serde", -] - -[[package]] -name = "tracing" -version = "0.1.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a400e31aa60b9d44a52a8ee0343b5b18566b03a8321e0d321f695cf56e940160" -dependencies = [ - "cfg-if", - "pin-project-lite", - "tracing-attributes", - "tracing-core", -] - -[[package]] -name = "tracing-attributes" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11c75893af559bc8e10716548bdef5cb2b983f8e637db9d0e15126b61b484ee2" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tracing-core" -version = "0.1.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b7358be39f2f274f322d2aaed611acc57f382e8eb1e5b48cb9ae30933495ce7" -dependencies = [ - "once_cell", - "valuable", -] - -[[package]] -name = "tracing-log" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" -dependencies = [ - "lazy_static", - "log", - "tracing-core", -] - -[[package]] -name = "tracing-serde" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb65ea441fbb84f9f6748fd496cf7f63ec9af5bca94dd86456978d055e8eb28b" -dependencies = [ - "serde", - "tracing-core", -] - -[[package]] -name = "tracing-subscriber" -version = "0.2.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e0d2eaa99c3c2e41547cfa109e910a68ea03823cccad4a0525dcbc9b01e8c71" -dependencies = [ - "ansi_term", - "chrono", - "lazy_static", - "matchers", - "regex", - "serde", - "serde_json", - "sharded-slab", - "smallvec", - "thread_local", - "tracing", - "tracing-core", - "tracing-log", - "tracing-serde", -] - -[[package]] -name = "trie-db" -version = "0.23.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d32d034c0d3db64b43c31de38e945f15b40cd4ca6d2dcfc26d4798ce8de4ab83" -dependencies = [ - "hash-db", - "hashbrown", - "log", - "rustc-hex", - "smallvec", -] - -[[package]] -name = "trie-db" -version = "0.24.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "004e1e8f92535694b4cb1444dc5a8073ecf0815e3357f729638b9f8fc4062908" -dependencies = [ - "hash-db", - "hashbrown", - "log", - "rustc-hex", - "smallvec", -] - -[[package]] -name = "trie-root" -version = "0.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a36c5ca3911ed3c9a5416ee6c679042064b93fc637ded67e25f92e68d783891" -dependencies = [ - "hash-db", -] - -[[package]] -name = "tt-call" -version = "1.0.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e66dcbec4290c69dd03c57e76c2469ea5c7ce109c6dd4351c13055cf71ea055" - -[[package]] -name = "twox-hash" -version = "1.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97fee6b57c6a41524a810daee9286c02d7752c4253064d0b05472833a438f675" -dependencies = [ - "cfg-if", - "digest 0.10.3", - "rand 0.8.2", - "static_assertions", -] - -[[package]] -name = "typenum" -version = "1.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcf81ac59edc17cc8697ff311e8f5ef2d99fcbd9817b34cec66f90b6c3dfd987" - -[[package]] -name = "uint" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e11fe9a9348741cf134085ad57c249508345fe16411b3d7fb4ff2da2f1d6382e" -dependencies = [ - "byteorder", - "crunchy", - "hex", - "static_assertions", -] - -[[package]] -name = "unicode-ident" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5bd2fe26506023ed7b5e1e315add59d6f584c621d037f9368fea9cfb988f368c" - -[[package]] -name = "unicode-normalization" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a13e63ab62dbe32aeee58d1c5408d35c36c392bba5d9d3142287219721afe606" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-xid" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "957e51f3646910546462e67d5f7599b9e4fb8acdd304b087a6494730f9eebf04" - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[package]] -name = "version_check" -version = "0.9.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5a972e5669d67ba988ce3dc826706fb0a8b01471c088cb0b6110b805cc36aed" - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.81" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c53b543413a17a202f4be280a7e5c62a1c69345f5de525ee64f8cfdbc954994" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.81" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5491a68ab4500fa6b4d726bd67408630c3dbe9c4fe7bda16d5c82a1fd8c7340a" -dependencies = [ - "bumpalo", - "lazy_static", - "log", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.81" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c441e177922bc58f1e12c022624b6216378e5febc2f0533e41ba443d505b80aa" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.81" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d94ac45fcf608c1f45ef53e748d35660f168490c10b23704c7779ab8f5c3048" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.81" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a89911bd99e5f3659ec4acf9c4d93b0a90fe4a2a11f15328472058edc5261be" - -[[package]] -name = "wasmi" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca00c5147c319a8ec91ec1a0edbec31e566ce2c9cc93b3f9bb86a9efd0eb795d" -dependencies = [ - "downcast-rs", - "libc", - "memory_units", - "num-rational", - "num-traits", - "parity-wasm", - "wasmi-validation", -] - -[[package]] -name = "wasmi-validation" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "165343ecd6c018fc09ebcae280752702c9a2ef3e6f8d02f1cfcbdb53ef6d7937" -dependencies = [ - "parity-wasm", -] - -[[package]] -name = "winapi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" -dependencies = [ - "winapi-i686-pc-windows-gnu", - "winapi-x86_64-pc-windows-gnu", -] - -[[package]] -name = "winapi-i686-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" - -[[package]] -name = "winapi-util" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178" -dependencies = [ - "winapi", -] - -[[package]] -name = "winapi-x86_64-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" - -[[package]] -name = "windows-sys" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea04155a16a59f9eab786fe12a4a450e75cdb175f9e0d80da1e17db09f55b8d2" -dependencies = [ - "windows_aarch64_msvc 0.36.1", - "windows_i686_gnu 0.36.1", - "windows_i686_msvc 0.36.1", - "windows_x86_64_gnu 0.36.1", - "windows_x86_64_msvc 0.36.1", -] - -[[package]] -name = "windows-sys" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" -dependencies = [ - "windows_aarch64_gnullvm", - "windows_aarch64_msvc 0.42.1", - "windows_i686_gnu 0.42.1", - "windows_i686_msvc 0.42.1", - "windows_x86_64_gnu 0.42.1", - "windows_x86_64_gnullvm", - "windows_x86_64_msvc 0.42.1", -] - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c9864e83243fdec7fc9c5444389dcbbfd258f745e7853198f365e3c4968a608" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9bb8c3fd39ade2d67e9874ac4f3db21f0d710bee00fe7cab16949ec184eeaa47" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c8b1b673ffc16c47a9ff48570a9d85e25d265735c503681332589af6253c6c7" - -[[package]] -name = "windows_i686_gnu" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "180e6ccf01daf4c426b846dfc66db1fc518f074baa793aa7d9b9aaeffad6a3b6" - -[[package]] -name = "windows_i686_gnu" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3887528ad530ba7bdbb1faa8275ec7a1155a45ffa57c37993960277145d640" - -[[package]] -name = "windows_i686_msvc" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2e7917148b2812d1eeafaeb22a97e4813dfa60a3f8f78ebe204bcc88f12f024" - -[[package]] -name = "windows_i686_msvc" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf4d1122317eddd6ff351aa852118a2418ad4214e6613a50e0191f7004372605" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dcd171b8776c41b97521e5da127a2d86ad280114807d0b2ab1e462bc764d9e1" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1040f221285e17ebccbc2591ffdc2d44ee1f9186324dd3e84e99ac68d699c45" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "628bfdf232daa22b0d64fdb62b09fcc36bb01f05a3939e20ab73aaf9470d0463" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c811ca4a8c853ef420abd8592ba53ddbbac90410fab6903b3e79972a631f7680" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "447660ad36a13288b1db4d4248e857b510e8c3a225c822ba4fb748c0aafecffd" - -[[package]] -name = "wyz" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30b31594f29d27036c383b53b59ed3476874d518f0efb151b27a4c275141390e" -dependencies = [ - "tap", -] - -[[package]] -name = "zeroize" -version = "1.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20b578acffd8516a6c3f2a1bdefc1ec37e547bb4e0fb8b6b01a4cafc886b4442" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f8f187641dad4f680d25c4bfc4225b418165984179f26ca76ec4fb6441d3a17" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "synstructure", -] diff --git a/fuzz/storage-proof/Cargo.toml b/fuzz/storage-proof/Cargo.toml deleted file mode 100644 index 4bd087365afff..0000000000000 --- a/fuzz/storage-proof/Cargo.toml +++ /dev/null @@ -1,25 +0,0 @@ -[package] -name = "storage-proof-fuzzer" -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html - -[dependencies] -honggfuzz = "0.5.54" -log = "0.4.20" -env_logger = "0.10.1" - -# Bridge Dependencies - -bp-runtime = { path = "../../primitives/runtime" } - -# Substrate Dependencies - -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-state-machine = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-std = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-trie = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } diff --git a/fuzz/storage-proof/README.md b/fuzz/storage-proof/README.md deleted file mode 100644 index 1eeec7562a961..0000000000000 --- a/fuzz/storage-proof/README.md +++ /dev/null @@ -1,34 +0,0 @@ -# Storage Proof Fuzzer - -## How to run? - -Install dependencies: -``` -$ sudo apt install build-essential binutils-dev libunwind-dev -``` -or on nix: -``` -$ nix-shell -p honggfuzz -``` - -Install `cargo hfuzz` plugin: -``` -$ cargo install honggfuzz -``` - -Run: -``` -$ cargo hfuzz run storage-proof-fuzzer -``` - -Use `HFUZZ_RUN_ARGS` to customize execution: -``` -# 1 second of timeout -# use 12 fuzzing thread -# be verbose -# stop after 1000000 fuzzing iteration -# exit upon crash -HFUZZ_RUN_ARGS="-t 1 -n 12 -v -N 1000000 --exit_upon_crash" cargo hfuzz run example -``` - -More details in the [official documentation](https://docs.rs/honggfuzz/0.5.52/honggfuzz/#about-honggfuzz). diff --git a/fuzz/storage-proof/src/main.rs b/fuzz/storage-proof/src/main.rs deleted file mode 100644 index 9ceda58d16359..0000000000000 --- a/fuzz/storage-proof/src/main.rs +++ /dev/null @@ -1,78 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Storage Proof Checker fuzzer. - -#![warn(missing_docs)] - -use honggfuzz::fuzz; -// Logic for checking Substrate storage proofs. - -use sp_core::{Blake2Hasher, H256}; -use sp_state_machine::{backend::Backend, prove_read, InMemoryBackend}; -use sp_std::vec::Vec; -use std::collections::HashMap; - -fn craft_known_storage_proof( - input_vec: Vec<(Vec, Vec)>, -) -> (H256, bp_runtime::RawStorageProof) { - let storage_proof_vec = - vec![(None, input_vec.iter().map(|x| (x.0.clone(), Some(x.1.clone()))).collect())]; - log::info!("Storage proof vec {:?}", storage_proof_vec); - let state_version = sp_runtime::StateVersion::default(); - let backend = >::from((storage_proof_vec, state_version)); - let root = backend.storage_root(std::iter::empty(), state_version).0; - let vector_element_proof = - prove_read(backend, input_vec.iter().map(|x| x.0.as_slice())).unwrap(); - (root, vector_element_proof.iter_nodes().cloned().collect()) -} - -fn transform_into_unique(input_vec: Vec<(Vec, Vec)>) -> Vec<(Vec, Vec)> { - let mut output_hashmap = HashMap::new(); - let mut output_vec = Vec::new(); - for key_value_pair in input_vec { - output_hashmap.insert(key_value_pair.0, key_value_pair.1); //Only 1 value per key - } - for (key, val) in output_hashmap.iter() { - output_vec.push((key.clone(), val.clone())); - } - output_vec -} - -fn run_fuzzer() { - fuzz!(|input_vec: Vec<(Vec, Vec)>| { - if input_vec.is_empty() { - return - } - let unique_input_vec = transform_into_unique(input_vec); - let (root, craft_known_storage_proof) = craft_known_storage_proof(unique_input_vec.clone()); - let mut checker = - >::new(root, craft_known_storage_proof) - .expect("Valid proof passed; qed"); - for key_value_pair in unique_input_vec { - log::info!("Reading value for pair {:?}", key_value_pair); - assert_eq!(checker.read_value(&key_value_pair.0), Ok(Some(key_value_pair.1.clone()))); - } - }) -} - -fn main() { - env_logger::init(); - - loop { - run_fuzzer(); - } -} diff --git a/local.Dockerfile.dockerignore b/local.Dockerfile.dockerignore index 068e4c39b6619..2b771e7ef6346 100644 --- a/local.Dockerfile.dockerignore +++ b/local.Dockerfile.dockerignore @@ -1,6 +1,3 @@ # This file only works for `local.Dockerfile` when docker buildkit is used (see ./scripts/build-containers.sh for details) * -!target/release/millau-bridge-node -!target/release/rialto-bridge-node* -!target/release/rialto-parachain-collator !target/release/substrate-relay diff --git a/modules/grandpa/src/weights.rs b/modules/grandpa/src/weights.rs index 89ed70d13ac33..a75e7b5a8e4ad 100644 --- a/modules/grandpa/src/weights.rs +++ b/modules/grandpa/src/weights.rs @@ -23,7 +23,7 @@ //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// target/release/millau-bridge-node +// target/release/unknown-bridge-node // benchmark // pallet // --chain=dev @@ -58,39 +58,39 @@ pub trait WeightInfo { /// Those weights are test only and must never be used in production. pub struct BridgeWeight(PhantomData); impl WeightInfo for BridgeWeight { - /// Storage: BridgeRialtoGrandpa PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownGrandpa PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa PalletOperatingMode (max_values: Some(1), max_size: Some(1), + /// Proof: BridgeUnknownGrandpa PalletOperatingMode (max_values: Some(1), max_size: Some(1), /// added: 496, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa RequestCount (r:1 w:1) + /// Storage: BridgeUnknownGrandpa RequestCount (r:1 w:1) /// - /// Proof: BridgeRialtoGrandpa RequestCount (max_values: Some(1), max_size: Some(4), added: 499, - /// mode: MaxEncodedLen) + /// Proof: BridgeUnknownGrandpa RequestCount (max_values: Some(1), max_size: Some(4), added: + /// 499, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa BestFinalized (r:1 w:1) + /// Storage: BridgeUnknownGrandpa BestFinalized (r:1 w:1) /// - /// Proof: BridgeRialtoGrandpa BestFinalized (max_values: Some(1), max_size: Some(36), added: + /// Proof: BridgeUnknownGrandpa BestFinalized (max_values: Some(1), max_size: Some(36), added: /// 531, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa CurrentAuthoritySet (r:1 w:0) + /// Storage: BridgeUnknownGrandpa CurrentAuthoritySet (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa CurrentAuthoritySet (max_values: Some(1), max_size: Some(209), + /// Proof: BridgeUnknownGrandpa CurrentAuthoritySet (max_values: Some(1), max_size: Some(209), /// added: 704, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHashesPointer (r:1 w:1) + /// Storage: BridgeUnknownGrandpa ImportedHashesPointer (r:1 w:1) /// - /// Proof: BridgeRialtoGrandpa ImportedHashesPointer (max_values: Some(1), max_size: Some(4), + /// Proof: BridgeUnknownGrandpa ImportedHashesPointer (max_values: Some(1), max_size: Some(4), /// added: 499, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHashes (r:1 w:1) + /// Storage: BridgeUnknownGrandpa ImportedHashes (r:1 w:1) /// - /// Proof: BridgeRialtoGrandpa ImportedHashes (max_values: Some(14400), max_size: Some(36), + /// Proof: BridgeUnknownGrandpa ImportedHashes (max_values: Some(14400), max_size: Some(36), /// added: 2016, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:0 w:2) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:0 w:2) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// /// The range of component `p` is `[1, 4]`. @@ -113,39 +113,39 @@ impl WeightInfo for BridgeWeight { // For backwards compatibility and tests impl WeightInfo for () { - /// Storage: BridgeRialtoGrandpa PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownGrandpa PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa PalletOperatingMode (max_values: Some(1), max_size: Some(1), + /// Proof: BridgeUnknownGrandpa PalletOperatingMode (max_values: Some(1), max_size: Some(1), /// added: 496, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa RequestCount (r:1 w:1) + /// Storage: BridgeUnknownGrandpa RequestCount (r:1 w:1) /// - /// Proof: BridgeRialtoGrandpa RequestCount (max_values: Some(1), max_size: Some(4), added: 499, - /// mode: MaxEncodedLen) + /// Proof: BridgeUnknownGrandpa RequestCount (max_values: Some(1), max_size: Some(4), added: + /// 499, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa BestFinalized (r:1 w:1) + /// Storage: BridgeUnknownGrandpa BestFinalized (r:1 w:1) /// - /// Proof: BridgeRialtoGrandpa BestFinalized (max_values: Some(1), max_size: Some(36), added: + /// Proof: BridgeUnknownGrandpa BestFinalized (max_values: Some(1), max_size: Some(36), added: /// 531, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa CurrentAuthoritySet (r:1 w:0) + /// Storage: BridgeUnknownGrandpa CurrentAuthoritySet (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa CurrentAuthoritySet (max_values: Some(1), max_size: Some(209), + /// Proof: BridgeUnknownGrandpa CurrentAuthoritySet (max_values: Some(1), max_size: Some(209), /// added: 704, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHashesPointer (r:1 w:1) + /// Storage: BridgeUnknownGrandpa ImportedHashesPointer (r:1 w:1) /// - /// Proof: BridgeRialtoGrandpa ImportedHashesPointer (max_values: Some(1), max_size: Some(4), + /// Proof: BridgeUnknownGrandpa ImportedHashesPointer (max_values: Some(1), max_size: Some(4), /// added: 499, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHashes (r:1 w:1) + /// Storage: BridgeUnknownGrandpa ImportedHashes (r:1 w:1) /// - /// Proof: BridgeRialtoGrandpa ImportedHashes (max_values: Some(14400), max_size: Some(36), + /// Proof: BridgeUnknownGrandpa ImportedHashes (max_values: Some(14400), max_size: Some(36), /// added: 2016, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:0 w:2) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:0 w:2) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// /// The range of component `p` is `[1, 4]`. diff --git a/modules/messages/src/weights.rs b/modules/messages/src/weights.rs index 5b6863984ec78..5bf7d56756079 100644 --- a/modules/messages/src/weights.rs +++ b/modules/messages/src/weights.rs @@ -14,7 +14,7 @@ // You should have received a copy of the GNU General Public License // along with Parity Bridges Common. If not, see . -//! Autogenerated weights for RialtoMessages +//! Autogenerated weights for pallet_bridge_messages //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev //! DATE: 2023-03-23, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` @@ -23,13 +23,13 @@ //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// target/release/millau-bridge-node +// target/release/unknown-bridge-node // benchmark // pallet // --chain=dev // --steps=50 // --repeat=20 -// --pallet=RialtoMessages +// --pallet=pallet_bridge_messages // --extrinsic=* // --execution=wasm // --wasm-execution=Compiled @@ -48,7 +48,7 @@ use frame_support::{ }; use sp_std::marker::PhantomData; -/// Weight functions needed for RialtoMessages. +/// Weight functions needed for pallet_bridge_messages. pub trait WeightInfo { fn receive_single_message_proof() -> Weight; fn receive_two_messages_proof() -> Weight; @@ -61,24 +61,24 @@ pub trait WeightInfo { fn receive_single_message_proof_with_dispatch(i: u32) -> Weight; } -/// Weights for `RialtoMessages` that are generated using one of the Bridge testnets. +/// Weights for `pallet_bridge_messages` that are generated using one of the Bridge testnets. /// /// Those weights are test only and must never be used in production. pub struct BridgeWeight(PhantomData); impl WeightInfo for BridgeWeight { - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) fn receive_single_message_proof() -> Weight { // Proof Size summary in bytes: @@ -89,19 +89,19 @@ impl WeightInfo for BridgeWeight { .saturating_add(T::DbWeight::get().reads(3_u64)) .saturating_add(T::DbWeight::get().writes(1_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) fn receive_two_messages_proof() -> Weight { // Proof Size summary in bytes: @@ -112,19 +112,19 @@ impl WeightInfo for BridgeWeight { .saturating_add(T::DbWeight::get().reads(3_u64)) .saturating_add(T::DbWeight::get().writes(1_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) fn receive_single_message_proof_with_outbound_lane_state() -> Weight { // Proof Size summary in bytes: @@ -135,19 +135,19 @@ impl WeightInfo for BridgeWeight { .saturating_add(T::DbWeight::get().reads(3_u64)) .saturating_add(T::DbWeight::get().writes(1_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) fn receive_single_message_proof_1_kb() -> Weight { // Proof Size summary in bytes: @@ -158,19 +158,19 @@ impl WeightInfo for BridgeWeight { .saturating_add(T::DbWeight::get().reads(3_u64)) .saturating_add(T::DbWeight::get().writes(1_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) fn receive_single_message_proof_16_kb() -> Weight { // Proof Size summary in bytes: @@ -181,19 +181,19 @@ impl WeightInfo for BridgeWeight { .saturating_add(T::DbWeight::get().reads(3_u64)) .saturating_add(T::DbWeight::get().writes(1_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages OutboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages OutboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: + /// Proof: BridgeUnknownMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: /// 539, mode: MaxEncodedLen) /// /// Storage: BridgeRelayers RelayerRewards (r:1 w:1) @@ -209,19 +209,19 @@ impl WeightInfo for BridgeWeight { .saturating_add(T::DbWeight::get().reads(4_u64)) .saturating_add(T::DbWeight::get().writes(2_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages OutboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages OutboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: + /// Proof: BridgeUnknownMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: /// 539, mode: MaxEncodedLen) /// /// Storage: BridgeRelayers RelayerRewards (r:1 w:1) @@ -237,19 +237,19 @@ impl WeightInfo for BridgeWeight { .saturating_add(T::DbWeight::get().reads(4_u64)) .saturating_add(T::DbWeight::get().writes(2_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages OutboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages OutboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: + /// Proof: BridgeUnknownMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: /// 539, mode: MaxEncodedLen) /// /// Storage: BridgeRelayers RelayerRewards (r:2 w:2) @@ -265,19 +265,19 @@ impl WeightInfo for BridgeWeight { .saturating_add(T::DbWeight::get().reads(5_u64)) .saturating_add(T::DbWeight::get().writes(3_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) /// /// The range of component `i` is `[128, 2048]`. @@ -296,19 +296,19 @@ impl WeightInfo for BridgeWeight { // For backwards compatibility and tests impl WeightInfo for () { - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) fn receive_single_message_proof() -> Weight { // Proof Size summary in bytes: @@ -319,19 +319,19 @@ impl WeightInfo for () { .saturating_add(RocksDbWeight::get().reads(3_u64)) .saturating_add(RocksDbWeight::get().writes(1_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) fn receive_two_messages_proof() -> Weight { // Proof Size summary in bytes: @@ -342,19 +342,19 @@ impl WeightInfo for () { .saturating_add(RocksDbWeight::get().reads(3_u64)) .saturating_add(RocksDbWeight::get().writes(1_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) fn receive_single_message_proof_with_outbound_lane_state() -> Weight { // Proof Size summary in bytes: @@ -365,19 +365,19 @@ impl WeightInfo for () { .saturating_add(RocksDbWeight::get().reads(3_u64)) .saturating_add(RocksDbWeight::get().writes(1_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) fn receive_single_message_proof_1_kb() -> Weight { // Proof Size summary in bytes: @@ -388,19 +388,19 @@ impl WeightInfo for () { .saturating_add(RocksDbWeight::get().reads(3_u64)) .saturating_add(RocksDbWeight::get().writes(1_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) fn receive_single_message_proof_16_kb() -> Weight { // Proof Size summary in bytes: @@ -411,19 +411,19 @@ impl WeightInfo for () { .saturating_add(RocksDbWeight::get().reads(3_u64)) .saturating_add(RocksDbWeight::get().writes(1_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages OutboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages OutboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: + /// Proof: BridgeUnknownMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: /// 539, mode: MaxEncodedLen) /// /// Storage: BridgeRelayers RelayerRewards (r:1 w:1) @@ -439,19 +439,19 @@ impl WeightInfo for () { .saturating_add(RocksDbWeight::get().reads(4_u64)) .saturating_add(RocksDbWeight::get().writes(2_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages OutboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages OutboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: + /// Proof: BridgeUnknownMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: /// 539, mode: MaxEncodedLen) /// /// Storage: BridgeRelayers RelayerRewards (r:1 w:1) @@ -467,19 +467,19 @@ impl WeightInfo for () { .saturating_add(RocksDbWeight::get().reads(4_u64)) .saturating_add(RocksDbWeight::get().writes(2_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages OutboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages OutboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: + /// Proof: BridgeUnknownMessages OutboundLanes (max_values: Some(1), max_size: Some(44), added: /// 539, mode: MaxEncodedLen) /// /// Storage: BridgeRelayers RelayerRewards (r:2 w:2) @@ -495,19 +495,19 @@ impl WeightInfo for () { .saturating_add(RocksDbWeight::get().reads(5_u64)) .saturating_add(RocksDbWeight::get().writes(3_u64)) } - /// Storage: BridgeRialtoMessages PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownMessages PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), + /// Proof: BridgeUnknownMessages PalletOperatingMode (max_values: Some(1), max_size: Some(2), /// added: 497, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoMessages InboundLanes (r:1 w:1) + /// Storage: BridgeUnknownMessages InboundLanes (r:1 w:1) /// - /// Proof: BridgeRialtoMessages InboundLanes (max_values: None, max_size: Some(49180), added: + /// Proof: BridgeUnknownMessages InboundLanes (max_values: None, max_size: Some(49180), added: /// 51655, mode: MaxEncodedLen) /// /// The range of component `i` is `[128, 2048]`. diff --git a/modules/parachains/src/weights.rs b/modules/parachains/src/weights.rs index 9182ec466117b..abddc87689470 100644 --- a/modules/parachains/src/weights.rs +++ b/modules/parachains/src/weights.rs @@ -23,7 +23,7 @@ //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// target/release/millau-bridge-node +// target/release/unknown-bridge-node // benchmark // pallet // --chain=dev @@ -60,29 +60,29 @@ pub trait WeightInfo { /// Those weights are test only and must never be used in production. pub struct BridgeWeight(PhantomData); impl WeightInfo for BridgeWeight { - /// Storage: BridgeRialtoParachains PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownParachains PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), + /// Proof: BridgeUnknownParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), /// added: 496, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ParasInfo (r:1 w:1) + /// Storage: BridgeUnknownParachains ParasInfo (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: + /// Proof: BridgeUnknownParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: /// 555, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHashes (r:1 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHashes (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHashes (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHashes (max_values: Some(1024), max_size: /// Some(64), added: 1549, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:0 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHeads (r:0 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHeads (max_values: Some(1024), max_size: /// Some(196), added: 1681, mode: MaxEncodedLen) /// /// The range of component `p` is `[1, 2]`. @@ -97,29 +97,29 @@ impl WeightInfo for BridgeWeight { .saturating_add(T::DbWeight::get().reads(4_u64)) .saturating_add(T::DbWeight::get().writes(3_u64)) } - /// Storage: BridgeRialtoParachains PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownParachains PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), + /// Proof: BridgeUnknownParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), /// added: 496, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ParasInfo (r:1 w:1) + /// Storage: BridgeUnknownParachains ParasInfo (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: + /// Proof: BridgeUnknownParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: /// 555, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHashes (r:1 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHashes (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHashes (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHashes (max_values: Some(1024), max_size: /// Some(64), added: 1549, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:0 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHeads (r:0 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHeads (max_values: Some(1024), max_size: /// Some(196), added: 1681, mode: MaxEncodedLen) fn submit_parachain_heads_with_1kb_proof() -> Weight { // Proof Size summary in bytes: @@ -130,29 +130,29 @@ impl WeightInfo for BridgeWeight { .saturating_add(T::DbWeight::get().reads(4_u64)) .saturating_add(T::DbWeight::get().writes(3_u64)) } - /// Storage: BridgeRialtoParachains PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownParachains PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), + /// Proof: BridgeUnknownParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), /// added: 496, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ParasInfo (r:1 w:1) + /// Storage: BridgeUnknownParachains ParasInfo (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: + /// Proof: BridgeUnknownParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: /// 555, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHashes (r:1 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHashes (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHashes (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHashes (max_values: Some(1024), max_size: /// Some(64), added: 1549, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:0 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHeads (r:0 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHeads (max_values: Some(1024), max_size: /// Some(196), added: 1681, mode: MaxEncodedLen) fn submit_parachain_heads_with_16kb_proof() -> Weight { // Proof Size summary in bytes: @@ -167,29 +167,29 @@ impl WeightInfo for BridgeWeight { // For backwards compatibility and tests impl WeightInfo for () { - /// Storage: BridgeRialtoParachains PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownParachains PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), + /// Proof: BridgeUnknownParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), /// added: 496, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ParasInfo (r:1 w:1) + /// Storage: BridgeUnknownParachains ParasInfo (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: + /// Proof: BridgeUnknownParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: /// 555, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHashes (r:1 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHashes (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHashes (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHashes (max_values: Some(1024), max_size: /// Some(64), added: 1549, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:0 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHeads (r:0 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHeads (max_values: Some(1024), max_size: /// Some(196), added: 1681, mode: MaxEncodedLen) /// /// The range of component `p` is `[1, 2]`. @@ -204,29 +204,29 @@ impl WeightInfo for () { .saturating_add(RocksDbWeight::get().reads(4_u64)) .saturating_add(RocksDbWeight::get().writes(3_u64)) } - /// Storage: BridgeRialtoParachains PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownParachains PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), + /// Proof: BridgeUnknownParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), /// added: 496, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ParasInfo (r:1 w:1) + /// Storage: BridgeUnknownParachains ParasInfo (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: + /// Proof: BridgeUnknownParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: /// 555, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHashes (r:1 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHashes (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHashes (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHashes (max_values: Some(1024), max_size: /// Some(64), added: 1549, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:0 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHeads (r:0 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHeads (max_values: Some(1024), max_size: /// Some(196), added: 1681, mode: MaxEncodedLen) fn submit_parachain_heads_with_1kb_proof() -> Weight { // Proof Size summary in bytes: @@ -237,29 +237,29 @@ impl WeightInfo for () { .saturating_add(RocksDbWeight::get().reads(4_u64)) .saturating_add(RocksDbWeight::get().writes(3_u64)) } - /// Storage: BridgeRialtoParachains PalletOperatingMode (r:1 w:0) + /// Storage: BridgeUnknownParachains PalletOperatingMode (r:1 w:0) /// - /// Proof: BridgeRialtoParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), + /// Proof: BridgeUnknownParachains PalletOperatingMode (max_values: Some(1), max_size: Some(1), /// added: 496, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoGrandpa ImportedHeaders (r:1 w:0) + /// Storage: BridgeUnknownGrandpa ImportedHeaders (r:1 w:0) /// - /// Proof: BridgeRialtoGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), + /// Proof: BridgeUnknownGrandpa ImportedHeaders (max_values: Some(14400), max_size: Some(68), /// added: 2048, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ParasInfo (r:1 w:1) + /// Storage: BridgeUnknownParachains ParasInfo (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: + /// Proof: BridgeUnknownParachains ParasInfo (max_values: Some(1), max_size: Some(60), added: /// 555, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHashes (r:1 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHashes (r:1 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHashes (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHashes (max_values: Some(1024), max_size: /// Some(64), added: 1549, mode: MaxEncodedLen) /// - /// Storage: BridgeRialtoParachains ImportedParaHeads (r:0 w:1) + /// Storage: BridgeUnknownParachains ImportedParaHeads (r:0 w:1) /// - /// Proof: BridgeRialtoParachains ImportedParaHeads (max_values: Some(1024), max_size: + /// Proof: BridgeUnknownParachains ImportedParaHeads (max_values: Some(1024), max_size: /// Some(196), added: 1681, mode: MaxEncodedLen) fn submit_parachain_heads_with_16kb_proof() -> Weight { // Proof Size summary in bytes: diff --git a/modules/parachains/src/weights_ext.rs b/modules/parachains/src/weights_ext.rs index 13bc9ad2bbce0..393086a85690f 100644 --- a/modules/parachains/src/weights_ext.rs +++ b/modules/parachains/src/weights_ext.rs @@ -31,7 +31,7 @@ use frame_support::weights::{RuntimeDbWeight, Weight}; pub const DEFAULT_PARACHAIN_HEAD_SIZE: u32 = 384; /// Number of extra bytes (excluding size of storage value itself) of storage proof, built at -/// the Rialto chain. +/// some generic chain. pub const EXTRA_STORAGE_PROOF_SIZE: u32 = 1024; /// Extended weight info. diff --git a/modules/relayers/src/weights.rs b/modules/relayers/src/weights.rs index 2e064a3936df3..c2c065b0c0a27 100644 --- a/modules/relayers/src/weights.rs +++ b/modules/relayers/src/weights.rs @@ -23,7 +23,7 @@ //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// target/release/millau-bridge-node +// target/release/rip-bridge-node // benchmark // pallet // --chain=dev diff --git a/modules/shift-session-manager/Cargo.toml b/modules/shift-session-manager/Cargo.toml deleted file mode 100644 index e70dd6ace16e4..0000000000000 --- a/modules/shift-session-manager/Cargo.toml +++ /dev/null @@ -1,38 +0,0 @@ -[package] -name = "pallet-shift-session-manager" -description = "A Substrate Runtime module that selects 2/3 of initial validators for every session" -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[dependencies] -codec = { package = "parity-scale-codec", version = "3.1.5", default-features = false } -scale-info = { version = "2.10.0", default-features = false, features = ["derive"] } - -# Substrate Dependencies - -frame-support = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -pallet-session = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-staking = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-std = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -[dev-dependencies] -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-io = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-state-machine = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - -[features] -default = [ "std" ] -std = [ - "codec/std", - "frame-support/std", - "frame-system/std", - "pallet-session/std", - "scale-info/std", - "sp-staking/std", - "sp-std/std", -] -try-runtime = [ "frame-support/try-runtime", "frame-system/try-runtime" ] diff --git a/modules/shift-session-manager/README.md b/modules/shift-session-manager/README.md deleted file mode 100644 index 8dfbfd416e3cc..0000000000000 --- a/modules/shift-session-manager/README.md +++ /dev/null @@ -1,10 +0,0 @@ -# Shift Session Manager Pallet - -**THIS PALLET IS NOT INTENDED TO BE USED IN PRODUCTION** - -The pallet does not provide any calls or runtime storage entries. It only provides implementation of the -`pallet_session::SessionManager`. This implementation, starting from session `3` selects two thirds of initial -validators and changes the set on every session. We are using it at our testnets ([Rialto](../../bin/rialto/) and -[Millau](../../bin/millau/)) to be sure that the set changes every session. On well-known production chains -(like Kusama and Polkadot) the alternative is the set of [nPoS](https://research.web3.foundation/en/latest/polkadot/NPoS/index.html) -pallets, which selects validators, based on their nominations. diff --git a/modules/shift-session-manager/src/lib.rs b/modules/shift-session-manager/src/lib.rs deleted file mode 100644 index 49690842418ce..0000000000000 --- a/modules/shift-session-manager/src/lib.rs +++ /dev/null @@ -1,259 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Substrate session manager that selects 2/3 validators from initial set, -//! starting from session 2. - -#![cfg_attr(not(feature = "std"), no_std)] - -use frame_support::traits::{ValidatorSet, ValidatorSetWithIdentification}; -use sp_std::prelude::*; - -pub use pallet::*; - -#[frame_support::pallet] -pub mod pallet { - use super::*; - use frame_support::pallet_prelude::*; - use frame_system::pallet_prelude::*; - - #[pallet::config] - #[pallet::disable_frame_system_supertrait_check] - pub trait Config: pallet_session::Config {} - - #[pallet::pallet] - #[pallet::without_storage_info] - pub struct Pallet(PhantomData); - - #[pallet::hooks] - impl Hooks> for Pallet {} - - #[pallet::call] - impl Pallet {} - - /// Validators of first two sessions. - #[pallet::storage] - pub(super) type InitialValidators = StorageValue<_, Vec>; -} - -impl ValidatorSet for Pallet { - type ValidatorId = T::ValidatorId; - type ValidatorIdOf = T::ValidatorIdOf; - - fn session_index() -> sp_staking::SessionIndex { - pallet_session::Pallet::::current_index() - } - - fn validators() -> Vec { - pallet_session::Pallet::::validators() - } -} - -impl ValidatorSetWithIdentification for Pallet { - type Identification = (); - type IdentificationOf = (); -} - -impl pallet_session::SessionManager for Pallet { - fn end_session(_: sp_staking::SessionIndex) {} - fn start_session(_: sp_staking::SessionIndex) {} - fn new_session(session_index: sp_staking::SessionIndex) -> Option> { - // we don't want to add even more fields to genesis config => just return None - if session_index == 0 || session_index == 1 { - return None - } - - // the idea that on first call (i.e. when session 1 ends) we're reading current - // set of validators from session module (they are initial validators) and save - // in our 'local storage'. - // then for every session we select (deterministically) 2/3 of these initial - // validators to serve validators of new session - let available_validators = InitialValidators::::get().unwrap_or_else(|| { - let validators = >::validators(); - InitialValidators::::put(validators.clone()); - validators - }); - - Some(Self::select_validators(session_index, &available_validators)) - } -} - -impl Pallet { - /// Select validators for session. - fn select_validators( - session_index: sp_staking::SessionIndex, - available_validators: &[T::ValidatorId], - ) -> Vec { - let available_validators_count = available_validators.len(); - let count = sp_std::cmp::max(1, 2 * available_validators_count / 3); - let offset = session_index as usize % available_validators_count; - let end = offset + count; - let session_validators = match end.overflowing_sub(available_validators_count) { - (wrapped_end, false) if wrapped_end != 0 => available_validators[offset..] - .iter() - .chain(available_validators[..wrapped_end].iter()) - .cloned() - .collect(), - _ => available_validators[offset..end].to_vec(), - }; - - session_validators - } -} - -#[cfg(test)] -mod tests { - // From construct_runtime macro - #![allow(clippy::from_over_into)] - - use super::*; - use frame_support::{ - parameter_types, - sp_runtime::{ - testing::UintAuthorityId, - traits::{BlakeTwo256, ConvertInto, IdentityLookup}, - BuildStorage, Perbill, RuntimeAppPublic, - }, - weights::Weight, - }; - use sp_core::H256; - use sp_io::TestExternalities; - use sp_state_machine::BasicExternalities; - - type AccountId = u64; - - type Block = frame_system::mocking::MockBlock; - - frame_support::construct_runtime! { - pub enum TestRuntime { - System: frame_system::{Pallet, Call, Config, Storage, Event}, - Session: pallet_session::{Pallet}, - } - } - - parameter_types! { - pub const MaximumBlockWeight: Weight = Weight::from_parts(1024, 0); - pub const MaximumBlockLength: u32 = 2 * 1024; - pub const AvailableBlockRatio: Perbill = Perbill::one(); - } - - impl frame_system::Config for TestRuntime { - type RuntimeOrigin = RuntimeOrigin; - type Nonce = u64; - type RuntimeCall = RuntimeCall; - type Hash = H256; - type Hashing = BlakeTwo256; - type AccountId = AccountId; - type Lookup = IdentityLookup; - type Block = Block; - type RuntimeEvent = (); - type BlockHashCount = frame_support::traits::ConstU64<250>; - type Version = (); - type PalletInfo = PalletInfo; - type AccountData = (); - type OnNewAccount = (); - type OnKilledAccount = (); - type BaseCallFilter = frame_support::traits::Everything; - type SystemWeightInfo = (); - type BlockWeights = (); - type BlockLength = (); - type DbWeight = (); - type SS58Prefix = (); - type OnSetCode = (); - type MaxConsumers = frame_support::traits::ConstU32<16>; - } - - parameter_types! { - pub const Period: u64 = 1; - pub const Offset: u64 = 0; - } - - impl pallet_session::Config for TestRuntime { - type RuntimeEvent = (); - type ValidatorId = ::AccountId; - type ValidatorIdOf = ConvertInto; - type ShouldEndSession = pallet_session::PeriodicSessions; - type NextSessionRotation = pallet_session::PeriodicSessions; - type SessionManager = (); - type SessionHandler = TestSessionHandler; - type Keys = UintAuthorityId; - type WeightInfo = (); - } - - impl Config for TestRuntime {} - - pub struct TestSessionHandler; - impl pallet_session::SessionHandler for TestSessionHandler { - const KEY_TYPE_IDS: &'static [sp_runtime::KeyTypeId] = &[UintAuthorityId::ID]; - - fn on_genesis_session(_validators: &[(AccountId, Ks)]) { - } - - fn on_new_session( - _: bool, - _: &[(AccountId, Ks)], - _: &[(AccountId, Ks)], - ) { - } - - fn on_disabled(_: u32) {} - } - - fn new_test_ext() -> TestExternalities { - let mut t = frame_system::GenesisConfig::::default().build_storage().unwrap(); - - let keys = vec![ - (1, 1, UintAuthorityId(1)), - (2, 2, UintAuthorityId(2)), - (3, 3, UintAuthorityId(3)), - (4, 4, UintAuthorityId(4)), - (5, 5, UintAuthorityId(5)), - ]; - - BasicExternalities::execute_with_storage(&mut t, || { - for (ref k, ..) in &keys { - frame_system::Pallet::::inc_providers(k); - } - }); - - pallet_session::GenesisConfig:: { keys } - .assimilate_storage(&mut t) - .unwrap(); - TestExternalities::new(t) - } - - #[test] - fn shift_session_manager_works() { - new_test_ext().execute_with(|| { - let all_accs = vec![1, 2, 3, 4, 5]; - - // at least 1 validator is selected - assert_eq!(Pallet::::select_validators(0, &[1]), vec![1],); - - // at session#0, shift is also 0 - assert_eq!(Pallet::::select_validators(0, &all_accs), vec![1, 2, 3],); - - // at session#1, shift is also 1 - assert_eq!(Pallet::::select_validators(1, &all_accs), vec![2, 3, 4],); - - // at session#3, we're wrapping - assert_eq!(Pallet::::select_validators(3, &all_accs), vec![4, 5, 1],); - - // at session#5, we're starting from the beginning again - assert_eq!(Pallet::::select_validators(5, &all_accs), vec![1, 2, 3],); - }); - } -} diff --git a/modules/xcm-bridge-hub-router/src/weights.rs b/modules/xcm-bridge-hub-router/src/weights.rs index 62936e997f3cd..b0c8fc6252cd5 100644 --- a/modules/xcm-bridge-hub-router/src/weights.rs +++ b/modules/xcm-bridge-hub-router/src/weights.rs @@ -23,7 +23,7 @@ //! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// target/release/millau-bridge-node +// target/release/rip-bridge-node // benchmark // pallet // --chain=dev diff --git a/primitives/chain-millau/Cargo.toml b/primitives/chain-millau/Cargo.toml deleted file mode 100644 index 5ea9d36f9f7b1..0000000000000 --- a/primitives/chain-millau/Cargo.toml +++ /dev/null @@ -1,62 +0,0 @@ -[package] -name = "bp-millau" -description = "Primitives of Millau runtime." -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[dependencies] - -# TODO: Consume `fixed-hash` from crates.io when the following fix is published: -# https://github.com/paritytech/parity-common/commit/d3a9327124a66e52ca1114bb8640c02c18c134b8 -# Expected in a version > 0.8.0 -fixed-hash = { git = "https://github.com/paritytech/parity-common", branch = "master", default-features = false } -hash256-std-hasher = { version = "0.15.2", default-features = false } -impl-codec = { version = "0.6", default-features = false } -impl-serde = { version = "0.4.0", default-features = false } -parity-util-mem = { version = "0.12.0", default-features = false, features = ["primitive-types"] } -scale-info = { version = "2.10.0", default-features = false, features = ["derive"] } -serde = { version = "1.0", default-features = false, features = ["alloc", "derive"] } - -# Bridge Dependencies - -bp-beefy = { path = "../beefy", default-features = false } -bp-header-chain = { path = "../header-chain", default-features = false } -bp-messages = { path = "../messages", default-features = false } -bp-runtime = { path = "../runtime", default-features = false } - -# Substrate Based Dependencies - -frame-support = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-io = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-std = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-trie = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -[features] -default = [ "std" ] -std = [ - "bp-beefy/std", - "bp-header-chain/std", - "bp-messages/std", - "bp-runtime/std", - "fixed-hash/std", - "frame-support/std", - "frame-system/std", - "hash256-std-hasher/std", - "impl-codec/std", - "impl-serde/std", - "parity-util-mem/std", - "scale-info/std", - "serde/std", - "sp-api/std", - "sp-core/std", - "sp-io/std", - "sp-runtime/std", - "sp-std/std", - "sp-trie/std", -] diff --git a/primitives/chain-millau/src/lib.rs b/primitives/chain-millau/src/lib.rs deleted file mode 100644 index 0c31287166661..0000000000000 --- a/primitives/chain-millau/src/lib.rs +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -#![cfg_attr(not(feature = "std"), no_std)] -// RuntimeApi generated functions -#![allow(clippy::too_many_arguments)] - -mod millau_hash; - -use bp_beefy::ChainWithBeefy; -use bp_header_chain::ChainWithGrandpa; -use bp_messages::MessageNonce; -use bp_runtime::{decl_bridge_finality_runtime_apis, decl_bridge_runtime_apis, Chain}; -use frame_support::{ - dispatch::DispatchClass, - weights::{constants::WEIGHT_REF_TIME_PER_SECOND, IdentityFee, Weight}, -}; -use frame_system::limits; -use scale_info::TypeInfo; -use serde::{Deserialize, Serialize}; -use sp_core::{storage::StateVersion, Hasher as HasherT}; -use sp_runtime::{ - traits::{IdentifyAccount, Verify}, - MultiSignature, MultiSigner, Perbill, RuntimeDebug, -}; -use sp_std::prelude::*; -use sp_trie::{LayoutV0, LayoutV1, TrieConfiguration}; - -use sp_runtime::traits::Keccak256; - -pub use millau_hash::MillauHash; - -/// Number of extra bytes (excluding size of storage value itself) of storage proof, built at -/// Millau chain. This mostly depends on number of entries (and their density) in the storage trie. -/// Some reserve is reserved to account future chain growth. -pub const EXTRA_STORAGE_PROOF_SIZE: u32 = 1024; - -/// Number of bytes, included in the signed Millau transaction apart from the encoded call itself. -/// -/// Can be computed by subtracting encoded call size from raw transaction size. -pub const TX_EXTRA_BYTES: u32 = 103; - -/// Maximum weight of single Millau block. -/// -/// This represents 0.5 seconds of compute assuming a target block time of six seconds. -/// -/// Max PoV size is set to max value, since it isn't important for relay/standalone chains. -pub const MAXIMUM_BLOCK_WEIGHT: Weight = - Weight::from_parts(WEIGHT_REF_TIME_PER_SECOND.saturating_div(2), u64::MAX); - -/// Represents the portion of a block that will be used by Normal extrinsics. -pub const NORMAL_DISPATCH_RATIO: Perbill = Perbill::from_percent(75); - -/// Maximal number of unrewarded relayer entries in Millau confirmation transaction. -pub const MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX: MessageNonce = 128; - -/// Maximal number of unconfirmed messages in Millau confirmation transaction. -pub const MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX: MessageNonce = 128; - -/// The target length of a session (how often authorities change) on Millau measured in of number of -/// blocks. -/// -/// Note that since this is a target sessions may change before/after this time depending on network -/// conditions. -pub const SESSION_LENGTH: BlockNumber = 5 * time_units::MINUTES; - -/// Maximal number of GRANDPA authorities at Millau. -pub const MAX_AUTHORITIES_COUNT: u32 = 5; - -/// Reasonable number of headers in the `votes_ancestries` on Millau chain. -/// -/// See [`bp-header-chain::ChainWithGrandpa`] for more details. -pub const REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY: u32 = 8; - -/// Approximate average header size in `votes_ancestries` field of justification on Millau chain. -/// -/// See [`bp-header-chain::ChainWithGrandpa`] for more details. -pub const AVERAGE_HEADER_SIZE_IN_JUSTIFICATION: u32 = 256; - -/// Approximate maximal header size on Millau chain. -/// -/// We expect maximal header to have digest item with the new authorities set for every consensus -/// engine (GRANDPA, Babe, BEEFY, ...) - so we multiply it by 3. And also -/// `AVERAGE_HEADER_SIZE_IN_JUSTIFICATION` bytes for other stuff. -/// -/// See [`bp-header-chain::ChainWithGrandpa`] for more details. -pub const MAX_HEADER_SIZE: u32 = MAX_AUTHORITIES_COUNT - .saturating_mul(3) - .saturating_add(AVERAGE_HEADER_SIZE_IN_JUSTIFICATION); - -/// Re-export `time_units` to make usage easier. -pub use time_units::*; - -/// Human readable time units defined in terms of number of blocks. -pub mod time_units { - use super::BlockNumber; - - pub const MILLISECS_PER_BLOCK: u64 = 6000; - pub const SLOT_DURATION: u64 = MILLISECS_PER_BLOCK; - - pub const MINUTES: BlockNumber = 60_000 / (MILLISECS_PER_BLOCK as BlockNumber); - pub const HOURS: BlockNumber = MINUTES * 60; - pub const DAYS: BlockNumber = HOURS * 24; -} - -/// Block number type used in Millau. -pub type BlockNumber = u64; - -/// Hash type used in Millau. -pub type Hash = ::Out; - -/// Type of object that can produce hashes on Millau. -pub type Hasher = BlakeTwoAndKeccak256; - -/// The header type used by Millau. -pub type Header = sp_runtime::generic::Header; - -/// Alias to 512-bit hash when used in the context of a transaction signature on the chain. -pub type Signature = MultiSignature; - -/// Some way of identifying an account on the chain. We intentionally make it equivalent -/// to the public key of our transaction signing scheme. -pub type AccountId = <::Signer as IdentifyAccount>::AccountId; - -/// Public key of the chain account that may be used to verify signatures. -pub type AccountSigner = MultiSigner; - -/// Balance of an account. -pub type Balance = u64; - -/// Nonce of a transaction in the chain. -pub type Nonce = u32; - -/// Weight-to-Fee type used by Millau. -pub type WeightToFee = IdentityFee; - -/// Millau chain. -#[derive(RuntimeDebug)] -pub struct Millau; - -impl Chain for Millau { - type BlockNumber = BlockNumber; - type Hash = Hash; - type Hasher = Hasher; - type Header = Header; - - type AccountId = AccountId; - type Balance = Balance; - type Nonce = Nonce; - type Signature = Signature; - - fn max_extrinsic_size() -> u32 { - *BlockLength::get().max.get(DispatchClass::Normal) - } - - fn max_extrinsic_weight() -> Weight { - BlockWeights::get() - .get(DispatchClass::Normal) - .max_extrinsic - .unwrap_or(Weight::MAX) - } -} - -impl ChainWithGrandpa for Millau { - const WITH_CHAIN_GRANDPA_PALLET_NAME: &'static str = WITH_MILLAU_GRANDPA_PALLET_NAME; - const MAX_AUTHORITIES_COUNT: u32 = MAX_AUTHORITIES_COUNT; - const REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY: u32 = - REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY; - const MAX_HEADER_SIZE: u32 = MAX_HEADER_SIZE; - const AVERAGE_HEADER_SIZE_IN_JUSTIFICATION: u32 = AVERAGE_HEADER_SIZE_IN_JUSTIFICATION; -} - -impl ChainWithBeefy for Millau { - type CommitmentHasher = Keccak256; - type MmrHashing = Keccak256; - type MmrHash = ::Output; - type BeefyMmrLeafExtra = (); - type AuthorityId = bp_beefy::EcdsaValidatorId; - type AuthorityIdToMerkleLeaf = bp_beefy::BeefyEcdsaToEthereum; -} - -/// Millau Hasher (Blake2-256 ++ Keccak-256) implementation. -#[derive(PartialEq, Eq, Clone, Copy, RuntimeDebug, TypeInfo, Serialize, Deserialize)] -pub struct BlakeTwoAndKeccak256; - -impl sp_core::Hasher for BlakeTwoAndKeccak256 { - type Out = MillauHash; - type StdHasher = hash256_std_hasher::Hash256StdHasher; - const LENGTH: usize = 64; - - fn hash(s: &[u8]) -> Self::Out { - let mut combined_hash = MillauHash::default(); - combined_hash.as_mut()[..32].copy_from_slice(&sp_io::hashing::blake2_256(s)); - combined_hash.as_mut()[32..].copy_from_slice(&sp_io::hashing::keccak_256(s)); - combined_hash - } -} - -impl sp_runtime::traits::Hash for BlakeTwoAndKeccak256 { - type Output = MillauHash; - - fn trie_root(input: Vec<(Vec, Vec)>, state_version: StateVersion) -> Self::Output { - match state_version { - StateVersion::V0 => LayoutV0::::trie_root(input), - StateVersion::V1 => LayoutV1::::trie_root(input), - } - } - - fn ordered_trie_root(input: Vec>, state_version: StateVersion) -> Self::Output { - match state_version { - StateVersion::V0 => LayoutV0::::ordered_trie_root(input), - StateVersion::V1 => LayoutV1::::ordered_trie_root(input), - } - } -} - -frame_support::parameter_types! { - pub BlockLength: limits::BlockLength = - limits::BlockLength::max_with_normal_ratio(2 * 1024 * 1024, NORMAL_DISPATCH_RATIO); - pub BlockWeights: limits::BlockWeights = - limits::BlockWeights::with_sensible_defaults(MAXIMUM_BLOCK_WEIGHT, NORMAL_DISPATCH_RATIO); -} - -/// Name of the With-Millau GRANDPA pallet instance that is deployed at bridged chains. -pub const WITH_MILLAU_GRANDPA_PALLET_NAME: &str = "BridgeMillauGrandpa"; -/// Name of the With-Millau messages pallet instance that is deployed at bridged chains. -pub const WITH_MILLAU_MESSAGES_PALLET_NAME: &str = "BridgeMillauMessages"; -/// Name of the transaction payment pallet at the Millau runtime. -pub const TRANSACTION_PAYMENT_PALLET_NAME: &str = "TransactionPayment"; - -decl_bridge_runtime_apis!(millau, grandpa); diff --git a/primitives/chain-millau/src/millau_hash.rs b/primitives/chain-millau/src/millau_hash.rs deleted file mode 100644 index 8851c319dd451..0000000000000 --- a/primitives/chain-millau/src/millau_hash.rs +++ /dev/null @@ -1,56 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use parity_util_mem::MallocSizeOf; -use scale_info::TypeInfo; -use sp_runtime::traits::CheckEqual; - -// `sp_core::H512` can't be used, because it doesn't implement `CheckEqual`, which is required -// by `frame_system::Config::Hash`. - -fixed_hash::construct_fixed_hash! { - /// Hash type used in Millau chain. - #[derive(MallocSizeOf, TypeInfo)] - pub struct MillauHash(64); -} - -impl_serde::impl_fixed_hash_serde!(MillauHash, 64); -impl_codec::impl_fixed_hash_codec!(MillauHash, 64); - -impl CheckEqual for MillauHash { - #[cfg(feature = "std")] - fn check_equal(&self, other: &Self) { - use sp_core::hexdisplay::HexDisplay; - if self != other { - println!( - "Hash: given={}, expected={}", - HexDisplay::from(self.as_fixed_bytes()), - HexDisplay::from(other.as_fixed_bytes()), - ); - } - } - - #[cfg(not(feature = "std"))] - fn check_equal(&self, other: &Self) { - use frame_support::Printable; - - if self != other { - "Hash not equal".print(); - self.as_bytes().print(); - other.as_bytes().print(); - } - } -} diff --git a/primitives/chain-rialto-parachain/Cargo.toml b/primitives/chain-rialto-parachain/Cargo.toml deleted file mode 100644 index 0122c508e2b92..0000000000000 --- a/primitives/chain-rialto-parachain/Cargo.toml +++ /dev/null @@ -1,39 +0,0 @@ -[package] -name = "bp-rialto-parachain" -description = "Primitives of Rialto parachain runtime." -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[dependencies] - -# Bridge Dependencies - -bp-bridge-hub-cumulus = { path = "../chain-bridge-hub-cumulus", default-features = false } -bp-messages = { path = "../messages", default-features = false } -bp-polkadot-core = { path = "../polkadot-core", default-features = false } -bp-runtime = { path = "../runtime", default-features = false } - -# Substrate Based Dependencies - -frame-support = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-std = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -[features] -default = [ "std" ] -std = [ - "bp-bridge-hub-cumulus/std", - "bp-messages/std", - "bp-runtime/std", - "frame-support/std", - "frame-system/std", - "sp-api/std", - "sp-core/std", - "sp-runtime/std", - "sp-std/std", -] diff --git a/primitives/chain-rialto-parachain/src/lib.rs b/primitives/chain-rialto-parachain/src/lib.rs deleted file mode 100644 index 18655503edddf..0000000000000 --- a/primitives/chain-rialto-parachain/src/lib.rs +++ /dev/null @@ -1,148 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -#![cfg_attr(not(feature = "std"), no_std)] -// RuntimeApi generated functions -#![allow(clippy::too_many_arguments)] - -use bp_messages::MessageNonce; -use bp_runtime::{decl_bridge_runtime_apis, Chain, Parachain}; -use frame_support::{ - dispatch::DispatchClass, - weights::{constants::WEIGHT_REF_TIME_PER_SECOND, IdentityFee, Weight}, -}; -use frame_system::limits; -use sp_core::Hasher as HasherT; -use sp_runtime::{ - traits::{BlakeTwo256, IdentifyAccount, Verify}, - MultiSignature, MultiSigner, Perbill, RuntimeDebug, -}; - -/// Identifier of RialtoParachain in the Rialto relay chain. -/// -/// This identifier is not something that is declared either by Rialto or RialtoParachain. This -/// is an identifier of registration. So in theory it may be changed. But since bridge is going -/// to be deployed after parachain registration AND since parachain de-registration is highly -/// likely impossible, it is fine to declare this constant here. -pub const RIALTO_PARACHAIN_ID: u32 = 2000; - -/// Number of extra bytes (excluding size of storage value itself) of storage proof, built at -/// RialtoParachain chain. This mostly depends on number of entries (and their density) in the -/// storage trie. Some reserve is reserved to account future chain growth. -pub const EXTRA_STORAGE_PROOF_SIZE: u32 = 1024; - -/// Can be computed by subtracting encoded call size from raw transaction size. -pub const TX_EXTRA_BYTES: u32 = 104; - -/// Maximal weight of single RialtoParachain block. -/// -/// This represents two seconds of compute assuming a target block time of six seconds. -/// -/// Max PoV size is set to `5Mb` as all Cumulus-based parachains do. -pub const MAXIMUM_BLOCK_WEIGHT: Weight = - Weight::from_parts(WEIGHT_REF_TIME_PER_SECOND.saturating_mul(2), 5 * 1024 * 1024); - -/// Represents the portion of a block that will be used by Normal extrinsics. -pub const NORMAL_DISPATCH_RATIO: Perbill = Perbill::from_percent(75); - -/// Maximal number of unrewarded relayer entries in Rialto confirmation transaction. -pub const MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX: MessageNonce = 1024; - -/// Maximal number of unconfirmed messages in Rialto confirmation transaction. -pub const MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX: MessageNonce = 1024; - -/// Block number type used in Rialto. -pub type BlockNumber = u32; - -/// Hash type used in Rialto. -pub type Hash = ::Out; - -/// The type of object that can produce hashes on Rialto. -pub type Hasher = BlakeTwo256; - -/// The header type used by Rialto. -pub type Header = sp_runtime::generic::Header; - -/// Alias to 512-bit hash when used in the context of a transaction signature on the chain. -pub type Signature = MultiSignature; - -/// Some way of identifying an account on the chain. We intentionally make it equivalent -/// to the public key of our transaction signing scheme. -pub type AccountId = <::Signer as IdentifyAccount>::AccountId; - -/// Public key of the chain account that may be used to verify signatures. -pub type AccountSigner = MultiSigner; - -/// Balance of an account. -pub type Balance = u128; - -/// An instant or duration in time. -pub type Moment = u64; - -/// Nonce of a transaction in the parachain. -pub type Nonce = u32; - -/// Weight-to-Fee type used by Rialto parachain. -pub type WeightToFee = IdentityFee; - -/// Rialto parachain. -#[derive(RuntimeDebug)] -pub struct RialtoParachain; - -impl Chain for RialtoParachain { - type BlockNumber = BlockNumber; - type Hash = Hash; - type Hasher = Hasher; - type Header = Header; - - type AccountId = AccountId; - type Balance = Balance; - type Nonce = Nonce; - type Signature = Signature; - - fn max_extrinsic_size() -> u32 { - *BlockLength::get().max.get(DispatchClass::Normal) - } - - fn max_extrinsic_weight() -> Weight { - BlockWeights::get() - .get(DispatchClass::Normal) - .max_extrinsic - .unwrap_or(Weight::MAX) - } -} - -impl Parachain for RialtoParachain { - const PARACHAIN_ID: u32 = RIALTO_PARACHAIN_ID; -} - -// Technically this is incorrect, because rialto-parachain isn't a bridge hub, but we're -// trying to keep it close to the bridge hubs code (at least in this aspect). -pub use bp_bridge_hub_cumulus::SignedExtension; - -frame_support::parameter_types! { - pub BlockLength: limits::BlockLength = - limits::BlockLength::max_with_normal_ratio(5 * 1024 * 1024, NORMAL_DISPATCH_RATIO); - pub BlockWeights: limits::BlockWeights = - limits::BlockWeights::with_sensible_defaults(MAXIMUM_BLOCK_WEIGHT, NORMAL_DISPATCH_RATIO); -} - -/// Name of the With-Rialto-Parachain messages pallet instance that is deployed at bridged chains. -pub const WITH_RIALTO_PARACHAIN_MESSAGES_PALLET_NAME: &str = "BridgeRialtoParachainMessages"; -/// Name of the transaction payment pallet at the Rialto parachain runtime. -pub const TRANSACTION_PAYMENT_PALLET_NAME: &str = "TransactionPayment"; - -decl_bridge_runtime_apis!(rialto_parachain); diff --git a/primitives/chain-rialto/Cargo.toml b/primitives/chain-rialto/Cargo.toml deleted file mode 100644 index 083abbd545840..0000000000000 --- a/primitives/chain-rialto/Cargo.toml +++ /dev/null @@ -1,38 +0,0 @@ -[package] -name = "bp-rialto" -description = "Primitives of Rialto runtime." -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[dependencies] - -# Bridge Dependencies - -bp-header-chain = { path = "../header-chain", default-features = false } -bp-messages = { path = "../messages", default-features = false } -bp-runtime = { path = "../runtime", default-features = false } - -# Substrate Based Dependencies - -frame-support = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -frame-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } -sp-std = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master", default-features = false } - -[features] -default = [ "std" ] -std = [ - "bp-header-chain/std", - "bp-messages/std", - "bp-runtime/std", - "frame-support/std", - "frame-system/std", - "sp-api/std", - "sp-core/std", - "sp-runtime/std", - "sp-std/std", -] diff --git a/primitives/chain-rialto/src/lib.rs b/primitives/chain-rialto/src/lib.rs deleted file mode 100644 index 9d5215c10292a..0000000000000 --- a/primitives/chain-rialto/src/lib.rs +++ /dev/null @@ -1,210 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -#![cfg_attr(not(feature = "std"), no_std)] -// RuntimeApi generated functions -#![allow(clippy::too_many_arguments)] - -use bp_header_chain::ChainWithGrandpa; -use bp_messages::MessageNonce; -use bp_runtime::{decl_bridge_finality_runtime_apis, decl_bridge_runtime_apis, Chain}; -use frame_support::{ - dispatch::DispatchClass, - weights::{constants::WEIGHT_REF_TIME_PER_SECOND, IdentityFee, Weight}, -}; -use frame_system::limits; -use sp_core::Hasher as HasherT; -use sp_runtime::{ - traits::{BlakeTwo256, IdentifyAccount, Verify}, - MultiSignature, MultiSigner, Perbill, RuntimeDebug, -}; - -/// Number of extra bytes (excluding size of storage value itself) of storage proof, built at -/// Rialto chain. This mostly depends on number of entries (and their density) in the storage trie. -/// Some reserve is reserved to account future chain growth. -pub const EXTRA_STORAGE_PROOF_SIZE: u32 = 1024; - -/// Number of bytes, included in the signed Rialto transaction apart from the encoded call itself. -/// -/// Can be computed by subtracting encoded call size from raw transaction size. -pub const TX_EXTRA_BYTES: u32 = 104; - -/// Maximal weight of single Rialto block. -/// -/// This represents two seconds of compute assuming a target block time of six seconds. -/// -/// Max PoV size is set to max value, since it isn't important for relay/standalone chains. -pub const MAXIMUM_BLOCK_WEIGHT: Weight = - Weight::from_parts(WEIGHT_REF_TIME_PER_SECOND.saturating_mul(2), u64::MAX); - -/// Represents the portion of a block that will be used by Normal extrinsics. -pub const NORMAL_DISPATCH_RATIO: Perbill = Perbill::from_percent(75); - -/// Maximal number of unrewarded relayer entries in Rialto confirmation transaction. -pub const MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX: MessageNonce = 1024; - -/// Maximal number of unconfirmed messages in Rialto confirmation transaction. -pub const MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX: MessageNonce = 1024; - -/// The target length of a session (how often authorities change) on Rialto measured in of number of -/// blocks. -/// -/// Note that since this is a target sessions may change before/after this time depending on network -/// conditions. -pub const SESSION_LENGTH: BlockNumber = 4; - -/// Maximal number of GRANDPA authorities at Rialto. -pub const MAX_AUTHORITIES_COUNT: u32 = 5; - -/// Reasonable number of headers in the `votes_ancestries` on Rialto chain. -/// -/// See [`bp-header-chain::ChainWithGrandpa`] for more details. -pub const REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY: u32 = 8; - -/// Approximate average header size in `votes_ancestries` field of justification on Rialto chain. -/// -/// See [`bp-header-chain::ChainWithGrandpa`] for more details. -pub const AVERAGE_HEADER_SIZE_IN_JUSTIFICATION: u32 = 256; - -/// Approximate maximal header size on Rialto chain. -/// -/// We expect maximal header to have digest item with the new authorities set for every consensus -/// engine (GRANDPA, Babe, BEEFY, ...) - so we multiply it by 3. And also -/// `AVERAGE_HEADER_SIZE_IN_JUSTIFICATION` bytes for other stuff. -/// -/// See [`bp-header-chain::ChainWithGrandpa`] for more details. -pub const MAX_HEADER_SIZE: u32 = MAX_AUTHORITIES_COUNT - .saturating_mul(3) - .saturating_add(AVERAGE_HEADER_SIZE_IN_JUSTIFICATION); - -/// Maximal size of encoded `bp_parachains::ParaStoredHeaderData` structure among all Rialto -/// parachains. -/// -/// It includes the block number and state root, so it shall be near 40 bytes, but let's have some -/// reserve. -pub const MAX_NESTED_PARACHAIN_HEAD_DATA_SIZE: u32 = 128; - -/// Re-export `time_units` to make usage easier. -pub use time_units::*; - -/// Human readable time units defined in terms of number of blocks. -pub mod time_units { - use super::{BlockNumber, SESSION_LENGTH}; - - pub const MILLISECS_PER_BLOCK: u64 = 6000; - pub const SLOT_DURATION: u64 = MILLISECS_PER_BLOCK; - - pub const MINUTES: BlockNumber = 60_000 / (MILLISECS_PER_BLOCK as BlockNumber); - pub const HOURS: BlockNumber = MINUTES * 60; - pub const DAYS: BlockNumber = HOURS * 24; - - pub const EPOCH_DURATION_IN_SLOTS: BlockNumber = SESSION_LENGTH; - - // 1 in 4 blocks (on average, not counting collisions) will be primary babe blocks. - pub const PRIMARY_PROBABILITY: (u64, u64) = (1, 4); -} - -/// Block number type used in Rialto. -pub type BlockNumber = u32; - -/// Hash type used in Rialto. -pub type Hash = ::Out; - -/// The type of object that can produce hashes on Rialto. -pub type Hasher = BlakeTwo256; - -/// The header type used by Rialto. -pub type Header = sp_runtime::generic::Header; - -/// Alias to 512-bit hash when used in the context of a transaction signature on the chain. -pub type Signature = MultiSignature; - -/// Some way of identifying an account on the chain. We intentionally make it equivalent -/// to the public key of our transaction signing scheme. -pub type AccountId = <::Signer as IdentifyAccount>::AccountId; - -/// Public key of the chain account that may be used to verify signatures. -pub type AccountSigner = MultiSigner; - -/// Balance of an account. -pub type Balance = u128; - -/// An instant or duration in time. -pub type Moment = u64; - -/// Nonce of a transaction in the chain. -pub type Nonce = u32; - -/// Weight-to-Fee type used by Rialto. -pub type WeightToFee = IdentityFee; - -/// Rialto chain. -#[derive(RuntimeDebug)] -pub struct Rialto; - -impl Chain for Rialto { - type BlockNumber = BlockNumber; - type Hash = Hash; - type Hasher = Hasher; - type Header = Header; - - type AccountId = AccountId; - type Balance = Balance; - type Nonce = Nonce; - type Signature = Signature; - - fn max_extrinsic_size() -> u32 { - *BlockLength::get().max.get(DispatchClass::Normal) - } - - fn max_extrinsic_weight() -> Weight { - BlockWeights::get() - .get(DispatchClass::Normal) - .max_extrinsic - .unwrap_or(Weight::MAX) - } -} - -impl ChainWithGrandpa for Rialto { - const WITH_CHAIN_GRANDPA_PALLET_NAME: &'static str = WITH_RIALTO_GRANDPA_PALLET_NAME; - const MAX_AUTHORITIES_COUNT: u32 = MAX_AUTHORITIES_COUNT; - const REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY: u32 = - REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY; - const MAX_HEADER_SIZE: u32 = MAX_HEADER_SIZE; - const AVERAGE_HEADER_SIZE_IN_JUSTIFICATION: u32 = AVERAGE_HEADER_SIZE_IN_JUSTIFICATION; -} - -frame_support::parameter_types! { - pub BlockLength: limits::BlockLength = - limits::BlockLength::max_with_normal_ratio(5 * 1024 * 1024, NORMAL_DISPATCH_RATIO); - pub BlockWeights: limits::BlockWeights = - limits::BlockWeights::with_sensible_defaults(MAXIMUM_BLOCK_WEIGHT, NORMAL_DISPATCH_RATIO); -} - -/// Name of the With-Rialto GRANDPA pallet instance that is deployed at bridged chains. -pub const WITH_RIALTO_GRANDPA_PALLET_NAME: &str = "BridgeRialtoGrandpa"; -/// Name of the With-Rialto messages pallet instance that is deployed at bridged chains. -pub const WITH_RIALTO_MESSAGES_PALLET_NAME: &str = "BridgeRialtoMessages"; -/// Name of the With-Rialto parachains bridge pallet instance that is deployed at bridged chains. -pub const WITH_RIALTO_BRIDGE_PARAS_PALLET_NAME: &str = "BridgeRialtoParachains"; - -/// Name of the parachain registrar pallet in the Rialto runtime. -pub const PARAS_REGISTRAR_PALLET_NAME: &str = "Registrar"; - -/// Name of the parachains pallet in the Rialto runtime. -pub const PARAS_PALLET_NAME: &str = "Paras"; - -decl_bridge_runtime_apis!(rialto, grandpa); diff --git a/primitives/runtime/src/chain.rs b/primitives/runtime/src/chain.rs index e1809e145248f..b78023efb1b86 100644 --- a/primitives/runtime/src/chain.rs +++ b/primitives/runtime/src/chain.rs @@ -280,7 +280,7 @@ pub type TransactionEraOf = crate::TransactionEra, HashOf /// - constants that are stringified names of runtime API methods: /// - `BEST_FINALIZED__HEADER_METHOD` /// - `_ACCEPTED__FINALITY_PROOFS_METHOD` -/// The name of the chain has to be specified in snake case (e.g. `rialto_parachain`). +/// The name of the chain has to be specified in snake case (e.g. `bridge_hub_polkadot`). #[macro_export] macro_rules! decl_bridge_finality_runtime_apis { ($chain: ident $(, $consensus: ident => $justification_type: ty)?) => { @@ -332,7 +332,7 @@ macro_rules! decl_bridge_finality_runtime_apis { /// - `FromInboundLaneApi` /// - constants that are stringified names of runtime API methods: /// - `FROM__MESSAGE_DETAILS_METHOD`, -/// The name of the chain has to be specified in snake case (e.g. `rialto_parachain`). +/// The name of the chain has to be specified in snake case (e.g. `bridge_hub_polkadot`). #[macro_export] macro_rules! decl_bridge_messages_runtime_apis { ($chain: ident) => { @@ -390,7 +390,7 @@ macro_rules! decl_bridge_messages_runtime_apis { /// Convenience macro that declares bridge finality runtime apis, bridge messages runtime apis /// and related constants for a chain. -/// The name of the chain has to be specified in snake case (e.g. `rialto_parachain`). +/// The name of the chain has to be specified in snake case (e.g. `bridge_hub_polkadot`). #[macro_export] macro_rules! decl_bridge_runtime_apis { ($chain: ident $(, $consensus: ident)?) => { diff --git a/primitives/runtime/src/lib.rs b/primitives/runtime/src/lib.rs index e5277d8db6a84..0b6f90fd934ff 100644 --- a/primitives/runtime/src/lib.rs +++ b/primitives/runtime/src/lib.rs @@ -61,15 +61,6 @@ pub use sp_runtime::paste; /// Use this when something must be shared among all instances. pub const NO_INSTANCE_ID: ChainId = [0, 0, 0, 0]; -/// Rialto chain id. -pub const RIALTO_CHAIN_ID: ChainId = *b"rlto"; - -/// RialtoParachain chain id. -pub const RIALTO_PARACHAIN_CHAIN_ID: ChainId = *b"rlpa"; - -/// Millau chain id. -pub const MILLAU_CHAIN_ID: ChainId = *b"mlau"; - /// Polkadot chain id. pub const POLKADOT_CHAIN_ID: ChainId = *b"pdot"; @@ -277,18 +268,6 @@ pub fn storage_map_final_key( StorageKey(final_key) } -/// This is how a storage key of storage parameter (`parameter_types! { storage Param: bool = false; -/// }`) is computed. -/// -/// Copied from `frame_support::parameter_types` macro. -pub fn storage_parameter_key(parameter_name: &str) -> StorageKey { - let mut buffer = Vec::with_capacity(1 + parameter_name.len() + 1); - buffer.push(b':'); - buffer.extend_from_slice(parameter_name.as_bytes()); - buffer.push(b':'); - StorageKey(sp_io::hashing::twox_128(&buffer).to_vec()) -} - /// This is how a storage key of storage value is computed. /// /// Copied from `frame_support::storage::storage_prefix`. @@ -574,14 +553,6 @@ where mod tests { use super::*; - #[test] - fn storage_parameter_key_works() { - assert_eq!( - storage_parameter_key("MillauToRialtoConversionRate"), - StorageKey(hex_literal::hex!("58942375551bb0af1682f72786b59d04").to_vec()), - ); - } - #[test] fn storage_value_key_works() { assert_eq!( diff --git a/relays/bin-substrate/Cargo.toml b/relays/bin-substrate/Cargo.toml index b4e69816e59c4..b1ebcbbdcee9b 100644 --- a/relays/bin-substrate/Cargo.toml +++ b/relays/bin-substrate/Cargo.toml @@ -25,19 +25,12 @@ strum = { version = "0.25.0", features = ["derive"] } bp-header-chain = { path = "../../primitives/header-chain" } bp-messages = { path = "../../primitives/messages" } bp-parachains = { path = "../../primitives/parachains" } -bp-millau = { path = "../../primitives/chain-millau" } bp-polkadot-bulletin = { path = "../../primitives/chain-polkadot-bulletin" } bp-polkadot-core = { path = "../../primitives/polkadot-core" } -bp-rialto = { path = "../../primitives/chain-rialto" } -bp-rialto-parachain = { path = "../../primitives/chain-rialto-parachain" } bp-runtime = { path = "../../primitives/runtime" } bridge-runtime-common = { path = "../../bin/runtime-common" } -millau-runtime = { path = "../../bin/millau/runtime" } pallet-bridge-parachains = { path = "../../modules/parachains" } parachains-relay = { path = "../parachains" } -relay-millau-client = { path = "../client-millau" } -relay-rialto-client = { path = "../client-rialto" } -relay-rialto-parachain-client = { path = "../client-rialto-parachain" } relay-bridge-hub-kusama-client = { path = "../client-bridge-hub-kusama" } relay-bridge-hub-polkadot-client = { path = "../client-bridge-hub-polkadot" } relay-bridge-hub-rococo-client = { path = "../client-bridge-hub-rococo" } @@ -51,10 +44,6 @@ relay-substrate-client = { path = "../client-substrate" } relay-utils = { path = "../utils" } relay-westend-client = { path = "../client-westend" } relay-wococo-client = { path = "../client-wococo" } -rialto-runtime = { path = "../../bin/rialto/runtime" } -# we are not using this runtime to craft call or transactions, but we still need it -# to prepare large XCM messages -rialto-parachain-runtime = { path = "../../bin/rialto-parachain/runtime" } substrate-relay-helper = { path = "../lib-substrate-relay" } # Substrate Dependencies @@ -63,14 +52,6 @@ frame-support = { git = "https://github.com/paritytech/polkadot-sdk", branch = " sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -# Polkadot Dependencies -polkadot-parachain-primitives = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -polkadot-primitives = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -polkadot-runtime-common = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -polkadot-runtime-parachains = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -xcm = { package = "staging-xcm", git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -xcm-executor = { package = "staging-xcm-executor", git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } - [dev-dependencies] bp-test-utils = { path = "../../primitives/test-utils" } hex-literal = "0.4" diff --git a/relays/bin-substrate/src/bridges/mod.rs b/relays/bin-substrate/src/bridges/mod.rs index 5a6bf72d0c523..5a40b80cb9321 100644 --- a/relays/bin-substrate/src/bridges/mod.rs +++ b/relays/bin-substrate/src/bridges/mod.rs @@ -18,8 +18,5 @@ pub mod kusama_polkadot; pub mod polkadot_bulletin; -pub mod rialto_millau; -pub mod rialto_parachain_millau; pub mod rococo_westend; pub mod rococo_wococo; -pub mod westend_millau; diff --git a/relays/bin-substrate/src/bridges/rialto_millau/millau_headers_to_rialto.rs b/relays/bin-substrate/src/bridges/rialto_millau/millau_headers_to_rialto.rs deleted file mode 100644 index 7fd5513a27295..0000000000000 --- a/relays/bin-substrate/src/bridges/rialto_millau/millau_headers_to_rialto.rs +++ /dev/null @@ -1,74 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Millau-to-Rialto headers sync entrypoint. - -use crate::cli::bridge::{ - CliBridgeBase, MessagesCliBridge, RelayToRelayEquivocationDetectionCliBridge, - RelayToRelayHeadersCliBridge, -}; -use substrate_relay_helper::{ - equivocation::{ - DirectReportGrandpaEquivocationCallBuilder, SubstrateEquivocationDetectionPipeline, - }, - finality::{DirectSubmitGrandpaFinalityProofCallBuilder, SubstrateFinalitySyncPipeline}, - finality_base::{engine::Grandpa as GrandpaFinalityEngine, SubstrateFinalityPipeline}, -}; - -/// Description of Millau -> Rialto finalized headers bridge. -#[derive(Clone, Debug)] -pub struct MillauFinalityToRialto; - -impl SubstrateFinalityPipeline for MillauFinalityToRialto { - type SourceChain = relay_millau_client::Millau; - type TargetChain = relay_rialto_client::Rialto; - - type FinalityEngine = GrandpaFinalityEngine; -} - -impl SubstrateFinalitySyncPipeline for MillauFinalityToRialto { - type SubmitFinalityProofCallBuilder = DirectSubmitGrandpaFinalityProofCallBuilder< - Self, - rialto_runtime::Runtime, - rialto_runtime::MillauGrandpaInstance, - >; -} - -impl SubstrateEquivocationDetectionPipeline for MillauFinalityToRialto { - type ReportEquivocationCallBuilder = - DirectReportGrandpaEquivocationCallBuilder; -} - -/// `Millau` to `Rialto` bridge definition. -pub struct MillauToRialtoCliBridge {} - -impl CliBridgeBase for MillauToRialtoCliBridge { - type Source = relay_millau_client::Millau; - type Target = relay_rialto_client::Rialto; -} - -impl RelayToRelayHeadersCliBridge for MillauToRialtoCliBridge { - type Finality = MillauFinalityToRialto; -} - -impl RelayToRelayEquivocationDetectionCliBridge for MillauToRialtoCliBridge { - type Equivocation = MillauFinalityToRialto; -} - -impl MessagesCliBridge for MillauToRialtoCliBridge { - type MessagesLane = - crate::bridges::rialto_millau::millau_messages_to_rialto::MillauMessagesToRialto; -} diff --git a/relays/bin-substrate/src/bridges/rialto_millau/millau_messages_to_rialto.rs b/relays/bin-substrate/src/bridges/rialto_millau/millau_messages_to_rialto.rs deleted file mode 100644 index e6a2ef1a85660..0000000000000 --- a/relays/bin-substrate/src/bridges/rialto_millau/millau_messages_to_rialto.rs +++ /dev/null @@ -1,47 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Millau-to-Rialto messages sync entrypoint. - -use relay_millau_client::Millau; -use relay_rialto_client::Rialto; -use substrate_relay_helper::messages_lane::{ - DirectReceiveMessagesDeliveryProofCallBuilder, DirectReceiveMessagesProofCallBuilder, - SubstrateMessageLane, -}; - -/// Description of Millau -> Rialto messages bridge. -#[derive(Clone, Debug)] -pub struct MillauMessagesToRialto; - -impl SubstrateMessageLane for MillauMessagesToRialto { - type SourceChain = Millau; - type TargetChain = Rialto; - - type ReceiveMessagesProofCallBuilder = DirectReceiveMessagesProofCallBuilder< - Self, - rialto_runtime::Runtime, - rialto_runtime::WithMillauMessagesInstance, - >; - type ReceiveMessagesDeliveryProofCallBuilder = DirectReceiveMessagesDeliveryProofCallBuilder< - Self, - millau_runtime::Runtime, - millau_runtime::WithRialtoMessagesInstance, - >; - - type SourceBatchCallBuilder = (); - type TargetBatchCallBuilder = (); -} diff --git a/relays/bin-substrate/src/bridges/rialto_millau/mod.rs b/relays/bin-substrate/src/bridges/rialto_millau/mod.rs deleted file mode 100644 index 2353b58ce616e..0000000000000 --- a/relays/bin-substrate/src/bridges/rialto_millau/mod.rs +++ /dev/null @@ -1,22 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Declaration of all bridges between Rialto and Millau. - -pub mod millau_headers_to_rialto; -pub mod millau_messages_to_rialto; -pub mod rialto_headers_to_millau; -pub mod rialto_messages_to_millau; diff --git a/relays/bin-substrate/src/bridges/rialto_millau/rialto_headers_to_millau.rs b/relays/bin-substrate/src/bridges/rialto_millau/rialto_headers_to_millau.rs deleted file mode 100644 index d9b98d77784e7..0000000000000 --- a/relays/bin-substrate/src/bridges/rialto_millau/rialto_headers_to_millau.rs +++ /dev/null @@ -1,74 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Rialto-to-Millau headers sync entrypoint. - -use crate::cli::bridge::{ - CliBridgeBase, MessagesCliBridge, RelayToRelayEquivocationDetectionCliBridge, - RelayToRelayHeadersCliBridge, -}; -use substrate_relay_helper::{ - equivocation::{ - DirectReportGrandpaEquivocationCallBuilder, SubstrateEquivocationDetectionPipeline, - }, - finality::{DirectSubmitGrandpaFinalityProofCallBuilder, SubstrateFinalitySyncPipeline}, - finality_base::{engine::Grandpa as GrandpaFinalityEngine, SubstrateFinalityPipeline}, -}; - -/// Description of Millau -> Rialto finalized headers bridge. -#[derive(Clone, Debug)] -pub struct RialtoFinalityToMillau; - -impl SubstrateFinalityPipeline for RialtoFinalityToMillau { - type SourceChain = relay_rialto_client::Rialto; - type TargetChain = relay_millau_client::Millau; - - type FinalityEngine = GrandpaFinalityEngine; -} - -impl SubstrateFinalitySyncPipeline for RialtoFinalityToMillau { - type SubmitFinalityProofCallBuilder = DirectSubmitGrandpaFinalityProofCallBuilder< - Self, - millau_runtime::Runtime, - millau_runtime::RialtoGrandpaInstance, - >; -} - -impl SubstrateEquivocationDetectionPipeline for RialtoFinalityToMillau { - type ReportEquivocationCallBuilder = - DirectReportGrandpaEquivocationCallBuilder; -} - -/// `Rialto` to `Millau` bridge definition. -pub struct RialtoToMillauCliBridge {} - -impl CliBridgeBase for RialtoToMillauCliBridge { - type Source = relay_rialto_client::Rialto; - type Target = relay_millau_client::Millau; -} - -impl RelayToRelayHeadersCliBridge for RialtoToMillauCliBridge { - type Finality = RialtoFinalityToMillau; -} - -impl RelayToRelayEquivocationDetectionCliBridge for RialtoToMillauCliBridge { - type Equivocation = RialtoFinalityToMillau; -} - -impl MessagesCliBridge for RialtoToMillauCliBridge { - type MessagesLane = - crate::bridges::rialto_millau::rialto_messages_to_millau::RialtoMessagesToMillau; -} diff --git a/relays/bin-substrate/src/bridges/rialto_millau/rialto_messages_to_millau.rs b/relays/bin-substrate/src/bridges/rialto_millau/rialto_messages_to_millau.rs deleted file mode 100644 index b45239fb9a91e..0000000000000 --- a/relays/bin-substrate/src/bridges/rialto_millau/rialto_messages_to_millau.rs +++ /dev/null @@ -1,47 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Rialto-to-Millau messages sync entrypoint. - -use relay_millau_client::Millau; -use relay_rialto_client::Rialto; -use substrate_relay_helper::messages_lane::{ - DirectReceiveMessagesDeliveryProofCallBuilder, DirectReceiveMessagesProofCallBuilder, - SubstrateMessageLane, -}; - -/// Description of Rialto -> Millau messages bridge. -#[derive(Clone, Debug)] -pub struct RialtoMessagesToMillau; - -impl SubstrateMessageLane for RialtoMessagesToMillau { - type SourceChain = Rialto; - type TargetChain = Millau; - - type ReceiveMessagesProofCallBuilder = DirectReceiveMessagesProofCallBuilder< - Self, - millau_runtime::Runtime, - millau_runtime::WithRialtoMessagesInstance, - >; - type ReceiveMessagesDeliveryProofCallBuilder = DirectReceiveMessagesDeliveryProofCallBuilder< - Self, - rialto_runtime::Runtime, - rialto_runtime::WithMillauMessagesInstance, - >; - - type SourceBatchCallBuilder = (); - type TargetBatchCallBuilder = (); -} diff --git a/relays/bin-substrate/src/bridges/rialto_parachain_millau/millau_headers_to_rialto_parachain.rs b/relays/bin-substrate/src/bridges/rialto_parachain_millau/millau_headers_to_rialto_parachain.rs deleted file mode 100644 index 051057e217665..0000000000000 --- a/relays/bin-substrate/src/bridges/rialto_parachain_millau/millau_headers_to_rialto_parachain.rs +++ /dev/null @@ -1,95 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Millau-to-RialtoParachain headers sync entrypoint. - -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Millau-to-RialtoParachain headers sync entrypoint. - -use crate::cli::bridge::{ - CliBridgeBase, MessagesCliBridge, RelayToRelayEquivocationDetectionCliBridge, - RelayToRelayHeadersCliBridge, -}; -use substrate_relay_helper::{ - equivocation::{ - DirectReportGrandpaEquivocationCallBuilder, SubstrateEquivocationDetectionPipeline, - }, - finality::SubstrateFinalitySyncPipeline, - finality_base::{engine::Grandpa as GrandpaFinalityEngine, SubstrateFinalityPipeline}, -}; - -substrate_relay_helper::generate_submit_finality_proof_call_builder!( - MillauFinalityToRialtoParachain, - MillauFinalityToRialtoParachainCallBuilder, - relay_rialto_parachain_client::RuntimeCall::BridgeMillauGrandpa, - relay_rialto_parachain_client::BridgeGrandpaCall::submit_finality_proof -); - -/// Description of Millau -> Rialto finalized headers bridge. -#[derive(Clone, Debug)] -pub struct MillauFinalityToRialtoParachain; - -impl SubstrateFinalityPipeline for MillauFinalityToRialtoParachain { - type SourceChain = relay_millau_client::Millau; - type TargetChain = relay_rialto_parachain_client::RialtoParachain; - - type FinalityEngine = GrandpaFinalityEngine; -} - -impl SubstrateFinalitySyncPipeline for MillauFinalityToRialtoParachain { - type SubmitFinalityProofCallBuilder = MillauFinalityToRialtoParachainCallBuilder; -} - -impl SubstrateEquivocationDetectionPipeline for MillauFinalityToRialtoParachain { - type ReportEquivocationCallBuilder = - DirectReportGrandpaEquivocationCallBuilder; -} - -/// `Millau` to `RialtoParachain` bridge definition. -pub struct MillauToRialtoParachainCliBridge {} - -impl CliBridgeBase for MillauToRialtoParachainCliBridge { - type Source = relay_millau_client::Millau; - type Target = relay_rialto_parachain_client::RialtoParachain; -} - -impl RelayToRelayHeadersCliBridge for MillauToRialtoParachainCliBridge { - type Finality = MillauFinalityToRialtoParachain; -} - -impl RelayToRelayEquivocationDetectionCliBridge for MillauToRialtoParachainCliBridge { - type Equivocation = MillauFinalityToRialtoParachain; -} - -impl MessagesCliBridge for MillauToRialtoParachainCliBridge { - type MessagesLane = - crate::bridges::rialto_parachain_millau::millau_messages_to_rialto_parachain::MillauMessagesToRialtoParachain; -} diff --git a/relays/bin-substrate/src/bridges/rialto_parachain_millau/millau_messages_to_rialto_parachain.rs b/relays/bin-substrate/src/bridges/rialto_parachain_millau/millau_messages_to_rialto_parachain.rs deleted file mode 100644 index 8fedd22a40abe..0000000000000 --- a/relays/bin-substrate/src/bridges/rialto_parachain_millau/millau_messages_to_rialto_parachain.rs +++ /dev/null @@ -1,51 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Millau-to-RialtoParachain messages sync entrypoint. - -use relay_millau_client::Millau; -use relay_rialto_parachain_client::RialtoParachain; -use substrate_relay_helper::{ - messages_lane::{DirectReceiveMessagesDeliveryProofCallBuilder, SubstrateMessageLane}, - UtilityPalletBatchCallBuilder, -}; - -substrate_relay_helper::generate_receive_message_proof_call_builder!( - MillauMessagesToRialtoParachain, - MillauMessagesToRialtoParachainReceiveMessagesProofCallBuilder, - relay_rialto_parachain_client::RuntimeCall::BridgeMillauMessages, - relay_rialto_parachain_client::BridgeMessagesCall::receive_messages_proof -); - -/// Description of Millau -> RialtoParachain messages bridge. -#[derive(Clone, Debug)] -pub struct MillauMessagesToRialtoParachain; - -impl SubstrateMessageLane for MillauMessagesToRialtoParachain { - type SourceChain = Millau; - type TargetChain = RialtoParachain; - - type ReceiveMessagesProofCallBuilder = - MillauMessagesToRialtoParachainReceiveMessagesProofCallBuilder; - type ReceiveMessagesDeliveryProofCallBuilder = DirectReceiveMessagesDeliveryProofCallBuilder< - Self, - millau_runtime::Runtime, - millau_runtime::WithRialtoParachainMessagesInstance, - >; - - type SourceBatchCallBuilder = UtilityPalletBatchCallBuilder; - type TargetBatchCallBuilder = (); -} diff --git a/relays/bin-substrate/src/bridges/rialto_parachain_millau/mod.rs b/relays/bin-substrate/src/bridges/rialto_parachain_millau/mod.rs deleted file mode 100644 index f0613d1511eb3..0000000000000 --- a/relays/bin-substrate/src/bridges/rialto_parachain_millau/mod.rs +++ /dev/null @@ -1,22 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Declaration of all bridges between Rialto Parachain and Millau. - -pub mod millau_headers_to_rialto_parachain; -pub mod millau_messages_to_rialto_parachain; -pub mod rialto_parachain_messages_to_millau; -pub mod rialto_parachains_to_millau; diff --git a/relays/bin-substrate/src/bridges/rialto_parachain_millau/rialto_parachain_messages_to_millau.rs b/relays/bin-substrate/src/bridges/rialto_parachain_millau/rialto_parachain_messages_to_millau.rs deleted file mode 100644 index e19953eac554d..0000000000000 --- a/relays/bin-substrate/src/bridges/rialto_parachain_millau/rialto_parachain_messages_to_millau.rs +++ /dev/null @@ -1,51 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! RialtoParachain-to-Millau messages sync entrypoint. - -use relay_millau_client::Millau; -use relay_rialto_parachain_client::RialtoParachain; -use substrate_relay_helper::{ - messages_lane::{DirectReceiveMessagesProofCallBuilder, SubstrateMessageLane}, - UtilityPalletBatchCallBuilder, -}; - -substrate_relay_helper::generate_receive_message_delivery_proof_call_builder!( - RialtoParachainMessagesToMillau, - RialtoParachainMessagesToMillauReceiveMessagesDeliveryProofCallBuilder, - relay_rialto_parachain_client::RuntimeCall::BridgeMillauMessages, - relay_rialto_parachain_client::BridgeMessagesCall::receive_messages_delivery_proof -); - -/// Description of RialtoParachain -> Millau messages bridge. -#[derive(Clone, Debug)] -pub struct RialtoParachainMessagesToMillau; - -impl SubstrateMessageLane for RialtoParachainMessagesToMillau { - type SourceChain = RialtoParachain; - type TargetChain = Millau; - - type ReceiveMessagesProofCallBuilder = DirectReceiveMessagesProofCallBuilder< - Self, - millau_runtime::Runtime, - millau_runtime::WithRialtoParachainMessagesInstance, - >; - type ReceiveMessagesDeliveryProofCallBuilder = - RialtoParachainMessagesToMillauReceiveMessagesDeliveryProofCallBuilder; - - type SourceBatchCallBuilder = (); - type TargetBatchCallBuilder = UtilityPalletBatchCallBuilder; -} diff --git a/relays/bin-substrate/src/bridges/rialto_parachain_millau/rialto_parachains_to_millau.rs b/relays/bin-substrate/src/bridges/rialto_parachain_millau/rialto_parachains_to_millau.rs deleted file mode 100644 index 6b2a1332144dc..0000000000000 --- a/relays/bin-substrate/src/bridges/rialto_parachain_millau/rialto_parachains_to_millau.rs +++ /dev/null @@ -1,65 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Rialto-to-Millau parachains sync entrypoint. - -use crate::cli::bridge::{CliBridgeBase, MessagesCliBridge, ParachainToRelayHeadersCliBridge}; -use relay_millau_client::Millau; -use relay_rialto_client::Rialto; -use relay_rialto_parachain_client::RialtoParachain; -use substrate_relay_helper::parachains::{ - DirectSubmitParachainHeadsCallBuilder, SubstrateParachainsPipeline, -}; - -/// Rialto-to-Millau parachains sync description. -#[derive(Clone, Debug)] -pub struct RialtoParachainsToMillau; - -impl SubstrateParachainsPipeline for RialtoParachainsToMillau { - type SourceParachain = RialtoParachain; - type SourceRelayChain = Rialto; - type TargetChain = Millau; - - type SubmitParachainHeadsCallBuilder = RialtoParachainsToMillauSubmitParachainHeadsCallBuilder; -} - -/// `submit_parachain_heads` call builder for Rialto-to-Millau parachains sync pipeline. -pub type RialtoParachainsToMillauSubmitParachainHeadsCallBuilder = - DirectSubmitParachainHeadsCallBuilder< - RialtoParachainsToMillau, - millau_runtime::Runtime, - millau_runtime::WithRialtoParachainsInstance, - >; - -/// `RialtoParachain` to `Millau` bridge definition. -pub struct RialtoParachainToMillauCliBridge {} - -impl CliBridgeBase for RialtoParachainToMillauCliBridge { - type Source = RialtoParachain; - type Target = Millau; -} - -impl ParachainToRelayHeadersCliBridge for RialtoParachainToMillauCliBridge { - type SourceRelay = Rialto; - type ParachainFinality = RialtoParachainsToMillau; - type RelayFinality = - crate::bridges::rialto_millau::rialto_headers_to_millau::RialtoFinalityToMillau; -} - -impl MessagesCliBridge for RialtoParachainToMillauCliBridge { - type MessagesLane = - crate::bridges::rialto_parachain_millau::rialto_parachain_messages_to_millau::RialtoParachainMessagesToMillau; -} diff --git a/relays/bin-substrate/src/bridges/westend_millau/mod.rs b/relays/bin-substrate/src/bridges/westend_millau/mod.rs deleted file mode 100644 index 10bc19241ce12..0000000000000 --- a/relays/bin-substrate/src/bridges/westend_millau/mod.rs +++ /dev/null @@ -1,20 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Declaration of all bridges between Westend and Millau. - -pub mod westend_headers_to_millau; -pub mod westend_parachains_to_millau; diff --git a/relays/bin-substrate/src/bridges/westend_millau/westend_headers_to_millau.rs b/relays/bin-substrate/src/bridges/westend_millau/westend_headers_to_millau.rs deleted file mode 100644 index afbbd064d1fe0..0000000000000 --- a/relays/bin-substrate/src/bridges/westend_millau/westend_headers_to_millau.rs +++ /dev/null @@ -1,54 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Westend-to-Millau headers sync entrypoint. - -use crate::cli::bridge::{CliBridgeBase, RelayToRelayHeadersCliBridge}; -use substrate_relay_helper::{ - finality::{DirectSubmitGrandpaFinalityProofCallBuilder, SubstrateFinalitySyncPipeline}, - finality_base::{engine::Grandpa as GrandpaFinalityEngine, SubstrateFinalityPipeline}, -}; - -/// Description of Westend -> Millau finalized headers bridge. -#[derive(Clone, Debug)] -pub struct WestendFinalityToMillau; - -impl SubstrateFinalityPipeline for WestendFinalityToMillau { - type SourceChain = relay_westend_client::Westend; - type TargetChain = relay_millau_client::Millau; - - type FinalityEngine = GrandpaFinalityEngine; -} - -impl SubstrateFinalitySyncPipeline for WestendFinalityToMillau { - type SubmitFinalityProofCallBuilder = DirectSubmitGrandpaFinalityProofCallBuilder< - Self, - millau_runtime::Runtime, - millau_runtime::WestendGrandpaInstance, - >; -} - -/// `Westend` to `Millau` bridge definition. -pub struct WestendToMillauCliBridge {} - -impl CliBridgeBase for WestendToMillauCliBridge { - type Source = relay_westend_client::Westend; - type Target = relay_millau_client::Millau; -} - -impl RelayToRelayHeadersCliBridge for WestendToMillauCliBridge { - type Finality = WestendFinalityToMillau; -} diff --git a/relays/bin-substrate/src/bridges/westend_millau/westend_parachains_to_millau.rs b/relays/bin-substrate/src/bridges/westend_millau/westend_parachains_to_millau.rs deleted file mode 100644 index 96023dc430a28..0000000000000 --- a/relays/bin-substrate/src/bridges/westend_millau/westend_parachains_to_millau.rs +++ /dev/null @@ -1,90 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Westend-to-Millau parachains sync entrypoint. - -use crate::cli::bridge::{CliBridgeBase, ParachainToRelayHeadersCliBridge}; -use relay_millau_client::Millau; -use relay_westend_client::Westend; -use substrate_relay_helper::parachains::{ - DirectSubmitParachainHeadsCallBuilder, SubstrateParachainsPipeline, -}; - -/// Westend-to-Millau parachains sync description. -#[derive(Clone, Debug)] -pub struct WestendParachainsToMillau; - -impl SubstrateParachainsPipeline for WestendParachainsToMillau { - type SourceParachain = relay_asset_hub_westend_client::AssetHubWestend; - type SourceRelayChain = Westend; - type TargetChain = Millau; - - type SubmitParachainHeadsCallBuilder = WestendParachainsToMillauSubmitParachainHeadsCallBuilder; -} - -/// `submit_parachain_heads` call builder for Rialto-to-Millau parachains sync pipeline. -pub type WestendParachainsToMillauSubmitParachainHeadsCallBuilder = - DirectSubmitParachainHeadsCallBuilder< - WestendParachainsToMillau, - millau_runtime::Runtime, - millau_runtime::WithWestendParachainsInstance, - >; - -/// `WestendParachain` to `Millau` bridge definition. -pub struct AssetHubWestendToMillauCliBridge {} - -impl ParachainToRelayHeadersCliBridge for AssetHubWestendToMillauCliBridge { - type SourceRelay = Westend; - type ParachainFinality = WestendParachainsToMillau; - type RelayFinality = - crate::bridges::westend_millau::westend_headers_to_millau::WestendFinalityToMillau; -} - -impl CliBridgeBase for AssetHubWestendToMillauCliBridge { - type Source = relay_asset_hub_westend_client::AssetHubWestend; - type Target = Millau; -} - -/// TODO: Note: I know this does not belong here, but I don't want to add it to the -/// `chain-asset-hub-westend` or `chain-westend`, because we wont use it for production and I don't -/// want to bring this to the bridges subtree now. Anyway, we plan to retire millau/rialto, so this -/// hack will disappear with that. -pub mod relay_asset_hub_westend_client { - use bp_runtime::{ChainId, UnderlyingChainProvider}; - use relay_substrate_client::Chain; - use std::time::Duration; - - /// `AssetHubWestend` parachain definition - #[derive(Debug, Clone, Copy)] - pub struct AssetHubWestend; - - impl UnderlyingChainProvider for AssetHubWestend { - type Chain = millau_runtime::bp_bridged_chain::AssetHubWestend; - } - - // Westmint seems to use the same configuration as all Polkadot-like chains, so we'll use - // Westend primitives here. - impl Chain for AssetHubWestend { - const ID: ChainId = bp_runtime::ASSET_HUB_WESTEND_CHAIN_ID; - const NAME: &'static str = "Westmint"; - const BEST_FINALIZED_HEADER_ID_METHOD: &'static str = - millau_runtime::bp_bridged_chain::BEST_FINALIZED_ASSETHUBWESTEND_HEADER_METHOD; - const AVERAGE_BLOCK_INTERVAL: Duration = Duration::from_secs(6); - - type SignedBlock = bp_polkadot_core::SignedBlock; - type Call = (); - } -} diff --git a/relays/bin-substrate/src/chains/millau.rs b/relays/bin-substrate/src/chains/millau.rs deleted file mode 100644 index f60d60386e9ba..0000000000000 --- a/relays/bin-substrate/src/chains/millau.rs +++ /dev/null @@ -1,75 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Millau chain specification for CLI. - -use crate::cli::{encode_message::CliEncodeMessage, CliChain}; -use bp_runtime::EncodedOrDecodedCall; -use bridge_runtime_common::CustomNetworkId; -use relay_millau_client::Millau; -use relay_substrate_client::SimpleRuntimeVersion; -use xcm_executor::traits::ExportXcm; - -impl CliEncodeMessage for Millau { - fn encode_wire_message( - target: xcm::v3::NetworkId, - at_target_xcm: xcm::v3::Xcm<()>, - ) -> anyhow::Result> { - anyhow::ensure!( - [ - CustomNetworkId::Rialto.as_network_id(), - CustomNetworkId::RialtoParachain.as_network_id() - ] - .contains(&target), - anyhow::format_err!("Unsupported target chain: {:?}", target) - ); - - Ok(millau_runtime::xcm_config::ToRialtoOrRialtoParachainSwitchExporter::validate( - target, - 0, - &mut Some(Self::dummy_universal_source()?), - &mut Some(target.into()), - &mut Some(at_target_xcm), - ) - .map_err(|e| anyhow::format_err!("Failed to prepare outbound message: {:?}", e))? - .0 - .1 - .0) - } - - fn encode_execute_xcm( - message: xcm::VersionedXcm, - ) -> anyhow::Result> { - Ok(millau_runtime::RuntimeCall::XcmPallet(millau_runtime::XcmCall::execute { - message: Box::new(message), - max_weight: Self::estimate_execute_xcm_weight(), - }) - .into()) - } -} - -impl CliChain for Millau { - const RUNTIME_VERSION: Option = - Some(SimpleRuntimeVersion::from_runtime_version(&millau_runtime::VERSION)); -} - -/// TODO: Note: I know this does not belong here, but I don't want to add it to the -/// `chain-asset-hub-westend` or `chain-westend`, because we wont use it for production and I don't -/// want to bring this to the bridges subtree now. Anyway, we plan to retire millau/rialto, so this -/// hack will disappear with that. -impl CliChain for crate::bridges::westend_millau::westend_parachains_to_millau::relay_asset_hub_westend_client::AssetHubWestend { - const RUNTIME_VERSION: Option = None; -} diff --git a/relays/bin-substrate/src/chains/mod.rs b/relays/bin-substrate/src/chains/mod.rs index c9a55e9e900f0..442236997c8ba 100644 --- a/relays/bin-substrate/src/chains/mod.rs +++ b/relays/bin-substrate/src/chains/mod.rs @@ -17,95 +17,8 @@ //! Chain-specific relayer configuration. mod kusama; -mod millau; mod polkadot; mod polkadot_bulletin; -mod rialto; -mod rialto_parachain; mod rococo; mod westend; mod wococo; - -#[cfg(test)] -mod tests { - use crate::cli::encode_message; - use bp_messages::source_chain::TargetHeaderChain; - use bp_runtime::Chain as _; - use codec::Encode; - use relay_millau_client::Millau; - use relay_rialto_client::Rialto; - use relay_substrate_client::{ChainWithTransactions, SignParam, UnsignedTransaction}; - - #[test] - fn maximal_rialto_to_millau_message_size_is_computed_correctly() { - use rialto_runtime::millau_messages::MillauAsTargetHeaderChain; - - let maximal_message_size = encode_message::compute_maximal_message_size( - bp_rialto::Rialto::max_extrinsic_size(), - bp_millau::Millau::max_extrinsic_size(), - ); - - let message = vec![42; maximal_message_size as _]; - assert_eq!(MillauAsTargetHeaderChain::verify_message(&message), Ok(())); - - let message = vec![42; (maximal_message_size + 1) as _]; - assert!(MillauAsTargetHeaderChain::verify_message(&message).is_err()); - } - - #[test] - fn maximal_size_remark_to_rialto_is_generated_correctly() { - assert!( - bridge_runtime_common::messages::target::maximal_incoming_message_size( - bp_rialto::Rialto::max_extrinsic_size() - ) > bp_millau::Millau::max_extrinsic_size(), - "We can't actually send maximal messages to Rialto from Millau, because Millau extrinsics can't be that large", - ) - } - #[test] - fn rialto_tx_extra_bytes_constant_is_correct() { - let rialto_call = rialto_runtime::RuntimeCall::System(rialto_runtime::SystemCall::remark { - remark: vec![], - }); - let rialto_tx = Rialto::sign_transaction( - SignParam { - spec_version: 1, - transaction_version: 1, - genesis_hash: Default::default(), - signer: sp_keyring::AccountKeyring::Alice.pair(), - }, - UnsignedTransaction::new(rialto_call.clone().into(), 0), - ) - .unwrap(); - let extra_bytes_in_transaction = rialto_tx.encode().len() - rialto_call.encode().len(); - assert!( - bp_rialto::TX_EXTRA_BYTES as usize >= extra_bytes_in_transaction, - "Hardcoded number of extra bytes in Rialto transaction {} is lower than actual value: {}", - bp_rialto::TX_EXTRA_BYTES, - extra_bytes_in_transaction, - ); - } - - #[test] - fn millau_tx_extra_bytes_constant_is_correct() { - let millau_call = millau_runtime::RuntimeCall::System(millau_runtime::SystemCall::remark { - remark: vec![], - }); - let millau_tx = Millau::sign_transaction( - SignParam { - spec_version: 0, - transaction_version: 0, - genesis_hash: Default::default(), - signer: sp_keyring::AccountKeyring::Alice.pair(), - }, - UnsignedTransaction::new(millau_call.clone().into(), 0), - ) - .unwrap(); - let extra_bytes_in_transaction = millau_tx.encode().len() - millau_call.encode().len(); - assert!( - bp_millau::TX_EXTRA_BYTES as usize >= extra_bytes_in_transaction, - "Hardcoded number of extra bytes in Millau transaction {} is lower than actual value: {}", - bp_millau::TX_EXTRA_BYTES, - extra_bytes_in_transaction, - ); - } -} diff --git a/relays/bin-substrate/src/chains/rialto.rs b/relays/bin-substrate/src/chains/rialto.rs deleted file mode 100644 index 30bc7eb13ca99..0000000000000 --- a/relays/bin-substrate/src/chains/rialto.rs +++ /dev/null @@ -1,62 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Rialto chain specification for CLI. - -use crate::cli::{encode_message::CliEncodeMessage, CliChain}; -use bp_runtime::EncodedOrDecodedCall; -use bridge_runtime_common::CustomNetworkId; -use relay_rialto_client::Rialto; -use relay_substrate_client::SimpleRuntimeVersion; -use xcm_executor::traits::ExportXcm; - -impl CliEncodeMessage for Rialto { - fn encode_wire_message( - target: xcm::v3::NetworkId, - at_target_xcm: xcm::v3::Xcm<()>, - ) -> anyhow::Result> { - anyhow::ensure!( - target == CustomNetworkId::Millau.as_network_id(), - anyhow::format_err!("Unsupported target chain: {:?}", target) - ); - - Ok(rialto_runtime::millau_messages::ToMillauBlobExporter::validate( - target, - 0, - &mut Some(Self::dummy_universal_source()?), - &mut Some(target.into()), - &mut Some(at_target_xcm), - ) - .map_err(|e| anyhow::format_err!("Failed to prepare outbound message: {:?}", e))? - .0 - .0) - } - - fn encode_execute_xcm( - message: xcm::VersionedXcm, - ) -> anyhow::Result> { - Ok(rialto_runtime::RuntimeCall::XcmPallet(rialto_runtime::XcmCall::execute { - message: Box::new(message), - max_weight: Self::estimate_execute_xcm_weight(), - }) - .into()) - } -} - -impl CliChain for Rialto { - const RUNTIME_VERSION: Option = - Some(SimpleRuntimeVersion::from_runtime_version(&rialto_runtime::VERSION)); -} diff --git a/relays/bin-substrate/src/chains/rialto_parachain.rs b/relays/bin-substrate/src/chains/rialto_parachain.rs deleted file mode 100644 index 872d96981d0bf..0000000000000 --- a/relays/bin-substrate/src/chains/rialto_parachain.rs +++ /dev/null @@ -1,65 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Rialto parachain specification for CLI. - -use crate::cli::{encode_message::CliEncodeMessage, CliChain}; -use bp_runtime::EncodedOrDecodedCall; -use bridge_runtime_common::CustomNetworkId; -use relay_rialto_parachain_client::RialtoParachain; -use relay_substrate_client::SimpleRuntimeVersion; -use xcm_executor::traits::ExportXcm; - -impl CliEncodeMessage for RialtoParachain { - fn encode_wire_message( - target: xcm::v3::NetworkId, - at_target_xcm: xcm::v3::Xcm<()>, - ) -> anyhow::Result> { - anyhow::ensure!( - target == CustomNetworkId::Millau.as_network_id(), - anyhow::format_err!("Unsupported target chain: {:?}", target) - ); - - Ok(rialto_parachain_runtime::millau_messages::ToMillauBlobExporter::validate( - target, - 0, - &mut Some(Self::dummy_universal_source()?), - &mut Some(target.into()), - &mut Some(at_target_xcm), - ) - .map_err(|e| anyhow::format_err!("Failed to prepare outbound message: {:?}", e))? - .0 - .0) - } - - fn encode_execute_xcm( - message: xcm::VersionedXcm, - ) -> anyhow::Result> { - type RuntimeCall = relay_rialto_parachain_client::RuntimeCall; - type XcmCall = relay_rialto_parachain_client::runtime_types::pallet_xcm::pallet::Call; - - let xcm_call = XcmCall::execute { - message: Box::new(unsafe { std::mem::transmute(message) }), - max_weight: Self::estimate_execute_xcm_weight(), - }; - - Ok(RuntimeCall::PolkadotXcm(xcm_call).into()) - } -} - -impl CliChain for RialtoParachain { - const RUNTIME_VERSION: Option = None; -} diff --git a/relays/bin-substrate/src/cli/bridge.rs b/relays/bin-substrate/src/cli/bridge.rs index 0c1483b348b1a..cc6dc8e43574e 100644 --- a/relays/bin-substrate/src/cli/bridge.rs +++ b/relays/bin-substrate/src/cli/bridge.rs @@ -29,10 +29,6 @@ use substrate_relay_helper::{ #[strum(serialize_all = "kebab_case")] /// Supported full bridges (headers + messages). pub enum FullBridge { - MillauToRialto, - RialtoToMillau, - MillauToRialtoParachain, - RialtoParachainToMillau, BridgeHubRococoToBridgeHubWococo, BridgeHubWococoToBridgeHubRococo, BridgeHubRococoToBridgeHubWestend, diff --git a/relays/bin-substrate/src/cli/chain_schema.rs b/relays/bin-substrate/src/cli/chain_schema.rs index bbc95d7dcdbd1..5c2161acdbd70 100644 --- a/relays/bin-substrate/src/cli/chain_schema.rs +++ b/relays/bin-substrate/src/cli/chain_schema.rs @@ -129,29 +129,6 @@ macro_rules! declare_chain_connection_params_cli_schema { }; } -/// Helper trait to override transaction parameters differently. -pub trait TransactionParamsProvider { - /// Returns `true` if transaction parameters are defined by this provider. - fn is_defined(&self) -> bool; - /// Returns transaction parameters. - fn transaction_params( - &self, - ) -> anyhow::Result>>; - - /// Returns transaction parameters, defined by `self` provider or, if they're not defined, - /// defined by `other` provider. - fn transaction_params_or( - &self, - other: &T, - ) -> anyhow::Result>> { - if self.is_defined() { - self.transaction_params::() - } else { - other.transaction_params::() - } - } -} - /// Create chain-specific set of signing parameters. #[macro_export] macro_rules! declare_chain_signing_params_cli_schema { @@ -239,15 +216,12 @@ macro_rules! declare_chain_signing_params_cli_schema { suri_password.as_deref() ).map_err(|e| anyhow::format_err!("{:?}", e)) } - } - - #[allow(dead_code)] - impl TransactionParamsProvider for [<$chain SigningParams>] { - fn is_defined(&self) -> bool { - self.[<$chain_prefix _signer>].is_some() || self.[<$chain_prefix _signer_file>].is_some() - } - fn transaction_params(&self) -> anyhow::Result>> { + /// Return transaction parameters. + #[allow(dead_code)] + pub fn transaction_params( + &self, + ) -> anyhow::Result>> { Ok(TransactionParams { mortality: self.transactions_mortality()?, signer: self.to_keypair::()?, @@ -310,7 +284,7 @@ mod tests { target_transactions_mortality: None, } - .to_keypair::() + .to_keypair::() .map(|p| p.public()) .map_err(drop), Ok(alice.public()), @@ -327,7 +301,7 @@ mod tests { target_transactions_mortality: None, } - .to_keypair::() + .to_keypair::() .map(|p| p.public()) .map_err(drop), Ok(bob.public()), @@ -344,7 +318,7 @@ mod tests { target_transactions_mortality: None, } - .to_keypair::() + .to_keypair::() .map(|p| p.public()) .map_err(drop), Ok(bob_with_alice_password.public()), @@ -361,7 +335,7 @@ mod tests { target_transactions_mortality: None, } - .to_keypair::() + .to_keypair::() .map(|p| p.public()) .map_err(drop), Ok(alice.public()), diff --git a/relays/bin-substrate/src/cli/detect_equivocations.rs b/relays/bin-substrate/src/cli/detect_equivocations.rs index bc456e025499e..704839db0e66f 100644 --- a/relays/bin-substrate/src/cli/detect_equivocations.rs +++ b/relays/bin-substrate/src/cli/detect_equivocations.rs @@ -20,11 +20,6 @@ use crate::{ kusama_headers_to_bridge_hub_polkadot::KusamaToBridgeHubPolkadotCliBridge, polkadot_headers_to_bridge_hub_kusama::PolkadotToBridgeHubKusamaCliBridge, }, - rialto_millau::{ - millau_headers_to_rialto::MillauToRialtoCliBridge, - rialto_headers_to_millau::RialtoToMillauCliBridge, - }, - rialto_parachain_millau::millau_headers_to_rialto_parachain::MillauToRialtoParachainCliBridge, rococo_wococo::{ rococo_headers_to_bridge_hub_wococo::RococoToBridgeHubWococoCliBridge, wococo_headers_to_bridge_hub_rococo::WococoToBridgeHubRococoCliBridge, @@ -58,9 +53,6 @@ pub struct DetectEquivocations { #[strum(serialize_all = "kebab_case")] /// Equivocations detection bridge. pub enum DetectEquivocationsBridge { - MillauToRialto, - RialtoToMillau, - MillauToRialtoParachain, RococoToBridgeHubWococo, WococoToBridgeHubRococo, KusamaToBridgeHubPolkadot, @@ -90,9 +82,6 @@ where } } -impl EquivocationsDetector for MillauToRialtoCliBridge {} -impl EquivocationsDetector for RialtoToMillauCliBridge {} -impl EquivocationsDetector for MillauToRialtoParachainCliBridge {} impl EquivocationsDetector for RococoToBridgeHubWococoCliBridge {} impl EquivocationsDetector for WococoToBridgeHubRococoCliBridge {} impl EquivocationsDetector for KusamaToBridgeHubPolkadotCliBridge {} @@ -102,10 +91,6 @@ impl DetectEquivocations { /// Run the command. pub async fn run(self) -> anyhow::Result<()> { match self.bridge { - DetectEquivocationsBridge::MillauToRialto => MillauToRialtoCliBridge::start(self), - DetectEquivocationsBridge::RialtoToMillau => RialtoToMillauCliBridge::start(self), - DetectEquivocationsBridge::MillauToRialtoParachain => - MillauToRialtoParachainCliBridge::start(self), DetectEquivocationsBridge::RococoToBridgeHubWococo => RococoToBridgeHubWococoCliBridge::start(self), DetectEquivocationsBridge::WococoToBridgeHubRococo => diff --git a/relays/bin-substrate/src/cli/encode_message.rs b/relays/bin-substrate/src/cli/encode_message.rs deleted file mode 100644 index 646075e832679..0000000000000 --- a/relays/bin-substrate/src/cli/encode_message.rs +++ /dev/null @@ -1,189 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use crate::cli::{ExplicitOrMaximal, HexBytes}; -use bp_runtime::EncodedOrDecodedCall; -use bridge_runtime_common::CustomNetworkId; -use codec::Encode; -use frame_support::weights::Weight; -use relay_substrate_client::Chain; -use structopt::StructOpt; -use xcm::latest::prelude::*; - -/// All possible messages that may be delivered to generic Substrate chain. -/// -/// Note this enum may be used in the context of both Source (as part of `encode-call`) -/// and Target chain (as part of `encode-message/send-message`). -#[derive(StructOpt, Debug, PartialEq, Eq)] -pub enum Message { - /// Raw bytes for the message. - Raw { - /// Raw message bytes. - data: HexBytes, - }, - /// Message with given size. - Sized { - /// Sized of the message. - size: ExplicitOrMaximal, - }, -} - -/// Raw, SCALE-encoded message payload used in expected deployment. -pub type RawMessage = Vec; - -pub trait CliEncodeMessage: Chain { - /// Returns dummy `AccountId32` universal source given this network id. - fn dummy_universal_source() -> anyhow::Result { - use xcm::v3::prelude::*; - - let this_network = CustomNetworkId::try_from(Self::ID) - .map(|n| n.as_network_id()) - .map_err(|_| anyhow::format_err!("Unsupported chain: {:?}", Self::ID))?; - Ok(X2( - GlobalConsensus(this_network), - AccountId32 { network: Some(this_network), id: [0u8; 32] }, - )) - } - - /// Returns XCM blob that is passed to the `send_message` function of the messages pallet - /// and then is sent over the wire. - fn encode_wire_message(target: NetworkId, at_target_xcm: Xcm<()>) -> anyhow::Result>; - /// Encode an `execute` XCM call of the XCM pallet. - fn encode_execute_xcm( - message: xcm::VersionedXcm, - ) -> anyhow::Result>; - - /// Estimate value of `max_weight` argument for the `execute` XCM call of the XCM pallet. - fn estimate_execute_xcm_weight() -> Weight { - // we are only executing XCM on our testnets and 1/100 of max extrinsic weight is ok - Self::max_extrinsic_weight() / 100 - } -} - -/// Encode message payload passed through CLI flags. -pub(crate) fn encode_message( - message: &Message, -) -> anyhow::Result { - Ok(match message { - Message::Raw { ref data } => data.0.clone(), - Message::Sized { ref size } => { - let destination = CustomNetworkId::try_from(Target::ID) - .map(|n| n.as_network_id()) - .map_err(|_| anyhow::format_err!("Unsupported target chain: {:?}", Target::ID))?; - let expected_size = match *size { - ExplicitOrMaximal::Explicit(size) => size, - ExplicitOrMaximal::Maximal => compute_maximal_message_size( - Source::max_extrinsic_size(), - Target::max_extrinsic_size(), - ), - } as usize; - - let at_target_xcm = vec![ExpectPallet { - index: 0, - name: vec![42; expected_size], - module_name: vec![], - crate_major: 0, - min_crate_minor: 0, - }] - .into(); - let at_target_xcm_size = - Source::encode_wire_message(destination, at_target_xcm)?.encoded_size(); - let at_target_xcm_overhead = at_target_xcm_size.saturating_sub(expected_size); - let at_target_xcm = vec![ExpectPallet { - index: 0, - name: vec![42; expected_size.saturating_sub(at_target_xcm_overhead)], - module_name: vec![], - crate_major: 0, - min_crate_minor: 0, - }] - .into(); - - xcm::VersionedXcm::<()>::V3( - vec![ExportMessage { - network: destination, - destination: destination.into(), - xcm: at_target_xcm, - }] - .into(), - ) - .encode() - }, - }) -} - -/// Compute maximal message size, given max extrinsic size at source and target chains. -pub(crate) fn compute_maximal_message_size( - maximal_source_extrinsic_size: u32, - maximal_target_extrinsic_size: u32, -) -> u32 { - // assume that both signed extensions and other arguments fit 1KB - let service_tx_bytes_on_source_chain = 1024; - let maximal_source_extrinsic_size = - maximal_source_extrinsic_size - service_tx_bytes_on_source_chain; - let maximal_message_size = - bridge_runtime_common::messages::target::maximal_incoming_message_size( - maximal_target_extrinsic_size, - ); - std::cmp::min(maximal_message_size, maximal_source_extrinsic_size) -} - -#[cfg(test)] -mod tests { - use super::*; - use crate::cli::send_message::decode_xcm; - use bp_runtime::Chain; - use relay_millau_client::Millau; - use relay_rialto_client::Rialto; - - fn approximate_message_size(xcm_msg_len: usize) -> usize { - xcm_msg_len + Source::dummy_universal_source().unwrap().encoded_size() - } - - #[test] - fn encode_explicit_size_message_works() { - let msg = encode_message::(&Message::Sized { - size: ExplicitOrMaximal::Explicit(100), - }) - .unwrap(); - // since it isn't the returned XCM what is sent over the wire, we can only check if - // it is close to what we need - assert!( - (1f64 - (approximate_message_size::(msg.len()) as f64) / 100_f64).abs() < 0.1 - ); - // check that it decodes to valid xcm - let _ = decode_xcm::<()>(msg).unwrap(); - } - - #[test] - fn encode_maximal_size_message_works() { - let maximal_size = compute_maximal_message_size( - Rialto::max_extrinsic_size(), - Millau::max_extrinsic_size(), - ); - - let msg = - encode_message::(&Message::Sized { size: ExplicitOrMaximal::Maximal }) - .unwrap(); - // since it isn't the returned XCM what is sent over the wire, we can only check if - // it is close to what we need - assert!( - (1f64 - approximate_message_size::(msg.len()) as f64 / maximal_size as f64) - .abs() < 0.1 - ); - // check that it decodes to valid xcm - let _ = decode_xcm::<()>(msg).unwrap(); - } -} diff --git a/relays/bin-substrate/src/cli/init_bridge.rs b/relays/bin-substrate/src/cli/init_bridge.rs index 415897aeba94c..21d95b4bfa0ea 100644 --- a/relays/bin-substrate/src/cli/init_bridge.rs +++ b/relays/bin-substrate/src/cli/init_bridge.rs @@ -27,11 +27,6 @@ use crate::{ polkadot_bulletin_headers_to_bridge_hub_polkadot::PolkadotBulletinToBridgeHubPolkadotCliBridge, polkadot_headers_to_polkadot_bulletin::PolkadotToPolkadotBulletinCliBridge, }, - rialto_millau::{ - millau_headers_to_rialto::MillauToRialtoCliBridge, - rialto_headers_to_millau::RialtoToMillauCliBridge, - }, - rialto_parachain_millau::millau_headers_to_rialto_parachain::MillauToRialtoParachainCliBridge, rococo_westend::{ rococo_headers_to_bridge_hub_westend::RococoToBridgeHubWestendCliBridge, westend_headers_to_bridge_hub_rococo::WestendToBridgeHubRococoCliBridge, @@ -40,7 +35,6 @@ use crate::{ rococo_headers_to_bridge_hub_wococo::RococoToBridgeHubWococoCliBridge, wococo_headers_to_bridge_hub_rococo::WococoToBridgeHubRococoCliBridge, }, - westend_millau::westend_headers_to_millau::WestendToMillauCliBridge, }, cli::{bridge::CliBridgeBase, chain_schema::*}, }; @@ -72,10 +66,6 @@ pub struct InitBridge { #[strum(serialize_all = "kebab_case")] /// Bridge to initialize. pub enum InitBridgeName { - MillauToRialto, - RialtoToMillau, - WestendToMillau, - MillauToRialtoParachain, RococoToBridgeHubWococo, WococoToBridgeHubRococo, KusamaToBridgeHubPolkadot, @@ -126,72 +116,6 @@ where } } -impl BridgeInitializer for MillauToRialtoCliBridge { - type Engine = GrandpaFinalityEngine; - - fn encode_init_bridge( - init_data: >::InitializationData, - ) -> ::Call { - rialto_runtime::SudoCall::sudo { - call: Box::new(rialto_runtime::BridgeGrandpaCall::initialize { init_data }.into()), - } - .into() - } -} - -impl BridgeInitializer for MillauToRialtoParachainCliBridge { - type Engine = GrandpaFinalityEngine; - - fn encode_init_bridge( - init_data: >::InitializationData, - ) -> ::Call { - type RuntimeCall = relay_rialto_parachain_client::RuntimeCall; - type BridgeGrandpaCall = relay_rialto_parachain_client::BridgeGrandpaCall; - type SudoCall = relay_rialto_parachain_client::SudoCall; - - let initialize_call = - RuntimeCall::BridgeMillauGrandpa(BridgeGrandpaCall::initialize { init_data }); - - RuntimeCall::Sudo(SudoCall::sudo { call: Box::new(initialize_call) }) - } -} - -impl BridgeInitializer for RialtoToMillauCliBridge { - type Engine = GrandpaFinalityEngine; - - fn encode_init_bridge( - init_data: >::InitializationData, - ) -> ::Call { - let initialize_call = millau_runtime::BridgeGrandpaCall::< - millau_runtime::Runtime, - millau_runtime::RialtoGrandpaInstance, - >::initialize { - init_data, - }; - millau_runtime::SudoCall::sudo { call: Box::new(initialize_call.into()) }.into() - } -} - -impl BridgeInitializer for WestendToMillauCliBridge { - type Engine = GrandpaFinalityEngine; - - fn encode_init_bridge( - init_data: >::InitializationData, - ) -> ::Call { - // at Westend -> Millau initialization we're not using sudo, because otherwise - // our deployments may fail, because we need to initialize both Rialto -> Millau - // and Westend -> Millau bridge. => since there's single possible sudo account, - // one of transaction may fail with duplicate nonce error - millau_runtime::BridgeGrandpaCall::< - millau_runtime::Runtime, - millau_runtime::WestendGrandpaInstance, - >::initialize { - init_data, - } - .into() - } -} - impl BridgeInitializer for RococoToBridgeHubWococoCliBridge { type Engine = GrandpaFinalityEngine; @@ -305,11 +229,6 @@ impl InitBridge { /// Run the command. pub async fn run(self) -> anyhow::Result<()> { match self.bridge { - InitBridgeName::MillauToRialto => MillauToRialtoCliBridge::init_bridge(self), - InitBridgeName::RialtoToMillau => RialtoToMillauCliBridge::init_bridge(self), - InitBridgeName::WestendToMillau => WestendToMillauCliBridge::init_bridge(self), - InitBridgeName::MillauToRialtoParachain => - MillauToRialtoParachainCliBridge::init_bridge(self), InitBridgeName::RococoToBridgeHubWococo => RococoToBridgeHubWococoCliBridge::init_bridge(self), InitBridgeName::WococoToBridgeHubRococo => diff --git a/relays/bin-substrate/src/cli/mod.rs b/relays/bin-substrate/src/cli/mod.rs index 890fd9efb34ed..580463ef9f9ed 100644 --- a/relays/bin-substrate/src/cli/mod.rs +++ b/relays/bin-substrate/src/cli/mod.rs @@ -16,8 +16,6 @@ //! Deal with CLI args of substrate-to-substrate relay. -use std::convert::TryInto; - use async_std::prelude::*; use codec::{Decode, Encode}; use futures::{select, FutureExt}; @@ -31,18 +29,14 @@ use bp_messages::LaneId; use relay_substrate_client::SimpleRuntimeVersion; pub(crate) mod bridge; -pub(crate) mod encode_message; -pub(crate) mod send_message; mod chain_schema; mod detect_equivocations; mod init_bridge; -mod register_parachain; mod relay_headers; mod relay_headers_and_messages; mod relay_messages; mod relay_parachains; -mod resubmit_transactions; /// The target that will be used when publishing logs related to this pallet. pub const LOG_TARGET: &str = "bridge"; @@ -77,16 +71,6 @@ pub enum Command { /// /// Sends initialization transaction to bootstrap the bridge with current finalized block data. InitBridge(init_bridge::InitBridge), - /// Send custom message over the bridge. - /// - /// Allows interacting with the bridge by sending messages over `Messages` component. - /// The message is being sent to the source chain, delivered to the target chain and dispatched - /// there. - SendMessage(send_message::SendMessage), - /// Resubmit transactions with increased tip if they are stalled. - ResubmitTransactions(resubmit_transactions::ResubmitTransactions), - /// Register parachain. - RegisterParachain(register_parachain::RegisterParachain), /// Relay parachain heads. RelayParachains(relay_parachains::RelayParachains), /// Detect and report equivocations. @@ -121,9 +105,6 @@ impl Command { Self::RelayMessages(arg) => arg.run().await?, Self::RelayHeadersAndMessages(arg) => arg.run().await?, Self::InitBridge(arg) => arg.run().await?, - Self::SendMessage(arg) => arg.run().await?, - Self::ResubmitTransactions(arg) => arg.run().await?, - Self::RegisterParachain(arg) => arg.run().await?, Self::RelayParachains(arg) => arg.run().await?, Self::DetectEquivocations(arg) => arg.run().await?, } @@ -169,33 +150,7 @@ arg_enum! { } } -/// Generic balance type. -#[derive(Debug, Clone, Copy, PartialEq, Eq)] -pub struct Balance(pub u128); - -impl std::fmt::Display for Balance { - fn fmt(&self, fmt: &mut std::fmt::Formatter) -> std::fmt::Result { - use num_format::{Locale, ToFormattedString}; - write!(fmt, "{}", self.0.to_formatted_string(&Locale::en)) - } -} - -impl std::str::FromStr for Balance { - type Err = ::Err; - - fn from_str(s: &str) -> Result { - Ok(Self(s.parse()?)) - } -} - -impl Balance { - /// Cast balance to `u64` type, panicking if it's too large. - pub fn cast(&self) -> u64 { - self.0.try_into().expect("Balance is too high for this chain.") - } -} - -// Bridge-supported network definition. +/// Bridge-supported network definition. /// /// Used to abstract away CLI commands. pub trait CliChain: relay_substrate_client::Chain { diff --git a/relays/bin-substrate/src/cli/register_parachain.rs b/relays/bin-substrate/src/cli/register_parachain.rs deleted file mode 100644 index 90464335166e8..0000000000000 --- a/relays/bin-substrate/src/cli/register_parachain.rs +++ /dev/null @@ -1,324 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use crate::cli::{chain_schema::*, Balance}; - -use codec::Encode; -use frame_support::Twox64Concat; -use num_traits::Zero; -use polkadot_parachain_primitives::primitives::{ - HeadData as ParaHeadData, Id as ParaId, ValidationCode as ParaValidationCode, -}; -use polkadot_runtime_common::{ - paras_registrar::Call as ParaRegistrarCall, slots::Call as ParaSlotsCall, -}; -use polkadot_runtime_parachains::paras::ParaLifecycle; -use relay_substrate_client::{AccountIdOf, CallOf, Chain, Client, UnsignedTransaction}; -use relay_utils::{TrackedTransactionStatus, TransactionTracker}; -use rialto_runtime::SudoCall; -use sp_core::{ - storage::{well_known_keys::CODE, StorageKey}, - Pair, -}; -use structopt::StructOpt; -use strum::{EnumString, EnumVariantNames, VariantNames}; - -/// Name of the `NextFreeParaId` value in the `polkadot_runtime_common::paras_registrar` pallet. -const NEXT_FREE_PARA_ID_STORAGE_NAME: &str = "NextFreeParaId"; -/// Name of the `ParaLifecycles` map in the `polkadot_runtime_parachains::paras` pallet. -const PARAS_LIFECYCLES_STORAGE_NAME: &str = "ParaLifecycles"; - -/// Register parachain. -#[derive(StructOpt, Debug, PartialEq, Eq)] -pub struct RegisterParachain { - /// A parachain to register. - #[structopt(possible_values = Parachain::VARIANTS, case_insensitive = true)] - parachain: Parachain, - /// Parachain deposit. - #[structopt(long, default_value = "0")] - deposit: Balance, - /// Lease begin. - #[structopt(long, default_value = "0")] - lease_begin: u32, - /// Lease end. - #[structopt(long, default_value = "256")] - lease_end: u32, - #[structopt(flatten)] - relay_connection: RelaychainConnectionParams, - #[structopt(flatten)] - relay_sign: RelaychainSigningParams, - #[structopt(flatten)] - para_connection: ParachainConnectionParams, -} - -/// Parachain to register. -#[derive(Debug, EnumString, EnumVariantNames, PartialEq, Eq)] -#[strum(serialize_all = "kebab_case")] -pub enum Parachain { - RialtoParachain, -} - -macro_rules! select_bridge { - ($bridge: expr, $generic: tt) => { - match $bridge { - Parachain::RialtoParachain => { - type Relaychain = relay_rialto_client::Rialto; - type Parachain = relay_rialto_parachain_client::RialtoParachain; - - use bp_rialto::{PARAS_PALLET_NAME, PARAS_REGISTRAR_PALLET_NAME}; - - $generic - }, - } - }; -} - -impl RegisterParachain { - /// Run the command. - pub async fn run(self) -> anyhow::Result<()> { - select_bridge!(self.parachain, { - let relay_client = self.relay_connection.into_client::().await?; - let relay_sign = self.relay_sign.to_keypair::()?; - let para_client = self.para_connection.into_client::().await?; - - // hopefully we're the only actor that is registering parachain right now - // => read next parachain id - let para_id_key = bp_runtime::storage_value_final_key( - PARAS_REGISTRAR_PALLET_NAME.as_bytes(), - NEXT_FREE_PARA_ID_STORAGE_NAME.as_bytes(), - ); - let para_id: ParaId = relay_client - .storage_value(StorageKey(para_id_key.to_vec()), None) - .await? - .unwrap_or(polkadot_primitives::v6::LOWEST_PUBLIC_ID) - .max(polkadot_primitives::v6::LOWEST_PUBLIC_ID); - log::info!(target: "bridge", "Going to reserve parachain id: {:?}", para_id); - - // step 1: reserve a parachain id - let relay_sudo_account: AccountIdOf = relay_sign.public().into(); - let reserve_parachain_id_call: CallOf = - ParaRegistrarCall::reserve {}.into(); - let reserve_result = relay_client - .submit_and_watch_signed_extrinsic(&relay_sign, move |_, transaction_nonce| { - Ok(UnsignedTransaction::new( - reserve_parachain_id_call.into(), - transaction_nonce, - )) - }) - .await? - .wait() - .await; - if reserve_result == TrackedTransactionStatus::Lost { - return Err(anyhow::format_err!( - "Failed to finalize `reserve-parachain-id` transaction" - )) - } - log::info!(target: "bridge", "Reserved parachain id: {:?}", para_id); - - // step 2: register parathread - let para_genesis_header = para_client.header_by_number(Zero::zero()).await?; - let para_code = para_client - .raw_storage_value(StorageKey(CODE.to_vec()), Some(para_genesis_header.hash())) - .await? - .ok_or_else(|| { - anyhow::format_err!("Cannot fetch validation code of {}", Parachain::NAME) - })? - .0; - log::info!( - target: "bridge", - "Going to register parachain {:?}: genesis len = {} code len = {}", - para_id, - para_genesis_header.encode().len(), - para_code.len(), - ); - let register_parathread_call: CallOf = ParaRegistrarCall::register { - id: para_id, - genesis_head: ParaHeadData(para_genesis_header.encode()), - validation_code: ParaValidationCode(para_code), - } - .into(); - let register_result = relay_client - .submit_and_watch_signed_extrinsic(&relay_sign, move |_, transaction_nonce| { - Ok(UnsignedTransaction::new(register_parathread_call.into(), transaction_nonce)) - }) - .await? - .wait() - .await; - if register_result == TrackedTransactionStatus::Lost { - return Err(anyhow::format_err!( - "Failed to finalize `register-parathread` transaction" - )) - } - log::info!(target: "bridge", "Registered parachain: {:?}. Waiting for onboarding", para_id); - - // wait until parathread is onboarded - let para_state_key = bp_runtime::storage_map_final_key::( - PARAS_PALLET_NAME, - PARAS_LIFECYCLES_STORAGE_NAME, - ¶_id.encode(), - ); - wait_para_state( - &relay_client, - ¶_state_key.0, - &[ParaLifecycle::Onboarding, ParaLifecycle::Parathread], - ParaLifecycle::Parathread, - ) - .await?; - - // step 3: force parachain leases - let lease_begin = self.lease_begin; - let lease_end = self.lease_end; - let para_deposit = self.deposit.cast().into(); - log::info!( - target: "bridge", - "Going to force leases of parachain {:?}: [{}; {}]", - para_id, - lease_begin, - lease_end, - ); - let force_lease_call: CallOf = SudoCall::sudo { - call: Box::new( - ParaSlotsCall::force_lease { - para: para_id, - leaser: relay_sudo_account.clone(), - amount: para_deposit, - period_begin: lease_begin, - period_count: lease_end.saturating_sub(lease_begin).saturating_add(1), - } - .into(), - ), - } - .into(); - relay_client - .submit_signed_extrinsic(&relay_sign, move |_, transaction_nonce| { - Ok(UnsignedTransaction::new(force_lease_call.into(), transaction_nonce)) - }) - .await?; - log::info!(target: "bridge", "Registered parachain leases: {:?}. Waiting for onboarding", para_id); - - // wait until parachain is onboarded - wait_para_state( - &relay_client, - ¶_state_key.0, - &[ - ParaLifecycle::Onboarding, - ParaLifecycle::UpgradingParathread, - ParaLifecycle::Parathread, - ], - ParaLifecycle::Parachain, - ) - .await?; - - Ok(()) - }) - } -} - -/// Wait until parachain state is changed. -async fn wait_para_state( - relay_client: &Client, - para_state_key: &[u8], - from_states: &[ParaLifecycle], - to_state: ParaLifecycle, -) -> anyhow::Result<()> { - loop { - let para_state: ParaLifecycle = relay_client - .storage_value(StorageKey(para_state_key.to_vec()), None) - .await? - .ok_or_else(|| { - anyhow::format_err!( - "Cannot fetch next free parachain lifecycle from the runtime storage of {}", - Relaychain::NAME, - ) - })?; - if para_state == to_state { - log::info!(target: "bridge", "Parachain state is now: {:?}", to_state); - return Ok(()) - } - if !from_states.contains(¶_state) { - return Err(anyhow::format_err!("Invalid parachain lifecycle: {:?}", para_state)) - } - - log::info!(target: "bridge", "Parachain state: {:?}. Waiting for {:?}", para_state, to_state); - async_std::task::sleep(Relaychain::AVERAGE_BLOCK_INTERVAL).await; - } -} - -#[cfg(test)] -mod tests { - use super::*; - - #[test] - fn register_rialto_parachain() { - let register_parachain = RegisterParachain::from_iter(vec![ - "register-parachain", - "rialto-parachain", - "--parachain-host", - "127.0.0.1", - "--parachain-port", - "11949", - "--relaychain-host", - "127.0.0.1", - "--relaychain-port", - "9944", - "--relaychain-signer", - "//Alice", - "--deposit", - "42", - "--lease-begin", - "100", - "--lease-end", - "200", - ]); - - assert_eq!( - register_parachain, - RegisterParachain { - parachain: Parachain::RialtoParachain, - deposit: Balance(42), - lease_begin: 100, - lease_end: 200, - relay_connection: RelaychainConnectionParams { - relaychain_host: "127.0.0.1".into(), - relaychain_port: 9944, - relaychain_secure: false, - relaychain_runtime_version: RelaychainRuntimeVersionParams { - relaychain_version_mode: RuntimeVersionType::Bundle, - relaychain_spec_version: None, - relaychain_transaction_version: None, - } - }, - relay_sign: RelaychainSigningParams { - relaychain_signer: Some("//Alice".into()), - relaychain_signer_password: None, - relaychain_signer_file: None, - relaychain_signer_password_file: None, - relaychain_transactions_mortality: None, - }, - para_connection: ParachainConnectionParams { - parachain_host: "127.0.0.1".into(), - parachain_port: 11949, - parachain_secure: false, - parachain_runtime_version: ParachainRuntimeVersionParams { - parachain_version_mode: RuntimeVersionType::Bundle, - parachain_spec_version: None, - parachain_transaction_version: None, - } - }, - } - ); - } -} diff --git a/relays/bin-substrate/src/cli/relay_headers.rs b/relays/bin-substrate/src/cli/relay_headers.rs index d3a7fa09367df..95d93387a0728 100644 --- a/relays/bin-substrate/src/cli/relay_headers.rs +++ b/relays/bin-substrate/src/cli/relay_headers.rs @@ -27,16 +27,10 @@ use crate::bridges::{ polkadot_bulletin_headers_to_bridge_hub_polkadot::PolkadotBulletinToBridgeHubPolkadotCliBridge, polkadot_headers_to_polkadot_bulletin::PolkadotToPolkadotBulletinCliBridge, }, - rialto_millau::{ - millau_headers_to_rialto::MillauToRialtoCliBridge, - rialto_headers_to_millau::RialtoToMillauCliBridge, - }, - rialto_parachain_millau::millau_headers_to_rialto_parachain::MillauToRialtoParachainCliBridge, rococo_wococo::{ rococo_headers_to_bridge_hub_wococo::RococoToBridgeHubWococoCliBridge, wococo_headers_to_bridge_hub_rococo::WococoToBridgeHubRococoCliBridge, }, - westend_millau::westend_headers_to_millau::WestendToMillauCliBridge, }; use relay_utils::metrics::{GlobalMetrics, StandaloneMetric}; use substrate_relay_helper::finality::SubstrateFinalitySyncPipeline; @@ -67,10 +61,6 @@ pub struct RelayHeaders { #[strum(serialize_all = "kebab_case")] /// Headers relay bridge. pub enum RelayHeadersBridge { - MillauToRialto, - RialtoToMillau, - WestendToMillau, - MillauToRialtoParachain, RococoToBridgeHubWococo, WococoToBridgeHubRococo, KusamaToBridgeHubPolkadot, @@ -110,10 +100,6 @@ trait HeadersRelayer: RelayToRelayHeadersCliBridge { } } -impl HeadersRelayer for MillauToRialtoCliBridge {} -impl HeadersRelayer for RialtoToMillauCliBridge {} -impl HeadersRelayer for WestendToMillauCliBridge {} -impl HeadersRelayer for MillauToRialtoParachainCliBridge {} impl HeadersRelayer for RococoToBridgeHubWococoCliBridge {} impl HeadersRelayer for WococoToBridgeHubRococoCliBridge {} impl HeadersRelayer for KusamaToBridgeHubPolkadotCliBridge {} @@ -125,11 +111,6 @@ impl RelayHeaders { /// Run the command. pub async fn run(self) -> anyhow::Result<()> { match self.bridge { - RelayHeadersBridge::MillauToRialto => MillauToRialtoCliBridge::relay_headers(self), - RelayHeadersBridge::RialtoToMillau => RialtoToMillauCliBridge::relay_headers(self), - RelayHeadersBridge::WestendToMillau => WestendToMillauCliBridge::relay_headers(self), - RelayHeadersBridge::MillauToRialtoParachain => - MillauToRialtoParachainCliBridge::relay_headers(self), RelayHeadersBridge::RococoToBridgeHubWococo => RococoToBridgeHubWococoCliBridge::relay_headers(self), RelayHeadersBridge::WococoToBridgeHubRococo => diff --git a/relays/bin-substrate/src/cli/relay_headers_and_messages/mod.rs b/relays/bin-substrate/src/cli/relay_headers_and_messages/mod.rs index 5a8c084889d75..7075e742e02d8 100644 --- a/relays/bin-substrate/src/cli/relay_headers_and_messages/mod.rs +++ b/relays/bin-substrate/src/cli/relay_headers_and_messages/mod.rs @@ -36,7 +36,6 @@ use structopt::StructOpt; use futures::{FutureExt, TryFutureExt}; use relay_to_parachain::*; -use relay_to_relay::*; use crate::{ bridges::{ @@ -48,14 +47,6 @@ use crate::{ polkadot_bulletin_headers_to_bridge_hub_polkadot::PolkadotBulletinToBridgeHubPolkadotCliBridge, polkadot_parachains_to_polkadot_bulletin::PolkadotToPolkadotBulletinCliBridge, }, - rialto_millau::{ - millau_headers_to_rialto::MillauToRialtoCliBridge, - rialto_headers_to_millau::RialtoToMillauCliBridge, - }, - rialto_parachain_millau::{ - millau_headers_to_rialto_parachain::MillauToRialtoParachainCliBridge, - rialto_parachains_to_millau::RialtoParachainToMillauCliBridge, - }, rococo_westend::{ rococo_parachains_to_bridge_hub_westend::BridgeHubRococoToBridgeHubWestendCliBridge, westend_parachains_to_bridge_hub_rococo::BridgeHubWestendToBridgeHubRococoCliBridge, @@ -203,9 +194,6 @@ where } // All supported chains. -declare_chain_cli_schema!(Millau, millau); -declare_chain_cli_schema!(Rialto, rialto); -declare_chain_cli_schema!(RialtoParachain, rialto_parachain); declare_chain_cli_schema!(Rococo, rococo); declare_chain_cli_schema!(BridgeHubRococo, bridge_hub_rococo); declare_chain_cli_schema!(Wococo, wococo); @@ -217,53 +205,7 @@ declare_chain_cli_schema!(BridgeHubKusama, bridge_hub_kusama); declare_chain_cli_schema!(Polkadot, polkadot); declare_chain_cli_schema!(BridgeHubPolkadot, bridge_hub_polkadot); declare_chain_cli_schema!(PolkadotBulletin, polkadot_bulletin); -// Means to override signers of different layer transactions. -declare_chain_cli_schema!(MillauHeadersToRialto, millau_headers_to_rialto); -declare_chain_cli_schema!(MillauHeadersToRialtoParachain, millau_headers_to_rialto_parachain); -declare_chain_cli_schema!(RialtoHeadersToMillau, rialto_headers_to_millau); -declare_chain_cli_schema!(RialtoParachainsToMillau, rialto_parachains_to_millau); -declare_chain_cli_schema!(RococoHeadersToBridgeHubWococo, rococo_headers_to_bridge_hub_wococo); -declare_chain_cli_schema!( - RococoParachainsToBridgeHubWococo, - rococo_parachains_to_bridge_hub_wococo -); -declare_chain_cli_schema!(WococoHeadersToBridgeHubRococo, wococo_headers_to_bridge_hub_rococo); -declare_chain_cli_schema!( - WococoParachainsToBridgeHubRococo, - wococo_parachains_to_bridge_hub_rococo -); -declare_chain_cli_schema!(RococoHeadersToBridgeHubWestend, rococo_headers_to_bridge_hub_westend); -declare_chain_cli_schema!( - RococoParachainsToBridgeHubWestend, - rococo_parachains_to_bridge_hub_westend -); -declare_chain_cli_schema!(WestendHeadersToBridgeHubRococo, westend_headers_to_bridge_hub_rococo); -declare_chain_cli_schema!( - WestendParachainsToBridgeHubRococo, - westend_parachains_to_bridge_hub_rococo -); -declare_chain_cli_schema!(KusamaHeadersToBridgeHubPolkadot, kusama_headers_to_bridge_hub_polkadot); -declare_chain_cli_schema!( - KusamaParachainsToBridgeHubPolkadot, - kusama_parachains_to_bridge_hub_polkadot -); -declare_chain_cli_schema!(PolkadotHeadersToBridgeHubKusama, polkadot_headers_to_bridge_hub_kusama); -declare_chain_cli_schema!( - PolkadotParachainsToBridgeHubKusama, - polkadot_parachains_to_bridge_hub_kusama -); -declare_chain_cli_schema!( - PolkadotBulletinHeadersToBridgeHubPolkadot, - polkadot_bulletin_headers_to_bridge_hub_polkadot -); -declare_chain_cli_schema!(PolkadotHeadersToPolkadotBulletin, polkadot_headers_to_polkadot_bulletin); -declare_chain_cli_schema!( - PolkadotParachainsToPolkadotBulletin, - polkadot_parachains_to_polkadot_bulletin -); // All supported bridges. -declare_relay_to_relay_bridge_schema!(Millau, Rialto); -declare_relay_to_parachain_bridge_schema!(Millau, RialtoParachain, Rialto); declare_parachain_to_parachain_bridge_schema!(BridgeHubRococo, Rococo, BridgeHubWococo, Wococo); declare_parachain_to_parachain_bridge_schema!(BridgeHubRococo, Rococo, BridgeHubWestend, Westend); declare_parachain_to_parachain_bridge_schema!(BridgeHubKusama, Kusama, BridgeHubPolkadot, Polkadot); @@ -434,58 +376,6 @@ where } } -/// Millau <> Rialto complex relay. -pub struct MillauRialtoFull2WayBridge { - base: ::Base, -} - -#[async_trait] -impl Full2WayBridge for MillauRialtoFull2WayBridge { - type Base = RelayToRelayBridge; - type Left = relay_millau_client::Millau; - type Right = relay_rialto_client::Rialto; - type L2R = MillauToRialtoCliBridge; - type R2L = RialtoToMillauCliBridge; - - fn new(base: Self::Base) -> anyhow::Result { - Ok(Self { base }) - } - - fn base(&self) -> &Self::Base { - &self.base - } - - fn mut_base(&mut self) -> &mut Self::Base { - &mut self.base - } -} - -/// Millau <> RialtoParachain complex relay. -pub struct MillauRialtoParachainFull2WayBridge { - base: ::Base, -} - -#[async_trait] -impl Full2WayBridge for MillauRialtoParachainFull2WayBridge { - type Base = RelayToParachainBridge; - type Left = relay_millau_client::Millau; - type Right = relay_rialto_parachain_client::RialtoParachain; - type L2R = MillauToRialtoParachainCliBridge; - type R2L = RialtoParachainToMillauCliBridge; - - fn new(base: Self::Base) -> anyhow::Result { - Ok(Self { base }) - } - - fn base(&self) -> &Self::Base { - &self.base - } - - fn mut_base(&mut self) -> &mut Self::Base { - &mut self.base - } -} - /// BridgeHubRococo <> BridgeHubWococo complex relay. pub struct BridgeHubRococoBridgeHubWococoFull2WayBridge { base: ::Base, @@ -593,10 +483,6 @@ impl Full2WayBridge for PolkadotBulletinBridgeHubPolkadotFull2WayBridge { /// Complex headers+messages relay. #[derive(Debug, PartialEq, StructOpt)] pub enum RelayHeadersAndMessages { - /// Millau <> Rialto relay. - MillauRialto(MillauRialtoHeadersAndMessages), - /// Millau <> RialtoParachain relay. - MillauRialtoParachain(MillauRialtoParachainHeadersAndMessages), /// BridgeHubRococo <> BridgeHubWococo relay. BridgeHubRococoBridgeHubWococo(BridgeHubRococoBridgeHubWococoHeadersAndMessages), /// BridgeHubKusama <> BridgeHubPolkadot relay. @@ -611,12 +497,6 @@ impl RelayHeadersAndMessages { /// Run the command. pub async fn run(self) -> anyhow::Result<()> { match self { - RelayHeadersAndMessages::MillauRialto(params) => - MillauRialtoFull2WayBridge::new(params.into_bridge().await?)?.run().await, - RelayHeadersAndMessages::MillauRialtoParachain(params) => - MillauRialtoParachainFull2WayBridge::new(params.into_bridge().await?)? - .run() - .await, RelayHeadersAndMessages::BridgeHubRococoBridgeHubWococo(params) => BridgeHubRococoBridgeHubWococoFull2WayBridge::new(params.into_bridge().await?)? .run() @@ -642,130 +522,34 @@ mod tests { use super::*; #[test] - fn should_parse_relay_to_relay_options() { - // when - let res = RelayHeadersAndMessages::from_iter(vec![ - "relay-headers-and-messages", - "millau-rialto", - "--millau-host", - "millau-node-alice", - "--millau-port", - "9944", - "--millau-signer", - "//Charlie", - "--millau-transactions-mortality", - "64", - "--rialto-host", - "rialto-node-alice", - "--rialto-port", - "9944", - "--rialto-signer", - "//Charlie", - "--rialto-transactions-mortality", - "64", - "--lane", - "00000000", - "--lane", - "73776170", - "--prometheus-host", - "0.0.0.0", - ]); - - // then - assert_eq!( - res, - RelayHeadersAndMessages::MillauRialto(MillauRialtoHeadersAndMessages { - shared: HeadersAndMessagesSharedParams { - lane: vec![ - HexLaneId([0x00, 0x00, 0x00, 0x00]), - HexLaneId([0x73, 0x77, 0x61, 0x70]) - ], - only_mandatory_headers: false, - prometheus_params: PrometheusParams { - no_prometheus: false, - prometheus_host: "0.0.0.0".into(), - prometheus_port: 9616, - }, - }, - left: MillauConnectionParams { - millau_host: "millau-node-alice".into(), - millau_port: 9944, - millau_secure: false, - millau_runtime_version: MillauRuntimeVersionParams { - millau_version_mode: RuntimeVersionType::Bundle, - millau_spec_version: None, - millau_transaction_version: None, - }, - }, - left_sign: MillauSigningParams { - millau_signer: Some("//Charlie".into()), - millau_signer_password: None, - millau_signer_file: None, - millau_signer_password_file: None, - millau_transactions_mortality: Some(64), - }, - left_headers_to_right_sign_override: MillauHeadersToRialtoSigningParams { - millau_headers_to_rialto_signer: None, - millau_headers_to_rialto_signer_password: None, - millau_headers_to_rialto_signer_file: None, - millau_headers_to_rialto_signer_password_file: None, - millau_headers_to_rialto_transactions_mortality: None, - }, - right: RialtoConnectionParams { - rialto_host: "rialto-node-alice".into(), - rialto_port: 9944, - rialto_secure: false, - rialto_runtime_version: RialtoRuntimeVersionParams { - rialto_version_mode: RuntimeVersionType::Bundle, - rialto_spec_version: None, - rialto_transaction_version: None, - }, - }, - right_sign: RialtoSigningParams { - rialto_signer: Some("//Charlie".into()), - rialto_signer_password: None, - rialto_signer_file: None, - rialto_signer_password_file: None, - rialto_transactions_mortality: Some(64), - }, - right_headers_to_left_sign_override: RialtoHeadersToMillauSigningParams { - rialto_headers_to_millau_signer: None, - rialto_headers_to_millau_signer_password: None, - rialto_headers_to_millau_signer_file: None, - rialto_headers_to_millau_signer_password_file: None, - rialto_headers_to_millau_transactions_mortality: None, - }, - }), - ); - } - - #[test] - fn should_parse_relay_to_parachain_options() { + fn should_parse_parachain_to_parachain_options() { // when let res = RelayHeadersAndMessages::from_iter(vec![ "relay-headers-and-messages", - "millau-rialto-parachain", - "--millau-host", - "millau-node-alice", - "--millau-port", + "bridge-hub-kusama-bridge-hub-polkadot", + "--bridge-hub-kusama-host", + "bridge-hub-kusama-node-collator1", + "--bridge-hub-kusama-port", "9944", - "--millau-signer", + "--bridge-hub-kusama-signer", "//Iden", - "--rialto-headers-to-millau-signer", - "//Ken", - "--millau-transactions-mortality", + "--bridge-hub-kusama-transactions-mortality", "64", - "--rialto-parachain-host", - "rialto-parachain-collator-charlie", - "--rialto-parachain-port", + "--kusama-host", + "kusama-alice", + "--kusama-port", + "9944", + "--bridge-hub-polkadot-host", + "bridge-hub-polkadot-collator1", + "--bridge-hub-polkadot-port", "9944", - "--rialto-parachain-signer", + "--bridge-hub-polkadot-signer", "//George", - "--rialto-parachain-transactions-mortality", + "--bridge-hub-polkadot-transactions-mortality", "64", - "--rialto-host", - "rialto-node-alice", - "--rialto-port", + "--polkadot-host", + "polkadot-alice", + "--polkadot-port", "9944", "--lane", "00000000", @@ -776,8 +560,8 @@ mod tests { // then assert_eq!( res, - RelayHeadersAndMessages::MillauRialtoParachain( - MillauRialtoParachainHeadersAndMessages { + RelayHeadersAndMessages::BridgeHubKusamaBridgeHubPolkadot( + BridgeHubKusamaBridgeHubPolkadotHeadersAndMessages { shared: HeadersAndMessagesSharedParams { lane: vec![HexLaneId([0x00, 0x00, 0x00, 0x00])], only_mandatory_headers: false, @@ -787,70 +571,59 @@ mod tests { prometheus_port: 9616, }, }, - left: MillauConnectionParams { - millau_host: "millau-node-alice".into(), - millau_port: 9944, - millau_secure: false, - millau_runtime_version: MillauRuntimeVersionParams { - millau_version_mode: RuntimeVersionType::Bundle, - millau_spec_version: None, - millau_transaction_version: None, + left_relay: KusamaConnectionParams { + kusama_host: "kusama-alice".into(), + kusama_port: 9944, + kusama_secure: false, + kusama_runtime_version: KusamaRuntimeVersionParams { + kusama_version_mode: RuntimeVersionType::Bundle, + kusama_spec_version: None, + kusama_transaction_version: None, }, }, - left_sign: MillauSigningParams { - millau_signer: Some("//Iden".into()), - millau_signer_password: None, - millau_signer_file: None, - millau_signer_password_file: None, - millau_transactions_mortality: Some(64), - }, - left_headers_to_right_sign_override: - MillauHeadersToRialtoParachainSigningParams { - millau_headers_to_rialto_parachain_signer: None, - millau_headers_to_rialto_parachain_signer_password: None, - millau_headers_to_rialto_parachain_signer_file: None, - millau_headers_to_rialto_parachain_signer_password_file: None, - millau_headers_to_rialto_parachain_transactions_mortality: None, - }, - right: RialtoParachainConnectionParams { - rialto_parachain_host: "rialto-parachain-collator-charlie".into(), - rialto_parachain_port: 9944, - rialto_parachain_secure: false, - rialto_parachain_runtime_version: RialtoParachainRuntimeVersionParams { - rialto_parachain_version_mode: RuntimeVersionType::Bundle, - rialto_parachain_spec_version: None, - rialto_parachain_transaction_version: None, + left: BridgeHubKusamaConnectionParams { + bridge_hub_kusama_host: "bridge-hub-kusama-node-collator1".into(), + bridge_hub_kusama_port: 9944, + bridge_hub_kusama_secure: false, + bridge_hub_kusama_runtime_version: BridgeHubKusamaRuntimeVersionParams { + bridge_hub_kusama_version_mode: RuntimeVersionType::Bundle, + bridge_hub_kusama_spec_version: None, + bridge_hub_kusama_transaction_version: None, }, }, - right_sign: RialtoParachainSigningParams { - rialto_parachain_signer: Some("//George".into()), - rialto_parachain_signer_password: None, - rialto_parachain_signer_file: None, - rialto_parachain_signer_password_file: None, - rialto_parachain_transactions_mortality: Some(64), + left_sign: BridgeHubKusamaSigningParams { + bridge_hub_kusama_signer: Some("//Iden".into()), + bridge_hub_kusama_signer_password: None, + bridge_hub_kusama_signer_file: None, + bridge_hub_kusama_signer_password_file: None, + bridge_hub_kusama_transactions_mortality: Some(64), }, - right_relay_headers_to_left_sign_override: RialtoHeadersToMillauSigningParams { - rialto_headers_to_millau_signer: Some("//Ken".into()), - rialto_headers_to_millau_signer_password: None, - rialto_headers_to_millau_signer_file: None, - rialto_headers_to_millau_signer_password_file: None, - rialto_headers_to_millau_transactions_mortality: None, + right: BridgeHubPolkadotConnectionParams { + bridge_hub_polkadot_host: "bridge-hub-polkadot-collator1".into(), + bridge_hub_polkadot_port: 9944, + bridge_hub_polkadot_secure: false, + bridge_hub_polkadot_runtime_version: + BridgeHubPolkadotRuntimeVersionParams { + bridge_hub_polkadot_version_mode: RuntimeVersionType::Bundle, + bridge_hub_polkadot_spec_version: None, + bridge_hub_polkadot_transaction_version: None, + }, }, - right_parachains_to_left_sign_override: RialtoParachainsToMillauSigningParams { - rialto_parachains_to_millau_signer: None, - rialto_parachains_to_millau_signer_password: None, - rialto_parachains_to_millau_signer_file: None, - rialto_parachains_to_millau_signer_password_file: None, - rialto_parachains_to_millau_transactions_mortality: None, + right_sign: BridgeHubPolkadotSigningParams { + bridge_hub_polkadot_signer: Some("//George".into()), + bridge_hub_polkadot_signer_password: None, + bridge_hub_polkadot_signer_file: None, + bridge_hub_polkadot_signer_password_file: None, + bridge_hub_polkadot_transactions_mortality: Some(64), }, - right_relay: RialtoConnectionParams { - rialto_host: "rialto-node-alice".into(), - rialto_port: 9944, - rialto_secure: false, - rialto_runtime_version: RialtoRuntimeVersionParams { - rialto_version_mode: RuntimeVersionType::Bundle, - rialto_spec_version: None, - rialto_transaction_version: None, + right_relay: PolkadotConnectionParams { + polkadot_host: "polkadot-alice".into(), + polkadot_port: 9944, + polkadot_secure: false, + polkadot_runtime_version: PolkadotRuntimeVersionParams { + polkadot_version_mode: RuntimeVersionType::Bundle, + polkadot_spec_version: None, + polkadot_transaction_version: None, }, }, } diff --git a/relays/bin-substrate/src/cli/relay_headers_and_messages/parachain_to_parachain.rs b/relays/bin-substrate/src/cli/relay_headers_and_messages/parachain_to_parachain.rs index 1610f648bdcdd..32ba6b3ddadce 100644 --- a/relays/bin-substrate/src/cli/relay_headers_and_messages/parachain_to_parachain.rs +++ b/relays/bin-substrate/src/cli/relay_headers_and_messages/parachain_to_parachain.rs @@ -33,7 +33,6 @@ use substrate_relay_helper::{ on_demand::{ headers::OnDemandHeadersRelay, parachains::OnDemandParachainsRelay, OnDemandRelay, }, - TaggedAccount, TransactionParams, }; /// A base relay between two parachain from different consensus systems. @@ -54,20 +53,6 @@ pub struct ParachainToParachainBridge< pub left_relay: Client<::SourceRelay>, /// Client of the right relay chain. pub right_relay: Client<::SourceRelay>, - - /// Override for right_relay->left headers signer. - pub right_headers_to_left_transaction_params: - TransactionParams::Target>>, - /// Override for right->left parachains signer. - pub right_parachains_to_left_transaction_params: - TransactionParams::Target>>, - - /// Override for left_relay->right headers signer. - pub left_headers_to_right_transaction_params: - TransactionParams::Target>>, - /// Override for left->right parachains signer. - pub left_parachains_to_right_transaction_params: - TransactionParams::Target>>, } macro_rules! declare_parachain_to_parachain_bridge_schema { @@ -86,12 +71,6 @@ macro_rules! declare_parachain_to_parachain_bridge_schema { // default signer, which is always used to sign messages relay transactions on the left chain #[structopt(flatten)] left_sign: [<$left_parachain SigningParams>], - // override for right_relay->left-parachain headers signer - #[structopt(flatten)] - right_relay_headers_to_left_sign_override: [<$right_chain HeadersTo $left_parachain SigningParams>], - // override for right->left parachains signer - #[structopt(flatten)] - right_parachains_to_left_sign_override: [<$right_chain ParachainsTo $left_parachain SigningParams>], #[structopt(flatten)] left_relay: [<$left_chain ConnectionParams>], @@ -101,12 +80,6 @@ macro_rules! declare_parachain_to_parachain_bridge_schema { // default signer, which is always used to sign messages relay transactions on the right chain #[structopt(flatten)] right_sign: [<$right_parachain SigningParams>], - // override for left_relay->right-parachain headers signer - #[structopt(flatten)] - left_relay_headers_to_right_sign_override: [<$left_chain HeadersTo $right_parachain SigningParams>], - // override for left->right parachains signer - #[structopt(flatten)] - left_parachains_to_right_sign_override: [<$left_chain ParachainsTo $right_parachain SigningParams>], #[structopt(flatten)] right_relay: [<$right_chain ConnectionParams>], @@ -143,18 +116,6 @@ macro_rules! declare_parachain_to_parachain_bridge_schema { )?, left_relay: self.left_relay.into_client::().await?, right_relay: self.right_relay.into_client::().await?, - right_headers_to_left_transaction_params: self - .right_relay_headers_to_left_sign_override - .transaction_params_or::(&self.left_sign)?, - left_headers_to_right_transaction_params: self - .left_relay_headers_to_right_sign_override - .transaction_params_or::(&self.right_sign)?, - right_parachains_to_left_transaction_params: self - .right_parachains_to_left_sign_override - .transaction_params_or::(&self.left_sign)?, - left_parachains_to_right_transaction_params: self - .left_parachains_to_right_sign_override - .transaction_params_or::(&self.right_sign)?, }) } } @@ -199,23 +160,6 @@ where Arc>, Arc>, )> { - self.common.left.accounts.push(TaggedAccount::Headers { - id: self.right_headers_to_left_transaction_params.signer.public().into(), - bridged_chain: RightRelay::NAME.to_string(), - }); - self.common.left.accounts.push(TaggedAccount::Parachains { - id: self.right_parachains_to_left_transaction_params.signer.public().into(), - bridged_chain: RightRelay::NAME.to_string(), - }); - self.common.right.accounts.push(TaggedAccount::Headers { - id: self.left_headers_to_right_transaction_params.signer.public().into(), - bridged_chain: Left::NAME.to_string(), - }); - self.common.right.accounts.push(TaggedAccount::Parachains { - id: self.left_parachains_to_right_transaction_params.signer.public().into(), - bridged_chain: LeftRelay::NAME.to_string(), - }); - ::RelayFinality::start_relay_guards( &self.common.right.client, self.common.right.client.can_start_version_guard(), @@ -231,7 +175,7 @@ where OnDemandHeadersRelay::<::RelayFinality>::new( self.left_relay.clone(), self.common.right.client.clone(), - self.left_headers_to_right_transaction_params.clone(), + self.common.right.tx_params.clone(), self.common.shared.only_mandatory_headers, Some(self.common.metrics_params.clone()), ); @@ -239,7 +183,7 @@ where OnDemandHeadersRelay::<::RelayFinality>::new( self.right_relay.clone(), self.common.left.client.clone(), - self.right_headers_to_left_transaction_params.clone(), + self.common.left.tx_params.clone(), self.common.shared.only_mandatory_headers, Some(self.common.metrics_params.clone()), ); @@ -249,7 +193,7 @@ where >::new( self.left_relay.clone(), self.common.right.client.clone(), - self.left_parachains_to_right_transaction_params.clone(), + self.common.right.tx_params.clone(), Arc::new(left_relay_to_right_on_demand_headers), ); let right_to_left_on_demand_parachains = OnDemandParachainsRelay::< @@ -257,7 +201,7 @@ where >::new( self.right_relay.clone(), self.common.left.client.clone(), - self.right_parachains_to_left_transaction_params.clone(), + self.common.left.tx_params.clone(), Arc::new(right_relay_to_left_on_demand_headers), ); diff --git a/relays/bin-substrate/src/cli/relay_headers_and_messages/relay_to_parachain.rs b/relays/bin-substrate/src/cli/relay_headers_and_messages/relay_to_parachain.rs index 98b313cc0960d..fd885b6ea6c6c 100644 --- a/relays/bin-substrate/src/cli/relay_headers_and_messages/relay_to_parachain.rs +++ b/relays/bin-substrate/src/cli/relay_headers_and_messages/relay_to_parachain.rs @@ -36,7 +36,6 @@ use substrate_relay_helper::{ on_demand::{ headers::OnDemandHeadersRelay, parachains::OnDemandParachainsRelay, OnDemandRelay, }, - TaggedAccount, TransactionParams, }; /// A base relay between standalone (relay) chain and a parachain from another consensus system. @@ -54,17 +53,6 @@ pub struct RelayToParachainBridge< Full2WayBridgeCommonParams<::Target, ::Target>, /// Client of the right relay chain. pub right_relay: Client<::SourceRelay>, - - /// Override for right_relay->left headers signer. - pub right_headers_to_left_transaction_params: - TransactionParams::Target>>, - /// Override for right->left parachains signer. - pub right_parachains_to_left_transaction_params: - TransactionParams::Target>>, - - /// Override for left->right headers signer. - pub left_headers_to_right_transaction_params: - TransactionParams::Target>>, } macro_rules! declare_relay_to_parachain_bridge_schema { @@ -83,21 +71,12 @@ macro_rules! declare_relay_to_parachain_bridge_schema { // default signer, which is always used to sign messages relay transactions on the left chain #[structopt(flatten)] left_sign: [<$left_chain SigningParams>], - // override for right_relay->left headers signer - #[structopt(flatten)] - right_relay_headers_to_left_sign_override: [<$right_chain HeadersTo $left_chain SigningParams>], - // override for right->left parachains signer - #[structopt(flatten)] - right_parachains_to_left_sign_override: [<$right_chain ParachainsTo $left_chain SigningParams>], #[structopt(flatten)] right: [<$right_parachain ConnectionParams>], // default signer, which is always used to sign messages relay transactions on the right chain #[structopt(flatten)] right_sign: [<$right_parachain SigningParams>], - // override for left->right headers signer - #[structopt(flatten)] - left_headers_to_right_sign_override: [<$left_chain HeadersTo $right_parachain SigningParams>], #[structopt(flatten)] right_relay: [<$right_chain ConnectionParams>], @@ -130,19 +109,6 @@ macro_rules! declare_relay_to_parachain_bridge_schema { }, )?, right_relay: self.right_relay.into_client::().await?, - right_headers_to_left_transaction_params: self - .right_relay_headers_to_left_sign_override - .transaction_params_or::( - &self.left_sign, - )?, - right_parachains_to_left_transaction_params: self - .right_parachains_to_left_sign_override - .transaction_params_or::( - &self.left_sign, - )?, - left_headers_to_right_transaction_params: self - .left_headers_to_right_sign_override - .transaction_params_or::(&self.right_sign)?, }) } } @@ -185,19 +151,6 @@ where Arc>, Arc>, )> { - self.common.left.accounts.push(TaggedAccount::Headers { - id: self.right_headers_to_left_transaction_params.signer.public().into(), - bridged_chain: RightRelay::NAME.to_string(), - }); - self.common.left.accounts.push(TaggedAccount::Parachains { - id: self.right_parachains_to_left_transaction_params.signer.public().into(), - bridged_chain: RightRelay::NAME.to_string(), - }); - self.common.right.accounts.push(TaggedAccount::Headers { - id: self.left_headers_to_right_transaction_params.signer.public().into(), - bridged_chain: Left::NAME.to_string(), - }); - ::Finality::start_relay_guards( &self.common.right.client, self.common.right.client.can_start_version_guard(), @@ -213,7 +166,7 @@ where OnDemandHeadersRelay::<::Finality>::new( self.common.left.client.clone(), self.common.right.client.clone(), - self.left_headers_to_right_transaction_params.clone(), + self.common.right.tx_params.clone(), self.common.shared.only_mandatory_headers, None, ); @@ -221,7 +174,7 @@ where OnDemandHeadersRelay::<::RelayFinality>::new( self.right_relay.clone(), self.common.left.client.clone(), - self.right_headers_to_left_transaction_params.clone(), + self.common.left.tx_params.clone(), self.common.shared.only_mandatory_headers, Some(self.common.metrics_params.clone()), ); @@ -230,7 +183,7 @@ where >::new( self.right_relay.clone(), self.common.left.client.clone(), - self.right_parachains_to_left_transaction_params.clone(), + self.common.left.tx_params.clone(), Arc::new(right_relay_to_left_on_demand_headers), ); diff --git a/relays/bin-substrate/src/cli/relay_headers_and_messages/relay_to_relay.rs b/relays/bin-substrate/src/cli/relay_headers_and_messages/relay_to_relay.rs index a75263540a55f..11425035de287 100644 --- a/relays/bin-substrate/src/cli/relay_headers_and_messages/relay_to_relay.rs +++ b/relays/bin-substrate/src/cli/relay_headers_and_messages/relay_to_relay.rs @@ -14,6 +14,10 @@ // You should have received a copy of the GNU General Public License // along with Parity Bridges Common. If not, see . +// we don't have any relay/standalone <> relay/standalone chain bridges, but we may need it in a +// future +#![allow(unused_macros)] + use async_trait::async_trait; use std::sync::Arc; @@ -27,7 +31,6 @@ use sp_core::Pair; use substrate_relay_helper::{ finality::SubstrateFinalitySyncPipeline, on_demand::{headers::OnDemandHeadersRelay, OnDemandRelay}, - TaggedAccount, TransactionParams, }; /// A base relay between two standalone (relay) chains. @@ -40,12 +43,6 @@ pub struct RelayToRelayBridge< /// Parameters that are shared by all bridge types. pub common: Full2WayBridgeCommonParams<::Target, ::Target>, - /// Override for right->left headers signer. - pub right_to_left_transaction_params: - TransactionParams::Target>>, - /// Override for left->right headers signer. - pub left_to_right_transaction_params: - TransactionParams::Target>>, } macro_rules! declare_relay_to_relay_bridge_schema { @@ -62,18 +59,12 @@ macro_rules! declare_relay_to_relay_bridge_schema { // default signer, which is always used to sign messages relay transactions on the left chain #[structopt(flatten)] left_sign: [<$left_chain SigningParams>], - // override for right->left headers signer - #[structopt(flatten)] - right_headers_to_left_sign_override: [<$right_chain HeadersTo $left_chain SigningParams>], #[structopt(flatten)] right: [<$right_chain ConnectionParams>], #[structopt(flatten)] // default signer, which is always used to sign messages relay transactions on the right chain right_sign: [<$right_chain SigningParams>], - // override for left->right headers signer - #[structopt(flatten)] - left_headers_to_right_sign_override: [<$left_chain HeadersTo $right_chain SigningParams>], } impl [<$left_chain $right_chain HeadersAndMessages>] { @@ -99,12 +90,8 @@ macro_rules! declare_relay_to_relay_bridge_schema { accounts: vec![], }, )?, - right_to_left_transaction_params: self - .right_headers_to_left_sign_override - .transaction_params_or::(&self.left_sign)?, - left_to_right_transaction_params: self - .left_headers_to_right_sign_override - .transaction_params_or::(&self.right_sign)?, + right_to_left_transaction_params: self.left_sign.transaction_params::(), + left_to_right_transaction_params: self.right_sign.transaction_params::(), }) } } @@ -145,15 +132,6 @@ where Arc>, Arc>, )> { - self.common.right.accounts.push(TaggedAccount::Headers { - id: self.left_to_right_transaction_params.signer.public().into(), - bridged_chain: Self::Left::NAME.to_string(), - }); - self.common.left.accounts.push(TaggedAccount::Headers { - id: self.right_to_left_transaction_params.signer.public().into(), - bridged_chain: Self::Right::NAME.to_string(), - }); - ::Finality::start_relay_guards( &self.common.right.client, self.common.right.client.can_start_version_guard(), @@ -169,7 +147,7 @@ where OnDemandHeadersRelay::<::Finality>::new( self.common.left.client.clone(), self.common.right.client.clone(), - self.left_to_right_transaction_params.clone(), + self.common.right.tx_params.clone(), self.common.shared.only_mandatory_headers, None, ); @@ -177,7 +155,7 @@ where OnDemandHeadersRelay::<::Finality>::new( self.common.right.client.clone(), self.common.left.client.clone(), - self.right_to_left_transaction_params.clone(), + self.common.left.tx_params.clone(), self.common.shared.only_mandatory_headers, None, ); diff --git a/relays/bin-substrate/src/cli/relay_messages.rs b/relays/bin-substrate/src/cli/relay_messages.rs index 9880edcda2ca1..7d01f8bcd7df4 100644 --- a/relays/bin-substrate/src/cli/relay_messages.rs +++ b/relays/bin-substrate/src/cli/relay_messages.rs @@ -28,14 +28,6 @@ use crate::bridges::{ bridge_hub_polkadot_messages_to_polkadot_bulletin::BridgeHubPolkadotToPolkadotBulletinMessagesCliBridge, polkadot_bulletin_messages_to_bridge_hub_polkadot::PolkadotBulletinToBridgeHubPolkadotMessagesCliBridge, }, - rialto_millau::{ - millau_headers_to_rialto::MillauToRialtoCliBridge, - rialto_headers_to_millau::RialtoToMillauCliBridge, - }, - rialto_parachain_millau::{ - millau_headers_to_rialto_parachain::MillauToRialtoParachainCliBridge, - rialto_parachains_to_millau::RialtoParachainToMillauCliBridge, - }, rococo_westend::{ bridge_hub_rococo_messages_to_bridge_hub_westend::BridgeHubRococoToBridgeHubWestendMessagesCliBridge, bridge_hub_westend_messages_to_bridge_hub_rococo::BridgeHubWestendToBridgeHubRococoMessagesCliBridge, @@ -109,10 +101,6 @@ where } } -impl MessagesRelayer for MillauToRialtoCliBridge {} -impl MessagesRelayer for RialtoToMillauCliBridge {} -impl MessagesRelayer for MillauToRialtoParachainCliBridge {} -impl MessagesRelayer for RialtoParachainToMillauCliBridge {} impl MessagesRelayer for BridgeHubRococoToBridgeHubWococoMessagesCliBridge {} impl MessagesRelayer for BridgeHubWococoToBridgeHubRococoMessagesCliBridge {} impl MessagesRelayer for BridgeHubRococoToBridgeHubWestendMessagesCliBridge {} @@ -126,12 +114,6 @@ impl RelayMessages { /// Run the command. pub async fn run(self) -> anyhow::Result<()> { match self.bridge { - FullBridge::MillauToRialto => MillauToRialtoCliBridge::relay_messages(self), - FullBridge::RialtoToMillau => RialtoToMillauCliBridge::relay_messages(self), - FullBridge::MillauToRialtoParachain => - MillauToRialtoParachainCliBridge::relay_messages(self), - FullBridge::RialtoParachainToMillau => - RialtoParachainToMillauCliBridge::relay_messages(self), FullBridge::BridgeHubRococoToBridgeHubWococo => BridgeHubRococoToBridgeHubWococoMessagesCliBridge::relay_messages(self), FullBridge::BridgeHubWococoToBridgeHubRococo => diff --git a/relays/bin-substrate/src/cli/relay_parachains.rs b/relays/bin-substrate/src/cli/relay_parachains.rs index 03d3860f3b224..668632320efa8 100644 --- a/relays/bin-substrate/src/cli/relay_parachains.rs +++ b/relays/bin-substrate/src/cli/relay_parachains.rs @@ -20,7 +20,6 @@ use crate::bridges::{ polkadot_parachains_to_bridge_hub_kusama::BridgeHubPolkadotToBridgeHubKusamaCliBridge, }, polkadot_bulletin::polkadot_parachains_to_polkadot_bulletin::PolkadotToPolkadotBulletinCliBridge, - rialto_parachain_millau::rialto_parachains_to_millau::RialtoParachainToMillauCliBridge, rococo_westend::{ rococo_parachains_to_bridge_hub_westend::BridgeHubRococoToBridgeHubWestendCliBridge, westend_parachains_to_bridge_hub_rococo::BridgeHubWestendToBridgeHubRococoCliBridge, @@ -29,7 +28,6 @@ use crate::bridges::{ rococo_parachains_to_bridge_hub_wococo::BridgeHubRococoToBridgeHubWococoCliBridge, wococo_parachains_to_bridge_hub_rococo::BridgeHubWococoToBridgeHubRococoCliBridge, }, - westend_millau::westend_parachains_to_millau::AssetHubWestendToMillauCliBridge, }; use async_std::sync::Mutex; use async_trait::async_trait; @@ -70,8 +68,6 @@ pub struct RelayParachains { #[derive(Debug, EnumString, EnumVariantNames)] #[strum(serialize_all = "kebab_case")] pub enum RelayParachainsBridge { - RialtoToMillau, - WestendToMillau, RococoToBridgeHubWococo, WococoToBridgeHubRococo, KusamaToBridgeHubPolkadot, @@ -122,8 +118,6 @@ where } } -impl ParachainsRelayer for RialtoParachainToMillauCliBridge {} -impl ParachainsRelayer for AssetHubWestendToMillauCliBridge {} impl ParachainsRelayer for BridgeHubRococoToBridgeHubWococoCliBridge {} impl ParachainsRelayer for BridgeHubWococoToBridgeHubRococoCliBridge {} impl ParachainsRelayer for BridgeHubRococoToBridgeHubWestendCliBridge {} @@ -136,10 +130,6 @@ impl RelayParachains { /// Run the command. pub async fn run(self) -> anyhow::Result<()> { match self.bridge { - RelayParachainsBridge::RialtoToMillau => - RialtoParachainToMillauCliBridge::relay_parachains(self), - RelayParachainsBridge::WestendToMillau => - AssetHubWestendToMillauCliBridge::relay_parachains(self), RelayParachainsBridge::RococoToBridgeHubWococo => BridgeHubRococoToBridgeHubWococoCliBridge::relay_parachains(self), RelayParachainsBridge::WococoToBridgeHubRococo => diff --git a/relays/bin-substrate/src/cli/resubmit_transactions.rs b/relays/bin-substrate/src/cli/resubmit_transactions.rs deleted file mode 100644 index c5b20e939c1fa..0000000000000 --- a/relays/bin-substrate/src/cli/resubmit_transactions.rs +++ /dev/null @@ -1,560 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use crate::cli::{chain_schema::*, Balance}; - -use bp_runtime::HeaderIdProvider; -use codec::{Decode, Encode}; -use num_traits::{One, Zero}; -use relay_substrate_client::{ - AccountKeyPairOf, BlockWithJustification, Chain, ChainWithTransactions, Client, - Error as SubstrateError, HeaderIdOf, HeaderOf, SignParam, -}; -use relay_utils::FailedClient; -use sp_core::Bytes; -use sp_runtime::{ - traits::{Hash, Header as HeaderT}, - transaction_validity::TransactionPriority, -}; -use structopt::StructOpt; -use strum::{EnumString, EnumVariantNames, VariantNames}; -use substrate_relay_helper::TransactionParams; - -/// Start resubmit transactions process. -#[derive(StructOpt)] -pub struct ResubmitTransactions { - /// A bridge instance to relay headers for. - #[structopt(possible_values = RelayChain::VARIANTS, case_insensitive = true)] - chain: RelayChain, - #[structopt(flatten)] - target: TargetConnectionParams, - #[structopt(flatten)] - target_sign: TargetSigningParams, - /// Number of blocks we see before considering queued transaction as stalled. - #[structopt(long, default_value = "5")] - stalled_blocks: u32, - /// Tip limit. We'll never submit transaction with larger tip. - #[structopt(long)] - tip_limit: Balance, - /// Tip increase step. We'll be checking updated transaction priority by increasing its tip by - /// this step. - #[structopt(long)] - tip_step: Balance, - /// Priority selection strategy. - #[structopt(subcommand)] - strategy: PrioritySelectionStrategy, -} - -/// Chain, which transactions we're going to track && resubmit. -#[derive(Debug, EnumString, EnumVariantNames)] -#[strum(serialize_all = "kebab_case")] -pub enum RelayChain { - Millau, -} - -/// Strategy to use for priority selection. -#[derive(StructOpt, Debug, PartialEq, Eq, Clone, Copy)] -pub enum PrioritySelectionStrategy { - /// Strategy selects tip that changes transaction priority to be better than priority of - /// the first transaction of previous block. - /// - /// It only makes sense to use this strategy for Millau transactions. Millau has transactions - /// that are close to block limits, so if there are any other queued transactions, 'large' - /// transaction won't fit the block && will be postponed. To avoid this, we change its priority - /// to some large value, making it best transaction => it'll be 'mined' first. - MakeItBestTransaction, - /// Strategy selects tip that changes transaction priority to be better than priority of - /// selected queued transaction. - /// - /// When we first see stalled transaction, we make it better than worst 1/4 of queued - /// transactions. If it is still stalled, we'll make it better than 1/3 of queued transactions, - /// ... - MakeItBetterThanQueuedTransaction, -} - -macro_rules! select_bridge { - ($bridge: expr, $generic: tt) => { - match $bridge { - RelayChain::Millau => { - type Target = relay_millau_client::Millau; - - $generic - }, - } - }; -} - -impl ResubmitTransactions { - /// Run the command. - pub async fn run(self) -> anyhow::Result<()> { - select_bridge!(self.chain, { - let relay_loop_name = format!("ResubmitTransactions{}", Target::NAME); - let client = self.target.into_client::().await?; - let transaction_params = TransactionParams { - signer: self.target_sign.to_keypair::()?, - mortality: self.target_sign.target_transactions_mortality, - }; - - relay_utils::relay_loop((), client) - .run(relay_loop_name, move |_, client, _| { - run_until_connection_lost( - client, - transaction_params.clone(), - Context { - strategy: self.strategy, - best_header: HeaderOf::::new( - Default::default(), - Default::default(), - Default::default(), - Default::default(), - Default::default(), - ), - transaction: None, - resubmitted: 0, - stalled_for: Zero::zero(), - stalled_for_limit: self.stalled_blocks as _, - tip_step: self.tip_step.cast() as _, - tip_limit: self.tip_limit.cast() as _, - }, - ) - }) - .await - .map_err(Into::into) - }) - } -} - -impl PrioritySelectionStrategy { - /// Select target priority. - async fn select_target_priority( - &self, - client: &Client, - context: &Context, - ) -> Result, SubstrateError> { - match *self { - PrioritySelectionStrategy::MakeItBestTransaction => - read_previous_block_best_priority(client, context).await, - PrioritySelectionStrategy::MakeItBetterThanQueuedTransaction => - select_priority_from_queue(client, context).await, - } - } -} - -#[derive(Debug)] -struct Context { - /// Priority selection strategy. - strategy: PrioritySelectionStrategy, - /// Best known block header. - best_header: C::Header, - /// Hash of the (potentially) stalled transaction. - transaction: Option, - /// How many times we have resubmitted this `transaction`? - resubmitted: u32, - /// This transaction is in pool for `stalled_for` wakeup intervals. - stalled_for: C::BlockNumber, - /// When `stalled_for` reaching this limit, transaction is considered stalled. - stalled_for_limit: C::BlockNumber, - /// Tip step interval. - tip_step: C::Balance, - /// Maximal tip. - tip_limit: C::Balance, -} - -impl Context { - /// Return true if transaction has stalled. - fn is_stalled(&self) -> bool { - self.stalled_for >= self.stalled_for_limit - } - - /// Notice resubmitted transaction. - fn notice_resubmitted_transaction(mut self, transaction: C::Hash) -> Self { - self.transaction = Some(transaction); - self.stalled_for = Zero::zero(); - self.resubmitted += 1; - self - } - - /// Notice transaction from the transaction pool. - fn notice_transaction(mut self, transaction: C::Hash) -> Self { - if self.transaction == Some(transaction) { - self.stalled_for += One::one(); - } else { - self.transaction = Some(transaction); - self.stalled_for = One::one(); - self.resubmitted = 0; - } - self - } -} - -/// Run resubmit transactions loop. -async fn run_until_connection_lost( - client: Client, - transaction_params: TransactionParams>, - mut context: Context, -) -> Result<(), FailedClient> { - loop { - async_std::task::sleep(C::AVERAGE_BLOCK_INTERVAL).await; - - let result = run_loop_iteration(client.clone(), transaction_params.clone(), context).await; - context = match result { - Ok(context) => context, - Err(error) => { - log::error!( - target: "bridge", - "Resubmit {} transactions loop has failed with error: {:?}", - C::NAME, - error, - ); - return Err(FailedClient::Target) - }, - }; - } -} - -/// Run single loop iteration. -async fn run_loop_iteration( - client: Client, - transaction_params: TransactionParams>, - mut context: Context, -) -> Result, SubstrateError> { - // correct best header is required for all other actions - context.best_header = client.best_header().await?; - - // check if there's queued transaction, signed by given author - let original_transaction = - match lookup_signer_transaction(&client, &transaction_params.signer).await? { - Some(original_transaction) => original_transaction, - None => { - log::trace!(target: "bridge", "No {} transactions from required signer in the txpool", C::NAME); - return Ok(context) - }, - }; - let original_transaction_hash = C::Hasher::hash(&original_transaction.encode()); - let context = context.notice_transaction(original_transaction_hash); - - // if transaction hasn't been mined for `stalled_blocks`, we'll need to resubmit it - if !context.is_stalled() { - log::trace!( - target: "bridge", - "{} transaction {:?} is not yet stalled ({:?}/{:?})", - C::NAME, - context.transaction, - context.stalled_for, - context.stalled_for_limit, - ); - return Ok(context) - } - - // select priority for updated transaction - let target_priority = match context.strategy.select_target_priority(&client, &context).await? { - Some(target_priority) => target_priority, - None => { - log::trace!(target: "bridge", "Failed to select target priority"); - return Ok(context) - }, - }; - - // update transaction tip - let (is_updated, updated_transaction) = update_transaction_tip( - &client, - &transaction_params, - context.best_header.id(), - original_transaction, - context.tip_step, - context.tip_limit, - target_priority, - ) - .await?; - - if !is_updated { - log::trace!(target: "bridge", "{} transaction tip can not be updated. Reached limit?", C::NAME); - return Ok(context) - } - - let updated_transaction = updated_transaction.encode(); - let updated_transaction_hash = C::Hasher::hash(&updated_transaction); - client.submit_unsigned_extrinsic(Bytes(updated_transaction)).await?; - - log::info!( - target: "bridge", - "Replaced {} transaction {} with {} in txpool", - C::NAME, - original_transaction_hash, - updated_transaction_hash, - ); - - Ok(context.notice_resubmitted_transaction(updated_transaction_hash)) -} - -/// Search transaction pool for transaction, signed by given key pair. -async fn lookup_signer_transaction( - client: &Client, - key_pair: &AccountKeyPairOf, -) -> Result, SubstrateError> { - let pending_transactions = client.pending_extrinsics().await?; - for pending_transaction in pending_transactions { - let pending_transaction = C::SignedTransaction::decode(&mut &pending_transaction.0[..]) - .map_err(SubstrateError::ResponseParseFailed)?; - if !C::is_signed_by(key_pair, &pending_transaction) { - continue - } - - return Ok(Some(pending_transaction)) - } - - Ok(None) -} - -/// Read priority of best signed transaction of previous block. -async fn read_previous_block_best_priority( - client: &Client, - context: &Context, -) -> Result, SubstrateError> { - let best_block = client.get_block(Some(context.best_header.hash())).await?; - let best_transaction = best_block - .extrinsics() - .iter() - .filter_map(|xt| C::SignedTransaction::decode(&mut &xt[..]).ok()) - .find(|xt| C::is_signed(xt)); - match best_transaction { - Some(best_transaction) => Ok(Some( - client - .validate_transaction(*context.best_header.parent_hash(), best_transaction) - .await?? - .priority, - )), - None => Ok(None), - } -} - -/// Select priority of some queued transaction. -async fn select_priority_from_queue( - client: &Client, - context: &Context, -) -> Result, SubstrateError> { - // select transaction from the queue - let queued_transactions = client.pending_extrinsics().await?; - let selected_transaction = match select_transaction_from_queue(queued_transactions, context) { - Some(selected_transaction) => selected_transaction, - None => return Ok(None), - }; - - let selected_transaction = C::SignedTransaction::decode(&mut &selected_transaction[..]) - .map_err(SubstrateError::ResponseParseFailed)?; - let target_priority = client - .validate_transaction(context.best_header.hash(), selected_transaction) - .await?? - .priority; - Ok(Some(target_priority)) -} - -/// Select transaction with target priority from the vec of queued transactions. -fn select_transaction_from_queue( - mut queued_transactions: Vec, - context: &Context, -) -> Option { - if queued_transactions.is_empty() { - return None - } - - // the more times we resubmit transaction (`context.resubmitted`), the closer we move - // to the front of the transaction queue - let total_transactions = queued_transactions.len(); - let resubmitted_factor = context.resubmitted; - let divisor = - 1usize.saturating_add(1usize.checked_shl(resubmitted_factor).unwrap_or(usize::MAX)); - let transactions_to_skip = total_transactions / divisor; - - Some( - queued_transactions - .swap_remove(std::cmp::min(total_transactions - 1, transactions_to_skip)), - ) -} - -/// Try to find appropriate tip for transaction so that its priority is larger than given. -async fn update_transaction_tip( - client: &Client, - transaction_params: &TransactionParams>, - at_block: HeaderIdOf, - tx: C::SignedTransaction, - tip_step: C::Balance, - tip_limit: C::Balance, - target_priority: TransactionPriority, -) -> Result<(bool, C::SignedTransaction), SubstrateError> { - let stx = format!("{tx:?}"); - let mut current_priority = client.validate_transaction(at_block.1, tx.clone()).await??.priority; - let mut unsigned_tx = C::parse_transaction(tx).ok_or_else(|| { - SubstrateError::Custom(format!("Failed to parse {} transaction {stx}", C::NAME,)) - })?; - let old_tip = unsigned_tx.tip; - - let runtime_version = client.simple_runtime_version().await?; - while current_priority < target_priority { - let next_tip = unsigned_tx.tip + tip_step; - if next_tip > tip_limit { - break - } - - log::trace!( - target: "bridge", - "{} transaction priority with tip={:?}: {}. Target priority: {}", - C::NAME, - unsigned_tx.tip, - current_priority, - target_priority, - ); - - unsigned_tx.tip = next_tip; - current_priority = client - .validate_transaction( - at_block.1, - C::sign_transaction( - SignParam { - spec_version: runtime_version.spec_version, - transaction_version: runtime_version.transaction_version, - genesis_hash: *client.genesis_hash(), - signer: transaction_params.signer.clone(), - }, - unsigned_tx.clone(), - )?, - ) - .await?? - .priority; - } - - log::debug!( - target: "bridge", - "{} transaction tip has changed from {:?} to {:?}", - C::NAME, - old_tip, - unsigned_tx.tip, - ); - - Ok(( - old_tip != unsigned_tx.tip, - C::sign_transaction( - SignParam { - spec_version: runtime_version.spec_version, - transaction_version: runtime_version.transaction_version, - genesis_hash: *client.genesis_hash(), - signer: transaction_params.signer.clone(), - }, - unsigned_tx.era(relay_substrate_client::TransactionEra::new( - at_block, - transaction_params.mortality, - )), - )?, - )) -} - -#[cfg(test)] -mod tests { - use super::*; - use bp_rialto::Hash; - use relay_rialto_client::Rialto; - - fn context() -> Context { - Context { - strategy: PrioritySelectionStrategy::MakeItBestTransaction, - best_header: HeaderOf::::new( - Default::default(), - Default::default(), - Default::default(), - Default::default(), - Default::default(), - ), - transaction: None, - resubmitted: 0, - stalled_for: Zero::zero(), - stalled_for_limit: 3, - tip_step: 100, - tip_limit: 1000, - } - } - - #[test] - fn context_works() { - let mut context = context(); - - // when transaction is noticed 2/3 times, it isn't stalled - context = context.notice_transaction(Default::default()); - assert!(!context.is_stalled()); - assert_eq!(context.stalled_for, 1); - assert_eq!(context.resubmitted, 0); - context = context.notice_transaction(Default::default()); - assert!(!context.is_stalled()); - assert_eq!(context.stalled_for, 2); - assert_eq!(context.resubmitted, 0); - - // when transaction is noticed for 3rd time in a row, it is considered stalled - context = context.notice_transaction(Default::default()); - assert!(context.is_stalled()); - assert_eq!(context.stalled_for, 3); - assert_eq!(context.resubmitted, 0); - - // and after we resubmit it, we forget previous transaction - context = context.notice_resubmitted_transaction(Hash::from([1; 32])); - assert_eq!(context.transaction, Some(Hash::from([1; 32]))); - assert_eq!(context.resubmitted, 1); - assert_eq!(context.stalled_for, 0); - } - - #[test] - fn select_transaction_from_queue_works_with_empty_queue() { - assert_eq!(select_transaction_from_queue(vec![], &context()), None); - } - - #[test] - fn select_transaction_from_queue_works() { - let mut context = context(); - let queued_transactions = vec![ - Bytes(vec![1]), - Bytes(vec![2]), - Bytes(vec![3]), - Bytes(vec![4]), - Bytes(vec![5]), - Bytes(vec![6]), - ]; - - // when we resubmit tx for the first time, 1/2 of queue is skipped - assert_eq!( - select_transaction_from_queue(queued_transactions.clone(), &context), - Some(Bytes(vec![4])), - ); - - // when we resubmit tx for the second time, 1/3 of queue is skipped - context = context.notice_resubmitted_transaction(Hash::from([1; 32])); - assert_eq!( - select_transaction_from_queue(queued_transactions.clone(), &context), - Some(Bytes(vec![3])), - ); - - // when we resubmit tx for the third time, 1/5 of queue is skipped - context = context.notice_resubmitted_transaction(Hash::from([2; 32])); - assert_eq!( - select_transaction_from_queue(queued_transactions.clone(), &context), - Some(Bytes(vec![2])), - ); - - // when we resubmit tx for the second time, 1/9 of queue is skipped - context = context.notice_resubmitted_transaction(Hash::from([3; 32])); - assert_eq!( - select_transaction_from_queue(queued_transactions, &context), - Some(Bytes(vec![1])), - ); - } -} diff --git a/relays/bin-substrate/src/cli/send_message.rs b/relays/bin-substrate/src/cli/send_message.rs deleted file mode 100644 index 02ef58b371948..0000000000000 --- a/relays/bin-substrate/src/cli/send_message.rs +++ /dev/null @@ -1,177 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -use crate::{ - bridges::{ - rialto_millau::{ - millau_headers_to_rialto::MillauToRialtoCliBridge, - rialto_headers_to_millau::RialtoToMillauCliBridge, - }, - rialto_parachain_millau::{ - millau_headers_to_rialto_parachain::MillauToRialtoParachainCliBridge, - rialto_parachains_to_millau::RialtoParachainToMillauCliBridge, - }, - }, - cli::{ - bridge::{FullBridge, MessagesCliBridge}, - chain_schema::*, - encode_message::{self, CliEncodeMessage, RawMessage}, - CliChain, - }, -}; -use async_trait::async_trait; -use codec::{Decode, Encode}; -use relay_substrate_client::{ - AccountIdOf, AccountKeyPairOf, Chain, ChainBase, ChainWithTransactions, UnsignedTransaction, -}; -use sp_core::Pair; -use sp_runtime::AccountId32; -use std::fmt::Display; -use structopt::StructOpt; -use strum::VariantNames; - -/// Send bridge message. -#[derive(StructOpt)] -pub struct SendMessage { - /// A bridge instance to encode call for. - #[structopt(possible_values = FullBridge::VARIANTS, case_insensitive = true)] - bridge: FullBridge, - #[structopt(flatten)] - source: SourceConnectionParams, - #[structopt(flatten)] - source_sign: SourceSigningParams, - /// Message type. - #[structopt(subcommand)] - message: crate::cli::encode_message::Message, -} - -#[async_trait] -trait MessageSender: MessagesCliBridge -where - Self::Source: ChainBase + ChainWithTransactions + CliChain + CliEncodeMessage, - ::Balance: Display + From + Into, - ::Call: Sync, - ::SignedTransaction: Sync, - AccountIdOf: From< as Pair>::Public>, - AccountId32: From< as Pair>::Public>, -{ - async fn send_message(data: SendMessage) -> anyhow::Result<()> { - let payload = encode_message::encode_message::(&data.message)?; - - let source_client = data.source.into_client::().await?; - let source_sign = data.source_sign.to_keypair::()?; - - let payload_len = payload.encoded_size(); - let send_message_call = Self::Source::encode_execute_xcm(decode_xcm(payload)?)?; - - source_client - .submit_signed_extrinsic(&source_sign, move |_, transaction_nonce| { - let unsigned = UnsignedTransaction::new(send_message_call, transaction_nonce); - log::info!( - target: "bridge", - "Sending message to {}. Size: {}", - Self::Target::NAME, - payload_len, - ); - Ok(unsigned) - }) - .await?; - - Ok(()) - } -} - -impl MessageSender for MillauToRialtoCliBridge {} -impl MessageSender for RialtoToMillauCliBridge {} -impl MessageSender for MillauToRialtoParachainCliBridge {} -impl MessageSender for RialtoParachainToMillauCliBridge {} - -impl SendMessage { - /// Run the command. - pub async fn run(self) -> anyhow::Result<()> { - match self.bridge { - FullBridge::MillauToRialto => MillauToRialtoCliBridge::send_message(self), - FullBridge::RialtoToMillau => RialtoToMillauCliBridge::send_message(self), - FullBridge::MillauToRialtoParachain => - MillauToRialtoParachainCliBridge::send_message(self), - FullBridge::RialtoParachainToMillau => - RialtoParachainToMillauCliBridge::send_message(self), - // all our (soon to retire_ testnets are above, so if is fine to use `_` - _ => unimplemented!("Sending message from in {:?} is not supported", self.bridge,), - } - .await - } -} - -/// Decode SCALE encoded raw XCM message. -pub(crate) fn decode_xcm(message: RawMessage) -> anyhow::Result> { - Decode::decode(&mut &message[..]) - .map_err(|e| anyhow::format_err!("Failed to decode XCM program: {:?}", e)) -} - -#[cfg(test)] -mod tests { - use super::*; - use crate::cli::{ExplicitOrMaximal, HexBytes}; - - #[test] - fn send_raw_rialto_to_millau() { - // given - let send_message = SendMessage::from_iter(vec![ - "send-message", - "rialto-to-millau", - "--source-port", - "1234", - "--source-signer", - "//Alice", - "raw", - "dead", - ]); - - // then - assert_eq!(send_message.bridge, FullBridge::RialtoToMillau); - assert_eq!(send_message.source.source_port, 1234); - assert_eq!(send_message.source_sign.source_signer, Some("//Alice".into())); - assert_eq!( - send_message.message, - crate::cli::encode_message::Message::Raw { data: HexBytes(vec![0xDE, 0xAD]) } - ); - } - - #[test] - fn send_sized_rialto_to_millau() { - // given - let send_message = SendMessage::from_iter(vec![ - "send-message", - "rialto-to-millau", - "--source-port", - "1234", - "--source-signer", - "//Alice", - "sized", - "max", - ]); - - // then - assert_eq!(send_message.bridge, FullBridge::RialtoToMillau); - assert_eq!(send_message.source.source_port, 1234); - assert_eq!(send_message.source_sign.source_signer, Some("//Alice".into())); - assert_eq!( - send_message.message, - crate::cli::encode_message::Message::Sized { size: ExplicitOrMaximal::Maximal } - ); - } -} diff --git a/relays/client-millau/Cargo.toml b/relays/client-millau/Cargo.toml deleted file mode 100644 index ccfeced1c2704..0000000000000 --- a/relays/client-millau/Cargo.toml +++ /dev/null @@ -1,27 +0,0 @@ -[package] -name = "relay-millau-client" -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[dependencies] -codec = { package = "parity-scale-codec", version = "3.1.5" } -relay-substrate-client = { path = "../client-substrate" } -relay-utils = { path = "../utils" } - -# Supported Chains - -bp-messages = { path = "../../primitives/messages" } -bp-millau = { path = "../../primitives/chain-millau" } -bp-runtime = { path = "../../primitives/runtime" } -millau-runtime = { path = "../../bin/millau/runtime" } - -# Substrate Dependencies - -frame-support = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -frame-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -pallet-transaction-payment = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-session = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } diff --git a/relays/client-millau/src/lib.rs b/relays/client-millau/src/lib.rs deleted file mode 100644 index b3101c980c557..0000000000000 --- a/relays/client-millau/src/lib.rs +++ /dev/null @@ -1,197 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Types used to connect to the Millau-Substrate chain. - -use bp_messages::MessageNonce; -use bp_millau::MILLAU_SYNCED_HEADERS_GRANDPA_INFO_METHOD; -use bp_runtime::ChainId; -use codec::{Compact, Decode, Encode}; -use relay_substrate_client::{ - BalanceOf, Chain, ChainWithBalances, ChainWithGrandpa, ChainWithMessages, - ChainWithTransactions, ChainWithUtilityPallet, Error as SubstrateError, - FullRuntimeUtilityPallet, NonceOf, SignParam, UnderlyingChainProvider, UnsignedTransaction, -}; -use sp_core::{storage::StorageKey, Pair}; -use sp_runtime::{generic::SignedPayload, traits::IdentifyAccount}; -use sp_session::MembershipProof; -use std::time::Duration; - -/// Millau header id. -pub type HeaderId = relay_utils::HeaderId; - -/// Millau chain definition. -#[derive(Debug, Clone, Copy, PartialEq, Eq)] -pub struct Millau; - -impl UnderlyingChainProvider for Millau { - type Chain = bp_millau::Millau; -} - -impl ChainWithMessages for Millau { - const WITH_CHAIN_MESSAGES_PALLET_NAME: &'static str = - bp_millau::WITH_MILLAU_MESSAGES_PALLET_NAME; - // TODO (https://github.com/paritytech/parity-bridges-common/issues/1692): change the name - const WITH_CHAIN_RELAYERS_PALLET_NAME: Option<&'static str> = Some("BridgeRelayers"); - const TO_CHAIN_MESSAGE_DETAILS_METHOD: &'static str = - bp_millau::TO_MILLAU_MESSAGE_DETAILS_METHOD; - const FROM_CHAIN_MESSAGE_DETAILS_METHOD: &'static str = - bp_millau::FROM_MILLAU_MESSAGE_DETAILS_METHOD; - const MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX: MessageNonce = - bp_millau::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX; - const MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX: MessageNonce = - bp_millau::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX; -} - -impl Chain for Millau { - const ID: ChainId = bp_runtime::MILLAU_CHAIN_ID; - const NAME: &'static str = "Millau"; - const BEST_FINALIZED_HEADER_ID_METHOD: &'static str = - bp_millau::BEST_FINALIZED_MILLAU_HEADER_METHOD; - const AVERAGE_BLOCK_INTERVAL: Duration = Duration::from_secs(5); - - type SignedBlock = millau_runtime::SignedBlock; - type Call = millau_runtime::RuntimeCall; -} - -impl ChainWithGrandpa for Millau { - const SYNCED_HEADERS_GRANDPA_INFO_METHOD: &'static str = - MILLAU_SYNCED_HEADERS_GRANDPA_INFO_METHOD; - - type KeyOwnerProof = MembershipProof; -} - -impl ChainWithBalances for Millau { - fn account_info_storage_key(account_id: &Self::AccountId) -> StorageKey { - use frame_support::storage::generator::StorageMap; - StorageKey(frame_system::Account::::storage_map_final_key( - account_id, - )) - } -} - -impl ChainWithTransactions for Millau { - type AccountKeyPair = sp_core::sr25519::Pair; - type SignedTransaction = millau_runtime::UncheckedExtrinsic; - - fn sign_transaction( - param: SignParam, - unsigned: UnsignedTransaction, - ) -> Result { - let raw_payload = SignedPayload::from_raw( - unsigned.call.clone(), - ( - frame_system::CheckNonZeroSender::::new(), - frame_system::CheckSpecVersion::::new(), - frame_system::CheckTxVersion::::new(), - frame_system::CheckGenesis::::new(), - frame_system::CheckEra::::from(unsigned.era.frame_era()), - frame_system::CheckNonce::::from(unsigned.nonce), - frame_system::CheckWeight::::new(), - pallet_transaction_payment::ChargeTransactionPayment::::from(unsigned.tip), - millau_runtime::BridgeRejectObsoleteHeadersAndMessages, - millau_runtime::BridgeRefundRialtoParachainMessages::default(), - ), - ( - (), - param.spec_version, - param.transaction_version, - param.genesis_hash, - unsigned.era.signed_payload(param.genesis_hash), - (), - (), - (), - (), - () - ), - ); - let signature = raw_payload.using_encoded(|payload| param.signer.sign(payload)); - let signer: sp_runtime::MultiSigner = param.signer.public().into(); - let (call, extra, _) = raw_payload.deconstruct(); - - Ok(millau_runtime::UncheckedExtrinsic::new_signed( - call.into_decoded()?, - signer.into_account(), - signature.into(), - extra, - )) - } - - fn is_signed(tx: &Self::SignedTransaction) -> bool { - tx.signature.is_some() - } - - fn is_signed_by(signer: &Self::AccountKeyPair, tx: &Self::SignedTransaction) -> bool { - tx.signature - .as_ref() - .map(|(address, _, _)| { - *address == millau_runtime::Address::from(*signer.public().as_array_ref()) - }) - .unwrap_or(false) - } - - fn parse_transaction(tx: Self::SignedTransaction) -> Option> { - let extra = &tx.signature.as_ref()?.2; - Some( - UnsignedTransaction::new( - tx.function.into(), - Compact::>::decode(&mut &extra.5.encode()[..]).ok()?.into(), - ) - .tip(Compact::>::decode(&mut &extra.7.encode()[..]).ok()?.into()), - ) - } -} - -impl ChainWithUtilityPallet for Millau { - type UtilityPallet = FullRuntimeUtilityPallet; -} - -/// Millau signing params. -pub type SigningParams = sp_core::sr25519::Pair; - -/// Millau header type used in headers sync. -pub type SyncHeader = relay_substrate_client::SyncHeader; - -#[cfg(test)] -mod tests { - use super::*; - use relay_substrate_client::TransactionEra; - - #[test] - fn parse_transaction_works() { - let unsigned = UnsignedTransaction { - call: millau_runtime::RuntimeCall::System(millau_runtime::SystemCall::remark { - remark: b"Hello world!".to_vec(), - }) - .into(), - nonce: 777, - tip: 888, - era: TransactionEra::immortal(), - }; - let signed_transaction = Millau::sign_transaction( - SignParam { - spec_version: 42, - transaction_version: 50000, - genesis_hash: [42u8; 64].into(), - signer: sp_core::sr25519::Pair::from_seed_slice(&[1u8; 32]).unwrap(), - }, - unsigned.clone(), - ) - .unwrap(); - let parsed_transaction = Millau::parse_transaction(signed_transaction).unwrap(); - assert_eq!(parsed_transaction, unsigned); - } -} diff --git a/relays/client-rialto-parachain/Cargo.toml b/relays/client-rialto-parachain/Cargo.toml deleted file mode 100644 index fc91e27ee0f82..0000000000000 --- a/relays/client-rialto-parachain/Cargo.toml +++ /dev/null @@ -1,30 +0,0 @@ -[package] -name = "relay-rialto-parachain-client" -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[dependencies] -codec = { package = "parity-scale-codec", version = "3.1.5" } -scale-info = { version = "2.10.0", default-features = false, features = ["derive"] } -subxt = { version = "0.32.1", default-features = false, features = [] } - -# Bridge dependencies - -bp-bridge-hub-cumulus = { path = "../../primitives/chain-bridge-hub-cumulus" } -bp-header-chain = { path = "../../primitives/header-chain" } -bp-messages = { path = "../../primitives/messages" } -bp-millau = { path = "../../primitives/chain-millau" } -bp-polkadot-core = { path = "../../primitives/polkadot-core" } -bp-rialto-parachain = { path = "../../primitives/chain-rialto-parachain" } -bp-runtime = { path = "../../primitives/runtime" } - -bridge-runtime-common = { path = "../../bin/runtime-common" } -relay-substrate-client = { path = "../client-substrate" } - -# Substrate Dependencies - -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-weights = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } diff --git a/relays/client-rialto-parachain/src/codegen_runtime.rs b/relays/client-rialto-parachain/src/codegen_runtime.rs deleted file mode 100644 index eb19d98d7e487..0000000000000 --- a/relays/client-rialto-parachain/src/codegen_runtime.rs +++ /dev/null @@ -1,2936 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Autogenerated runtime API -//! THIS FILE WAS AUTOGENERATED USING parity-bridges-common::runtime-codegen -//! EXECUTED COMMAND: target/debug/runtime-codegen --from-node-url http://localhost:20433 - -#[allow(dead_code, unused_imports, non_camel_case_types)] -#[allow(clippy::all)] -pub mod api { - use super::api as root_mod; - pub mod runtime_types { - use super::runtime_types; - pub mod bounded_collections { - use super::runtime_types; - pub mod bounded_vec { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct BoundedVec<_0>(pub ::std::vec::Vec<_0>); - } - pub mod weak_bounded_vec { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct WeakBoundedVec<_0>(pub ::std::vec::Vec<_0>); - } - } - pub mod bp_header_chain { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct StoredHeaderData<_0, _1> { - pub number: _0, - pub state_root: _1, - } - } - pub mod bp_messages { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct DeliveredMessages { - pub begin: ::core::primitive::u64, - pub end: ::core::primitive::u64, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct InboundLaneData<_0> { - pub relayers: ::std::vec::Vec>, - pub last_confirmed_nonce: ::core::primitive::u64, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct LaneId(pub [::core::primitive::u8; 4usize]); - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct MessageKey { - pub lane_id: runtime_types::bp_messages::LaneId, - pub nonce: ::core::primitive::u64, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum MessagesOperatingMode { - #[codec(index = 0)] - Basic(runtime_types::bp_runtime::BasicOperatingMode), - #[codec(index = 1)] - RejectingOutboundMessages, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct OutboundLaneData { - pub oldest_unpruned_nonce: ::core::primitive::u64, - pub latest_received_nonce: ::core::primitive::u64, - pub latest_generated_nonce: ::core::primitive::u64, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum ReceivalResult<_0> { - #[codec(index = 0)] - Dispatched(runtime_types::bp_runtime::messages::MessageDispatchResult<_0>), - #[codec(index = 1)] - InvalidNonce, - #[codec(index = 2)] - TooManyUnrewardedRelayers, - #[codec(index = 3)] - TooManyUnconfirmedMessages, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct ReceivedMessages<_0> { - pub lane: runtime_types::bp_messages::LaneId, - pub receive_results: ::std::vec::Vec<( - ::core::primitive::u64, - runtime_types::bp_messages::ReceivalResult<_0>, - )>, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct UnrewardedRelayer<_0> { - pub relayer: _0, - pub messages: runtime_types::bp_messages::DeliveredMessages, - } - } - pub mod bp_relayers { - use super::runtime_types; - pub mod registration { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Registration<_0, _1> { - pub valid_till: _0, - pub stake: _1, - } - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum RewardsAccountOwner { - #[codec(index = 0)] - ThisChain, - #[codec(index = 1)] - BridgedChain, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct RewardsAccountParams { - pub lane_id: runtime_types::bp_messages::LaneId, - pub bridged_chain_id: [::core::primitive::u8; 4usize], - pub owner: runtime_types::bp_relayers::RewardsAccountOwner, - } - } - pub mod bp_runtime { - use super::runtime_types; - pub mod messages { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct MessageDispatchResult<_0> { - pub unspent_weight: ::sp_weights::Weight, - pub dispatch_level_result: _0, - } - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum BasicOperatingMode { - #[codec(index = 0)] - Normal, - #[codec(index = 1)] - Halted, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct HeaderId<_0, _1>(pub _1, pub _0); - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum OwnedBridgeModuleError { - #[codec(index = 0)] - Halted, - } - } - pub mod bridge_runtime_common { - use super::runtime_types; - pub mod messages_xcm_extension { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum XcmBlobMessageDispatchResult { - #[codec(index = 0)] - InvalidPayload, - #[codec(index = 1)] - Dispatched, - #[codec(index = 2)] - NotDispatched, - } - } - } - pub mod cumulus_pallet_dmp_queue { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call { - #[codec(index = 0)] - service_overweight { - index: ::core::primitive::u64, - weight_limit: ::sp_weights::Weight, - }, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - Unknown, - #[codec(index = 1)] - OverLimit, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - #[codec(index = 0)] - InvalidFormat { message_id: [::core::primitive::u8; 32usize] }, - #[codec(index = 1)] - UnsupportedVersion { message_id: [::core::primitive::u8; 32usize] }, - #[codec(index = 2)] - ExecutedDownward { - message_id: [::core::primitive::u8; 32usize], - outcome: runtime_types::xcm::v3::traits::Outcome, - }, - #[codec(index = 3)] - WeightExhausted { - message_id: [::core::primitive::u8; 32usize], - remaining_weight: ::sp_weights::Weight, - required_weight: ::sp_weights::Weight, - }, - #[codec(index = 4)] - OverweightEnqueued { - message_id: [::core::primitive::u8; 32usize], - overweight_index: ::core::primitive::u64, - required_weight: ::sp_weights::Weight, - }, - #[codec(index = 5)] - OverweightServiced { - overweight_index: ::core::primitive::u64, - weight_used: ::sp_weights::Weight, - }, - #[codec(index = 6)] - MaxMessagesExhausted { message_id: [::core::primitive::u8; 32usize] }, - } - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct ConfigData { - pub max_individual: ::sp_weights::Weight, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct PageIndexData { - pub begin_used: ::core::primitive::u32, - pub end_used: ::core::primitive::u32, - pub overweight_count: ::core::primitive::u64, - } - } - pub mod cumulus_pallet_parachain_system { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call { - # [codec (index = 0)] set_validation_data { data : runtime_types :: cumulus_primitives_parachain_inherent :: ParachainInherentData , } , # [codec (index = 1)] sudo_send_upward_message { message : :: std :: vec :: Vec < :: core :: primitive :: u8 > , } , # [codec (index = 2)] authorize_upgrade { code_hash : :: subxt :: utils :: H256 , check_version : :: core :: primitive :: bool , } , # [codec (index = 3)] enact_authorized_upgrade { code : :: std :: vec :: Vec < :: core :: primitive :: u8 > , } , } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - OverlappingUpgrades, - #[codec(index = 1)] - ProhibitedByPolkadot, - #[codec(index = 2)] - TooBig, - #[codec(index = 3)] - ValidationDataNotAvailable, - #[codec(index = 4)] - HostConfigurationNotAvailable, - #[codec(index = 5)] - NotScheduled, - #[codec(index = 6)] - NothingAuthorized, - #[codec(index = 7)] - Unauthorized, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - #[codec(index = 0)] - ValidationFunctionStored, - #[codec(index = 1)] - ValidationFunctionApplied { relay_chain_block_num: ::core::primitive::u32 }, - #[codec(index = 2)] - ValidationFunctionDiscarded, - #[codec(index = 3)] - UpgradeAuthorized { code_hash: ::subxt::utils::H256 }, - #[codec(index = 4)] - DownwardMessagesReceived { count: ::core::primitive::u32 }, - #[codec(index = 5)] - DownwardMessagesProcessed { - weight_used: ::sp_weights::Weight, - dmq_head: ::subxt::utils::H256, - }, - #[codec(index = 6)] - UpwardMessageSent { - message_hash: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - } - } - pub mod relay_state_snapshot { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct MessagingStateSnapshot { - pub dmq_mqc_head: ::subxt::utils::H256, - pub relay_dispatch_queue_size: (::core::primitive::u32, ::core::primitive::u32), - pub ingress_channels: ::std::vec::Vec<( - runtime_types::polkadot_parachain::primitives::Id, - runtime_types::polkadot_primitives::v4::AbridgedHrmpChannel, - )>, - pub egress_channels: ::std::vec::Vec<( - runtime_types::polkadot_parachain::primitives::Id, - runtime_types::polkadot_primitives::v4::AbridgedHrmpChannel, - )>, - } - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct CodeUpgradeAuthorization { - pub code_hash: ::subxt::utils::H256, - pub check_version: ::core::primitive::bool, - } - } - pub mod cumulus_pallet_xcm { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call {} - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error {} - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - #[codec(index = 0)] - InvalidFormat([::core::primitive::u8; 32usize]), - #[codec(index = 1)] - UnsupportedVersion([::core::primitive::u8; 32usize]), - #[codec(index = 2)] - ExecutedDownward( - [::core::primitive::u8; 32usize], - runtime_types::xcm::v3::traits::Outcome, - ), - } - } - } - pub mod cumulus_pallet_xcmp_queue { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call { - #[codec(index = 0)] - service_overweight { - index: ::core::primitive::u64, - weight_limit: ::sp_weights::Weight, - }, - #[codec(index = 1)] - suspend_xcm_execution, - #[codec(index = 2)] - resume_xcm_execution, - #[codec(index = 3)] - update_suspend_threshold { new: ::core::primitive::u32 }, - #[codec(index = 4)] - update_drop_threshold { new: ::core::primitive::u32 }, - #[codec(index = 5)] - update_resume_threshold { new: ::core::primitive::u32 }, - #[codec(index = 6)] - update_threshold_weight { new: ::sp_weights::Weight }, - #[codec(index = 7)] - update_weight_restrict_decay { new: ::sp_weights::Weight }, - #[codec(index = 8)] - update_xcmp_max_individual_weight { new: ::sp_weights::Weight }, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - FailedToSend, - #[codec(index = 1)] - BadXcmOrigin, - #[codec(index = 2)] - BadXcm, - #[codec(index = 3)] - BadOverweightIndex, - #[codec(index = 4)] - WeightOverLimit, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - #[codec(index = 0)] - Success { - message_hash: ::core::option::Option<[::core::primitive::u8; 32usize]>, - weight: ::sp_weights::Weight, - }, - #[codec(index = 1)] - Fail { - message_hash: ::core::option::Option<[::core::primitive::u8; 32usize]>, - error: runtime_types::xcm::v3::traits::Error, - weight: ::sp_weights::Weight, - }, - #[codec(index = 2)] - BadVersion { - message_hash: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - #[codec(index = 3)] - BadFormat { - message_hash: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - #[codec(index = 4)] - XcmpMessageSent { - message_hash: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - #[codec(index = 5)] - OverweightEnqueued { - sender: runtime_types::polkadot_parachain::primitives::Id, - sent_at: ::core::primitive::u32, - index: ::core::primitive::u64, - required: ::sp_weights::Weight, - }, - #[codec(index = 6)] - OverweightServiced { index: ::core::primitive::u64, used: ::sp_weights::Weight }, - } - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct InboundChannelDetails { - pub sender: runtime_types::polkadot_parachain::primitives::Id, - pub state: runtime_types::cumulus_pallet_xcmp_queue::InboundState, - pub message_metadata: ::std::vec::Vec<( - ::core::primitive::u32, - runtime_types::polkadot_parachain::primitives::XcmpMessageFormat, - )>, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum InboundState { - #[codec(index = 0)] - Ok, - #[codec(index = 1)] - Suspended, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct OutboundChannelDetails { - pub recipient: runtime_types::polkadot_parachain::primitives::Id, - pub state: runtime_types::cumulus_pallet_xcmp_queue::OutboundState, - pub signals_exist: ::core::primitive::bool, - pub first_index: ::core::primitive::u16, - pub last_index: ::core::primitive::u16, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum OutboundState { - #[codec(index = 0)] - Ok, - #[codec(index = 1)] - Suspended, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct QueueConfigData { - pub suspend_threshold: ::core::primitive::u32, - pub drop_threshold: ::core::primitive::u32, - pub resume_threshold: ::core::primitive::u32, - pub threshold_weight: ::sp_weights::Weight, - pub weight_restrict_decay: ::sp_weights::Weight, - pub xcmp_max_individual_weight: ::sp_weights::Weight, - } - } - pub mod cumulus_primitives_parachain_inherent { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct MessageQueueChain(pub ::subxt::utils::H256); - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct ParachainInherentData { - pub validation_data: - runtime_types::polkadot_primitives::v4::PersistedValidationData< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - pub relay_chain_state: runtime_types::sp_trie::storage_proof::StorageProof, - pub downward_messages: ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundDownwardMessage< - ::core::primitive::u32, - >, - >, - pub horizontal_messages: ::subxt::utils::KeyedVec< - runtime_types::polkadot_parachain::primitives::Id, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundHrmpMessage< - ::core::primitive::u32, - >, - >, - >, - } - } - pub mod finality_grandpa { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Commit<_0, _1, _2, _3> { - pub target_hash: _0, - pub target_number: _1, - pub precommits: ::std::vec::Vec< - runtime_types::finality_grandpa::SignedPrecommit<_0, _1, _2, _3>, - >, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Precommit<_0, _1> { - pub target_hash: _0, - pub target_number: _1, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct SignedPrecommit<_0, _1, _2, _3> { - pub precommit: runtime_types::finality_grandpa::Precommit<_0, _1>, - pub signature: _2, - pub id: _3, - } - } - pub mod frame_support { - use super::runtime_types; - pub mod dispatch { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum DispatchClass { - #[codec(index = 0)] - Normal, - #[codec(index = 1)] - Operational, - #[codec(index = 2)] - Mandatory, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct DispatchInfo { - pub weight: ::sp_weights::Weight, - pub class: runtime_types::frame_support::dispatch::DispatchClass, - pub pays_fee: runtime_types::frame_support::dispatch::Pays, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Pays { - #[codec(index = 0)] - Yes, - #[codec(index = 1)] - No, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct PerDispatchClass<_0> { - pub normal: _0, - pub operational: _0, - pub mandatory: _0, - } - } - pub mod traits { - use super::runtime_types; - pub mod tokens { - use super::runtime_types; - pub mod misc { - use super::runtime_types; - #[derive( - :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, - )] - pub enum BalanceStatus { - #[codec(index = 0)] - Free, - #[codec(index = 1)] - Reserved, - } - } - } - } - } - pub mod frame_system { - use super::runtime_types; - pub mod extensions { - use super::runtime_types; - pub mod check_genesis { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct CheckGenesis; - } - pub mod check_mortality { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct CheckMortality(pub ::sp_runtime::generic::Era); - } - pub mod check_non_zero_sender { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct CheckNonZeroSender; - } - pub mod check_nonce { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct CheckNonce(#[codec(compact)] pub ::core::primitive::u32); - } - pub mod check_spec_version { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct CheckSpecVersion; - } - pub mod check_tx_version { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct CheckTxVersion; - } - pub mod check_weight { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct CheckWeight; - } - } - pub mod limits { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct BlockLength { - pub max: runtime_types::frame_support::dispatch::PerDispatchClass< - ::core::primitive::u32, - >, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct BlockWeights { - pub base_block: ::sp_weights::Weight, - pub max_block: ::sp_weights::Weight, - pub per_class: runtime_types::frame_support::dispatch::PerDispatchClass< - runtime_types::frame_system::limits::WeightsPerClass, - >, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct WeightsPerClass { - pub base_extrinsic: ::sp_weights::Weight, - pub max_extrinsic: ::core::option::Option<::sp_weights::Weight>, - pub max_total: ::core::option::Option<::sp_weights::Weight>, - pub reserved: ::core::option::Option<::sp_weights::Weight>, - } - } - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call { - #[codec(index = 0)] - remark { remark: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 1)] - set_heap_pages { pages: ::core::primitive::u64 }, - #[codec(index = 2)] - set_code { code: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 3)] - set_code_without_checks { code: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 4)] - set_storage { - items: ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - ::std::vec::Vec<::core::primitive::u8>, - )>, - }, - #[codec(index = 5)] - kill_storage { keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>> }, - #[codec(index = 6)] - kill_prefix { - prefix: ::std::vec::Vec<::core::primitive::u8>, - subkeys: ::core::primitive::u32, - }, - #[codec(index = 7)] - remark_with_event { remark: ::std::vec::Vec<::core::primitive::u8> }, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - InvalidSpecName, - #[codec(index = 1)] - SpecVersionNeedsToIncrease, - #[codec(index = 2)] - FailedToExtractRuntimeVersion, - #[codec(index = 3)] - NonDefaultComposite, - #[codec(index = 4)] - NonZeroRefCount, - #[codec(index = 5)] - CallFiltered, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - #[codec(index = 0)] - ExtrinsicSuccess { - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 1)] - ExtrinsicFailed { - dispatch_error: runtime_types::sp_runtime::DispatchError, - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 2)] - CodeUpdated, - #[codec(index = 3)] - NewAccount { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 4)] - KilledAccount { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 5)] - Remarked { sender: ::sp_core::crypto::AccountId32, hash: ::subxt::utils::H256 }, - } - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct AccountInfo<_0, _1> { - pub nonce: _0, - pub consumers: _0, - pub providers: _0, - pub sufficients: _0, - pub data: _1, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct EventRecord<_0, _1> { - pub phase: runtime_types::frame_system::Phase, - pub event: _0, - pub topics: ::std::vec::Vec<_1>, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct LastRuntimeUpgradeInfo { - #[codec(compact)] - pub spec_version: ::core::primitive::u32, - pub spec_name: ::std::string::String, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Phase { - #[codec(index = 0)] - ApplyExtrinsic(::core::primitive::u32), - #[codec(index = 1)] - Finalization, - #[codec(index = 2)] - Initialization, - } - } - pub mod pallet_balances { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call { - #[codec(index = 0)] - transfer_allow_death { - dest: ::subxt::utils::MultiAddress<::sp_core::crypto::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 1)] - set_balance_deprecated { - who: ::subxt::utils::MultiAddress<::sp_core::crypto::AccountId32, ()>, - #[codec(compact)] - new_free: ::core::primitive::u128, - #[codec(compact)] - old_reserved: ::core::primitive::u128, - }, - #[codec(index = 2)] - force_transfer { - source: ::subxt::utils::MultiAddress<::sp_core::crypto::AccountId32, ()>, - dest: ::subxt::utils::MultiAddress<::sp_core::crypto::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 3)] - transfer_keep_alive { - dest: ::subxt::utils::MultiAddress<::sp_core::crypto::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 4)] - transfer_all { - dest: ::subxt::utils::MultiAddress<::sp_core::crypto::AccountId32, ()>, - keep_alive: ::core::primitive::bool, - }, - #[codec(index = 5)] - force_unreserve { - who: ::subxt::utils::MultiAddress<::sp_core::crypto::AccountId32, ()>, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - upgrade_accounts { who: ::std::vec::Vec<::sp_core::crypto::AccountId32> }, - #[codec(index = 7)] - transfer { - dest: ::subxt::utils::MultiAddress<::sp_core::crypto::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 8)] - force_set_balance { - who: ::subxt::utils::MultiAddress<::sp_core::crypto::AccountId32, ()>, - #[codec(compact)] - new_free: ::core::primitive::u128, - }, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - VestingBalance, - #[codec(index = 1)] - LiquidityRestrictions, - #[codec(index = 2)] - InsufficientBalance, - #[codec(index = 3)] - ExistentialDeposit, - #[codec(index = 4)] - Expendability, - #[codec(index = 5)] - ExistingVestingSchedule, - #[codec(index = 6)] - DeadAccount, - #[codec(index = 7)] - TooManyReserves, - #[codec(index = 8)] - TooManyHolds, - #[codec(index = 9)] - TooManyFreezes, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - #[codec(index = 0)] - Endowed { - account: ::sp_core::crypto::AccountId32, - free_balance: ::core::primitive::u128, - }, - #[codec(index = 1)] - DustLost { - account: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - Transfer { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - BalanceSet { - who: ::sp_core::crypto::AccountId32, - free: ::core::primitive::u128, - }, - #[codec(index = 4)] - Reserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - Unreserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - ReserveRepatriated { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - }, - #[codec(index = 7)] - Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 8)] - Withdraw { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 9)] - Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 10)] - Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 11)] - Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 12)] - Suspended { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 13)] - Restored { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 14)] - Upgraded { who: ::sp_core::crypto::AccountId32 }, - #[codec(index = 15)] - Issued { amount: ::core::primitive::u128 }, - #[codec(index = 16)] - Rescinded { amount: ::core::primitive::u128 }, - #[codec(index = 17)] - Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 18)] - Unlocked { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - } - } - pub mod types { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct AccountData<_0> { - pub free: _0, - pub reserved: _0, - pub frozen: _0, - pub flags: runtime_types::pallet_balances::types::ExtraFlags, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct BalanceLock<_0> { - pub id: [::core::primitive::u8; 8usize], - pub amount: _0, - pub reasons: runtime_types::pallet_balances::types::Reasons, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - )] - pub struct ExtraFlags(pub ::core::primitive::u128); - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct IdAmount<_0, _1> { - pub id: _0, - pub amount: _1, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Reasons { - #[codec(index = 0)] - Fee, - #[codec(index = 1)] - Misc, - #[codec(index = 2)] - All, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct ReserveData<_0, _1> { - pub id: _0, - pub amount: _1, - } - } - } - pub mod pallet_bridge_grandpa { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call { - #[codec(index = 0)] - submit_finality_proof { - finality_target: ::std::boxed::Box< - ::sp_runtime::generic::Header< - ::core::primitive::u64, - ::bp_millau::BlakeTwoAndKeccak256, - >, - >, - justification: ::bp_header_chain::justification::GrandpaJustification< - ::sp_runtime::generic::Header< - ::core::primitive::u64, - ::bp_millau::BlakeTwoAndKeccak256, - >, - >, - }, - #[codec(index = 1)] - initialize { - init_data: ::bp_header_chain::InitializationData< - ::sp_runtime::generic::Header< - ::core::primitive::u64, - ::bp_millau::BlakeTwoAndKeccak256, - >, - >, - }, - #[codec(index = 2)] - set_owner { new_owner: ::core::option::Option<::sp_core::crypto::AccountId32> }, - #[codec(index = 3)] - set_operating_mode { - operating_mode: runtime_types::bp_runtime::BasicOperatingMode, - }, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - InvalidJustification, - #[codec(index = 1)] - InvalidAuthoritySet, - #[codec(index = 2)] - OldHeader, - #[codec(index = 3)] - UnsupportedScheduledChange, - #[codec(index = 4)] - NotInitialized, - #[codec(index = 5)] - AlreadyInitialized, - #[codec(index = 6)] - TooManyAuthoritiesInSet, - #[codec(index = 7)] - BridgeModule(runtime_types::bp_runtime::OwnedBridgeModuleError), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - #[codec(index = 0)] - UpdatedBestFinalizedHeader { - number: ::core::primitive::u64, - hash: ::bp_millau::MillauHash, - }, - } - } - pub mod storage_types { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct StoredAuthoritySet { - pub authorities: runtime_types::bounded_collections::bounded_vec::BoundedVec<( - runtime_types::sp_consensus_grandpa::app::Public, - ::core::primitive::u64, - )>, - pub set_id: ::core::primitive::u64, - } - } - } - pub mod pallet_bridge_messages { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call { - # [codec (index = 0)] set_owner { new_owner : :: core :: option :: Option < :: sp_core :: crypto :: AccountId32 > , } , # [codec (index = 1)] set_operating_mode { operating_mode : runtime_types :: bp_messages :: MessagesOperatingMode , } , # [codec (index = 2)] receive_messages_proof { relayer_id_at_bridged_chain : :: sp_core :: crypto :: AccountId32 , proof : :: bridge_runtime_common :: messages :: target :: FromBridgedChainMessagesProof < :: bp_millau :: MillauHash > , messages_count : :: core :: primitive :: u32 , dispatch_weight : :: sp_weights :: Weight , } , # [codec (index = 3)] receive_messages_delivery_proof { proof : :: bridge_runtime_common :: messages :: source :: FromBridgedChainMessagesDeliveryProof < :: bp_millau :: MillauHash > , relayers_state : :: bp_messages :: UnrewardedRelayersState , } , } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - NotOperatingNormally, - #[codec(index = 1)] - InactiveOutboundLane, - #[codec(index = 2)] - MessageIsTooLarge, - #[codec(index = 3)] - MessageRejectedByChainVerifier, - #[codec(index = 4)] - MessageRejectedByLaneVerifier, - #[codec(index = 5)] - FailedToWithdrawMessageFee, - #[codec(index = 6)] - TooManyMessagesInTheProof, - #[codec(index = 7)] - InvalidMessagesProof, - #[codec(index = 8)] - InvalidMessagesDeliveryProof, - #[codec(index = 9)] - InvalidUnrewardedRelayers, - #[codec(index = 10)] - InvalidUnrewardedRelayersState, - #[codec(index = 11)] - InsufficientDispatchWeight, - #[codec(index = 12)] - MessageIsNotYetSent, - #[codec(index = 13)] - TryingToConfirmMoreMessagesThanExpected, - #[codec(index = 14)] - BridgeModule(runtime_types::bp_runtime::OwnedBridgeModuleError), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - # [codec (index = 0)] MessageAccepted { lane_id : runtime_types :: bp_messages :: LaneId , nonce : :: core :: primitive :: u64 , } , # [codec (index = 1)] MessagesReceived (:: std :: vec :: Vec < runtime_types :: bp_messages :: ReceivedMessages < runtime_types :: bridge_runtime_common :: messages_xcm_extension :: XcmBlobMessageDispatchResult > > ,) , # [codec (index = 2)] MessagesDelivered { lane_id : runtime_types :: bp_messages :: LaneId , messages : runtime_types :: bp_messages :: DeliveredMessages , } , } - } - } - pub mod pallet_bridge_relayers { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call { - #[codec(index = 0)] - claim_rewards { - rewards_account_params: runtime_types::bp_relayers::RewardsAccountParams, - }, - #[codec(index = 1)] - register { valid_till: ::core::primitive::u32 }, - #[codec(index = 2)] - deregister, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - NoRewardForRelayer, - #[codec(index = 1)] - FailedToPayReward, - #[codec(index = 2)] - InvalidRegistrationLease, - #[codec(index = 3)] - CannotReduceRegistrationLease, - #[codec(index = 4)] - FailedToReserve, - #[codec(index = 5)] - FailedToUnreserve, - #[codec(index = 6)] - NotRegistered, - #[codec(index = 7)] - RegistrationIsStillActive, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - #[codec(index = 0)] - RewardPaid { - relayer: ::sp_core::crypto::AccountId32, - rewards_account_params: runtime_types::bp_relayers::RewardsAccountParams, - reward: ::core::primitive::u128, - }, - #[codec(index = 1)] - RegistrationUpdated { - relayer: ::sp_core::crypto::AccountId32, - registration: runtime_types::bp_relayers::registration::Registration< - ::core::primitive::u32, - ::core::primitive::u128, - >, - }, - #[codec(index = 2)] - Deregistered { relayer: ::sp_core::crypto::AccountId32 }, - #[codec(index = 3)] - SlashedAndDeregistered { - relayer: ::sp_core::crypto::AccountId32, - registration: runtime_types::bp_relayers::registration::Registration< - ::core::primitive::u32, - ::core::primitive::u128, - >, - }, - } - } - } - pub mod pallet_sudo { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call { - #[codec(index = 0)] - sudo { - call: - ::std::boxed::Box, - }, - #[codec(index = 1)] - sudo_unchecked_weight { - call: - ::std::boxed::Box, - weight: ::sp_weights::Weight, - }, - #[codec(index = 2)] - set_key { - new: ::subxt::utils::MultiAddress<::sp_core::crypto::AccountId32, ()>, - }, - #[codec(index = 3)] - sudo_as { - who: ::subxt::utils::MultiAddress<::sp_core::crypto::AccountId32, ()>, - call: - ::std::boxed::Box, - }, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - RequireSudo, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - #[codec(index = 0)] - Sudid { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 1)] - KeyChanged { - old_sudoer: ::core::option::Option<::sp_core::crypto::AccountId32>, - }, - #[codec(index = 2)] - SudoAsDone { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - } - } - } - pub mod pallet_timestamp { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call { - #[codec(index = 0)] - set { - #[codec(compact)] - now: ::core::primitive::u64, - }, - } - } - } - pub mod pallet_transaction_payment { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - #[codec(index = 0)] - TransactionFeePaid { - who: ::sp_core::crypto::AccountId32, - actual_fee: ::core::primitive::u128, - tip: ::core::primitive::u128, - }, - } - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct ChargeTransactionPayment(#[codec(compact)] pub ::core::primitive::u128); - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Releases { - #[codec(index = 0)] - V1Ancient, - #[codec(index = 1)] - V2, - } - } - pub mod pallet_xcm { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Call { - #[codec(index = 0)] - send { - dest: ::std::boxed::Box, - message: ::std::boxed::Box, - }, - #[codec(index = 1)] - teleport_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - }, - #[codec(index = 2)] - reserve_transfer_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - }, - #[codec(index = 3)] - execute { - message: ::std::boxed::Box, - max_weight: ::sp_weights::Weight, - }, - #[codec(index = 4)] - force_xcm_version { - location: - ::std::boxed::Box, - xcm_version: ::core::primitive::u32, - }, - #[codec(index = 5)] - force_default_xcm_version { - maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, - }, - #[codec(index = 6)] - force_subscribe_version_notify { - location: ::std::boxed::Box, - }, - #[codec(index = 7)] - force_unsubscribe_version_notify { - location: ::std::boxed::Box, - }, - #[codec(index = 8)] - limited_reserve_transfer_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 9)] - limited_teleport_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - Unreachable, - #[codec(index = 1)] - SendFailure, - #[codec(index = 2)] - Filtered, - #[codec(index = 3)] - UnweighableMessage, - #[codec(index = 4)] - DestinationNotInvertible, - #[codec(index = 5)] - Empty, - #[codec(index = 6)] - CannotReanchor, - #[codec(index = 7)] - TooManyAssets, - #[codec(index = 8)] - InvalidOrigin, - #[codec(index = 9)] - BadVersion, - #[codec(index = 10)] - BadLocation, - #[codec(index = 11)] - NoSubscription, - #[codec(index = 12)] - AlreadySubscribed, - #[codec(index = 13)] - InvalidAsset, - #[codec(index = 14)] - LowBalance, - #[codec(index = 15)] - TooManyLocks, - #[codec(index = 16)] - AccountNotSovereign, - #[codec(index = 17)] - FeesNotMet, - #[codec(index = 18)] - LockNotFound, - #[codec(index = 19)] - InUse, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Event { - #[codec(index = 0)] - Attempted(runtime_types::xcm::v3::traits::Outcome), - #[codec(index = 1)] - Sent( - runtime_types::xcm::v3::multilocation::MultiLocation, - runtime_types::xcm::v3::multilocation::MultiLocation, - runtime_types::xcm::v3::Xcm, - ), - #[codec(index = 2)] - UnexpectedResponse( - runtime_types::xcm::v3::multilocation::MultiLocation, - ::core::primitive::u64, - ), - #[codec(index = 3)] - ResponseReady(::core::primitive::u64, runtime_types::xcm::v3::Response), - #[codec(index = 4)] - Notified(::core::primitive::u64, ::core::primitive::u8, ::core::primitive::u8), - #[codec(index = 5)] - NotifyOverweight( - ::core::primitive::u64, - ::core::primitive::u8, - ::core::primitive::u8, - ::sp_weights::Weight, - ::sp_weights::Weight, - ), - #[codec(index = 6)] - NotifyDispatchError( - ::core::primitive::u64, - ::core::primitive::u8, - ::core::primitive::u8, - ), - #[codec(index = 7)] - NotifyDecodeFailed( - ::core::primitive::u64, - ::core::primitive::u8, - ::core::primitive::u8, - ), - #[codec(index = 8)] - InvalidResponder( - runtime_types::xcm::v3::multilocation::MultiLocation, - ::core::primitive::u64, - ::core::option::Option< - runtime_types::xcm::v3::multilocation::MultiLocation, - >, - ), - #[codec(index = 9)] - InvalidResponderVersion( - runtime_types::xcm::v3::multilocation::MultiLocation, - ::core::primitive::u64, - ), - #[codec(index = 10)] - ResponseTaken(::core::primitive::u64), - #[codec(index = 11)] - AssetsTrapped( - ::subxt::utils::H256, - runtime_types::xcm::v3::multilocation::MultiLocation, - runtime_types::xcm::VersionedMultiAssets, - ), - #[codec(index = 12)] - VersionChangeNotified( - runtime_types::xcm::v3::multilocation::MultiLocation, - ::core::primitive::u32, - runtime_types::xcm::v3::multiasset::MultiAssets, - ), - #[codec(index = 13)] - SupportedVersionChanged( - runtime_types::xcm::v3::multilocation::MultiLocation, - ::core::primitive::u32, - ), - #[codec(index = 14)] - NotifyTargetSendFail( - runtime_types::xcm::v3::multilocation::MultiLocation, - ::core::primitive::u64, - runtime_types::xcm::v3::traits::Error, - ), - #[codec(index = 15)] - NotifyTargetMigrationFail( - runtime_types::xcm::VersionedMultiLocation, - ::core::primitive::u64, - ), - #[codec(index = 16)] - InvalidQuerierVersion( - runtime_types::xcm::v3::multilocation::MultiLocation, - ::core::primitive::u64, - ), - #[codec(index = 17)] - InvalidQuerier( - runtime_types::xcm::v3::multilocation::MultiLocation, - ::core::primitive::u64, - runtime_types::xcm::v3::multilocation::MultiLocation, - ::core::option::Option< - runtime_types::xcm::v3::multilocation::MultiLocation, - >, - ), - #[codec(index = 18)] - VersionNotifyStarted( - runtime_types::xcm::v3::multilocation::MultiLocation, - runtime_types::xcm::v3::multiasset::MultiAssets, - ), - #[codec(index = 19)] - VersionNotifyRequested( - runtime_types::xcm::v3::multilocation::MultiLocation, - runtime_types::xcm::v3::multiasset::MultiAssets, - ), - #[codec(index = 20)] - VersionNotifyUnrequested( - runtime_types::xcm::v3::multilocation::MultiLocation, - runtime_types::xcm::v3::multiasset::MultiAssets, - ), - #[codec(index = 21)] - FeesPaid( - runtime_types::xcm::v3::multilocation::MultiLocation, - runtime_types::xcm::v3::multiasset::MultiAssets, - ), - #[codec(index = 22)] - AssetsClaimed( - ::subxt::utils::H256, - runtime_types::xcm::v3::multilocation::MultiLocation, - runtime_types::xcm::VersionedMultiAssets, - ), - } - } - } - pub mod polkadot_core_primitives { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct InboundDownwardMessage<_0> { - pub sent_at: _0, - pub msg: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct InboundHrmpMessage<_0> { - pub sent_at: _0, - pub data: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct OutboundHrmpMessage<_0> { - pub recipient: _0, - pub data: ::std::vec::Vec<::core::primitive::u8>, - } - } - pub mod polkadot_parachain { - use super::runtime_types; - pub mod primitives { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct HeadData(pub ::std::vec::Vec<::core::primitive::u8>); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - )] - pub struct Id(pub ::core::primitive::u32); - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum XcmpMessageFormat { - #[codec(index = 0)] - ConcatenatedVersionedXcm, - #[codec(index = 1)] - ConcatenatedEncodedBlob, - #[codec(index = 2)] - Signals, - } - } - } - pub mod polkadot_primitives { - use super::runtime_types; - pub mod v4 { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct AbridgedHostConfiguration { - pub max_code_size: ::core::primitive::u32, - pub max_head_data_size: ::core::primitive::u32, - pub max_upward_queue_count: ::core::primitive::u32, - pub max_upward_queue_size: ::core::primitive::u32, - pub max_upward_message_size: ::core::primitive::u32, - pub max_upward_message_num_per_candidate: ::core::primitive::u32, - pub hrmp_max_message_num_per_candidate: ::core::primitive::u32, - pub validation_upgrade_cooldown: ::core::primitive::u32, - pub validation_upgrade_delay: ::core::primitive::u32, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct AbridgedHrmpChannel { - pub max_capacity: ::core::primitive::u32, - pub max_total_size: ::core::primitive::u32, - pub max_message_size: ::core::primitive::u32, - pub msg_count: ::core::primitive::u32, - pub total_size: ::core::primitive::u32, - pub mqc_head: ::core::option::Option<::subxt::utils::H256>, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct PersistedValidationData<_0, _1> { - pub parent_head: runtime_types::polkadot_parachain::primitives::HeadData, - pub relay_parent_number: _1, - pub relay_parent_storage_root: _0, - pub max_pov_size: _1, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum UpgradeRestriction { - #[codec(index = 0)] - Present, - } - } - } - pub mod rialto_parachain_runtime { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct BridgeRejectObsoleteHeadersAndMessages; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct DummyBridgeRefundMillauMessages; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Runtime; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum RuntimeCall { - #[codec(index = 0)] - System(runtime_types::frame_system::pallet::Call), - #[codec(index = 1)] - Timestamp(runtime_types::pallet_timestamp::pallet::Call), - #[codec(index = 2)] - Sudo(runtime_types::pallet_sudo::pallet::Call), - #[codec(index = 20)] - ParachainSystem(runtime_types::cumulus_pallet_parachain_system::pallet::Call), - #[codec(index = 30)] - Balances(runtime_types::pallet_balances::pallet::Call), - #[codec(index = 50)] - XcmpQueue(runtime_types::cumulus_pallet_xcmp_queue::pallet::Call), - #[codec(index = 51)] - PolkadotXcm(runtime_types::pallet_xcm::pallet::Call), - #[codec(index = 52)] - CumulusXcm(runtime_types::cumulus_pallet_xcm::pallet::Call), - #[codec(index = 53)] - DmpQueue(runtime_types::cumulus_pallet_dmp_queue::pallet::Call), - #[codec(index = 54)] - BridgeRelayers(runtime_types::pallet_bridge_relayers::pallet::Call), - #[codec(index = 55)] - BridgeMillauGrandpa(runtime_types::pallet_bridge_grandpa::pallet::Call), - #[codec(index = 56)] - BridgeMillauMessages(runtime_types::pallet_bridge_messages::pallet::Call), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum RuntimeEvent { - #[codec(index = 0)] - System(runtime_types::frame_system::pallet::Event), - #[codec(index = 2)] - Sudo(runtime_types::pallet_sudo::pallet::Event), - #[codec(index = 3)] - TransactionPayment(runtime_types::pallet_transaction_payment::pallet::Event), - #[codec(index = 20)] - ParachainSystem(runtime_types::cumulus_pallet_parachain_system::pallet::Event), - #[codec(index = 30)] - Balances(runtime_types::pallet_balances::pallet::Event), - #[codec(index = 50)] - XcmpQueue(runtime_types::cumulus_pallet_xcmp_queue::pallet::Event), - #[codec(index = 51)] - PolkadotXcm(runtime_types::pallet_xcm::pallet::Event), - #[codec(index = 52)] - CumulusXcm(runtime_types::cumulus_pallet_xcm::pallet::Event), - #[codec(index = 53)] - DmpQueue(runtime_types::cumulus_pallet_dmp_queue::pallet::Event), - #[codec(index = 54)] - BridgeRelayers(runtime_types::pallet_bridge_relayers::pallet::Event), - #[codec(index = 55)] - BridgeMillauGrandpa(runtime_types::pallet_bridge_grandpa::pallet::Event), - #[codec(index = 56)] - BridgeMillauMessages(runtime_types::pallet_bridge_messages::pallet::Event), - } - } - pub mod sp_arithmetic { - use super::runtime_types; - pub mod fixed_point { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - )] - pub struct FixedU128(pub ::core::primitive::u128); - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum ArithmeticError { - #[codec(index = 0)] - Underflow, - #[codec(index = 1)] - Overflow, - #[codec(index = 2)] - DivisionByZero, - } - } - pub mod sp_consensus_grandpa { - use super::runtime_types; - pub mod app { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Public(pub runtime_types::sp_core::ed25519::Public); - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Signature(pub runtime_types::sp_core::ed25519::Signature); - } - } - pub mod sp_core { - use super::runtime_types; - pub mod ecdsa { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Signature(pub [::core::primitive::u8; 65usize]); - } - pub mod ed25519 { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Public(pub [::core::primitive::u8; 32usize]); - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - pub mod sr25519 { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - } - pub mod sp_runtime { - use super::runtime_types; - pub mod generic { - use super::runtime_types; - pub mod digest { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum DigestItem { - #[codec(index = 6)] - PreRuntime( - [::core::primitive::u8; 4usize], - ::std::vec::Vec<::core::primitive::u8>, - ), - #[codec(index = 4)] - Consensus( - [::core::primitive::u8; 4usize], - ::std::vec::Vec<::core::primitive::u8>, - ), - #[codec(index = 5)] - Seal( - [::core::primitive::u8; 4usize], - ::std::vec::Vec<::core::primitive::u8>, - ), - #[codec(index = 0)] - Other(::std::vec::Vec<::core::primitive::u8>), - #[codec(index = 8)] - RuntimeEnvironmentUpdated, - } - } - pub mod unchecked_extrinsic { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct UncheckedExtrinsic<_0, _1, _2, _3>( - pub ::std::vec::Vec<::core::primitive::u8>, - #[codec(skip)] pub ::core::marker::PhantomData<(_1, _0, _2, _3)>, - ); - } - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum DispatchError { - #[codec(index = 0)] - Other, - #[codec(index = 1)] - CannotLookup, - #[codec(index = 2)] - BadOrigin, - #[codec(index = 3)] - Module(runtime_types::sp_runtime::ModuleError), - #[codec(index = 4)] - ConsumerRemaining, - #[codec(index = 5)] - NoProviders, - #[codec(index = 6)] - TooManyConsumers, - #[codec(index = 7)] - Token(runtime_types::sp_runtime::TokenError), - #[codec(index = 8)] - Arithmetic(runtime_types::sp_arithmetic::ArithmeticError), - #[codec(index = 9)] - Transactional(runtime_types::sp_runtime::TransactionalError), - #[codec(index = 10)] - Exhausted, - #[codec(index = 11)] - Corruption, - #[codec(index = 12)] - Unavailable, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct ModuleError { - pub index: ::core::primitive::u8, - pub error: [::core::primitive::u8; 4usize], - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum MultiSignature { - #[codec(index = 0)] - Ed25519(runtime_types::sp_core::ed25519::Signature), - #[codec(index = 1)] - Sr25519(runtime_types::sp_core::sr25519::Signature), - #[codec(index = 2)] - Ecdsa(runtime_types::sp_core::ecdsa::Signature), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum TokenError { - #[codec(index = 0)] - FundsUnavailable, - #[codec(index = 1)] - OnlyProvider, - #[codec(index = 2)] - BelowMinimum, - #[codec(index = 3)] - CannotCreate, - #[codec(index = 4)] - UnknownAsset, - #[codec(index = 5)] - Frozen, - #[codec(index = 6)] - Unsupported, - #[codec(index = 7)] - CannotCreateHold, - #[codec(index = 8)] - NotExpendable, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum TransactionalError { - #[codec(index = 0)] - LimitReached, - #[codec(index = 1)] - NoLayer, - } - } - pub mod sp_trie { - use super::runtime_types; - pub mod storage_proof { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct StorageProof { - pub trie_nodes: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - } - } - } - pub mod sp_version { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct RuntimeVersion { - pub spec_name: ::std::string::String, - pub impl_name: ::std::string::String, - pub authoring_version: ::core::primitive::u32, - pub spec_version: ::core::primitive::u32, - pub impl_version: ::core::primitive::u32, - pub apis: - ::std::vec::Vec<([::core::primitive::u8; 8usize], ::core::primitive::u32)>, - pub transaction_version: ::core::primitive::u32, - pub state_version: ::core::primitive::u8, - } - } - pub mod sp_weights { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct RuntimeDbWeight { - pub read: ::core::primitive::u64, - pub write: ::core::primitive::u64, - } - } - pub mod xcm { - use super::runtime_types; - pub mod double_encoded { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct DoubleEncoded { - pub encoded: ::std::vec::Vec<::core::primitive::u8>, - } - } - pub mod v2 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: runtime_types::xcm::v2::NetworkId, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: runtime_types::xcm::v2::NetworkId, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: runtime_types::xcm::v2::NetworkId, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::xcm::v2::BodyId, - part: runtime_types::xcm::v2::BodyPart, - }, - } - } - pub mod multiasset { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::xcm::v2::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract(::std::vec::Vec<::core::primitive::u8>), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - #[codec(index = 6)] - Blob(::std::vec::Vec<::core::primitive::u8>), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::xcm::v2::multiasset::AssetInstance), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct MultiAsset { - pub id: runtime_types::xcm::v2::multiasset::AssetId, - pub fun: runtime_types::xcm::v2::multiasset::Fungibility, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::xcm::v2::multiasset::WildMultiAsset), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct MultiAssets( - pub ::std::vec::Vec, - ); - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::xcm::v2::multiasset::AssetId, - fun: runtime_types::xcm::v2::multiasset::WildFungibility, - }, - } - } - pub mod multilocation { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::xcm::v2::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::xcm::v2::multilocation::Junctions, - } - } - pub mod traits { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - MultiLocationFull, - #[codec(index = 5)] - MultiLocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - UnhandledXcmVersion, - #[codec(index = 23)] - WeightLimitReached(::core::primitive::u64), - #[codec(index = 24)] - Barrier, - #[codec(index = 25)] - WeightNotComputable, - } - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::xcm::v2::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::xcm::v2::multilocation::Junctions), - #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - receive: runtime_types::xcm::v2::multiasset::MultiAssets, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - reserve: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::xcm::v2::multiasset::MultiAsset, - weight_limit: runtime_types::xcm::v2::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::xcm::v2::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::xcm::v2::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - ticket: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 27)] - UnsubscribeVersion, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum NetworkId { - #[codec(index = 0)] - Any, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum OriginKind { - #[codec(index = 0)] - Native, - #[codec(index = 1)] - SovereignAccount, - #[codec(index = 2)] - Superuser, - #[codec(index = 3)] - Xcm, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v2::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(#[codec(compact)] ::core::primitive::u64), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Xcm(pub ::std::vec::Vec); - } - pub mod v3 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Moniker([::core::primitive::u8; 4usize]), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: - ::core::option::Option, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: - ::core::option::Option, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: - ::core::option::Option, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey { - length: ::core::primitive::u8, - data: [::core::primitive::u8; 32usize], - }, - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::xcm::v3::junction::BodyId, - part: runtime_types::xcm::v3::junction::BodyPart, - }, - #[codec(index = 9)] - GlobalConsensus(runtime_types::xcm::v3::junction::NetworkId), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum NetworkId { - #[codec(index = 0)] - ByGenesis([::core::primitive::u8; 32usize]), - #[codec(index = 1)] - ByFork { - block_number: ::core::primitive::u64, - block_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - #[codec(index = 4)] - Westend, - #[codec(index = 5)] - Rococo, - #[codec(index = 6)] - Wococo, - #[codec(index = 7)] - Ethereum { - #[codec(compact)] - chain_id: ::core::primitive::u64, - }, - #[codec(index = 8)] - BitcoinCore, - #[codec(index = 9)] - BitcoinCash, - } - } - pub mod junctions { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::xcm::v3::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - } - } - pub mod multiasset { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::xcm::v3::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract([::core::primitive::u8; 32usize]), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::xcm::v3::multiasset::AssetInstance), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct MultiAsset { - pub id: runtime_types::xcm::v3::multiasset::AssetId, - pub fun: runtime_types::xcm::v3::multiasset::Fungibility, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::xcm::v3::multiasset::WildMultiAsset), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct MultiAssets( - pub ::std::vec::Vec, - ); - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::xcm::v3::multiasset::AssetId, - fun: runtime_types::xcm::v3::multiasset::WildFungibility, - }, - #[codec(index = 2)] - AllCounted(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - AllOfCounted { - id: runtime_types::xcm::v3::multiasset::AssetId, - fun: runtime_types::xcm::v3::multiasset::WildFungibility, - #[codec(compact)] - count: ::core::primitive::u32, - }, - } - } - pub mod multilocation { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::xcm::v3::junctions::Junctions, - } - } - pub mod traits { - use super::runtime_types; - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - LocationFull, - #[codec(index = 5)] - LocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - ExpectationFalse, - #[codec(index = 23)] - PalletNotFound, - #[codec(index = 24)] - NameMismatch, - #[codec(index = 25)] - VersionIncompatible, - #[codec(index = 26)] - HoldingWouldOverflow, - #[codec(index = 27)] - ExportError, - #[codec(index = 28)] - ReanchorFailed, - #[codec(index = 29)] - NoDeal, - #[codec(index = 30)] - FeesNotMet, - #[codec(index = 31)] - LockError, - #[codec(index = 32)] - NoPermission, - #[codec(index = 33)] - Unanchored, - #[codec(index = 34)] - NotDepositable, - #[codec(index = 35)] - UnhandledXcmVersion, - #[codec(index = 36)] - WeightLimitReached(::sp_weights::Weight), - #[codec(index = 37)] - Barrier, - #[codec(index = 38)] - WeightNotComputable, - #[codec(index = 39)] - ExceedsStackLimit, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Outcome { - #[codec(index = 0)] - Complete(::sp_weights::Weight), - #[codec(index = 1)] - Incomplete(::sp_weights::Weight, runtime_types::xcm::v3::traits::Error), - #[codec(index = 2)] - Error(runtime_types::xcm::v3::traits::Error), - } - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v3::Response, - max_weight: ::sp_weights::Weight, - querier: ::core::option::Option< - runtime_types::xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - beneficiary: runtime_types::xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - dest: runtime_types::xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::xcm::v2::OriginKind, - require_weight_at_most: ::sp_weights::Weight, - call: runtime_types::xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::xcm::v3::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::xcm::v3::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - beneficiary: runtime_types::xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - want: runtime_types::xcm::v3::multiasset::MultiAssets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - reserve: runtime_types::xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::xcm::v3::QueryResponseInfo, - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::xcm::v3::multiasset::MultiAsset, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::xcm::v3::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::xcm::v3::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - ticket: runtime_types::xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: ::sp_weights::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 29)] - ExpectAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option< - runtime_types::xcm::v3::multilocation::MultiLocation, - >, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::xcm::v3::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::std::vec::Vec<::core::primitive::u8>, - module_name: ::std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::xcm::v3::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::xcm::v3::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::xcm::v3::junction::NetworkId, - destination: runtime_types::xcm::v3::junctions::Junctions, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - unlocker: runtime_types::xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - target: runtime_types::xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - owner: runtime_types::xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - locker: runtime_types::xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::xcm::v3::multilocation::MultiLocation), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::xcm::v3::multilocation::MultiLocation, - >, - }, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum MaybeErrorCode { - #[codec(index = 0)] - Success, - #[codec(index = 1)] - Error( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - TruncatedError( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct PalletInfo { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - #[codec(compact)] - pub major: ::core::primitive::u32, - #[codec(compact)] - pub minor: ::core::primitive::u32, - #[codec(compact)] - pub patch: ::core::primitive::u32, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct QueryResponseInfo { - pub destination: runtime_types::xcm::v3::multilocation::MultiLocation, - #[codec(compact)] - pub query_id: ::core::primitive::u64, - pub max_weight: ::sp_weights::Weight, - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - #[codec(index = 4)] - PalletsInfo( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::xcm::v3::PalletInfo, - >, - ), - #[codec(index = 5)] - DispatchResult(runtime_types::xcm::v3::MaybeErrorCode), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(::sp_weights::Weight), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub struct Xcm(pub ::std::vec::Vec); - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum VersionedMultiAssets { - #[codec(index = 1)] - V2(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - V3(runtime_types::xcm::v3::multiasset::MultiAssets), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum VersionedMultiLocation { - #[codec(index = 1)] - V2(runtime_types::xcm::v2::multilocation::MultiLocation), - #[codec(index = 3)] - V3(runtime_types::xcm::v3::multilocation::MultiLocation), - } - #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - pub enum VersionedXcm { - #[codec(index = 2)] - V2(runtime_types::xcm::v2::Xcm), - #[codec(index = 3)] - V3(runtime_types::xcm::v3::Xcm), - } - } - } -} diff --git a/relays/client-rialto-parachain/src/lib.rs b/relays/client-rialto-parachain/src/lib.rs deleted file mode 100644 index b6617b90f137e..0000000000000 --- a/relays/client-rialto-parachain/src/lib.rs +++ /dev/null @@ -1,138 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Types used to connect to the Rialto-Substrate chain. - -pub mod codegen_runtime; - -use bp_messages::MessageNonce; -use bp_polkadot_core::SuffixedCommonSignedExtensionExt; -use bp_runtime::ChainId; -use codec::Encode; -use relay_substrate_client::{ - Chain, ChainWithBalances, ChainWithMessages, ChainWithTransactions, Error as SubstrateError, - SignParam, UnderlyingChainProvider, UnsignedTransaction, -}; -use sp_core::{storage::StorageKey, Pair}; -use sp_runtime::{generic::SignedPayload, traits::IdentifyAccount, MultiAddress}; -use std::time::Duration; - -pub use codegen_runtime::api::runtime_types; - -pub type RuntimeCall = runtime_types::rialto_parachain_runtime::RuntimeCall; -pub type SudoCall = runtime_types::pallet_sudo::pallet::Call; -pub type BridgeGrandpaCall = runtime_types::pallet_bridge_grandpa::pallet::Call; -pub type BridgeMessagesCall = runtime_types::pallet_bridge_messages::pallet::Call; - -/// The address format for describing accounts. -pub type Address = MultiAddress; - -/// Rialto parachain definition -#[derive(Debug, Clone, Copy)] -pub struct RialtoParachain; - -impl UnderlyingChainProvider for RialtoParachain { - type Chain = bp_rialto_parachain::RialtoParachain; -} - -impl Chain for RialtoParachain { - const ID: ChainId = bp_runtime::RIALTO_PARACHAIN_CHAIN_ID; - const NAME: &'static str = "RialtoParachain"; - const BEST_FINALIZED_HEADER_ID_METHOD: &'static str = - bp_rialto_parachain::BEST_FINALIZED_RIALTO_PARACHAIN_HEADER_METHOD; - const AVERAGE_BLOCK_INTERVAL: Duration = Duration::from_secs(5); - - type SignedBlock = bp_polkadot_core::SignedBlock; - type Call = RuntimeCall; -} - -impl ChainWithBalances for RialtoParachain { - fn account_info_storage_key(account_id: &Self::AccountId) -> StorageKey { - bp_polkadot_core::AccountInfoStorageMapKeyProvider::final_key(account_id) - } -} - -impl ChainWithMessages for RialtoParachain { - const WITH_CHAIN_MESSAGES_PALLET_NAME: &'static str = - bp_rialto_parachain::WITH_RIALTO_PARACHAIN_MESSAGES_PALLET_NAME; - // TODO (https://github.com/paritytech/parity-bridges-common/issues/1692): change the name - const WITH_CHAIN_RELAYERS_PALLET_NAME: Option<&'static str> = Some("BridgeRelayers"); - const TO_CHAIN_MESSAGE_DETAILS_METHOD: &'static str = - bp_rialto_parachain::TO_RIALTO_PARACHAIN_MESSAGE_DETAILS_METHOD; - const FROM_CHAIN_MESSAGE_DETAILS_METHOD: &'static str = - bp_rialto_parachain::FROM_RIALTO_PARACHAIN_MESSAGE_DETAILS_METHOD; - const MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX: MessageNonce = - bp_rialto_parachain::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX; - const MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX: MessageNonce = - bp_rialto_parachain::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX; -} - -impl ChainWithTransactions for RialtoParachain { - type AccountKeyPair = sp_core::sr25519::Pair; - type SignedTransaction = - bp_polkadot_core::UncheckedExtrinsic; - - fn sign_transaction( - param: SignParam, - unsigned: UnsignedTransaction, - ) -> Result { - let raw_payload = SignedPayload::new( - unsigned.call, - bp_rialto_parachain::SignedExtension::from_params( - param.spec_version, - param.transaction_version, - unsigned.era, - param.genesis_hash, - unsigned.nonce, - unsigned.tip, - (((), ()), ((), ())), - ), - )?; - - let signature = raw_payload.using_encoded(|payload| param.signer.sign(payload)); - let signer: sp_runtime::MultiSigner = param.signer.public().into(); - let (call, extra, _) = raw_payload.deconstruct(); - - Ok(Self::SignedTransaction::new_signed( - call, - signer.into_account().into(), - signature.into(), - extra, - )) - } - - fn is_signed(tx: &Self::SignedTransaction) -> bool { - tx.signature.is_some() - } - - fn is_signed_by(signer: &Self::AccountKeyPair, tx: &Self::SignedTransaction) -> bool { - tx.signature - .as_ref() - .map(|(address, _, _)| *address == Address::Id(signer.public().into())) - .unwrap_or(false) - } - - fn parse_transaction(tx: Self::SignedTransaction) -> Option> { - let extra = &tx.signature.as_ref()?.2; - Some(UnsignedTransaction::new(tx.function, extra.nonce()).tip(extra.tip())) - } -} - -/// RialtoParachain signing params. -pub type SigningParams = sp_core::sr25519::Pair; - -/// RialtoParachain header type used in headers sync. -pub type SyncHeader = relay_substrate_client::SyncHeader; diff --git a/relays/client-rialto/Cargo.toml b/relays/client-rialto/Cargo.toml deleted file mode 100644 index 7a1b378c9ac9c..0000000000000 --- a/relays/client-rialto/Cargo.toml +++ /dev/null @@ -1,27 +0,0 @@ -[package] -name = "relay-rialto-client" -version = "0.1.0" -authors = ["Parity Technologies "] -edition = "2021" -license = "GPL-3.0-or-later WITH Classpath-exception-2.0" - -[dependencies] -codec = { package = "parity-scale-codec", version = "3.1.5" } -relay-substrate-client = { path = "../client-substrate" } -relay-utils = { path = "../utils" } - -# Bridge dependencies - -bp-messages = { path = "../../primitives/messages" } -bp-rialto = { path = "../../primitives/chain-rialto" } -bp-runtime = { path = "../../primitives/runtime" } -rialto-runtime = { path = "../../bin/rialto/runtime" } - -# Substrate Dependencies - -frame-system = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -frame-support = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -pallet-transaction-payment = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -sp-session = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } diff --git a/relays/client-rialto/src/lib.rs b/relays/client-rialto/src/lib.rs deleted file mode 100644 index 2aa5bd638cc87..0000000000000 --- a/relays/client-rialto/src/lib.rs +++ /dev/null @@ -1,191 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - -//! Types used to connect to the Rialto-Substrate chain. - -use bp_messages::MessageNonce; -use bp_rialto::RIALTO_SYNCED_HEADERS_GRANDPA_INFO_METHOD; -use bp_runtime::ChainId; -use codec::{Compact, Decode, Encode}; -use relay_substrate_client::{ - BalanceOf, Chain, ChainWithBalances, ChainWithGrandpa, ChainWithMessages, - ChainWithTransactions, Error as SubstrateError, NonceOf, RelayChain, SignParam, - UnderlyingChainProvider, UnsignedTransaction, -}; -use sp_core::{storage::StorageKey, Pair}; -use sp_runtime::{generic::SignedPayload, traits::IdentifyAccount}; -use sp_session::MembershipProof; -use std::time::Duration; - -/// Rialto header id. -pub type HeaderId = relay_utils::HeaderId; - -/// Rialto chain definition -#[derive(Debug, Clone, Copy, PartialEq, Eq)] -pub struct Rialto; - -impl UnderlyingChainProvider for Rialto { - type Chain = bp_rialto::Rialto; -} - -impl Chain for Rialto { - const ID: ChainId = bp_runtime::RIALTO_CHAIN_ID; - const NAME: &'static str = "Rialto"; - const BEST_FINALIZED_HEADER_ID_METHOD: &'static str = - bp_rialto::BEST_FINALIZED_RIALTO_HEADER_METHOD; - const AVERAGE_BLOCK_INTERVAL: Duration = Duration::from_secs(5); - - type SignedBlock = rialto_runtime::SignedBlock; - type Call = rialto_runtime::RuntimeCall; -} - -impl ChainWithGrandpa for Rialto { - const SYNCED_HEADERS_GRANDPA_INFO_METHOD: &'static str = - RIALTO_SYNCED_HEADERS_GRANDPA_INFO_METHOD; - - type KeyOwnerProof = MembershipProof; -} - -impl RelayChain for Rialto { - const PARAS_PALLET_NAME: &'static str = bp_rialto::PARAS_PALLET_NAME; -} - -impl ChainWithMessages for Rialto { - const WITH_CHAIN_MESSAGES_PALLET_NAME: &'static str = - bp_rialto::WITH_RIALTO_MESSAGES_PALLET_NAME; - // TODO (https://github.com/paritytech/parity-bridges-common/issues/1692): change the name - const WITH_CHAIN_RELAYERS_PALLET_NAME: Option<&'static str> = Some("BridgeRelayers"); - const TO_CHAIN_MESSAGE_DETAILS_METHOD: &'static str = - bp_rialto::TO_RIALTO_MESSAGE_DETAILS_METHOD; - const FROM_CHAIN_MESSAGE_DETAILS_METHOD: &'static str = - bp_rialto::FROM_RIALTO_MESSAGE_DETAILS_METHOD; - const MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX: MessageNonce = - bp_rialto::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX; - const MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX: MessageNonce = - bp_rialto::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX; -} - -impl ChainWithBalances for Rialto { - fn account_info_storage_key(account_id: &Self::AccountId) -> StorageKey { - use frame_support::storage::generator::StorageMap; - StorageKey(frame_system::Account::::storage_map_final_key( - account_id, - )) - } -} - -impl ChainWithTransactions for Rialto { - type AccountKeyPair = sp_core::sr25519::Pair; - type SignedTransaction = rialto_runtime::UncheckedExtrinsic; - - fn sign_transaction( - param: SignParam, - unsigned: UnsignedTransaction, - ) -> Result { - let raw_payload = SignedPayload::from_raw( - unsigned.call.clone(), - ( - frame_system::CheckNonZeroSender::::new(), - frame_system::CheckSpecVersion::::new(), - frame_system::CheckTxVersion::::new(), - frame_system::CheckGenesis::::new(), - frame_system::CheckEra::::from(unsigned.era.frame_era()), - frame_system::CheckNonce::::from(unsigned.nonce), - frame_system::CheckWeight::::new(), - pallet_transaction_payment::ChargeTransactionPayment::::from(unsigned.tip), - ), - ( - (), - param.spec_version, - param.transaction_version, - param.genesis_hash, - unsigned.era.signed_payload(param.genesis_hash), - (), - (), - (), - ), - ); - let signature = raw_payload.using_encoded(|payload| param.signer.sign(payload)); - let signer: sp_runtime::MultiSigner = param.signer.public().into(); - let (call, extra, _) = raw_payload.deconstruct(); - - Ok(rialto_runtime::UncheckedExtrinsic::new_signed( - call.into_decoded()?, - signer.into_account().into(), - signature.into(), - extra, - )) - } - - fn is_signed(tx: &Self::SignedTransaction) -> bool { - tx.signature.is_some() - } - - fn is_signed_by(signer: &Self::AccountKeyPair, tx: &Self::SignedTransaction) -> bool { - tx.signature - .as_ref() - .map(|(address, _, _)| *address == rialto_runtime::Address::Id(signer.public().into())) - .unwrap_or(false) - } - - fn parse_transaction(tx: Self::SignedTransaction) -> Option> { - let extra = &tx.signature.as_ref()?.2; - Some( - UnsignedTransaction::new( - tx.function.into(), - Compact::>::decode(&mut &extra.5.encode()[..]).ok()?.into(), - ) - .tip(Compact::>::decode(&mut &extra.7.encode()[..]).ok()?.into()), - ) - } -} - -/// Rialto signing params. -pub type SigningParams = sp_core::sr25519::Pair; - -/// Rialto header type used in headers sync. -pub type SyncHeader = relay_substrate_client::SyncHeader; - -#[cfg(test)] -mod tests { - use super::*; - use relay_substrate_client::TransactionEra; - - #[test] - fn parse_transaction_works() { - let unsigned = UnsignedTransaction { - call: rialto_runtime::RuntimeCall::System(rialto_runtime::SystemCall::remark { - remark: b"Hello world!".to_vec(), - }) - .into(), - nonce: 777, - tip: 888, - era: TransactionEra::immortal(), - }; - let signed_transaction = Rialto::sign_transaction( - SignParam { - spec_version: 42, - transaction_version: 50000, - genesis_hash: [42u8; 32].into(), - signer: sp_core::sr25519::Pair::from_seed_slice(&[1u8; 32]).unwrap(), - }, - unsigned.clone(), - ) - .unwrap(); - let parsed_transaction = Rialto::parse_transaction(signed_transaction).unwrap(); - assert_eq!(parsed_transaction, unsigned); - } -} diff --git a/relays/finality/README.md b/relays/finality/README.md index 444056e756303..0a8d6a4c8b128 100644 --- a/relays/finality/README.md +++ b/relays/finality/README.md @@ -38,21 +38,21 @@ with mandatory headers are fee-free, the cost of running such relay is zero (in ## Finality Relay Metrics Finality relay provides several metrics. Metrics names depend on names of source and target chains. The list below -shows metrics names for Rialto (source chain) to Millau (target chain) finality relay. For other chains, simply -change chain names. So the metrics are: +shows metrics names for Rococo (source chain) to BridgeHubWestend (target chain) finality relay. For other +chains, simply change chain names. So the metrics are: -- `Rialto_to_Millau_Sync_best_source_block_number` - returns best finalized source chain (Rialto) block number, known +- `Rococo_to_BridgeHubWestend_Sync_best_source_block_number` - returns best finalized source chain (Rococo) block number, known to the relay. If relay is running in [on-demand mode](../bin-substrate/src/cli/relay_headers_and_messages/), the number may not match (it may be far behind) the actual best finalized number; -- `Rialto_to_Millau_Sync_best_source_at_target_block_number` - returns best finalized source chain (Rialto) block +- `Rococo_to_BridgeHubWestend_Sync_best_source_at_target_block_number` - returns best finalized source chain (Rococo) block number that is known to the bridge GRANDPA pallet at the target chain. -- `Rialto_to_Millau_Sync_is_source_and_source_at_target_using_different_forks` - if this metrics is set to `1`, then +- `Rococo_to_BridgeHubWestend_Sync_is_source_and_source_at_target_using_different_forks` - if this metrics is set to `1`, then the best source chain header, known to the target chain doesn't match the same-number-header at the source chain. It means that the GRANDPA validators set has crafted the duplicate justification and it has been submitted to the target chain. Normally (if majority of validators are honest and if you're running finality relay without large breaks) this shall not happen and the metric will have `0` value. -If relay operates properly, you should see that the `Rialto_to_Millau_Sync_best_source_at_target_block_number` -tries to reach the `Rialto_to_Millau_Sync_best_source_block_number`. And the latter one always increases. +If relay operates properly, you should see that the `Rococo_to_BridgeHubWestend_Sync_best_source_at_target_block_number` +tries to reach the `Rococo_to_BridgeHubWestend_Sync_best_source_block_number`. And the latter one always increases. diff --git a/relays/lib-substrate-relay/Cargo.toml b/relays/lib-substrate-relay/Cargo.toml index 6fe3c02cbca82..8a490a9d2756d 100644 --- a/relays/lib-substrate-relay/Cargo.toml +++ b/relays/lib-substrate-relay/Cargo.toml @@ -50,12 +50,9 @@ sp-consensus-grandpa = { git = "https://github.com/paritytech/polkadot-sdk", bra sp-runtime = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } [dev-dependencies] -bp-rialto = { path = "../../primitives/chain-rialto" } -bp-rialto-parachain = { path = "../../primitives/chain-rialto-parachain" } bp-rococo = { path = "../../primitives/chain-rococo" } bp-wococo = { path = "../../primitives/chain-wococo" } pallet-transaction-payment = { git = "https://github.com/paritytech/polkadot-sdk", branch = "master" } -relay-rialto-client = { path = "../client-rialto" } relay-rococo-client = { path = "../client-rococo" } -relay-wococo-client = { path = "../client-wococo" } -rialto-runtime = { path = "../../bin/rialto/runtime" } +relay-bridge-hub-rococo-client = { path = "../client-bridge-hub-rococo" } +relay-bridge-hub-wococo-client = { path = "../client-bridge-hub-wococo" } diff --git a/relays/lib-substrate-relay/src/lib.rs b/relays/lib-substrate-relay/src/lib.rs index 50a89e90e2dcd..6e62038665133 100644 --- a/relays/lib-substrate-relay/src/lib.rs +++ b/relays/lib-substrate-relay/src/lib.rs @@ -45,21 +45,8 @@ pub struct TransactionParams { /// Tagged relay account, which balance may be exposed as metrics by the relay. #[derive(Clone, Debug)] pub enum TaggedAccount { - /// Account, used to sign headers relay transactions from given bridged chain. - Headers { - /// Account id. - id: AccountId, - /// Name of the bridged chain, which headers are relayed. - bridged_chain: String, - }, - /// Account, used to sign parachains relay transactions from given bridged relay chain. - Parachains { - /// Account id. - id: AccountId, - /// Name of the bridged relay chain with parachain heads. - bridged_chain: String, - }, - /// Account, used to sign message relay transactions from given bridged chain. + /// Account, used to sign message (also headers and parachains) relay transactions from given + /// bridged chain. Messages { /// Account id. id: AccountId, @@ -72,8 +59,6 @@ impl TaggedAccount { /// Returns reference to the account id. pub fn id(&self) -> &AccountId { match *self { - TaggedAccount::Headers { ref id, .. } => id, - TaggedAccount::Parachains { ref id, .. } => id, TaggedAccount::Messages { ref id, .. } => id, } } @@ -81,10 +66,6 @@ impl TaggedAccount { /// Returns stringified account tag. pub fn tag(&self) -> String { match *self { - TaggedAccount::Headers { ref bridged_chain, .. } => format!("{bridged_chain}Headers"), - TaggedAccount::Parachains { ref bridged_chain, .. } => { - format!("{bridged_chain}Parachains") - }, TaggedAccount::Messages { ref bridged_chain, .. } => { format!("{bridged_chain}Messages") }, diff --git a/relays/lib-substrate-relay/src/messages_lane.rs b/relays/lib-substrate-relay/src/messages_lane.rs index 413f3d2c51ef5..41f04c8f986ee 100644 --- a/relays/lib-substrate-relay/src/messages_lane.rs +++ b/relays/lib-substrate-relay/src/messages_lane.rs @@ -187,8 +187,6 @@ where { // 2/3 is reserved for proofs and tx overhead let max_messages_size_in_single_batch = P::TargetChain::max_extrinsic_size() / 3; - // we don't know exact weights of the Polkadot runtime. So to guess weights we'll be using - // weights from Rialto and then simply dividing it by x2. let limits = match params.limits { Some(limits) => limits, None => diff --git a/relays/lib-substrate-relay/src/messages_source.rs b/relays/lib-substrate-relay/src/messages_source.rs index 4c49d76bdf357..ed7a2d5924fb7 100644 --- a/relays/lib-substrate-relay/src/messages_source.rs +++ b/relays/lib-substrate-relay/src/messages_source.rs @@ -555,9 +555,8 @@ fn split_msgs_to_refine( mod tests { use super::*; use bp_runtime::Chain as ChainBase; - use relay_rialto_client::Rialto; - use relay_rococo_client::Rococo; - use relay_wococo_client::Wococo; + use relay_bridge_hub_rococo_client::BridgeHubRococo; + use relay_bridge_hub_wococo_client::BridgeHubWococo; fn message_details_from_rpc( nonces: RangeInclusive, @@ -574,16 +573,20 @@ mod tests { #[test] fn validate_out_msgs_details_succeeds_if_no_messages_are_missing() { - assert!( - validate_out_msgs_details::(&message_details_from_rpc(1..=3), 1..=3,).is_ok() - ); + assert!(validate_out_msgs_details::( + &message_details_from_rpc(1..=3), + 1..=3, + ) + .is_ok()); } #[test] fn validate_out_msgs_details_succeeds_if_head_messages_are_missing() { - assert!( - validate_out_msgs_details::(&message_details_from_rpc(2..=3), 1..=3,).is_ok() + assert!(validate_out_msgs_details::( + &message_details_from_rpc(2..=3), + 1..=3, ) + .is_ok()) } #[test] @@ -591,7 +594,7 @@ mod tests { let mut message_details_from_rpc = message_details_from_rpc(1..=3); message_details_from_rpc.remove(1); assert!(matches!( - validate_out_msgs_details::(&message_details_from_rpc, 1..=3,), + validate_out_msgs_details::(&message_details_from_rpc, 1..=3,), Err(SubstrateError::Custom(_)) )); } @@ -599,7 +602,7 @@ mod tests { #[test] fn validate_out_msgs_details_map_fails_if_tail_messages_are_missing() { assert!(matches!( - validate_out_msgs_details::(&message_details_from_rpc(1..=2), 1..=3,), + validate_out_msgs_details::(&message_details_from_rpc(1..=2), 1..=3,), Err(SubstrateError::Custom(_)) )); } @@ -607,7 +610,7 @@ mod tests { #[test] fn validate_out_msgs_details_fails_if_all_messages_are_missing() { assert!(matches!( - validate_out_msgs_details::(&[], 1..=3), + validate_out_msgs_details::(&[], 1..=3), Err(SubstrateError::Custom(_)) )); } @@ -615,7 +618,7 @@ mod tests { #[test] fn validate_out_msgs_details_fails_if_more_messages_than_nonces() { assert!(matches!( - validate_out_msgs_details::(&message_details_from_rpc(1..=5), 2..=5,), + validate_out_msgs_details::(&message_details_from_rpc(1..=5), 2..=5,), Err(SubstrateError::Custom(_)) )); } @@ -641,8 +644,10 @@ mod tests { msgs_to_refine.push((payload, out_msg_details)); } - let maybe_batches = - split_msgs_to_refine::(LaneId([0, 0, 0, 0]), msgs_to_refine); + let maybe_batches = split_msgs_to_refine::( + Default::default(), + msgs_to_refine, + ); match expected_batches { Ok(expected_batches) => { let batches = maybe_batches.unwrap(); @@ -664,7 +669,7 @@ mod tests { #[test] fn test_split_msgs_to_refine() { - let max_extrinsic_size = Rococo::max_extrinsic_size() as usize; + let max_extrinsic_size = BridgeHubRococo::max_extrinsic_size() as usize; // Check that an error is returned when one of the messages is too big. check_split_msgs_to_refine(vec![max_extrinsic_size], Err(())); diff --git a/relays/parachains/README.md b/relays/parachains/README.md index fc5ad03fb340d..bacd28594d807 100644 --- a/relays/parachains/README.md +++ b/relays/parachains/README.md @@ -35,15 +35,15 @@ transaction. Every parachain in Polkadot is identified by the 32-bit number. All metrics, exposed by the parachains finality relay have the `parachain` label, which is set to the parachain id. And the metrics are prefixed with the prefix, that depends on the name of the source relay and target chains. The list below shows metrics names for -Rialto (source relay chain) to Millau (target chain) parachains finality relay. For other chains, simply +Rococo (source relay chain) to BridgeHubWestend (target chain) parachains finality relay. For other chains, simply change chain names. So the metrics are: -- `Rialto_to_Millau_Parachains_best_parachain_block_number_at_source` - returns best known parachain block - number, registered in the `paras` pallet at the source relay chain (Rialto in our example); +- `Rococo_to_BridgeHubWestend_Parachains_best_parachain_block_number_at_source` - returns best known parachain block + number, registered in the `paras` pallet at the source relay chain (Rococo in our example); -- `Rialto_to_Millau_Parachains_best_parachain_block_number_at_target` - returns best known parachain block - number, registered in the bridge parachains pallet at the target chain (Millau in our example). +- `Rococo_to_BridgeHubWestend_Parachains_best_parachain_block_number_at_target` - returns best known parachain block + number, registered in the bridge parachains pallet at the target chain (BridgeHubWestend in our example). -If relay operates properly, you should see that the `Rialto_to_Millau_Parachains_best_parachain_block_number_at_target` -tries to reach the `Rialto_to_Millau_Parachains_best_parachain_block_number_at_source`. And the latter one +If relay operates properly, you should see that the `Rococo_to_BridgeHubWestend_Parachains_best_parachain_block_number_at_target` +tries to reach the `Rococo_to_BridgeHubWestend_Parachains_best_parachain_block_number_at_source`. And the latter one always increases. diff --git a/scripts/add_license.sh b/scripts/add_license.sh deleted file mode 100755 index 49864b47c05f8..0000000000000 --- a/scripts/add_license.sh +++ /dev/null @@ -1,22 +0,0 @@ -#!/usr/bin/env bash - -PAT_GPL="^// Copyright.*If not, see \.$" -PAT_OTHER="^// Copyright" - -SCRIPTS_DIR=$( cd "$(dirname "${BASH_SOURCE[0]}")" ; pwd -P ) - -for f in $(find . -type f | egrep '\.(c|cpp|rs)$'); do - HEADER=$(head -16 $f) - if [[ $HEADER =~ $PAT_GPL ]]; then - BODY=$(tail -n +17 $f) - cat $SCRIPTS_DIR/license_header > temp - echo "$BODY" >> temp - mv temp $f - elif [[ $HEADER =~ $PAT_OTHER ]]; then - echo "Other license was found do nothing" - else - echo "$f was missing header" - cat $SCRIPTS_DIR/license_header $f > temp - mv temp $f - fi -done diff --git a/scripts/build-containers.sh b/scripts/build-containers.sh index b853b35f7f97d..cb87af7743f08 100755 --- a/scripts/build-containers.sh +++ b/scripts/build-containers.sh @@ -3,12 +3,9 @@ set -eux if [ -z "${LOCAL:-}" ]; then time docker build . -t local/substrate-relay --build-arg=PROJECT=substrate-relay - time docker build . -t local/rialto-bridge-node --build-arg=PROJECT=rialto-bridge-node - time docker build . -t local/millau-bridge-node --build-arg=PROJECT=millau-bridge-node - time docker build . -t local/rialto-parachain-collator --build-arg=PROJECT=rialto-parachain-collator else if [ -z "${SKIP_BUILD:-}" ]; then - time cargo build -p substrate-relay -p rialto-bridge-node -p millau-bridge-node -p rialto-parachain-collator --release + time cargo build -p substrate-relay --release fi # (try to) use docker image matching the host os @@ -18,13 +15,4 @@ else DOCKER_BUILDKIT=1 time docker build . -f local.Dockerfile -t local/substrate-relay \ --build-arg=PROJECT=substrate-relay \ --build-arg=UBUNTU_RELEASE=${UBUNTU_RELEASE} - DOCKER_BUILDKIT=1 time docker build . -f local.Dockerfile -t local/rialto-bridge-node \ - --build-arg=PROJECT=rialto-bridge-node \ - --build-arg=UBUNTU_RELEASE=${UBUNTU_RELEASE} - DOCKER_BUILDKIT=1 time docker build . -f local.Dockerfile -t local/millau-bridge-node \ - --build-arg=PROJECT=millau-bridge-node \ - --build-arg=UBUNTU_RELEASE=${UBUNTU_RELEASE} - DOCKER_BUILDKIT=1 time docker build . -f local.Dockerfile -t local/rialto-parachain-collator \ - --build-arg=PROJECT=rialto-parachain-collator \ - --build-arg=UBUNTU_RELEASE=${UBUNTU_RELEASE} fi diff --git a/scripts/ci-cache.sh b/scripts/ci-cache.sh deleted file mode 100755 index 040d44fa74a0e..0000000000000 --- a/scripts/ci-cache.sh +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/bash - -set -xeu - -echo $CARGO_TARGET_DIR; -mkdir -p $CARGO_TARGET_DIR; -echo "Current Rust nightly version:"; -rustc +nightly --version; -echo "Cached Rust nightly version:"; -if [ ! -f $CARGO_TARGET_DIR/check_nightly_rust ]; then - echo "" > $CARGO_TARGET_DIR/check_nightly_rust; -fi -cat $CARGO_TARGET_DIR/check_nightly_rust; -if [[ $(cat $CARGO_TARGET_DIR/check_nightly_rust) == $(rustc +nightly --version) ]]; then - echo "The Rust nightly version has not changed"; -else - echo "The Rust nightly version has changed. Clearing the cache"; - rm -rf $CARGO_TARGET_DIR/*; -fi diff --git a/scripts/dump-logs.sh b/scripts/dump-logs.sh deleted file mode 100755 index 709a50658872b..0000000000000 --- a/scripts/dump-logs.sh +++ /dev/null @@ -1,44 +0,0 @@ -#!/bin/bash - -# A script to dump logs from selected important docker containers -# to make it easier to analyze locally. - -set -xeu - -DATE=$(date +"%Y-%m-%d-%T") -LOGS_DIR="${DATE//:/-}-logs" -mkdir $LOGS_DIR -cd $LOGS_DIR - -# From $ docker ps --format '{{.Names}}' - -SERVICES=(\ - deployments_relay-messages-millau-to-rialto-generator_1 \ - deployments_relay-messages-rialto-to-millau-generator_1 \ - deployments_relay-millau-rialto_1 \ - deployments_relay-headers-westend-to-millau-1_1 \ - deployments_relay-headers-westend-to-millau-2_1 \ - deployments_relay-parachains-westend-to-millau-1_1 \ - deployments_relay-parachains-westend-to-millau-1_2 \ - deployments_relay-messages-millau-to-rialto-parachain-generator_1 \ - deployments_relay-messages-rialto-parachain-to-millau-generator_1 \ - deployments_relay-millau-rialto-parachain-1_1 \ - deployments_relay-millau-rialto-parachain-2_1 \ - deployments_rialto-node-alice_1 \ - deployments_rialto-node-bob_1 \ - deployments_millau-node-alice_1 \ - deployments_millau-node-bob_1 \ - deployments_rialto-parachain-collator-alice_1 \ - deployments_rialto-parachain-collator-bob_1 \ - deployments_relay-messages-millau-to-rialto-resubmitter_1 \ - deployments_relay-messages-millau-to-rialto-parachain-resubmitter_1 \ -) - -for SVC in ${SERVICES[*]} -do - SHORT_NAME="${SVC//deployments_/}" - docker logs $SVC &> $SHORT_NAME.log | true -done - -cd - -tar cvjf $LOGS_DIR.tar.bz2 $LOGS_DIR diff --git a/scripts/license_header b/scripts/license_header deleted file mode 100644 index f9b301209bbf1..0000000000000 --- a/scripts/license_header +++ /dev/null @@ -1,16 +0,0 @@ -// Copyright 2019-2021 Parity Technologies (UK) Ltd. -// This file is part of Parity Bridges Common. - -// Parity Bridges Common 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. - -// Parity Bridges Common 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 Parity Bridges Common. If not, see . - diff --git a/scripts/regenerate_runtimes.sh b/scripts/regenerate_runtimes.sh index e31761e0d4284..700f4dc1c86e8 100755 --- a/scripts/regenerate_runtimes.sh +++ b/scripts/regenerate_runtimes.sh @@ -2,7 +2,6 @@ cd tools/runtime-codegen cargo run --bin runtime-codegen -- --from-node-url "wss://rococo-bridge-hub-rpc.polkadot.io:443" > ../../relays/client-bridge-hub-rococo/src/codegen_runtime.rs -cargo run --bin runtime-codegen -- --from-node-url "http://localhost:20433" > ../../relays/client-rialto-parachain/src/codegen_runtime.rs cargo run --bin runtime-codegen -- --from-node-url "wss://rococo-rpc.polkadot.io:443" > ../../relays/client-rococo/src/codegen_runtime.rs cargo run --bin runtime-codegen -- --from-node-url "wss://westend-rpc.polkadot.io:443" > ../../relays/client-westend/src/codegen_runtime.rs cargo run --bin runtime-codegen -- --from-node-url "wss://kusama-rpc.polkadot.io:443" > ../../relays/client-kusama/src/codegen_runtime.rs diff --git a/scripts/send-message-from-millau-rialto.sh b/scripts/send-message-from-millau-rialto.sh deleted file mode 100755 index 1a736b4f8bd4d..0000000000000 --- a/scripts/send-message-from-millau-rialto.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/bash - -# Used for manually sending a message to a running network. -# -# You could for example spin up a full network using the Docker Compose files -# we have (to make sure the message relays are running), but remove the message -# generator service. From there you may submit messages manually using this script. - -# TODO: Fix demeo scripts https://github.com/paritytech/parity-bridges-common/issues/1406 - -MILLAU_PORT="${MILLAU_PORT:-9945}" - -RUST_LOG=runtime=trace,substrate-relay=trace,bridge=trace \ -./target/debug/substrate-relay send-message millau-to-rialto \ - --source-host localhost \ - --source-port $MILLAU_PORT \ - --source-signer //Alice \ - raw 030426020109020419a8 diff --git a/scripts/send-message-from-rialto-millau.sh b/scripts/send-message-from-rialto-millau.sh deleted file mode 100755 index 8133978f6ce53..0000000000000 --- a/scripts/send-message-from-rialto-millau.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/bash - -# Used for manually sending a message to a running network. -# -# You could for example spin up a full network using the Docker Compose files -# we have (to make sure the message relays are running), but remove the message -# generator service. From there you may submit messages manually using this script. - -# TODO: Fix demeo scripts https://github.com/paritytech/parity-bridges-common/issues/1406 - -RIALTO_PORT="${RIALTO_PORT:-9944}" - -RUST_LOG=runtime=trace,substrate-relay=trace,bridge=trace \ -./target/debug/substrate-relay send-message rialto-to-millau \ - --source-host localhost \ - --source-port $RIALTO_PORT \ - --source-signer //Bob \ - raw 030426030109030419a8 diff --git a/scripts/update-weights-setup.sh b/scripts/update-weights-setup.sh deleted file mode 100644 index 72534423d63c4..0000000000000 --- a/scripts/update-weights-setup.sh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/bash - -set -exu - -# Set up the standardized machine and run `update-weights.sh` script. -# The system is assumed to be pristine Ubuntu 20.04 and we install -# all required dependencies. - -# To avoid interruptions you might want to run this script in `screen` cause it will take a while -# to finish. - -# We start off with upgrading the system -apt update && apt dist-upgrade - -# and installing `git` and other required deps. -apt install -y git clang curl libssl-dev llvm libudev-dev screen - -# Now we clone the repository -git clone https://github.com/paritytech/parity-bridges-common.git -cd parity-bridges-common - -# Install rustup & toolchain -curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | bash -s -- -y - -# Source config -source ~/.cargo/env - -# Add nightly and WASM -rustup install nightly -rustup target add wasm32-unknown-unknown --toolchain nightly - -# Update the weights -./scripts/update-weights.sh diff --git a/scripts/update-weights.sh b/scripts/update-weights.sh deleted file mode 100755 index 155fe62ded158..0000000000000 --- a/scripts/update-weights.sh +++ /dev/null @@ -1,84 +0,0 @@ -#!/bin/sh -# -# Runtime benchmarks for the `pallet-bridge-messages` and `pallet-bridge-grandpa` pallets. -# -# Run this script from root of the repo. - -set -eux - -# default (test) weights that we'll bundle with our pallets - -time cargo run --release -p millau-bridge-node --features=runtime-benchmarks -- benchmark pallet \ - --chain=dev \ - --steps=50 \ - --repeat=20 \ - --pallet=pallet_bridge_messages \ - --extrinsic=* \ - --execution=wasm \ - --wasm-execution=Compiled \ - --heap-pages=4096 \ - --output=./modules/messages/src/weights.rs \ - --template=./.maintain/bridge-weight-template.hbs - -time cargo run --release -p millau-bridge-node --features=runtime-benchmarks -- benchmark pallet \ - --chain=dev \ - --steps=50 \ - --repeat=20 \ - --pallet=pallet_bridge_grandpa \ - --extrinsic=* \ - --execution=wasm \ - --wasm-execution=Compiled \ - --heap-pages=4096 \ - --output=./modules/grandpa/src/weights.rs \ - --template=./.maintain/bridge-weight-template.hbs - -time cargo run --release -p millau-bridge-node --features=runtime-benchmarks -- benchmark pallet \ - --chain=dev \ - --steps=50 \ - --repeat=20 \ - --pallet=pallet_bridge_parachains \ - --extrinsic=* \ - --execution=wasm \ - --wasm-execution=Compiled \ - --heap-pages=4096 \ - --output=./modules/parachains/src/weights.rs \ - --template=./.maintain/bridge-weight-template.hbs - -time cargo run --release -p millau-bridge-node --features=runtime-benchmarks -- benchmark pallet \ - --chain=dev \ - --steps=50 \ - --repeat=20 \ - --pallet=pallet_bridge_relayers \ - --extrinsic=* \ - --execution=wasm \ - --wasm-execution=Compiled \ - --heap-pages=4096 \ - --output=./modules/relayers/src/weights.rs \ - --template=./.maintain/bridge-weight-template.hbs - -time cargo run --release -p millau-bridge-node --features=runtime-benchmarks -- benchmark pallet \ - --chain=dev \ - --steps=50 \ - --repeat=20 \ - --pallet=pallet_xcm_bridge_hub_router \ - --extrinsic=* \ - --execution=wasm \ - --wasm-execution=Compiled \ - --heap-pages=4096 \ - --output=./modules/xcm-bridge-hub-router/src/weights.rs \ - --template=./.maintain/bridge-weight-template.hbs - -# weights for Millau runtime. We want to provide runtime weight overhead for messages calls, -# so we can't use "default" test weights directly - they'll be rejected by our integration tests. - -time cargo run --release -p millau-bridge-node --features=runtime-benchmarks -- benchmark pallet \ - --chain=dev \ - --steps=50 \ - --repeat=20 \ - --pallet=pallet_bridge_messages \ - --extrinsic=* \ - --execution=wasm \ - --wasm-execution=Compiled \ - --heap-pages=4096 \ - --output=./bin/millau/runtime/src/weights/ - diff --git a/scripts/update_substrate.sh b/scripts/update_substrate.sh deleted file mode 100755 index f7715bda5d1c5..0000000000000 --- a/scripts/update_substrate.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/sh - -# One-liner to update between Substrate releases -# Usage: ./update_substrate.sh 2.0.0-rc6 2.0.0 -set -xeu - -OLD_VERSION=$1 -NEW_VERSION=$2 - -find . -type f -name 'Cargo.toml' -exec sed -i '' -e "s/$OLD_VERSION/$NEW_VERSION/g" {} \; diff --git a/scripts/verify-pallets-build.sh b/scripts/verify-pallets-build.sh index e797f77d02657..b0bf9bdb413f2 100755 --- a/scripts/verify-pallets-build.sh +++ b/scripts/verify-pallets-build.sh @@ -61,19 +61,12 @@ trap revert_to_clean_state EXIT rm -rf $BRIDGES_FOLDER/.config rm -rf $BRIDGES_FOLDER/.github rm -rf $BRIDGES_FOLDER/.maintain -rm -rf $BRIDGES_FOLDER/bin/millau -rm -rf $BRIDGES_FOLDER/bin/rialto -rm -rf $BRIDGES_FOLDER/bin/rialto-parachain -rm -rf $BRIDGES_FOLDER/bin/.keep rm -rf $BRIDGES_FOLDER/deployments rm -f $BRIDGES_FOLDER/docs/dockerhub-* rm -rf $BRIDGES_FOLDER/fuzz rm -rf $BRIDGES_FOLDER/modules/beefy -rm -rf $BRIDGES_FOLDER/modules/shift-session-manager rm -rf $BRIDGES_FOLDER/primitives/beefy -rm -rf $BRIDGES_FOLDER/primitives/chain-millau -rm -rf $BRIDGES_FOLDER/primitives/chain-rialto -rm -rf $BRIDGES_FOLDER/primitives/chain-rialto-parachain +rm -rf $BRIDGES_FOLDER/primitives/chain-westend rm -rf $BRIDGES_FOLDER/relays rm -rf $BRIDGES_FOLDER/scripts/add_license.sh rm -rf $BRIDGES_FOLDER/scripts/build-containers.sh @@ -81,8 +74,6 @@ rm -rf $BRIDGES_FOLDER/scripts/ci-cache.sh rm -rf $BRIDGES_FOLDER/scripts/dump-logs.sh rm -rf $BRIDGES_FOLDER/scripts/license_header rm -rf $BRIDGES_FOLDER/scripts/regenerate_runtimes.sh -rm -rf $BRIDGES_FOLDER/scripts/send-message-from-millau-rialto.sh -rm -rf $BRIDGES_FOLDER/scripts/send-message-from-rialto-millau.sh rm -rf $BRIDGES_FOLDER/scripts/update-weights.sh rm -rf $BRIDGES_FOLDER/scripts/update-weights-setup.sh rm -rf $BRIDGES_FOLDER/scripts/update_substrate.sh diff --git a/tools/runtime-codegen/README.md b/tools/runtime-codegen/README.md index 7e1aa16f5e026..a5faeb840b81c 100644 --- a/tools/runtime-codegen/README.md +++ b/tools/runtime-codegen/README.md @@ -2,10 +2,6 @@ This is a tool for generating the bridge runtime code from metadata. Example commands: -``` -cargo run --bin runtime-codegen -- --from-node-url "http://localhost:20433" > /tmp/rialto_codegen.rs -``` - ``` cargo run --bin runtime-codegen -- --from-node-url "wss://rococo-bridge-hub-rpc.polkadot.io:443" > /tmp/rococo_codegen.rs ``` diff --git a/tools/runtime-codegen/src/main.rs b/tools/runtime-codegen/src/main.rs index 83f642d3c286f..4202cb2ae9292 100644 --- a/tools/runtime-codegen/src/main.rs +++ b/tools/runtime-codegen/src/main.rs @@ -140,8 +140,6 @@ fn main() -> color_eyre::Result<()> { TypeSubstitute::simple("bp_messages::target_chain::FromBridgedChainMessagesProof"), TypeSubstitute::simple("bp_messages::source_chain::FromBridgedChainMessagesDeliveryProof"), TypeSubstitute::simple("bp_messages::UnrewardedRelayersState"), - TypeSubstitute::custom("bp_millau::millau_hash::MillauHash", "::bp_millau::MillauHash"), - TypeSubstitute::simple("bp_millau::BlakeTwoAndKeccak256"), TypeSubstitute::custom( "sp_runtime::generic::digest::Digest", "::sp_runtime::generic::Digest",