diff --git a/.github/.markdownlint.yaml b/.github/.markdownlint.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..6a93d89c46ad4601505dd75ac252816fa4af5c40
--- /dev/null
+++ b/.github/.markdownlint.yaml
@@ -0,0 +1,210 @@
+# Default state for all rules
+default: true
+
+# Path to configuration file to extend
+extends: null
+
+# MD001/heading-increment/header-increment - Heading levels should only increment by one level at a time
+MD001: true
+
+# MD002/first-heading-h1/first-header-h1 - First heading should be a top-level heading
+MD002:
+ # Heading level
+ level: 1
+
+# MD003/heading-style/header-style - Heading style
+MD003:
+ # Heading style
+ style: "consistent"
+
+# MD004/ul-style - Unordered list style
+MD004:
+ # List style
+ style: "consistent"
+
+# MD005/list-indent - Inconsistent indentation for list items at the same level
+MD005: false
+
+# MD006/ul-start-left - Consider starting bulleted lists at the beginning of the line
+MD006: false
+
+# MD007/ul-indent - Unordered list indentation
+MD007: false
+
+# MD009/no-trailing-spaces - Trailing spaces
+MD009:
+ # Spaces for line break
+ br_spaces: 2
+ # Allow spaces for empty lines in list items
+ list_item_empty_lines: false
+ # Include unnecessary breaks
+ strict: false
+
+# MD010/no-hard-tabs - Hard tabs
+MD010: false
+
+# MD011/no-reversed-links - Reversed link syntax
+MD011: true
+
+# MD012/no-multiple-blanks - Multiple consecutive blank lines
+MD012:
+ # Consecutive blank lines
+ maximum: 2
+
+# MD013/line-length - Line length
+MD013:
+ # Number of characters
+ line_length: 120
+ # Number of characters for headings
+ heading_line_length: 120
+ # Number of characters for code blocks
+ code_block_line_length: 150
+ # Include code blocks
+ code_blocks: true
+ # Include tables
+ tables: true
+ # Include headings
+ headings: true
+ # Include headings
+ headers: true
+ # Strict length checking
+ strict: false
+ # Stern length checking
+ stern: false
+
+# MD014/commands-show-output - Dollar signs used before commands without showing output
+MD014: true
+
+# MD018/no-missing-space-atx - No space after hash on atx style heading
+MD018: true
+
+# MD019/no-multiple-space-atx - Multiple spaces after hash on atx style heading
+MD019: true
+
+# MD020/no-missing-space-closed-atx - No space inside hashes on closed atx style heading
+MD020: true
+
+# MD021/no-multiple-space-closed-atx - Multiple spaces inside hashes on closed atx style heading
+MD021: true
+
+# MD022/blanks-around-headings/blanks-around-headers - Headings should be surrounded by blank lines
+MD022: false
+
+# MD023/heading-start-left/header-start-left - Headings must start at the beginning of the line
+MD023: true
+
+# MD024/no-duplicate-heading/no-duplicate-header - Multiple headings with the same content
+MD024: false
+
+# MD025/single-title/single-h1 - Multiple top-level headings in the same document
+MD025: false
+
+# MD026/no-trailing-punctuation - Trailing punctuation in heading
+MD026:
+ # Punctuation characters
+ punctuation: ".,;:!。,;:!"
+
+# MD027/no-multiple-space-blockquote - Multiple spaces after blockquote symbol
+MD027: true
+
+# MD028/no-blanks-blockquote - Blank line inside blockquote
+MD028: true
+
+# MD029/ol-prefix - Ordered list item prefix
+MD029:
+ # List style
+ style: "one_or_ordered"
+
+# MD030/list-marker-space - Spaces after list markers
+MD030:
+ # Spaces for single-line unordered list items
+ ul_single: 1
+ # Spaces for single-line ordered list items
+ ol_single: 1
+ # Spaces for multi-line unordered list items
+ ul_multi: 1
+ # Spaces for multi-line ordered list items
+ ol_multi: 1
+
+# MD031/blanks-around-fences - Fenced code blocks should be surrounded by blank lines
+MD031: false
+
+# MD032/blanks-around-lists - Lists should be surrounded by blank lines
+MD032: false
+
+# MD033/no-inline-html - Inline HTML
+MD033: false
+
+# MD034/no-bare-urls - Bare URL used
+MD034: false
+
+# MD035/hr-style - Horizontal rule style
+MD035:
+ # Horizontal rule style
+ style: "consistent"
+
+# MD036/no-emphasis-as-heading/no-emphasis-as-header - Emphasis used instead of a heading
+MD036: false
+
+# MD037/no-space-in-emphasis - Spaces inside emphasis markers
+MD037: true
+
+# MD038/no-space-in-code - Spaces inside code span elements
+MD038: true
+
+# MD039/no-space-in-links - Spaces inside link text
+MD039: true
+
+# MD040/fenced-code-language - Fenced code blocks should have a language specified
+MD040: false
+
+# MD041/first-line-heading/first-line-h1 - First line in a file should be a top-level heading
+MD041: false
+
+# MD042/no-empty-links - No empty links
+MD042: true
+
+# MD043/required-headings/required-headers - Required heading structure
+MD043: false
+
+# MD044/proper-names - Proper names should have the correct capitalization
+MD044:
+ # List of proper names
+ names: ["Polkadot", "Substrate", "Cumulus", "Parity"]
+ # Include code blocks
+ code_blocks: false
+ # Include HTML elements
+ html_elements: false
+
+# MD045/no-alt-text - Images should have alternate text (alt text)
+MD045: false
+
+# MD046/code-block-style - Code block style
+MD046:
+ # Block style
+ style: "consistent"
+
+# MD047/single-trailing-newline - Files should end with a single newline character
+MD047: true
+
+# MD048/code-fence-style - Code fence style
+MD048:
+ # Code fence style
+ style: "consistent"
+
+# MD049/emphasis-style - Emphasis style should be consistent
+MD049: false
+
+# MD050/strong-style - Strong style should be consistent
+MD050:
+ # Strong style
+ style: "consistent"
+
+# MD051/link-fragments - Link fragments should be valid
+MD051: false
+
+# MD052/reference-links-images - Reference links and images should use a label that is defined
+MD052: false
+
+# MD053/link-image-reference-definitions - Link and image reference definitions should be needed
+MD053: false
diff --git a/.github/workflows/check-licenses.yml b/.github/workflows/check-licenses.yml
index e213acd4988ed37bd07dab47de622fbcccaf2a2a..4d0afefc47aace08bff9af796f9fb9c30dee99a7 100644
--- a/.github/workflows/check-licenses.yml
+++ b/.github/workflows/check-licenses.yml
@@ -9,28 +9,37 @@ permissions:
jobs:
check-licenses:
runs-on: ubuntu-22.04
- strategy:
- fail-fast: false
- matrix:
- repo: [polkadot]
+ env:
+ LICENSES: "'Apache-2.0' 'GPL-3.0-only' 'GPL-3.0-or-later WITH Classpath-exception-2.0'"
+ NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- name: Checkout sources
- uses: actions/checkout@v3
+ uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4.0.0
- uses: actions/setup-node@v3.8.1
with:
node-version: "18.x"
registry-url: "https://npm.pkg.github.com"
scope: "@paritytech"
- - name: Check the licenses for ${{ matrix.repo }}
+
+ - name: Check the licenses in Polkadot
run: |
shopt -s globstar
- echo "install"
- npm install -g @paritytech/license-scanner@0.0.5
- echo "run for ${{ matrix.repo }}"
- cd ${{ matrix.repo }}
npx @paritytech/license-scanner scan \
- --ensure-licenses=Apache-2.0 \
- --ensure-licenses=GPL-3.0-only \
- ./**/*.rs
- env:
- NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ --ensure-licenses ${{ env.LICENSES }} \
+ -- ./polkadot/**/*.rs
+
+ - name: Check the licenses in Cumulus
+ run: |
+ shopt -s globstar
+ npx @paritytech/license-scanner scan \
+ --ensure-licenses ${{ env.LICENSES }} \
+ --exclude ./cumulus/parachain-template \
+ -- ./cumulus/**/*.rs
+
+ - name: Check the licenses in Substrate
+ run: |
+ shopt -s globstar
+ npx @paritytech/license-scanner scan \
+ --ensure-licenses ${{ env.LICENSES }} \
+ --exclude ./substrate/bin/node-template \
+ -- ./substrate/**/*.rs
diff --git a/.github/workflows/check-markdown.yml b/.github/workflows/check-markdown.yml
new file mode 100644
index 0000000000000000000000000000000000000000..f1e46ca273515d9081f9c5a7f6b8b4ff902c444a
--- /dev/null
+++ b/.github/workflows/check-markdown.yml
@@ -0,0 +1,33 @@
+name: Check Markdown
+
+on:
+ pull_request:
+ types: [opened, synchronize, reopened, ready_for_review]
+
+permissions:
+ packages: read
+
+jobs:
+ lint-markdown:
+ runs-on: ubuntu-latest
+
+ steps:
+ - name: Checkout sources
+ uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4.0.0
+
+ - uses: actions/setup-node@v3.8.1
+ with:
+ node-version: "18.x"
+ registry-url: "https://npm.pkg.github.com"
+ scope: "@paritytech"
+
+ - name: Install tooling
+ run: |
+ npm install -g markdownlint-cli
+ markdownlint --version
+
+ - name: Check Markdown
+ env:
+ CONFIG: .github/.markdownlint.yaml
+ run: |
+ markdownlint --config "$CONFIG" --ignore target .
diff --git a/.github/workflows/fmt-check.yml b/.github/workflows/fmt-check.yml
index fd4b72061b925dfb3f6e4193a6b1fb97c0de75d8..df785404036e138c78cf1818620dd9db8c30a243 100644
--- a/.github/workflows/fmt-check.yml
+++ b/.github/workflows/fmt-check.yml
@@ -16,7 +16,7 @@ jobs:
container:
image: paritytech/ci-unified:bullseye-1.70.0-2023-05-23-v20230706
steps:
- - uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3
+ - uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4.0.0
- name: Cargo fmt
run: cargo +nightly fmt --all -- --check
diff --git a/.gitignore b/.gitignore
index bd7f34b481041163b45c4c75ad4757d28ec0ca20..35e02e706b4261dcac2a3f9c6686245a01de9a8a 100644
--- a/.gitignore
+++ b/.gitignore
@@ -7,6 +7,7 @@
.local
.vscode
.wasm-binaries
+*.adoc
*.bin
*.iml
*.orig
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index c6fbc17a182fddaf531e39b24919f01e18832d0c..2e0465ba1eb1b350e105a67703bd51ce13f544ae 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -22,7 +22,7 @@ workflow:
variables:
CI_IMAGE: "paritytech/ci-unified:bullseye-1.70.0-2023-05-23-v20230706"
- BUILDAH_IMAGE: "quay.io/buildah/stable:v1.29"
+ # BUILDAH_IMAGE is defined in group variables
BUILDAH_COMMAND: "buildah --storage-driver overlay2"
RELENG_SCRIPTS_BRANCH: "master"
RUSTY_CACHIER_SINGLE_BRANCH: master
@@ -333,3 +333,58 @@ cancel-pipeline-cargo-clippy:
extends: .cancel-pipeline-template
needs:
- job: cargo-clippy
+
+cancel-pipeline-build-linux-stable:
+ extends: .cancel-pipeline-template
+ needs:
+ - job: build-linux-stable
+
+cancel-pipeline-build-linux-stable-cumulus:
+ extends: .cancel-pipeline-template
+ needs:
+ - job: build-linux-stable-cumulus
+
+cancel-pipeline-build-linux-substrate:
+ extends: .cancel-pipeline-template
+ needs:
+ - job: build-linux-substrate
+
+cancel-pipeline-test-node-metrics:
+ extends: .cancel-pipeline-template
+ needs:
+ - job: test-node-metrics
+
+cancel-pipeline-test-frame-ui:
+ extends: .cancel-pipeline-template
+ needs:
+ - job: test-frame-ui
+
+cancel-pipeline-quick-benchmarks:
+ extends: .cancel-pipeline-template
+ needs:
+ - job: quick-benchmarks
+
+cancel-pipeline-check-try-runtime:
+ extends: .cancel-pipeline-template
+ needs:
+ - job: check-try-runtime
+
+cancel-pipeline-test-frame-examples-compile-to-wasm:
+ extends: .cancel-pipeline-template
+ needs:
+ - job: test-frame-examples-compile-to-wasm
+
+cancel-pipeline-build-short-benchmark:
+ extends: .cancel-pipeline-template
+ needs:
+ - job: build-short-benchmark
+
+cancel-pipeline-check-runtime-migration-rococo:
+ extends: .cancel-pipeline-template
+ needs:
+ - job: check-runtime-migration-rococo
+
+cancel-pipeline-check-runtime-migration-westend:
+ extends: .cancel-pipeline-template
+ needs:
+ - job: check-runtime-migration-westend
diff --git a/.gitlab/pipeline/build.yml b/.gitlab/pipeline/build.yml
index 0364c3607606516103ab6dd920725eaade38b3dd..20fed5df3dfd98fb204612f954640cab0b8a134c 100644
--- a/.gitlab/pipeline/build.yml
+++ b/.gitlab/pipeline/build.yml
@@ -88,7 +88,7 @@ build-staking-miner:
- job: build-malus
artifacts: false
script:
- - time cargo build --locked --release --package staking-miner
+ - time cargo build -q --locked --release --package staging-staking-miner
# # pack artifacts
# - mkdir -p ./artifacts
# - mv ./target/release/staking-miner ./artifacts/.
@@ -114,11 +114,30 @@ build-rustdoc:
script:
# FIXME: it fails with `RUSTDOCFLAGS="-Dwarnings"` and `--all-features`
# FIXME: return to stable when https://github.com/rust-lang/rust/issues/96937 gets into stable
- - time cargo doc --workspace --no-deps
+ - time cargo doc --features try-runtime,experimental --workspace --no-deps
- rm -f ./target/doc/.lock
- mv ./target/doc ./crate-docs
# FIXME: remove me after CI image gets nonroot
- chown -R nonroot:nonroot ./crate-docs
+ # Inject Simple Analytics (https://www.simpleanalytics.com/) privacy preserving tracker into
+ # all .html files
+ - |
+ inject_simple_analytics() {
+ local path="$1"
+ local script_content=""
+
+ # Function that inject script into the head of an html file using sed.
+ process_file() {
+ local file="$1"
+ echo "Adding Simple Analytics script to $file"
+ sed -i "s||$script_content|" "$file"
+ }
+ export -f process_file
+
+ # Modify .html files in parallel using xargs, otherwise it can take a long time.
+ find "$path" -name '*.html' | xargs -I {} -P "$(nproc)" bash -c 'process_file "$@"' _ {}
+ }
+ inject_simple_analytics "./crate-docs"
- echo "" > ./crate-docs/index.html
build-implementers-guide:
@@ -146,7 +165,7 @@ build-short-benchmark:
- .run-immediately
- .collect-artifacts
script:
- - cargo build --profile release --locked --features=runtime-benchmarks
+ - cargo build --profile release --locked --features=runtime-benchmarks --bin polkadot
- mkdir -p artifacts
- target/release/polkadot --version
- cp ./target/release/polkadot ./artifacts/
@@ -265,6 +284,19 @@ build-runtime-testing:
- job: build-runtime-starters
artifacts: false
+build-short-benchmark-cumulus:
+ stage: build
+ extends:
+ - .docker-env
+ - .common-refs
+ - .run-immediately
+ - .collect-artifacts
+ script:
+ - cargo build --profile release --locked --features=runtime-benchmarks --bin polkadot-parachain
+ - mkdir -p artifacts
+ - target/release/polkadot-parachain --version
+ - cp ./target/release/polkadot-parachain ./artifacts/
+
# substrate
build-linux-substrate:
@@ -353,4 +385,3 @@ build-subkey-linux:
# after_script: [""]
# tags:
# - osx
-
diff --git a/.gitlab/pipeline/check.yml b/.gitlab/pipeline/check.yml
index efd57ba1d863317af8e4f8f42c23e96129bec471..f88f5808637b89f452fdc77fb3031d40788cc0ba 100644
--- a/.gitlab/pipeline/check.yml
+++ b/.gitlab/pipeline/check.yml
@@ -121,30 +121,6 @@ test-rust-feature-propagation:
--runtime ./target/release/wbuild/"$NETWORK"-runtime/target/wasm32-unknown-unknown/release/"$NETWORK"_runtime.wasm \
on-runtime-upgrade --checks=pre-and-post live --uri wss://${NETWORK}-try-runtime-node.parity-chains.parity.io:443
-check-runtime-migration-polkadot:
- stage: check
- extends:
- - .docker-env
- - .test-pr-refs
- - .check-runtime-migration
- variables:
- NETWORK: "polkadot"
- allow_failure: true # FIXME https://github.com/paritytech/substrate/issues/13107
-
-check-runtime-migration-kusama:
- stage: check
- # DAG
- needs:
- - job: check-runtime-migration-polkadot
- artifacts: false
- extends:
- - .docker-env
- - .test-pr-refs
- - .check-runtime-migration
- variables:
- NETWORK: "kusama"
- allow_failure: true # FIXME https://github.com/paritytech/substrate/issues/13107
-
check-runtime-migration-westend:
stage: check
extends:
@@ -153,7 +129,6 @@ check-runtime-migration-westend:
- .check-runtime-migration
variables:
NETWORK: "westend"
- allow_failure: true # FIXME https://github.com/paritytech/substrate/issues/13107
check-runtime-migration-rococo:
stage: check
@@ -167,7 +142,6 @@ check-runtime-migration-rococo:
- .check-runtime-migration
variables:
NETWORK: "rococo"
- allow_failure: true # FIXME https://github.com/paritytech/substrate/issues/13107
find-fail-ci-phrase:
stage: check
diff --git a/.gitlab/pipeline/short-benchmarks.yml b/.gitlab/pipeline/short-benchmarks.yml
index 2993338cabb15f5d3c01b91d39e0d5a1b4477f35..81601fba32acfcc57415d1da57bb7b5a7c724956 100644
--- a/.gitlab/pipeline/short-benchmarks.yml
+++ b/.gitlab/pipeline/short-benchmarks.yml
@@ -2,6 +2,9 @@
# Here are all jobs that are executed during "short-benchmarks" stage
# Run all pallet benchmarks only once to check if there are any errors
+
+# run short-benchmarks for relay chain runtimes from polkadot
+
short-benchmark-polkadot: &short-bench
stage: short-benchmarks
extends:
@@ -12,6 +15,8 @@ short-benchmark-polkadot: &short-bench
artifacts: true
variables:
RUNTIME: polkadot
+ tags:
+ - benchmark
script:
- ./artifacts/polkadot benchmark pallet --execution wasm --wasm-execution compiled --chain $RUNTIME-dev --pallet "*" --extrinsic "*" --steps 2 --repeat 1
@@ -24,3 +29,60 @@ short-benchmark-westend:
<<: *short-bench
variables:
RUNTIME: westend
+
+# run short-benchmarks for system parachain runtimes from cumulus
+
+.short-benchmark-cumulus: &short-bench-cumulus
+ stage: short-benchmarks
+ extends:
+ - .common-refs
+ - .docker-env
+ needs:
+ - job: build-short-benchmark-cumulus
+ artifacts: true
+ variables:
+ RUNTIME_CHAIN: benchmarked-runtime-chain
+ tags:
+ - benchmark
+ script:
+ - ./artifacts/polkadot-parachain benchmark pallet --wasm-execution compiled --chain $RUNTIME_CHAIN --pallet "*" --extrinsic "*" --steps 2 --repeat 1
+
+short-benchmark-asset-hub-polkadot:
+ <<: *short-bench-cumulus
+ variables:
+ RUNTIME_CHAIN: asset-hub-polkadot-dev
+
+short-benchmark-asset-hub-kusama:
+ <<: *short-bench-cumulus
+ variables:
+ RUNTIME_CHAIN: asset-hub-kusama-dev
+
+short-benchmark-asset-hub-westend:
+ <<: *short-bench-cumulus
+ variables:
+ RUNTIME_CHAIN: asset-hub-westend-dev
+
+short-benchmark-bridge-hub-polkadot:
+ <<: *short-bench-cumulus
+ variables:
+ RUNTIME_CHAIN: bridge-hub-polkadot-dev
+
+short-benchmark-bridge-hub-kusama:
+ <<: *short-bench-cumulus
+ variables:
+ RUNTIME_CHAIN: bridge-hub-kusama-dev
+
+short-benchmark-bridge-hub-rococo:
+ <<: *short-bench-cumulus
+ variables:
+ RUNTIME_CHAIN: bridge-hub-rococo-dev
+
+short-benchmark-collectives-polkadot:
+ <<: *short-bench-cumulus
+ variables:
+ RUNTIME_CHAIN: collectives-polkadot-dev
+
+short-benchmark-glutton-kusama:
+ <<: *short-bench-cumulus
+ variables:
+ RUNTIME_CHAIN: glutton-kusama-dev-1300
diff --git a/.gitlab/pipeline/test.yml b/.gitlab/pipeline/test.yml
index a83ab8c2bfaa60b60dc0b6524939c06f5e5efd06..d128cb0990210f0f1b4fb90fc67fc7d83be2209f 100644
--- a/.gitlab/pipeline/test.yml
+++ b/.gitlab/pipeline/test.yml
@@ -34,7 +34,7 @@ test-linux-stable:
--locked \
--release \
--no-fail-fast \
- --features runtime-benchmarks,try-runtime,experimental \
+ --features try-runtime,experimental \
--partition count:${CI_NODE_INDEX}/${CI_NODE_TOTAL}
# run runtime-api tests with `enable-staging-api` feature on the 1st node
- if [ ${CI_NODE_INDEX} == 1 ]; then time cargo nextest run -p sp-api-test --features enable-staging-api; fi
@@ -92,7 +92,22 @@ test-linux-stable-additional-tests:
--locked \
--release \
--features runtime-benchmarks,try-runtime
- allow_failure: true
+
+# https://github.com/paritytech/ci_cd/issues/864
+test-linux-stable-runtime-benchmarks:
+ stage: test
+ extends:
+ - .docker-env
+ - .common-refs
+ - .run-immediately
+ - .pipeline-stopper-artifacts
+ variables:
+ RUST_TOOLCHAIN: stable
+ # Enable debug assertions since we are running optimized builds for testing
+ # but still want to have debug assertions.
+ RUSTFLAGS: "-Cdebug-assertions=y -Dwarnings"
+ script:
+ - time cargo nextest run --features runtime-benchmarks benchmark --locked --cargo-profile testnet
# these ones can be really slow so it's better to run them separately
test-linux-stable-slow:
@@ -147,7 +162,10 @@ test-doc:
extends:
- .docker-env
- .common-refs
- - .run-immediately
+ # DAG
+ needs:
+ - job: test-rustdoc
+ artifacts: false
variables:
# Enable debug assertions since we are running optimized builds for testing
# but still want to have debug assertions.
@@ -160,10 +178,7 @@ test-rustdoc:
extends:
- .docker-env
- .common-refs
- # DAG
- needs:
- - job: test-doc
- artifacts: false
+ - .run-immediately
variables:
SKIP_WASM_BUILD: 1
RUSTDOCFLAGS: "-Dwarnings"
@@ -196,6 +211,8 @@ test-node-metrics:
# but still want to have debug assertions.
RUSTFLAGS: "-Cdebug-assertions=y -Dwarnings"
script:
+ # Build the required workers.
+ - cargo build --bin polkadot-execute-worker --bin polkadot-prepare-worker --profile testnet --verbose --locked
- mkdir -p artifacts
- time cargo test --profile testnet
--locked
@@ -210,7 +227,7 @@ test-deterministic-wasm:
- .common-refs
# DAG
needs:
- - job: test-frame-support
+ - job: test-frame-ui
artifacts: false
script:
- .gitlab/test_deterministic_wasm.sh
@@ -293,7 +310,7 @@ node-bench-regression-guard:
# if this fails (especially after rust version upgrade) run
# ./substrate/.maintain/update-rust-stable.sh
-test-frame-support:
+test-frame-ui:
stage: test
extends:
- .docker-env
@@ -312,9 +329,8 @@ test-frame-support:
# Ensure we run the UI tests.
RUN_UI_TESTS: 1
script:
- - time cargo test --locked -p frame-support-test --features=frame-feature-testing,no-metadata-docs,try-runtime,experimental --manifest-path ./substrate/frame/support/test/Cargo.toml
- - time cargo test --locked -p frame-support-test --features=frame-feature-testing,frame-feature-testing-2,no-metadata-docs,try-runtime,experimental --manifest-path ./substrate/frame/support/test/Cargo.toml
- - SUBSTRATE_TEST_TIMEOUT=1 time cargo test -p substrate-test-utils --release --locked -- --ignored timeout
+ - time cargo test --locked -q --profile testnet -p frame-support-test --features=frame-feature-testing,no-metadata-docs,try-runtime,experimental
+ - time cargo test --locked -q --profile testnet -p frame-support-test --features=frame-feature-testing,frame-feature-testing-2,no-metadata-docs,try-runtime,experimental
- cat /cargo_target_dir/debug/.fingerprint/memory_units-759eddf317490d2b/lib-memory_units.json || true
# This job runs all benchmarks defined in the `/bin/node/runtime` once to check that there are no errors.
diff --git a/.gitlab/pipeline/zombienet/polkadot.yml b/.gitlab/pipeline/zombienet/polkadot.yml
index e4c56a7d6209f824d521e9baa230d8db50602d4b..87b821742c675b39294c8bfccead1058cf3f9e33 100644
--- a/.gitlab/pipeline/zombienet/polkadot.yml
+++ b/.gitlab/pipeline/zombienet/polkadot.yml
@@ -4,19 +4,24 @@
# common settings for all zombienet jobs
.zombienet-polkadot-common:
before_script:
+ - export BUILD_RELEASE_VERSION="$(cat ./artifacts/BUILD_RELEASE_VERSION)" # from build-linux-stable job
- export DEBUG=zombie,zombie::network-node
- export ZOMBIENET_INTEGRATION_TEST_IMAGE="${POLKADOT_IMAGE}":${PIPELINE_IMAGE_TAG}
+ - export ZOMBIENET_INTEGRATION_TEST_SECONDARY_IMAGE="docker.io/parity/polkadot:${BUILD_RELEASE_VERSION}"
- export COL_IMAGE="${COLANDER_IMAGE}":${PIPELINE_IMAGE_TAG}
- export MALUS_IMAGE="${MALUS_IMAGE}":${PIPELINE_IMAGE_TAG}
- echo "Zombienet Tests Config"
- echo "gh-dir ${GH_DIR}"
- echo "local-dir ${LOCAL_DIR}"
- echo "polkadot image ${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
+ - echo "polkadot secondary image ${ZOMBIENET_INTEGRATION_TEST_SECONDARY_IMAGE}"
- echo "colander image ${COL_IMAGE}"
- echo "malus image ${MALUS_IMAGE}"
stage: zombienet
image: "${ZOMBIENET_IMAGE}"
needs:
+ - job: build-linux-stable
+ artifacts: true
- job: build-push-image-malus
artifacts: true
- job: build-push-image-polkadot-debug
@@ -64,21 +69,29 @@ zombienet-polkadot-functional-0002-parachains-disputes:
--local-dir="${LOCAL_DIR}/functional"
--test="0002-parachains-disputes.zndsl"
-zombienet-polkadot-functional-0003-parachains-disputes-garbage-candidate:
+zombienet-polkadot-functional-0003-beefy-and-mmr:
extends:
- .zombienet-polkadot-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/functional"
- --test="0003-parachains-garbage-candidate.zndsl"
+ --test="0003-beefy-and-mmr.zndsl"
-zombienet-polkadot-functional-0004-beefy-and-mmr:
+zombienet-polkadot-functional-0004-parachains-disputes-garbage-candidate:
extends:
- .zombienet-polkadot-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/functional"
- --test="0003-beefy-and-mmr.zndsl"
+ --test="0004-parachains-garbage-candidate.zndsl"
+
+zombienet-polkadot-functional-0005-parachains-disputes-past-session:
+ extends:
+ - .zombienet-polkadot-common
+ script:
+ - /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
+ --local-dir="${LOCAL_DIR}/functional"
+ --test="0005-parachains-disputes-past-session.zndsl"
zombienet-polkadot-smoke-0001-parachains-smoke-test:
extends:
@@ -168,3 +181,27 @@ zombienet-polkadot-malus-0001-dispute-valid:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/integrationtests"
--test="0001-dispute-valid-block.zndsl"
+
+zombienet-polkadot-async-backing-compatibility:
+ extends:
+ - .zombienet-polkadot-common
+ script:
+ - /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
+ --local-dir="${LOCAL_DIR}/async_backing"
+ --test="001-async-backing-compatibility.zndsl"
+
+zombienet-polkadot-async-backing-runtime-upgrade:
+ extends:
+ - .zombienet-polkadot-common
+ script:
+ - /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
+ --local-dir="${LOCAL_DIR}/async_backing"
+ --test="002-async-backing-runtime-upgrade.zndsl"
+
+zombienet-polkadot-async-backing-collator-mix:
+ extends:
+ - .zombienet-polkadot-common
+ script:
+ - /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
+ --local-dir="${LOCAL_DIR}/async_backing"
+ --test="003-async-backing-collator-mix.zndsl"
diff --git a/.gitlab/test_deterministic_wasm.sh b/.gitlab/test_deterministic_wasm.sh
index 5b04013e1df3d5d6b49f5c78c230ceb2e56cf3f8..4f1d2981ff2b4535b7fba056f9f67500965a9359 100755
--- a/.gitlab/test_deterministic_wasm.sh
+++ b/.gitlab/test_deterministic_wasm.sh
@@ -1,15 +1,17 @@
#!/usr/bin/env bash
+set -e
#shellcheck source=../common/lib.sh
source "$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )/common/lib.sh"
# build runtime
-WASM_BUILD_NO_COLOR=1 cargo build --verbose --release -p kusama-runtime -p polkadot-runtime -p westend-runtime
+WASM_BUILD_NO_COLOR=1 cargo build -q --locked --release -p staging-kusama-runtime -p polkadot-runtime -p westend-runtime
# make checksum
sha256sum target/release/wbuild/*-runtime/target/wasm32-unknown-unknown/release/*.wasm > checksum.sha256
-# clean up - FIXME: can we reuse some of the artifacts?
+
cargo clean
+
# build again
-WASM_BUILD_NO_COLOR=1 cargo build --verbose --release -p kusama-runtime -p polkadot-runtime -p westend-runtime
+WASM_BUILD_NO_COLOR=1 cargo build -q --locked --release -p staging-kusama-runtime -p polkadot-runtime -p westend-runtime
# confirm checksum
sha256sum -c checksum.sha256
diff --git a/.rustfmt.toml b/.rustfmt.toml
index 10568e496801e075a399aa59d0db8003a6a16f85..c34215391239c1f39a1beab05e61b81b6ad60cab 100644
--- a/.rustfmt.toml
+++ b/.rustfmt.toml
@@ -1,4 +1,5 @@
# Basic
+edition = "2021"
hard_tabs = true
max_width = 100
use_small_heuristics = "Max"
@@ -18,10 +19,6 @@ match_block_trailing_comma = true
trailing_comma = "Vertical"
trailing_semicolon = false
use_field_init_shorthand = true
-ignore = [
- "bridges",
-]
-edition = "2021"
# Format comments
comment_width = 100
-wrap_comments = true
\ No newline at end of file
+wrap_comments = true
diff --git a/Cargo.lock b/Cargo.lock
index 781e464d125f0a8c0ad9d7f4f256519d7ad68b9e..c254302517f00a74e128ad3874b2ec694f00de08 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -499,11 +499,12 @@ dependencies = [
[[package]]
name = "ark-scale"
-version = "0.0.3"
+version = "0.0.10"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4d028cd1025d002fa88c10cd644d29028a7b40806579b608c6ba843b937bbb23"
+checksum = "49b08346a3e38e2be792ef53ee168623c9244d968ff00cd70fb9932f6fe36393"
dependencies = [
"ark-ec",
+ "ark-ff",
"ark-serialize",
"ark-std",
"parity-scale-codec",
@@ -512,7 +513,7 @@ dependencies = [
[[package]]
name = "ark-secret-scalar"
version = "0.0.2"
-source = "git+https://github.com/w3f/ring-vrf?rev=c86ebd4#c86ebd4114d3165d05f9ce28c1d9e8d7a9a4e801"
+source = "git+https://github.com/w3f/ring-vrf?rev=3119f51#3119f51b54b69308abfb0671f6176cb125ae1bf1"
dependencies = [
"ark-ec",
"ark-ff",
@@ -560,7 +561,7 @@ dependencies = [
[[package]]
name = "ark-transcript"
version = "0.0.2"
-source = "git+https://github.com/w3f/ring-vrf?rev=c86ebd4#c86ebd4114d3165d05f9ce28c1d9e8d7a9a4e801"
+source = "git+https://github.com/w3f/ring-vrf?rev=3119f51#3119f51b54b69308abfb0671f6176cb125ae1bf1"
dependencies = [
"ark-ff",
"ark-serialize",
@@ -697,9 +698,6 @@ version = "1.0.0"
dependencies = [
"assert_matches",
"asset-hub-kusama-runtime",
- "cumulus-pallet-dmp-queue",
- "cumulus-pallet-parachain-system",
- "cumulus-pallet-xcmp-queue",
"frame-support",
"frame-system",
"integration-tests-common",
@@ -710,15 +708,12 @@ dependencies = [
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime",
"polkadot-runtime-parachains",
- "sp-core",
"sp-runtime",
- "sp-weights",
- "xcm",
+ "staging-xcm",
"xcm-emulator",
- "xcm-executor",
]
[[package]]
@@ -770,7 +765,7 @@ dependencies = [
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-common",
"primitive-types",
"scale-info",
@@ -788,37 +783,33 @@ dependencies = [
"sp-transaction-pool",
"sp-version",
"sp-weights",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
name = "asset-hub-polkadot-integration-tests"
version = "1.0.0"
dependencies = [
- "cumulus-pallet-dmp-queue",
- "cumulus-pallet-parachain-system",
- "cumulus-pallet-xcmp-queue",
+ "asset-hub-kusama-runtime",
"frame-support",
"frame-system",
"integration-tests-common",
+ "pallet-asset-conversion",
"pallet-assets",
"pallet-balances",
"pallet-xcm",
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime",
"polkadot-runtime-parachains",
- "sp-core",
"sp-runtime",
- "sp-weights",
- "xcm",
+ "staging-xcm",
"xcm-emulator",
- "xcm-executor",
]
[[package]]
@@ -866,7 +857,7 @@ dependencies = [
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-common",
"polkadot-runtime-constants",
"scale-info",
@@ -884,10 +875,10 @@ dependencies = [
"sp-transaction-pool",
"sp-version",
"sp-weights",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -896,9 +887,6 @@ version = "1.0.0"
dependencies = [
"assert_matches",
"asset-hub-westend-runtime",
- "cumulus-pallet-dmp-queue",
- "cumulus-pallet-parachain-system",
- "cumulus-pallet-xcmp-queue",
"frame-support",
"frame-system",
"integration-tests-common",
@@ -909,15 +897,12 @@ dependencies = [
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime",
"polkadot-runtime-parachains",
- "sp-core",
"sp-runtime",
- "sp-weights",
- "xcm",
+ "staging-xcm",
"xcm-emulator",
- "xcm-executor",
]
[[package]]
@@ -967,7 +952,7 @@ dependencies = [
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-common",
"primitive-types",
"scale-info",
@@ -985,11 +970,11 @@ dependencies = [
"sp-storage",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
"westend-runtime-constants",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -1015,15 +1000,15 @@ dependencies = [
"parachains-common",
"parachains-runtimes-test-utils",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"sp-consensus-aura",
"sp-core",
"sp-io",
"sp-runtime",
"sp-std",
+ "staging-xcm",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-executor",
]
[[package]]
@@ -1043,10 +1028,10 @@ dependencies = [
"sp-api",
"sp-runtime",
"sp-std",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -1153,7 +1138,7 @@ checksum = "0e97ce7de6cf12de5d7226c73f5ba9811622f4db3a5b91b55c53e987e5f91cba"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -1175,7 +1160,7 @@ checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -1192,7 +1177,7 @@ checksum = "bc00ceb34980c03614e35a3a4e218276a0a824e911d07651cd0d858a51e8c0f0"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -1255,12 +1240,13 @@ dependencies = [
[[package]]
name = "bandersnatch_vrfs"
version = "0.0.1"
-source = "git+https://github.com/w3f/ring-vrf?rev=c86ebd4#c86ebd4114d3165d05f9ce28c1d9e8d7a9a4e801"
+source = "git+https://github.com/w3f/ring-vrf?rev=3119f51#3119f51b54b69308abfb0671f6176cb125ae1bf1"
dependencies = [
"ark-bls12-381",
"ark-ec",
"ark-ed-on-bls12-381-bandersnatch",
"ark-ff",
+ "ark-scale",
"ark-serialize",
"ark-std",
"dleq_vrf",
@@ -1366,7 +1352,7 @@ dependencies = [
"regex",
"rustc-hash",
"shlex",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -1865,7 +1851,7 @@ dependencies = [
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-common",
"scale-info",
"serde",
@@ -1883,10 +1869,10 @@ dependencies = [
"sp-storage",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -1927,7 +1913,7 @@ dependencies = [
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-common",
"polkadot-runtime-constants",
"scale-info",
@@ -1946,10 +1932,10 @@ dependencies = [
"sp-storage",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -1957,27 +1943,20 @@ name = "bridge-hub-rococo-integration-tests"
version = "1.0.0"
dependencies = [
"bp-messages",
- "cumulus-pallet-parachain-system",
+ "cumulus-pallet-dmp-queue",
"cumulus-pallet-xcmp-queue",
"frame-support",
- "frame-system",
"integration-tests-common",
- "pallet-assets",
- "pallet-balances",
"pallet-bridge-messages",
"pallet-xcm",
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime",
"polkadot-runtime-parachains",
- "sp-core",
- "sp-runtime",
- "sp-weights",
- "xcm",
+ "staging-xcm",
"xcm-emulator",
- "xcm-executor",
]
[[package]]
@@ -2033,7 +2012,7 @@ dependencies = [
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-common",
"rococo-runtime-constants",
"scale-info",
@@ -2053,11 +2032,11 @@ dependencies = [
"sp-storage",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"static_assertions",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -2102,9 +2081,9 @@ dependencies = [
"sp-io",
"sp-keyring",
"sp-runtime",
- "xcm",
- "xcm-builder",
- "xcm-executor",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
]
[[package]]
@@ -2138,9 +2117,9 @@ dependencies = [
"sp-runtime",
"sp-std",
"sp-trie",
+ "staging-xcm",
+ "staging-xcm-builder",
"static_assertions",
- "xcm",
- "xcm-builder",
]
[[package]]
@@ -2355,7 +2334,7 @@ name = "chain-spec-builder"
version = "2.0.0"
dependencies = [
"ansi_term",
- "clap 4.4.0",
+ "clap 4.4.2",
"node-cli",
"rand 0.8.5",
"sc-chain-spec",
@@ -2486,20 +2465,19 @@ dependencies = [
[[package]]
name = "clap"
-version = "4.4.0"
+version = "4.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1d5f1946157a96594eb2d2c10eb7ad9a2b27518cb3000209dec700c35df9197d"
+checksum = "6a13b88d2c62ff462f88e4a121f17a82c1af05693a2f192b5c38d14de73c19f6"
dependencies = [
"clap_builder",
- "clap_derive 4.4.0",
- "once_cell",
+ "clap_derive 4.4.2",
]
[[package]]
name = "clap_builder"
-version = "4.4.0"
+version = "4.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "78116e32a042dd73c2901f0dc30790d20ff3447f3e3472fad359e8c3d282bcd6"
+checksum = "2bb9faaa7c2ef94b2743a21f5a29e6f0010dff4caa69ac8e9d6cf8b6fa74da08"
dependencies = [
"anstream",
"anstyle",
@@ -2513,7 +2491,7 @@ version = "4.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "586a385f7ef2f8b4d86bddaa0c094794e7ccbfe5ffef1f434fe928143fc783a5"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
]
[[package]]
@@ -2531,14 +2509,14 @@ dependencies = [
[[package]]
name = "clap_derive"
-version = "4.4.0"
+version = "4.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c9fd1a5729c4548118d7d70ff234a44868d00489a4b6597b0b020918a0e91a1a"
+checksum = "0862016ff20d69b84ef8247369fabf5c008a7417002411897d40ee1f4532b873"
dependencies = [
"heck",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -2582,30 +2560,25 @@ dependencies = [
name = "collectives-polkadot-integration-tests"
version = "0.1.0"
dependencies = [
- "asset-hub-polkadot-runtime",
"collectives-polkadot-runtime",
"cumulus-pallet-parachain-system",
"cumulus-pallet-xcmp-queue",
"frame-support",
- "frame-system",
"integration-tests-common",
"pallet-assets",
- "pallet-balances",
"pallet-core-fellowship",
"pallet-salary",
"pallet-xcm",
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime",
"polkadot-runtime-parachains",
"sp-core",
"sp-runtime",
- "sp-weights",
- "xcm",
+ "staging-xcm",
"xcm-emulator",
- "xcm-executor",
]
[[package]]
@@ -2653,7 +2626,7 @@ dependencies = [
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-common",
"polkadot-runtime-constants",
"scale-info",
@@ -2672,10 +2645,10 @@ dependencies = [
"sp-storage",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -2732,7 +2705,7 @@ dependencies = [
[[package]]
name = "common"
version = "0.1.0"
-source = "git+https://github.com/w3f/ring-proof#0e948f3c28cbacecdd3020403c4841c0eb339213"
+source = "git+https://github.com/w3f/ring-proof?rev=0e948f3#0e948f3c28cbacecdd3020403c4841c0eb339213"
dependencies = [
"ark-ec",
"ark-ff",
@@ -2864,7 +2837,7 @@ dependencies = [
"parachains-common",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-common",
"scale-info",
"smallvec",
@@ -2880,10 +2853,10 @@ dependencies = [
"sp-storage",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -3113,7 +3086,7 @@ dependencies = [
"anes",
"cast",
"ciborium",
- "clap 4.4.0",
+ "clap 4.4.2",
"criterion-plot",
"futures",
"is-terminal",
@@ -3278,7 +3251,7 @@ dependencies = [
name = "cumulus-client-cli"
version = "0.1.0"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"parity-scale-codec",
"sc-chain-spec",
"sc-cli",
@@ -3442,7 +3415,7 @@ dependencies = [
"parity-scale-codec",
"parking_lot 0.12.1",
"polkadot-node-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-test-client",
"portpicker",
@@ -3555,7 +3528,7 @@ dependencies = [
"sp-runtime",
"sp-std",
"sp-version",
- "xcm",
+ "staging-xcm",
]
[[package]]
@@ -3577,7 +3550,7 @@ dependencies = [
"lazy_static",
"log",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"sc-client-api",
"scale-info",
"sp-core",
@@ -3591,8 +3564,8 @@ dependencies = [
"sp-tracing",
"sp-trie",
"sp-version",
+ "staging-xcm",
"trie-db",
- "xcm",
]
[[package]]
@@ -3602,7 +3575,7 @@ dependencies = [
"proc-macro-crate",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -3645,7 +3618,7 @@ dependencies = [
"sp-io",
"sp-runtime",
"sp-std",
- "xcm",
+ "staging-xcm",
]
[[package]]
@@ -3667,9 +3640,9 @@ dependencies = [
"sp-io",
"sp-runtime",
"sp-std",
- "xcm",
- "xcm-builder",
- "xcm-executor",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
]
[[package]]
@@ -3684,7 +3657,7 @@ dependencies = [
"scale-info",
"sp-runtime",
"sp-std",
- "xcm",
+ "staging-xcm",
]
[[package]]
@@ -3706,14 +3679,14 @@ version = "0.1.0"
dependencies = [
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"scale-info",
"sp-api",
"sp-runtime",
"sp-std",
"sp-trie",
- "xcm",
+ "staging-xcm",
]
[[package]]
@@ -3762,9 +3735,9 @@ dependencies = [
"sp-io",
"sp-runtime",
"sp-std",
- "xcm",
- "xcm-builder",
- "xcm-executor",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
]
[[package]]
@@ -3896,7 +3869,7 @@ dependencies = [
"pallet-balances",
"pallet-transaction-payment",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"sc-block-builder",
"sc-consensus",
@@ -3971,7 +3944,7 @@ name = "cumulus-test-service"
version = "0.1.0"
dependencies = [
"async-trait",
- "clap 4.4.0",
+ "clap 4.4.2",
"criterion 0.5.1",
"cumulus-client-cli",
"cumulus-client-consensus-common",
@@ -4094,7 +4067,7 @@ checksum = "83fdaf97f4804dcebfa5862639bc9ce4121e82140bec2a987ac5140294865b5b"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -4134,7 +4107,7 @@ dependencies = [
"proc-macro2",
"quote",
"scratch",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -4151,7 +4124,7 @@ checksum = "50c49547d73ba8dcfd4ad7325d64c6d5391ff4224d498fc39a6f3f49825a530d"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -4449,7 +4422,7 @@ checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -4461,10 +4434,11 @@ checksum = "86e3bdc80eee6e16b2b6b0f87fbc98c04bee3455e35174c0de1a125d0688c632"
[[package]]
name = "dleq_vrf"
version = "0.0.2"
-source = "git+https://github.com/w3f/ring-vrf?rev=c86ebd4#c86ebd4114d3165d05f9ce28c1d9e8d7a9a4e801"
+source = "git+https://github.com/w3f/ring-vrf?rev=3119f51#3119f51b54b69308abfb0671f6176cb125ae1bf1"
dependencies = [
"ark-ec",
"ark-ff",
+ "ark-scale",
"ark-secret-scalar",
"ark-serialize",
"ark-std",
@@ -4510,7 +4484,7 @@ dependencies = [
"proc-macro2",
"quote",
"regex",
- "syn 2.0.29",
+ "syn 2.0.31",
"termcolor",
"toml 0.7.6",
"walkdir",
@@ -4754,7 +4728,7 @@ checksum = "5e9a1f9f7d83e59740248a6e14ecf93929ade55027844dfcea78beafccc15745"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -4765,7 +4739,7 @@ checksum = "b893c4eb2dc092c811165f84dc7447fae16fb66521717968c34c509b39b1a5c5"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -4928,7 +4902,7 @@ dependencies = [
"fs-err",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -5218,7 +5192,7 @@ dependencies = [
"Inflector",
"array-bytes",
"chrono",
- "clap 4.4.0",
+ "clap 4.4.2",
"comfy-table",
"frame-benchmarking",
"frame-support",
@@ -5284,7 +5258,7 @@ dependencies = [
"quote",
"scale-info",
"sp-arithmetic",
- "syn 2.0.29",
+ "syn 2.0.31",
"trybuild",
]
@@ -5310,7 +5284,7 @@ dependencies = [
name = "frame-election-solution-type-fuzzer"
version = "2.0.0-alpha.5"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"frame-election-provider-solution-type",
"frame-election-provider-support",
"frame-support",
@@ -5436,7 +5410,7 @@ dependencies = [
"proc-macro-warning",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -5447,7 +5421,7 @@ dependencies = [
"proc-macro-crate",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -5456,7 +5430,7 @@ version = "3.0.0"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -5679,7 +5653,7 @@ checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -5892,10 +5866,10 @@ dependencies = [
"sp-storage",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -6435,7 +6409,6 @@ dependencies = [
"asset-hub-polkadot-runtime",
"asset-hub-westend-runtime",
"bp-messages",
- "bp-runtime",
"bridge-hub-kusama-runtime",
"bridge-hub-polkadot-runtime",
"bridge-hub-rococo-runtime",
@@ -6446,24 +6419,19 @@ dependencies = [
"cumulus-pallet-xcmp-queue",
"cumulus-primitives-core",
"frame-support",
- "frame-system",
- "kusama-runtime",
"kusama-runtime-constants",
- "lazy_static",
"pallet-assets",
- "pallet-balances",
"pallet-bridge-messages",
"pallet-im-online",
"pallet-message-queue",
"pallet-staking",
"pallet-xcm",
- "parachain-info",
"parachains-common",
"parity-scale-codec",
"paste",
"penpal-runtime",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-runtime",
"polkadot-runtime-constants",
@@ -6477,13 +6445,11 @@ dependencies = [
"sp-consensus-beefy",
"sp-core",
"sp-runtime",
- "sp-tracing",
- "sp-weights",
+ "staging-kusama-runtime",
+ "staging-xcm",
"westend-runtime",
"westend-runtime-constants",
- "xcm",
"xcm-emulator",
- "xcm-executor",
]
[[package]]
@@ -6505,12 +6471,6 @@ dependencies = [
"webrtc-util",
]
-[[package]]
-name = "intx"
-version = "0.1.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f6f38a50a899dc47a6d0ed5508e7f601a2e34c3a85303514b5d137f3c10a0c75"
-
[[package]]
name = "io-lifetimes"
version = "1.0.11"
@@ -6915,119 +6875,6 @@ dependencies = [
"substrate-wasm-builder",
]
-[[package]]
-name = "kusama-runtime"
-version = "1.0.0"
-dependencies = [
- "binary-merkle-tree",
- "bitvec",
- "frame-benchmarking",
- "frame-election-provider-support",
- "frame-executive",
- "frame-remote-externalities",
- "frame-support",
- "frame-system",
- "frame-system-benchmarking",
- "frame-system-rpc-runtime-api",
- "frame-try-runtime",
- "hex-literal 0.4.1",
- "kusama-runtime-constants",
- "log",
- "pallet-authority-discovery",
- "pallet-authorship",
- "pallet-babe",
- "pallet-bags-list",
- "pallet-balances",
- "pallet-beefy",
- "pallet-beefy-mmr",
- "pallet-bounties",
- "pallet-child-bounties",
- "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-nis",
- "pallet-nomination-pools",
- "pallet-nomination-pools-benchmarking",
- "pallet-nomination-pools-runtime-api",
- "pallet-offences",
- "pallet-offences-benchmarking",
- "pallet-preimage",
- "pallet-proxy",
- "pallet-ranked-collective",
- "pallet-recovery",
- "pallet-referenda",
- "pallet-scheduler",
- "pallet-session",
- "pallet-session-benchmarking",
- "pallet-society",
- "pallet-staking",
- "pallet-staking-runtime-api",
- "pallet-state-trie-migration",
- "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-primitives",
- "polkadot-runtime-common",
- "polkadot-runtime-parachains",
- "rustc-hex",
- "scale-info",
- "separator",
- "serde",
- "serde_derive",
- "serde_json",
- "smallvec",
- "sp-api",
- "sp-application-crypto",
- "sp-arithmetic",
- "sp-authority-discovery",
- "sp-block-builder",
- "sp-consensus-babe",
- "sp-consensus-beefy",
- "sp-core",
- "sp-inherents",
- "sp-io",
- "sp-keyring",
- "sp-mmr-primitives",
- "sp-npos-elections",
- "sp-offchain",
- "sp-runtime",
- "sp-session",
- "sp-staking",
- "sp-std",
- "sp-storage",
- "sp-tracing",
- "sp-transaction-pool",
- "sp-trie",
- "sp-version",
- "static_assertions",
- "substrate-wasm-builder",
- "tiny-keccak",
- "tokio",
- "xcm",
- "xcm-builder",
- "xcm-executor",
-]
-
[[package]]
name = "kusama-runtime-constants"
version = "1.0.0"
@@ -7813,7 +7660,7 @@ dependencies = [
"macro_magic_core",
"macro_magic_macros",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -7827,7 +7674,7 @@ dependencies = [
"macro_magic_core_macros",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -7838,7 +7685,7 @@ checksum = "c12469fc165526520dff2807c2975310ab47cf7190a45b99b49a7dc8befab17b"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -7849,7 +7696,7 @@ checksum = "b8fb85ec1620619edf2984a7693497d4ec88a9665d8b87e942856884c92dbf2a"
dependencies = [
"macro_magic_core",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -8345,7 +8192,7 @@ name = "node-bench"
version = "0.9.0-dev"
dependencies = [
"array-bytes",
- "clap 4.4.0",
+ "clap 4.4.2",
"derive_more",
"fs_extra",
"futures",
@@ -8382,7 +8229,7 @@ version = "3.0.0-dev"
dependencies = [
"array-bytes",
"assert_cmd",
- "clap 4.4.0",
+ "clap 4.4.2",
"clap_complete",
"criterion 0.4.0",
"frame-benchmarking-cli",
@@ -8508,7 +8355,7 @@ dependencies = [
name = "node-inspect"
version = "0.9.0-dev"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"parity-scale-codec",
"sc-cli",
"sc-client-api",
@@ -8562,7 +8409,7 @@ dependencies = [
name = "node-runtime-generate-bags"
version = "3.0.0"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"generate-bags",
"kitchensink-runtime",
]
@@ -8571,7 +8418,7 @@ dependencies = [
name = "node-template"
version = "4.0.0-dev"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"frame-benchmarking",
"frame-benchmarking-cli",
"frame-system",
@@ -8614,7 +8461,7 @@ dependencies = [
name = "node-template-release"
version = "3.0.0"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"flate2",
"fs_extra",
"glob",
@@ -9534,7 +9381,7 @@ dependencies = [
"sp-runtime",
"sp-std",
"wasm-instrument 0.4.0",
- "wasmi 0.30.0",
+ "wasmi",
"wat",
]
@@ -9556,7 +9403,7 @@ version = "4.0.0-dev"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -10083,7 +9930,6 @@ dependencies = [
name = "pallet-nfts-runtime-api"
version = "4.0.0-dev"
dependencies = [
- "frame-support",
"pallet-nfts",
"parity-scale-codec",
"sp-api",
@@ -10628,7 +10474,7 @@ dependencies = [
"proc-macro2",
"quote",
"sp-runtime",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -10942,7 +10788,7 @@ dependencies = [
"log",
"pallet-balances",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-parachains",
"scale-info",
"serde",
@@ -10950,9 +10796,9 @@ dependencies = [
"sp-io",
"sp-runtime",
"sp-std",
- "xcm",
- "xcm-builder",
- "xcm-executor",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
]
[[package]]
@@ -10975,9 +10821,9 @@ dependencies = [
"sp-runtime",
"sp-std",
"sp-tracing",
- "xcm",
- "xcm-builder",
- "xcm-executor",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
]
[[package]]
@@ -10995,8 +10841,8 @@ dependencies = [
"sp-io",
"sp-runtime",
"sp-std",
- "xcm",
- "xcm-builder",
+ "staging-xcm",
+ "staging-xcm-builder",
]
[[package]]
@@ -11016,7 +10862,7 @@ dependencies = [
name = "parachain-template-node"
version = "0.1.0"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"color-print",
"cumulus-client-cli",
"cumulus-client-collator",
@@ -11063,10 +10909,10 @@ dependencies = [
"sp-keystore",
"sp-runtime",
"sp-timestamp",
+ "staging-xcm",
"substrate-build-script-utils",
"substrate-frame-rpc-system",
"substrate-prometheus-endpoint",
- "xcm",
]
[[package]]
@@ -11103,7 +10949,7 @@ dependencies = [
"pallet-xcm",
"parachain-info",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-common",
"scale-info",
"smallvec",
@@ -11118,10 +10964,10 @@ dependencies = [
"sp-std",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -11132,6 +10978,7 @@ dependencies = [
"cumulus-primitives-utility",
"frame-support",
"frame-system",
+ "kusama-runtime-constants",
"log",
"num-traits",
"pallet-asset-tx-payment",
@@ -11140,17 +10987,22 @@ dependencies = [
"pallet-balances",
"pallet-collator-selection",
"parity-scale-codec",
+ "polkadot-core-primitives",
"polkadot-primitives",
+ "polkadot-runtime-constants",
+ "rococo-runtime-constants",
"scale-info",
+ "smallvec",
"sp-consensus-aura",
"sp-core",
"sp-io",
"sp-runtime",
"sp-std",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
+ "westend-runtime-constants",
]
[[package]]
@@ -11175,16 +11027,16 @@ dependencies = [
"parachain-info",
"parachains-common",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"sp-consensus-aura",
"sp-core",
"sp-io",
"sp-runtime",
"sp-std",
"sp-tracing",
+ "staging-xcm",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-executor",
]
[[package]]
@@ -11428,7 +11280,7 @@ dependencies = [
"parachain-info",
"parachains-common",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-runtime-common",
"scale-info",
@@ -11445,10 +11297,10 @@ dependencies = [
"sp-storage",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -11487,7 +11339,7 @@ dependencies = [
"pest_meta",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -11528,7 +11380,7 @@ checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -11746,7 +11598,7 @@ dependencies = [
name = "polkadot-cli"
version = "1.0.0"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"frame-benchmarking-cli",
"futures",
"log",
@@ -12063,7 +11915,7 @@ dependencies = [
"polkadot-node-subsystem-test-helpers",
"polkadot-node-subsystem-util",
"polkadot-overseer",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-primitives-test-helpers",
"sp-core",
@@ -12220,7 +12072,7 @@ dependencies = [
"polkadot-node-core-pvf-prepare-worker",
"polkadot-node-metrics",
"polkadot-node-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"rand 0.8.5",
"slotmap",
@@ -12269,7 +12121,7 @@ dependencies = [
"landlock",
"libc",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"sc-executor",
"sc-executor-common",
@@ -12291,13 +12143,12 @@ dependencies = [
"futures",
"parity-scale-codec",
"polkadot-node-core-pvf-common",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"rayon",
"sp-core",
"sp-maybe-compressed-blob",
"sp-tracing",
- "tikv-jemalloc-ctl",
"tokio",
"tracing-gum",
]
@@ -12310,7 +12161,7 @@ dependencies = [
"libc",
"parity-scale-codec",
"polkadot-node-core-pvf-common",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"rayon",
"sc-executor",
@@ -12367,7 +12218,7 @@ name = "polkadot-node-metrics"
version = "1.0.0"
dependencies = [
"assert_cmd",
- "bs58 0.4.0",
+ "bs58 0.5.0",
"futures",
"futures-timer",
"hyper",
@@ -12420,7 +12271,7 @@ dependencies = [
"futures",
"parity-scale-codec",
"polkadot-erasure-coding",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"schnorrkel 0.9.1",
"serde",
@@ -12431,7 +12282,7 @@ dependencies = [
"sp-maybe-compressed-blob",
"sp-runtime",
"thiserror",
- "zstd 0.11.2+zstd.1.5.2",
+ "zstd 0.12.4",
]
[[package]]
@@ -12551,22 +12402,6 @@ dependencies = [
"tracing-gum",
]
-[[package]]
-name = "polkadot-parachain"
-version = "1.0.0"
-dependencies = [
- "bounded-collections",
- "derive_more",
- "frame-support",
- "parity-scale-codec",
- "polkadot-core-primitives",
- "scale-info",
- "serde",
- "sp-core",
- "sp-runtime",
- "sp-std",
-]
-
[[package]]
name = "polkadot-parachain-bin"
version = "1.0.0"
@@ -12579,7 +12414,7 @@ dependencies = [
"bridge-hub-kusama-runtime",
"bridge-hub-polkadot-runtime",
"bridge-hub-rococo-runtime",
- "clap 4.4.0",
+ "clap 4.4.2",
"collectives-polkadot-runtime",
"color-print",
"contracts-rococo-runtime",
@@ -12640,6 +12475,7 @@ dependencies = [
"sp-session",
"sp-timestamp",
"sp-transaction-pool",
+ "staging-xcm",
"substrate-build-script-utils",
"substrate-frame-rpc-system",
"substrate-prometheus-endpoint",
@@ -12647,7 +12483,22 @@ dependencies = [
"tempfile",
"tokio",
"wait-timeout",
- "xcm",
+]
+
+[[package]]
+name = "polkadot-parachain-primitives"
+version = "1.0.0"
+dependencies = [
+ "bounded-collections",
+ "derive_more",
+ "frame-support",
+ "parity-scale-codec",
+ "polkadot-core-primitives",
+ "scale-info",
+ "serde",
+ "sp-core",
+ "sp-runtime",
+ "sp-std",
]
[[package]]
@@ -12655,7 +12506,6 @@ name = "polkadot-performance-test"
version = "1.0.0"
dependencies = [
"env_logger 0.9.3",
- "kusama-runtime",
"log",
"polkadot-erasure-coding",
"polkadot-node-core-pvf-prepare-worker",
@@ -12664,6 +12514,7 @@ dependencies = [
"quote",
"sc-executor-common",
"sp-maybe-compressed-blob",
+ "staging-kusama-runtime",
"thiserror",
]
@@ -12675,7 +12526,7 @@ dependencies = [
"hex-literal 0.4.1",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"scale-info",
"serde",
"sp-api",
@@ -12830,13 +12681,13 @@ dependencies = [
"sp-transaction-pool",
"sp-trie",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"static_assertions",
"substrate-wasm-builder",
"tiny-keccak",
"tokio",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -12886,8 +12737,8 @@ dependencies = [
"sp-session",
"sp-staking",
"sp-std",
+ "staging-xcm",
"static_assertions",
- "xcm",
]
[[package]]
@@ -12907,7 +12758,7 @@ dependencies = [
name = "polkadot-runtime-metrics"
version = "1.0.0"
dependencies = [
- "bs58 0.4.0",
+ "bs58 0.5.0",
"frame-benchmarking",
"parity-scale-codec",
"polkadot-primitives",
@@ -12940,7 +12791,7 @@ dependencies = [
"pallet-timestamp",
"pallet-vesting",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-primitives-test-helpers",
"polkadot-runtime-metrics",
@@ -12963,10 +12814,10 @@ dependencies = [
"sp-staking",
"sp-std",
"sp-tracing",
+ "staging-xcm",
+ "staging-xcm-executor",
"static_assertions",
"thousands",
- "xcm",
- "xcm-executor",
]
[[package]]
@@ -12984,7 +12835,6 @@ dependencies = [
"futures",
"hex-literal 0.4.1",
"is_executable",
- "kusama-runtime",
"kusama-runtime-constants",
"kvdb",
"kvdb-rocksdb",
@@ -13028,7 +12878,7 @@ dependencies = [
"polkadot-node-subsystem-types",
"polkadot-node-subsystem-util",
"polkadot-overseer",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-rpc",
"polkadot-runtime",
@@ -13089,6 +12939,7 @@ dependencies = [
"sp-transaction-pool",
"sp-version",
"sp-weights",
+ "staging-kusama-runtime",
"substrate-prometheus-endpoint",
"tempfile",
"thiserror",
@@ -13176,7 +13027,7 @@ version = "1.0.0"
dependencies = [
"assert_matches",
"async-trait",
- "clap 4.4.0",
+ "clap 4.4.2",
"color-eyre",
"futures",
"futures-timer",
@@ -13230,7 +13081,7 @@ dependencies = [
"pallet-vesting",
"pallet-xcm",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-runtime-common",
"polkadot-runtime-parachains",
@@ -13258,12 +13109,12 @@ dependencies = [
"sp-transaction-pool",
"sp-trie",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
"test-runtime-constants",
"tiny-keccak",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -13279,7 +13130,7 @@ dependencies = [
"polkadot-node-primitives",
"polkadot-node-subsystem",
"polkadot-overseer",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-rpc",
"polkadot-runtime-common",
@@ -13322,11 +13173,11 @@ dependencies = [
name = "polkadot-voter-bags"
version = "1.0.0"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"generate-bags",
- "kusama-runtime",
"polkadot-runtime",
"sp-io",
+ "staging-kusama-runtime",
"westend-runtime",
]
@@ -13502,7 +13353,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6c64d9ba0963cdcea2e1b2230fbae2bab30eb25a174be395c41e764bfb65dd62"
dependencies = [
"proc-macro2",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -13578,13 +13429,13 @@ checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068"
[[package]]
name = "proc-macro-warning"
-version = "0.4.1"
+version = "0.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "70550716265d1ec349c41f70dd4f964b4fd88394efe4405f0c1da679c4799a07"
+checksum = "3d1eaa7fa0aa1929ffdf7eeb6eac234dde6268914a14ad44d23521ab6a9b258e"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -13630,7 +13481,7 @@ checksum = "440f724eba9f6996b75d63681b0a92b06947f1457076d503a4d2e2c8f56442b8"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -14021,7 +13872,7 @@ checksum = "7f7473c2cfcf90008193dd0e3e16599455cb601a9fce322b5bb55de799664925"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -14084,9 +13935,8 @@ checksum = "e5ea92a5b6195c6ef2a0295ea818b312502c6fc94dde986c5553242e18fd4ce2"
name = "remote-ext-tests-bags-list"
version = "1.0.0"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"frame-system",
- "kusama-runtime",
"kusama-runtime-constants",
"log",
"pallet-bags-list-remote-tests",
@@ -14094,6 +13944,7 @@ dependencies = [
"polkadot-runtime-constants",
"sp-core",
"sp-tracing",
+ "staging-kusama-runtime",
"tokio",
"westend-runtime",
"westend-runtime-constants",
@@ -14172,7 +14023,7 @@ dependencies = [
[[package]]
name = "ring"
version = "0.1.0"
-source = "git+https://github.com/w3f/ring-proof#0e948f3c28cbacecdd3020403c4841c0eb339213"
+source = "git+https://github.com/w3f/ring-proof?rev=0e948f3#0e948f3c28cbacecdd3020403c4841c0eb339213"
dependencies = [
"ark-ec",
"ark-ff",
@@ -14253,7 +14104,7 @@ dependencies = [
"parachain-info",
"parachains-common",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"scale-info",
"sp-api",
"sp-block-builder",
@@ -14266,10 +14117,10 @@ dependencies = [
"sp-std",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -14327,7 +14178,7 @@ dependencies = [
"pallet-xcm",
"pallet-xcm-benchmarks",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-runtime-common",
"polkadot-runtime-parachains",
@@ -14358,13 +14209,13 @@ dependencies = [
"sp-transaction-pool",
"sp-trie",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"static_assertions",
"substrate-wasm-builder",
"tiny-keccak",
"tokio",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -14783,7 +14634,7 @@ dependencies = [
"proc-macro-crate",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -14792,7 +14643,7 @@ version = "0.10.0-dev"
dependencies = [
"array-bytes",
"chrono",
- "clap 4.4.0",
+ "clap 4.4.2",
"fdlimit",
"futures",
"futures-timer",
@@ -15896,7 +15747,7 @@ dependencies = [
name = "sc-storage-monitor"
version = "0.1.0"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"fs4",
"log",
"sc-client-db",
@@ -15996,7 +15847,7 @@ dependencies = [
"proc-macro-crate",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -16335,22 +16186,22 @@ checksum = "f97841a747eef040fcd2e7b3b9a220a7205926e60488e673d9e4926d27772ce5"
[[package]]
name = "serde"
-version = "1.0.186"
+version = "1.0.188"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9f5db24220c009de9bd45e69fb2938f4b6d2df856aa9304ce377b3180f83b7c1"
+checksum = "cf9e0fcba69a370eed61bcf2b728575f726b50b55cba78064753d708ddc7549e"
dependencies = [
"serde_derive",
]
[[package]]
name = "serde_derive"
-version = "1.0.186"
+version = "1.0.188"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5ad697f7e0b65af4983a4ce8f56ed5b357e8d3c36651bf6a7e13639c17b8e670"
+checksum = "4eca7ac642d82aa35b60049a6eccb4be6be75e599bd2e9adb5f875a737654af2"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -16416,7 +16267,7 @@ checksum = "91d129178576168c589c9ec973feedf7d3126c01ac2bf08795109aa35b69fb8f"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -16534,10 +16385,10 @@ dependencies = [
"sp-std",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -16723,7 +16574,7 @@ dependencies = [
"smallvec",
"soketto",
"twox-hash",
- "wasmi 0.31.0",
+ "wasmi",
"x25519-dalek 2.0.0",
"zeroize",
]
@@ -16856,7 +16707,7 @@ dependencies = [
"proc-macro-crate",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -16935,9 +16786,9 @@ dependencies = [
[[package]]
name = "sp-ark-bls12-377"
-version = "0.4.0-beta"
+version = "0.4.1-beta"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1b8e61a06f286f4e8565a67865ef52e83edabf447881898c94527ffc7b839177"
+checksum = "f9b60ba7d8fbb82e21f5be499b02438c9a79365acb441a4dc3993179f09c4cc9"
dependencies = [
"ark-bls12-377",
"ark-ff",
@@ -16950,9 +16801,9 @@ dependencies = [
[[package]]
name = "sp-ark-bls12-381"
-version = "0.4.0-beta"
+version = "0.4.1-beta"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3352feef6c9c34022fa766a0c9a86a88a83d280a3e5b34781a1a9af98377a130"
+checksum = "c2cd101171d2e988a4e1b2320ad3f26f8746a263110c7153213fe86293e0552b"
dependencies = [
"ark-bls12-381",
"ark-ff",
@@ -16965,9 +16816,9 @@ dependencies = [
[[package]]
name = "sp-ark-bw6-761"
-version = "0.4.0-beta"
+version = "0.4.1-beta"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2bf069165e230aef3c4680edea2d8ab3caa89c039e0b61fad2b8e061fb393668"
+checksum = "d94d66ba98893cc42dfe81d5b5dee9142577176bdbdba80ec25a37d8cdffdbd5"
dependencies = [
"ark-bw6-761",
"ark-ff",
@@ -16979,9 +16830,9 @@ dependencies = [
[[package]]
name = "sp-ark-ed-on-bls12-377"
-version = "0.4.0-beta"
+version = "0.4.1-beta"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e63f1fe8e7e87cb0258d61212b019d4d0fd230293ec42a564eb671c83d437497"
+checksum = "37f6ea96c9b1cd4cbd05d741225ff7f6328ab035bda16cf3fac105c87ad98959"
dependencies = [
"ark-ed-on-bls12-377",
"ark-ff",
@@ -16995,9 +16846,9 @@ dependencies = [
[[package]]
name = "sp-ark-ed-on-bls12-381-bandersnatch"
-version = "0.4.0-beta"
+version = "0.4.1-beta"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "838ddc5508aff3e89f930e7e7f3565d0786ac27868cfd61587afe681011e1140"
+checksum = "4db7a801260397cd58077befcee87acfdde8c189f48718bba1bc3783c799b67b"
dependencies = [
"ark-ec",
"ark-ed-on-bls12-381-bandersnatch",
@@ -17012,9 +16863,9 @@ dependencies = [
[[package]]
name = "sp-ark-models"
-version = "0.4.0"
+version = "0.4.1-beta"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "28fa906b809d7a346b2aa32a4bd0c884a75f9f588f9a4a07272f63eaf8a10765"
+checksum = "cd77599e09f12893739e1ef822ae065f2f46c3be040ba1979bb786ae21059f44"
dependencies = [
"ark-ec",
"ark-ff",
@@ -17163,6 +17014,21 @@ dependencies = [
"sp-std",
]
+[[package]]
+name = "sp-consensus-sassafras"
+version = "0.3.4-dev"
+dependencies = [
+ "parity-scale-codec",
+ "scale-info",
+ "serde",
+ "sp-api",
+ "sp-application-crypto",
+ "sp-consensus-slots",
+ "sp-core",
+ "sp-runtime",
+ "sp-std",
+]
+
[[package]]
name = "sp-consensus-slots"
version = "0.10.0-dev"
@@ -17184,7 +17050,7 @@ dependencies = [
"bitflags 1.3.2",
"blake2",
"bounded-collections",
- "bs58 0.4.0",
+ "bs58 0.5.0",
"criterion 0.4.0",
"dyn-clonable",
"ed25519-zebra 3.1.0",
@@ -17242,7 +17108,7 @@ version = "9.0.0"
dependencies = [
"quote",
"sp-core-hashing",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -17286,7 +17152,7 @@ version = "8.0.0"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -17424,7 +17290,7 @@ dependencies = [
name = "sp-npos-elections-fuzzer"
version = "2.0.0-alpha.5"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"honggfuzz",
"rand 0.8.5",
"sp-npos-elections",
@@ -17517,7 +17383,7 @@ dependencies = [
"proc-macro-crate",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -17757,7 +17623,7 @@ dependencies = [
"proc-macro2",
"quote",
"sp-version",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -17851,11 +17717,124 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3"
[[package]]
-name = "staking-miner"
+name = "staging-kusama-runtime"
+version = "1.0.0"
+dependencies = [
+ "binary-merkle-tree",
+ "bitvec",
+ "frame-benchmarking",
+ "frame-election-provider-support",
+ "frame-executive",
+ "frame-remote-externalities",
+ "frame-support",
+ "frame-system",
+ "frame-system-benchmarking",
+ "frame-system-rpc-runtime-api",
+ "frame-try-runtime",
+ "hex-literal 0.4.1",
+ "kusama-runtime-constants",
+ "log",
+ "pallet-authority-discovery",
+ "pallet-authorship",
+ "pallet-babe",
+ "pallet-bags-list",
+ "pallet-balances",
+ "pallet-beefy",
+ "pallet-beefy-mmr",
+ "pallet-bounties",
+ "pallet-child-bounties",
+ "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-nis",
+ "pallet-nomination-pools",
+ "pallet-nomination-pools-benchmarking",
+ "pallet-nomination-pools-runtime-api",
+ "pallet-offences",
+ "pallet-offences-benchmarking",
+ "pallet-preimage",
+ "pallet-proxy",
+ "pallet-ranked-collective",
+ "pallet-recovery",
+ "pallet-referenda",
+ "pallet-scheduler",
+ "pallet-session",
+ "pallet-session-benchmarking",
+ "pallet-society",
+ "pallet-staking",
+ "pallet-staking-runtime-api",
+ "pallet-state-trie-migration",
+ "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-primitives",
+ "polkadot-runtime-common",
+ "polkadot-runtime-parachains",
+ "rustc-hex",
+ "scale-info",
+ "separator",
+ "serde",
+ "serde_derive",
+ "serde_json",
+ "smallvec",
+ "sp-api",
+ "sp-application-crypto",
+ "sp-arithmetic",
+ "sp-authority-discovery",
+ "sp-block-builder",
+ "sp-consensus-babe",
+ "sp-consensus-beefy",
+ "sp-core",
+ "sp-inherents",
+ "sp-io",
+ "sp-keyring",
+ "sp-mmr-primitives",
+ "sp-npos-elections",
+ "sp-offchain",
+ "sp-runtime",
+ "sp-session",
+ "sp-staking",
+ "sp-std",
+ "sp-storage",
+ "sp-tracing",
+ "sp-transaction-pool",
+ "sp-trie",
+ "sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
+ "static_assertions",
+ "substrate-wasm-builder",
+ "tiny-keccak",
+ "tokio",
+]
+
+[[package]]
+name = "staging-staking-miner"
version = "1.0.0"
dependencies = [
"assert_cmd",
- "clap 4.4.0",
+ "clap 4.4.2",
"exitcode",
"frame-election-provider-support",
"frame-remote-externalities",
@@ -17863,7 +17842,6 @@ dependencies = [
"frame-system",
"futures-util",
"jsonrpsee",
- "kusama-runtime",
"log",
"pallet-balances",
"pallet-election-provider-multi-phase",
@@ -17884,6 +17862,7 @@ dependencies = [
"sp-runtime",
"sp-state-machine",
"sp-version",
+ "staging-kusama-runtime",
"sub-tokens",
"thiserror",
"tokio",
@@ -17891,6 +17870,74 @@ dependencies = [
"westend-runtime",
]
+[[package]]
+name = "staging-xcm"
+version = "1.0.0"
+dependencies = [
+ "bounded-collections",
+ "derivative",
+ "environmental",
+ "hex",
+ "hex-literal 0.4.1",
+ "impl-trait-for-tuples",
+ "log",
+ "parity-scale-codec",
+ "scale-info",
+ "serde",
+ "sp-io",
+ "sp-weights",
+ "xcm-procedural",
+]
+
+[[package]]
+name = "staging-xcm-builder"
+version = "1.0.0"
+dependencies = [
+ "assert_matches",
+ "frame-support",
+ "frame-system",
+ "impl-trait-for-tuples",
+ "log",
+ "pallet-assets",
+ "pallet-balances",
+ "pallet-salary",
+ "pallet-transaction-payment",
+ "pallet-xcm",
+ "parity-scale-codec",
+ "polkadot-parachain-primitives",
+ "polkadot-primitives",
+ "polkadot-runtime-parachains",
+ "polkadot-test-runtime",
+ "primitive-types",
+ "scale-info",
+ "sp-arithmetic",
+ "sp-io",
+ "sp-runtime",
+ "sp-std",
+ "sp-weights",
+ "staging-xcm",
+ "staging-xcm-executor",
+]
+
+[[package]]
+name = "staging-xcm-executor"
+version = "1.0.0"
+dependencies = [
+ "environmental",
+ "frame-benchmarking",
+ "frame-support",
+ "impl-trait-for-tuples",
+ "log",
+ "parity-scale-codec",
+ "sp-arithmetic",
+ "sp-core",
+ "sp-io",
+ "sp-runtime",
+ "sp-std",
+ "sp-weights",
+ "staging-xcm",
+]
+
[[package]]
name = "static_assertions"
version = "1.1.0"
@@ -18009,7 +18056,7 @@ dependencies = [
name = "subkey"
version = "3.0.0"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"sc-cli",
]
@@ -18051,7 +18098,7 @@ dependencies = [
name = "substrate-frame-cli"
version = "4.0.0-dev"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"frame-support",
"frame-system",
"sc-cli",
@@ -18254,30 +18301,10 @@ version = "4.0.0-dev"
dependencies = [
"futures",
"sc-service",
- "substrate-test-utils-derive",
"tokio",
"trybuild",
]
-[[package]]
-name = "substrate-test-utils-derive"
-version = "0.10.0-dev"
-dependencies = [
- "proc-macro-crate",
- "proc-macro2",
- "quote",
- "syn 2.0.29",
-]
-
-[[package]]
-name = "substrate-test-utils-test-crate"
-version = "0.1.0"
-dependencies = [
- "sc-service",
- "substrate-test-utils",
- "tokio",
-]
-
[[package]]
name = "substrate-wasm-builder"
version = "5.0.0-dev"
@@ -18420,9 +18447,9 @@ dependencies = [
[[package]]
name = "syn"
-version = "2.0.29"
+version = "2.0.31"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c324c494eba9d92503e6f1ef2e6df781e78f6a7705a0202d9801b198807d518a"
+checksum = "718fa2415bcb8d8bd775917a1bf12a7931b6dfa890753378538118181e0cb398"
dependencies = [
"proc-macro2",
"quote",
@@ -18519,7 +18546,7 @@ version = "1.0.0"
dependencies = [
"dlmalloc",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"sp-io",
"sp-std",
"substrate-wasm-builder",
@@ -18530,7 +18557,7 @@ dependencies = [
name = "test-parachain-adder-collator"
version = "1.0.0"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"futures",
"futures-timer",
"log",
@@ -18539,7 +18566,7 @@ dependencies = [
"polkadot-node-core-pvf",
"polkadot-node-primitives",
"polkadot-node-subsystem",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-service",
"polkadot-test-service",
@@ -18568,7 +18595,7 @@ dependencies = [
"dlmalloc",
"log",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"sp-io",
"sp-std",
"substrate-wasm-builder",
@@ -18579,7 +18606,7 @@ dependencies = [
name = "test-parachain-undying-collator"
version = "1.0.0"
dependencies = [
- "clap 4.4.0",
+ "clap 4.4.2",
"futures",
"futures-timer",
"log",
@@ -18588,7 +18615,7 @@ dependencies = [
"polkadot-node-core-pvf",
"polkadot-node-primitives",
"polkadot-node-subsystem",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-service",
"polkadot-test-service",
@@ -18634,9 +18661,9 @@ checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d"
[[package]]
name = "thiserror"
-version = "1.0.47"
+version = "1.0.48"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "97a802ec30afc17eee47b2855fc72e0c4cd62be9b4efe6591edde0ec5bd68d8f"
+checksum = "9d6d7a740b8a666a7e828dd00da9c0dc290dff53154ea77ac109281de90589b7"
dependencies = [
"thiserror-impl",
]
@@ -18663,13 +18690,13 @@ dependencies = [
[[package]]
name = "thiserror-impl"
-version = "1.0.47"
+version = "1.0.48"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6bb623b56e39ab7dcd4b1b98bb6c8f8d907ed255b18de254088016b27a8ee19b"
+checksum = "49922ecae66cc8a249b77e68d1d0623c1b2c514f0060c27cdc68bd62a1219d35"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -18860,7 +18887,7 @@ checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -19041,7 +19068,7 @@ checksum = "5f4f31f56159e98206da9efd823404b79b6ef3143b4a7ab76e67b1751b25a4ab"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -19084,7 +19111,7 @@ dependencies = [
"proc-macro-crate",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -19255,7 +19282,7 @@ version = "0.10.0-dev"
dependencies = [
"assert_cmd",
"async-trait",
- "clap 4.4.0",
+ "clap 4.4.2",
"frame-remote-externalities",
"frame-try-runtime",
"hex",
@@ -19657,7 +19684,7 @@ dependencies = [
"once_cell",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
"wasm-bindgen-shared",
]
@@ -19691,7 +19718,7 @@ checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
"wasm-bindgen-backend",
"wasm-bindgen-shared",
]
@@ -19784,20 +19811,6 @@ dependencies = [
"web-sys",
]
-[[package]]
-name = "wasmi"
-version = "0.30.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e51fb5c61993e71158abf5bb863df2674ca3ec39ed6471c64f07aeaf751d67b4"
-dependencies = [
- "intx",
- "smallvec",
- "spin 0.9.8",
- "wasmi_arena",
- "wasmi_core 0.12.0",
- "wasmparser-nostd",
-]
-
[[package]]
name = "wasmi"
version = "0.31.0"
@@ -19807,7 +19820,7 @@ dependencies = [
"smallvec",
"spin 0.9.8",
"wasmi_arena",
- "wasmi_core 0.13.0",
+ "wasmi_core",
"wasmparser-nostd",
]
@@ -19817,18 +19830,6 @@ version = "0.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "401c1f35e413fac1846d4843745589d9ec678977ab35a384db8ae7830525d468"
-[[package]]
-name = "wasmi_core"
-version = "0.12.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "624e6333e861ef49095d2d678b76ebf30b06bf37effca845be7e5b87c90071b7"
-dependencies = [
- "downcast-rs",
- "libm",
- "num-traits",
- "paste",
-]
-
[[package]]
name = "wasmi_core"
version = "0.13.0"
@@ -20402,7 +20403,7 @@ dependencies = [
"pallet-xcm",
"pallet-xcm-benchmarks",
"parity-scale-codec",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-runtime-common",
"polkadot-runtime-parachains",
@@ -20433,13 +20434,13 @@ dependencies = [
"sp-tracing",
"sp-transaction-pool",
"sp-version",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"substrate-wasm-builder",
"tiny-keccak",
"tokio",
"westend-runtime-constants",
- "xcm",
- "xcm-builder",
- "xcm-executor",
]
[[package]]
@@ -20794,61 +20795,11 @@ dependencies = [
"libc",
]
-[[package]]
-name = "xcm"
-version = "1.0.0"
-dependencies = [
- "bounded-collections",
- "derivative",
- "hex",
- "hex-literal 0.4.1",
- "impl-trait-for-tuples",
- "log",
- "parity-scale-codec",
- "scale-info",
- "serde",
- "sp-io",
- "sp-weights",
- "xcm-procedural",
-]
-
-[[package]]
-name = "xcm-builder"
-version = "1.0.0"
-dependencies = [
- "assert_matches",
- "frame-support",
- "frame-system",
- "impl-trait-for-tuples",
- "log",
- "pallet-assets",
- "pallet-balances",
- "pallet-salary",
- "pallet-transaction-payment",
- "pallet-xcm",
- "parity-scale-codec",
- "polkadot-parachain",
- "polkadot-primitives",
- "polkadot-runtime-parachains",
- "polkadot-test-runtime",
- "primitive-types",
- "scale-info",
- "sp-arithmetic",
- "sp-io",
- "sp-runtime",
- "sp-std",
- "sp-weights",
- "xcm",
- "xcm-executor",
-]
-
[[package]]
name = "xcm-emulator"
version = "0.1.0"
dependencies = [
- "cumulus-pallet-dmp-queue",
"cumulus-pallet-parachain-system",
- "cumulus-pallet-xcmp-queue",
"cumulus-primitives-core",
"cumulus-primitives-parachain-inherent",
"cumulus-test-relay-sproof-builder",
@@ -20859,10 +20810,10 @@ dependencies = [
"log",
"pallet-balances",
"pallet-message-queue",
- "parachain-info",
"parachains-common",
"parity-scale-codec",
"paste",
+ "polkadot-parachain-primitives",
"polkadot-primitives",
"polkadot-runtime-parachains",
"sp-arithmetic",
@@ -20870,28 +20821,9 @@ dependencies = [
"sp-io",
"sp-runtime",
"sp-std",
- "sp-trie",
- "xcm",
- "xcm-executor",
-]
-
-[[package]]
-name = "xcm-executor"
-version = "1.0.0"
-dependencies = [
- "environmental",
- "frame-benchmarking",
- "frame-support",
- "impl-trait-for-tuples",
- "log",
- "parity-scale-codec",
- "sp-arithmetic",
- "sp-core",
- "sp-io",
- "sp-runtime",
- "sp-std",
- "sp-weights",
- "xcm",
+ "sp-tracing",
+ "staging-xcm",
+ "staging-xcm-executor",
]
[[package]]
@@ -20911,8 +20843,8 @@ dependencies = [
"sp-runtime",
"sp-state-machine",
"sp-tracing",
- "xcm",
- "xcm-executor",
+ "staging-xcm",
+ "staging-xcm-executor",
]
[[package]]
@@ -20922,7 +20854,7 @@ dependencies = [
"Inflector",
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
@@ -20933,13 +20865,13 @@ dependencies = [
"parity-scale-codec",
"paste",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-parachains",
"sp-io",
"sp-std",
- "xcm",
- "xcm-builder",
- "xcm-executor",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
]
[[package]]
@@ -20955,7 +20887,7 @@ dependencies = [
"pallet-xcm",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-parachains",
"scale-info",
"sp-core",
@@ -20963,9 +20895,9 @@ dependencies = [
"sp-runtime",
"sp-std",
"sp-tracing",
- "xcm",
- "xcm-builder",
- "xcm-executor",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"xcm-simulator",
]
@@ -20982,16 +20914,16 @@ dependencies = [
"pallet-xcm",
"parity-scale-codec",
"polkadot-core-primitives",
- "polkadot-parachain",
+ "polkadot-parachain-primitives",
"polkadot-runtime-parachains",
"scale-info",
"sp-core",
"sp-io",
"sp-runtime",
"sp-std",
- "xcm",
- "xcm-builder",
- "xcm-executor",
+ "staging-xcm",
+ "staging-xcm-builder",
+ "staging-xcm-executor",
"xcm-simulator",
]
@@ -21041,7 +20973,7 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.29",
+ "syn 2.0.31",
]
[[package]]
diff --git a/Cargo.toml b/Cargo.toml
index 48081ad14a312b0c46c6de30f776d87b2b17179b..4db27b98e90788775663aed31cbc10c851316318 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -385,6 +385,7 @@ members = [
"substrate/primitives/consensus/common",
"substrate/primitives/consensus/grandpa",
"substrate/primitives/consensus/pow",
+ "substrate/primitives/consensus/sassafras",
"substrate/primitives/consensus/slots",
"substrate/primitives/core",
"substrate/primitives/core/hashing",
@@ -432,11 +433,9 @@ members = [
"substrate/test-utils",
"substrate/test-utils/cli",
"substrate/test-utils/client",
- "substrate/test-utils/derive",
"substrate/test-utils/runtime",
"substrate/test-utils/runtime/client",
"substrate/test-utils/runtime/transaction-pool",
- "substrate/test-utils/test-crate",
"substrate/utils/binary-merkle-tree",
"substrate/utils/build-script-utils",
"substrate/utils/fork-tree",
diff --git a/README.md b/README.md
new file mode 100644
index 0000000000000000000000000000000000000000..56b3481bafc038f7d3dd0606558e9e37243dcd53
--- /dev/null
+++ b/README.md
@@ -0,0 +1,60 @@
+> NOTE: We have recently made significant changes to our repository structure. In order to streamline our development
+process and foster better contributions, we have merged three separate repositories Cumulus, Substrate and Polkadot into
+this repository. Read more about the changes [
+here](https://polkadot-public.notion.site/Polkadot-SDK-FAQ-fbc4cecc2c46443fb37b9eeec2f0d85f).
+
+# Polkadot SDK
+
+![](https://cms.polkadot.network/content/images/2021/06/1-xPcVR_fkITd0ssKBvJ3GMw.png)
+
+[![StackExchange](https://img.shields.io/badge/StackExchange-Community%20&%20Support-222222?logo=stackexchange)](https://substrate.stackexchange.com/)
+
+The Polkadot SDK repository provides all the resources needed to start building on the Polkadot network, a multi-chain
+blockchain platform that enables different blockchains to interoperate and share information in a secure and scalable
+way. The Polkadot SDK comprises three main pieces of software:
+
+## [Polkadot](./polkadot/)
+[![PolkadotForum](https://img.shields.io/badge/Polkadot_Forum-e6007a?logo=polkadot)](https://forum.polkadot.network/)
+[![Polkadot-license](https://img.shields.io/badge/License-GPL3-blue)](./polkadot/LICENSE)
+
+Implementation of a node for the https://polkadot.network in Rust, using the Substrate framework. This directory
+currently contains runtimes for the Polkadot, Kusama, Westend, and Rococo networks. In the future, these will be
+relocated to the [`runtimes`](https://github.com/polkadot-fellows/runtimes/) repository.
+
+## [Substrate](./substrate/)
+ [![SubstrateRustDocs](https://img.shields.io/badge/Rust_Docs-Substrate-24CC85?logo=rust)](https://paritytech.github.io/substrate/master/substrate/index.html)
+ [![Substrate-license](https://img.shields.io/badge/License-GPL3%2FApache2.0-blue)](./substrate/README.md#LICENSE)
+
+Substrate is the primary blockchain SDK used by developers to create the parachains that make up the Polkadot network.
+Additionally, it allows for the development of self-sovereign blockchains that operate completely independently of
+Polkadot.
+
+## [Cumulus](./cumulus/)
+[![CumulusRustDocs](https://img.shields.io/badge/Rust_Docs-Cumulus-222222?logo=rust)](https://paritytech.github.io/cumulus/cumulus_client_collator/index.html)
+[![Cumulus-license](https://img.shields.io/badge/License-GPL3-blue)](./cumulus/LICENSE)
+
+Cumulus is a set of tools for writing Substrate-based Polkadot parachains.
+
+## Upstream Dependencies
+
+Below are the primary upstream dependencies utilized in this project:
+
+- [`parity-scale-codec`](https://crates.io/crates/parity-scale-codec)
+- [`parity-db`](https://crates.io/crates/parity-db)
+- [`parity-common`](https://github.com/paritytech/parity-common)
+- [`trie`](https://github.com/paritytech/trie)
+
+## Security
+
+The security policy and procedures can be found in [docs/SECURITY.md](./docs/SECURITY.md).
+
+## Contributing & Code of Conduct
+
+Ensure you follow our [contribution guidelines](./docs/CONTRIBUTING.md). In every interaction and contribution, this
+project adheres to the [Contributor Covenant Code of Conduct](./docs/CODE_OF_CONDUCT.md).
+
+## Additional Resources
+
+- For monitoring upcoming changes and current proposals related to the technical implementation of the Polkadot network,
+ visit the [`Requests for Comment (RFC)`](https://github.com/polkadot-fellows/RFCs) repository. While it's maintained
+ by the Polkadot Fellowship, the RFC process welcomes contributions from everyone.
diff --git a/cumulus/BRIDGES.md b/cumulus/BRIDGES.md
index 8766de92c17e3b5b0d4596453cbf6bfce1893297..a6f00aec09283e10d1a697bcef3f523881941663 100644
--- a/cumulus/BRIDGES.md
+++ b/cumulus/BRIDGES.md
@@ -1,13 +1,13 @@
-# Using Parity Bridges Common dependency (`git subtree`).
+# Using Parity Bridges Common dependency (`git subtree`)
In `./bridges` sub-directory you can find a `git subtree` imported version of:
-[parity-bridges-common](https://github.com/paritytech/parity-bridges-common/) repository.
+[`parity-bridges-common`](https://github.com/paritytech/parity-bridges-common/) repository.
(For regular Cumulus contributor 1. is relevant) \
(For Cumulus maintainer 1. and 2. are relevant) \
(For Bridges team 1. and 2. and 3. are relevant)
-# 1. How to fix broken Bridges code?
+## How to fix broken Bridges code?
To fix Bridges code simply create a commit in current (`Cumulus`) repo. Best if
the commit is isolated to changes in `./bridges` sub-directory, because it makes
@@ -16,7 +16,7 @@ it easier to import that change back to upstream repo.
(Any changes to `bridges` subtree require Bridges team approve and they should manage backport to Bridges repo)
-# 2. How to pull latest Bridges code to the `bridges` subtree
+## How to pull latest Bridges code to the `bridges` subtree
(in practice)
The `bridges` repo has a stabilized branch `polkadot-staging` dedicated for releasing.
@@ -25,7 +25,7 @@ The `bridges` repo has a stabilized branch `polkadot-staging` dedicated for rele
cd
# this will update new git branches from bridges repo
-# there could be unresolved conflicts, but dont worry,
+# there could be unresolved conflicts, but don't worry,
# lots of them are caused because of removed unneeded files with patch step,
BRANCH=polkadot-staging ./scripts/bridges_update_subtree.sh fetch
@@ -45,9 +45,9 @@ BRANCH=polkadot-staging ./scripts/bridges_update_subtree.sh fetch
# so after all conflicts are solved and patch passes and compiles,
# then we need to finish merge with:
git merge --continue
-````
+```
-# 3. How to pull latest Bridges code or contribute back?
+## How to pull latest Bridges code or contribute back?
(in theory)
Note that it's totally fine to ping the **Bridges Team** to do that for you. The point
@@ -58,34 +58,34 @@ If you still would like to either update the code to match latest code from the
or create an upstream PR read below. The following commands should be run in the
current (`polkadot`) repo.
-1. Add Bridges repo as a local remote:
+### Add Bridges repo as a local remote
```
-$ git remote add -f bridges git@github.com:paritytech/parity-bridges-common.git
+git remote add -f bridges git@github.com:paritytech/parity-bridges-common.git
```
If you plan to contribute back, consider forking the repository on Github and adding
your personal fork as a remote as well.
```
-$ git remote add -f my-bridges git@github.com:tomusdrw/parity-bridges-common.git
+git remote add -f my-bridges git@github.com:tomusdrw/parity-bridges-common.git
```
-2. To update Bridges:
+### To update Bridges
+```
+git fetch bridges polkadot-staging
+git subtree pull --prefix=bridges bridges polkadot-staging --squash
```
-$ git fetch bridges polkadot-staging
-$ git subtree pull --prefix=bridges bridges polkadot-staging --squash
-````
We use `--squash` to avoid adding individual commits and rather squashing them
all into one.
-3. Clean unneeded files here:
+### Clean unneeded files here
```
./bridges/scripts/verify-pallets-build.sh --ignore-git-state --no-revert
```
-4. Contributing back to Bridges (creating upstream PR)
+### Contributing back to Bridges (creating upstream PR)
```
-$ git subtree push --prefix=bridges my-bridges polkadot-staging
+git subtree push --prefix=bridges my-bridges polkadot-staging
```
This command will push changes to your personal fork of Bridges repo, from where
you can simply create a PR to the main repo.
diff --git a/cumulus/README.md b/cumulus/README.md
index 419e293a0abd3a032de6e591d60b7006c64aa628..19f9f3f113dd06655c418a4caf6b30a9cad6ee9f 100644
--- a/cumulus/README.md
+++ b/cumulus/README.md
@@ -2,59 +2,53 @@
[![Doc](https://img.shields.io/badge/cumulus%20docs-master-brightgreen)](https://paritytech.github.io/cumulus/)
-This repository contains both the Cumulus SDK and also specific chains implemented on top of this
-SDK.
+This repository contains both the Cumulus SDK and also specific chains implemented on top of this SDK.
-If you only want to run a **Polkadot Parachain Node**, check out our [container
-section](./docs/container.md).
+If you only want to run a **Polkadot Parachain Node**, check out our [container section](./docs/container.md).
## Cumulus SDK
-A set of tools for writing [Substrate](https://substrate.io/)-based
-[Polkadot](https://wiki.polkadot.network/en/)
-[parachains](https://wiki.polkadot.network/docs/en/learn-parachains). Refer to the included
-[overview](docs/overview.md) for architectural details, and the [Connect to a relay chain how-to
-guide](https://docs.substrate.io/reference/how-to-guides/parachains/connect-to-a-relay-chain/) for a
-guided walk-through of using these tools.
+A set of tools for writing [Substrate](https://substrate.io/)-based [Polkadot](https://wiki.polkadot.network/en/)
+[parachains](https://wiki.polkadot.network/docs/en/learn-parachains). Refer to the included [overview](docs/overview.md)
+for architectural details, and the [Connect to a relay chain how-to
+guide](https://docs.substrate.io/reference/how-to-guides/parachains/connect-to-a-relay-chain/) for a guided walk-through
+of using these tools.
-It's easy to write blockchains using Substrate, and the overhead of writing parachains'
-distribution, p2p, database, and synchronization layers should be just as low. This project aims to
-make it easy to write parachains for Polkadot by leveraging the power of Substrate.
+It's easy to write blockchains using Substrate, and the overhead of writing parachains' distribution, p2p, database, and
+synchronization layers should be just as low. This project aims to make it easy to write parachains for Polkadot by
+leveraging the power of Substrate.
-Cumulus clouds are shaped sort of like dots; together they form a system that is intricate,
-beautiful and functional.
+Cumulus clouds are shaped sort of like dots; together they form a system that is intricate, beautiful and functional.
### Consensus
[`parachain-consensus`](https://github.com/paritytech/polkadot-sdk/blob/master/cumulus/client/consensus/common/src/parachain_consensus.rs)
-is a [consensus engine](https://docs.substrate.io/v3/advanced/consensus) for Substrate that follows
-a Polkadot [relay chain](https://wiki.polkadot.network/docs/en/learn-architecture#relay-chain). This
-will run a Polkadot node internally, and dictate to the client and synchronization algorithms which
-chain to follow,
-[finalize](https://wiki.polkadot.network/docs/en/learn-consensus#probabilistic-vs-provable-finality),
-and treat as best.
+is a [consensus engine](https://docs.substrate.io/v3/advanced/consensus) for Substrate that follows a Polkadot [relay
+chain](https://wiki.polkadot.network/docs/en/learn-architecture#relay-chain). This will run a Polkadot node internally,
+and dictate to the client and synchronization algorithms which chain to follow,
+[finalize](https://wiki.polkadot.network/docs/en/learn-consensus#probabilistic-vs-provable-finality), and treat as best.
### Collator
-A Polkadot [collator](https://wiki.polkadot.network/docs/en/learn-collator) for the parachain is
-implemented by the `polkadot-parachain` binary (previously called `polkadot-collator`).
+A Polkadot [collator](https://wiki.polkadot.network/docs/en/learn-collator) for the parachain is implemented by the
+`polkadot-parachain` binary (previously called `polkadot-collator`).
-You may run `polkadot-parachain` locally after building it or using one of the container option
-described [here](./docs/container.md).
+You may run `polkadot-parachain` locally after building it or using one of the container option described
+[here](./docs/container.md).
-### Relay Chain Interaction
-To operate a parachain node, a connection to the corresponding relay
-chain is necessary. This can be achieved in one of three ways:
-1. Run a full relay chain node within the parachain node (default)
-2. Connect to an external relay chain node via WebSocket RPC
+### Relay Chain Interaction
+To operate a parachain node, a connection to the corresponding relay chain is necessary. This can be achieved in one of
+three ways:
+1. Run a full relay chain node within the parachain node (default)
+2. Connect to an external relay chain node via WebSocket RPC
3. Run a light client for the relay chain
#### In-process Relay Chain Node
-If an external relay chain node is not specified (default behavior), then a full relay chain node is
-spawned within the same process.
+If an external relay chain node is not specified (default behavior), then a full relay chain node is spawned within the
+same process.
-This node has all of the typical components of a regular Polkadot node and will have to fully sync
-with the relay chain to work.
+This node has all of the typical components of a regular Polkadot node and will have to fully sync with the relay chain
+to work.
##### Example command
```bash
@@ -66,19 +60,16 @@ polkadot-parachain \
```
#### External Relay Chain Node
-An external relay chain node is connected via WebsSocket RPC by using the
-`--relay-chain-rpc-urls` command line argument. This option accepts one or more
-space-separated WebSocket URLs to a full relay chain node. By default, only the
-first URL will be used, with the rest as a backup in case the connection to the
-first node is lost.
+An external relay chain node is connected via WebsSocket RPC by using the `--relay-chain-rpc-urls` command line
+argument. This option accepts one or more space-separated WebSocket URLs to a full relay chain node. By default, only
+the first URL will be used, with the rest as a backup in case the connection to the first node is lost.
-Parachain nodes using this feature won't have to fully sync with the relay chain
-to work, so in general they will use fewer system resources.
+Parachain nodes using this feature won't have to fully sync with the relay chain to work, so in general they will use
+fewer system resources.
-**Note:** At this time, any parachain nodes using this feature will still spawn a
-significantly cut-down relay chain node in-process. Even though they lack the
-majority of normal Polkadot subsystems, they will still need to connect directly
-to the relay chain network.
+**Note:** At this time, any parachain nodes using this feature will still spawn a significantly cut-down relay chain
+node in-process. Even though they lack the majority of normal Polkadot subsystems, they will still need to connect
+directly to the relay chain network.
##### Example command
@@ -94,17 +85,15 @@ polkadot-parachain \
```
#### Relay Chain Light Client
-An internal relay chain light client provides a fast and lightweight approach
-for connecting to the relay chain network. It provides relay chain notifications
-and facilitates runtime calls.
+An internal relay chain light client provides a fast and lightweight approach for connecting to the relay chain network.
+It provides relay chain notifications and facilitates runtime calls.
-To specify which chain the light client should connect to, users need to supply
-a relay chain chain-spec as part of the relay chain arguments.
+To specify which chain the light client should connect to, users need to supply a relay chain chain-spec as part of the
+relay chain arguments.
-**Note:** At this time, any parachain nodes using this feature will still spawn
-a significantly cut-down relay chain node in-process. Even though they lack the
-majority of normal Polkadot subsystems, they will still need to connect directly
-to the relay chain network.
+**Note:** At this time, any parachain nodes using this feature will still spawn a significantly cut-down relay chain
+node in-process. Even though they lack the majority of normal Polkadot subsystems, they will still need to connect
+directly to the relay chain network.
##### Example command
@@ -118,23 +107,22 @@ polkadot-parachain \
```
## Installation and Setup
-Before building Cumulus SDK based nodes / runtimes prepare your environment by
-following Substrate [installation instructions](https://docs.substrate.io/main-docs/install/).
+Before building Cumulus SDK based nodes / runtimes prepare your environment by following Substrate [installation
+instructions](https://docs.substrate.io/main-docs/install/).
-To launch a local network, you can use [zombienet](https://github.com/paritytech/zombienet)
-for quick setup and experimentation or follow the [manual setup](#manual-setup).
+To launch a local network, you can use [zombienet](https://github.com/paritytech/zombienet) for quick setup and
+experimentation or follow the [manual setup](#manual-setup).
### Zombienet
-We use Zombienet to spin up networks for integration tests and local networks.
-Follow [these installation steps](https://github.com/paritytech/zombienet#requirements-by-provider)
-to set it up on your machine. A simple network specification with two relay chain
-nodes and one collator is located at [zombienet/examples/small_network.toml](zombienet/examples/small_network.toml).
+We use Zombienet to spin up networks for integration tests and local networks. Follow [these installation
+steps](https://github.com/paritytech/zombienet#requirements-by-provider) to set it up on your machine. A simple network
+specification with two relay chain nodes and one collator is located at
+[zombienet/examples/small_network.toml](zombienet/examples/small_network.toml).
#### Which provider should I use?
Zombienet offers multiple providers to run networks. Choose the one that best fits your needs:
- **Podman:** Choose this if you want to spin up a network quick and easy.
-- **Native:** Choose this if you want to develop and deploy your changes. Requires compilation
-of the binaries.
+- **Native:** Choose this if you want to develop and deploy your changes. Requires compilation of the binaries.
- **Kubernetes:** Choose this for advanced use-cases or running on cloud-infrastructure.
#### How to run
@@ -183,13 +171,16 @@ cargo build --release --bin polkadot-parachain
./target/release/polkadot-parachain export-genesis-wasm > genesis-wasm
# Collator1
-./target/release/polkadot-parachain --collator --alice --force-authoring --tmp --port 40335 --rpc-port 9946 -- --chain ../polkadot/rococo-local-cfde.json --port 30335
+./target/release/polkadot-parachain --collator --alice --force-authoring \
+ --tmp --port 40335 --rpc-port 9946 -- --chain ../polkadot/rococo-local-cfde.json --port 30335
# Collator2
-./target/release/polkadot-parachain --collator --bob --force-authoring --tmp --port 40336 --rpc-port 9947 -- --chain ../polkadot/rococo-local-cfde.json --port 30336
+./target/release/polkadot-parachain --collator --bob --force-authoring \
+ --tmp --port 40336 --rpc-port 9947 -- --chain ../polkadot/rococo-local-cfde.json --port 30336
# Parachain Full Node 1
-./target/release/polkadot-parachain --tmp --port 40337 --rpc-port 9948 -- --chain ../polkadot/rococo-local-cfde.json --port 30337
+./target/release/polkadot-parachain --tmp --port 40337 --rpc-port 9948 -- \
+ --chain ../polkadot/rococo-local-cfde.json --port 30337
```
#### Register the parachain
@@ -199,8 +190,8 @@ cargo build --release --bin polkadot-parachain
## Asset Hub 🪙
-This repository also contains the Asset Hub runtimes. Asset Hub is a system parachain
-providing an asset store for the Polkadot ecosystem.
+This repository also contains the Asset Hub runtimes. Asset Hub is a system parachain providing an asset store for the
+Polkadot ecosystem.
### Build & Launch a Node
@@ -228,20 +219,18 @@ See [the `contracts-rococo` readme](parachains/runtimes/contracts/contracts-roco
See [the `bridge-hubs` readme](parachains/runtimes/bridge-hubs/README.md) for details.
## Rococo 👑
-[Rococo](https://polkadot.js.org/apps/?rpc=wss://rococo-rpc.polkadot.io) is becoming a
-[Community Parachain Testbed](https://polkadot.network/blog/rococo-revamp-becoming-a-community-parachain-testbed/)
-for parachain teams in the Polkadot ecosystem. It supports multiple parachains with the
-differentiation of long-term connections and recurring short-term connections, to see
-which parachains are currently connected and how long they will be connected for
-[see here](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Frococo-rpc.polkadot.io#/parachains).
+[Rococo](https://polkadot.js.org/apps/?rpc=wss://rococo-rpc.polkadot.io) is becoming a [Community Parachain
+Testbed](https://polkadot.network/blog/rococo-revamp-becoming-a-community-parachain-testbed/) for parachain teams in the
+Polkadot ecosystem. It supports multiple parachains with the differentiation of long-term connections and recurring
+short-term connections, to see which parachains are currently connected and how long they will be connected for [see
+here](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Frococo-rpc.polkadot.io#/parachains).
-Rococo is an elaborate style of design and the name describes the painstaking effort that
-has gone into this project.
+Rococo is an elaborate style of design and the name describes the painstaking effort that has gone into this project.
### Build & Launch Rococo Collators
-Collators are similar to validators in the relay chain. These nodes build the blocks that
-will eventually be included by the relay chain for a parachain.
+Collators are similar to validators in the relay chain. These nodes build the blocks that will eventually be included by
+the relay chain for a parachain.
To run a Rococo collator you will need to compile the following binary:
@@ -250,8 +239,7 @@ To run a Rococo collator you will need to compile the following binary:
cargo build --release --locked --bin polkadot-parachain
```
-Once the executable is built, launch collators for each parachain (repeat once each for chain
-`tick`, `trick`, `track`):
+Once the executable is built, launch collators for each parachain (repeat once each for chain `tick`, `trick`, `track`):
```bash
./target/release/polkadot-parachain --chain $CHAIN --validator
@@ -261,10 +249,10 @@ You can also build [using a container](./docs/container.md).
### Parachains
-* [Asset Hub](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Frococo-statemint-rpc.polkadot.io#/explorer)
-* [Contracts on Rococo](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Frococo-contracts-rpc.polkadot.io#/explorer)
-* [RILT](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Frococo.kilt.io#/explorer)
+- [Asset Hub](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Frococo-statemint-rpc.polkadot.io#/explorer)
+- [Contracts on Rococo](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Frococo-contracts-rpc.polkadot.io#/explorer)
+- [RILT](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Frococo.kilt.io#/explorer)
-The network uses horizontal message passing (HRMP) to enable communication between
-parachains and the relay chain and, in turn, between parachains. This means that every
-message is sent to the relay chain, and from the relay chain to its destination parachain.
+The network uses horizontal message passing (HRMP) to enable communication between parachains and the relay chain and,
+in turn, between parachains. This means that every message is sent to the relay chain, and from the relay chain to its
+destination parachain.
diff --git a/cumulus/bridges/CODE_OF_CONDUCT.md b/cumulus/bridges/CODE_OF_CONDUCT.md
index 70541fb72fa25af86a4268b947cdeb880d1d739c..23411da2e048c758d56d511c792e020a37d0ee0d 100644
--- a/cumulus/bridges/CODE_OF_CONDUCT.md
+++ b/cumulus/bridges/CODE_OF_CONDUCT.md
@@ -34,9 +34,9 @@ of preference. We see that blockchains are naturally community platforms with u
ultimate decision makers. We assert that good software will maximise user agency by facilitate
user-expression on the network. As such:
-- This project will strive to give users as much choice as is both reasonable and possible over what
+* This project will strive to give users as much choice as is both reasonable and possible over what
protocol they adhere to; but
-- use of the project's technical forums, commenting systems, pull requests and issue trackers as a
+* use of the project's technical forums, commenting systems, pull requests and issue trackers as a
means to express individual protocol preferences is forbidden.
## Our Responsibilities
diff --git a/cumulus/bridges/README.md b/cumulus/bridges/README.md
index 2f8c5ca9abb293699fc9510ed60ef4be117dd783..da46fe67d924acb2afffcf971bacb60b560f0cd5 100644
--- a/cumulus/bridges/README.md
+++ b/cumulus/bridges/README.md
@@ -2,11 +2,10 @@
This is a collection of components for building bridges.
-These components include Substrate pallets for syncing headers, passing arbitrary messages, as well
-as libraries for building relayers to provide cross-chain communication capabilities.
+These components include Substrate pallets for syncing headers, passing arbitrary messages, as well as libraries for
+building relayers to provide cross-chain communication capabilities.
-Three bridge nodes are also available. The nodes can be used to run test networks which bridge other
-Substrate chains.
+Three bridge nodes are also available. The nodes can be used to run test networks which bridge other Substrate chains.
🚧 The bridges are currently under construction - a hardhat is recommended beyond this point 🚧
@@ -21,8 +20,8 @@ Substrate chains.
## Installation
-To get up and running you need both stable and nightly Rust. Rust nightly is used to build the Web
-Assembly (WASM) runtime for the node. You can configure the WASM support as so:
+To get up and running you need both stable and nightly Rust. Rust nightly is used to build the Web Assembly (WASM)
+runtime for the node. You can configure the WASM support as so:
```bash
rustup install nightly
@@ -38,8 +37,8 @@ cargo build --all
cargo test --all
```
-Also you can build the repo with
-[Parity CI Docker image](https://github.com/paritytech/scripts/tree/master/dockerfiles/bridges-ci):
+Also you can build the repo with [Parity CI Docker
+image](https://github.com/paritytech/scripts/tree/master/dockerfiles/bridges-ci):
```bash
docker pull paritytech/bridges-ci:production
@@ -57,16 +56,14 @@ docker run --rm -it -w /shellhere/parity-bridges-common \
If you want to reproduce other steps of CI process you can use the following
[guide](https://github.com/paritytech/scripts#reproduce-ci-locally).
-If you need more information about setting up your development environment [Substrate's
-Installation page](https://docs.substrate.io/main-docs/install/) is a good
-resource.
+If you need more information about setting up your development environment [Substrate's Installation
+page](https://docs.substrate.io/main-docs/install/) is a good resource.
## High-Level Architecture
-This repo has support for bridging foreign chains together using a combination of Substrate pallets
-and external processes called relayers. A bridge chain is one that is able to follow the consensus
-of a foreign chain independently. For example, consider the case below where we want to bridge two
-Substrate based chains.
+This repo has support for bridging foreign chains together using a combination of Substrate pallets and external
+processes called relayers. A bridge chain is one that is able to follow the consensus of a foreign chain independently.
+For example, consider the case below where we want to bridge two Substrate based chains.
```
+---------------+ +---------------+
@@ -82,19 +79,19 @@ Substrate based chains.
+---------------+
```
-The Millau chain must be able to accept Rialto 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 chain for verification.
+The Millau chain must be able to accept Rialto 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
+chain for verification.
-Take a look at [Bridge High Level Documentation](./docs/high-level-overview.md) for more in-depth
-description of the bridge interaction.
+Take a look at [Bridge High Level Documentation](./docs/high-level-overview.md) for more in-depth description of the
+bridge interaction.
## Project Layout
-Here's an overview of how the project is laid out. The main bits are the `bin`, which is the actual
-"blockchain", the `modules` which are used to build the blockchain's logic (a.k.a the runtime) and
-the `relays` which are used to pass messages between chains.
+Here's an overview of how the project is laid out. The main bits are the `bin`, which is the actual "blockchain", the
+`modules` which are used to build the blockchain's logic (a.k.a the runtime) and the `relays` which are used to pass
+messages between chains.
```
├── bin // Node and Runtime for the various Substrate chains
@@ -117,16 +114,16 @@ the `relays` which are used to pass messages between chains.
## 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).
+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;
+- 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.
+- running a Docker Compose setup: this is a recommended option, where you'll see bridges with parachains, complex relays
+and more.
### Using the Source
@@ -141,16 +138,15 @@ 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).
+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.
+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).
+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.
@@ -167,8 +163,8 @@ After the nodes are up we can run the header relayers.
./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.
+At this point you should see the relayer submitting headers from the Millau Substrate chain to the Rialto Substrate
+chain.
```
# Header Relayer Logs
@@ -192,20 +188,23 @@ You will also see the message lane relayers listening for new messages.
[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 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 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...) }
+[...] [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.
+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
@@ -222,20 +221,20 @@ 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).
-```
+... 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.
+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).
+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).
+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:
@@ -247,13 +246,12 @@ docker run -p 30333:30333 -p 9933:9933 -p 9944:9944 \
## 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.
+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.
+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.
+The [Substrate Technical](https://app.element.io/#/room/#substrate-technical:matrix.org) Element channel is most suited
+for discussions regarding Substrate itself.
diff --git a/cumulus/bridges/SECURITY.md b/cumulus/bridges/SECURITY.md
index 65f2f3bff05dd94786f7f3c8d084af2ca9fe236f..9f215c88765474e6b211882296c8cf190f216780 100644
--- a/cumulus/bridges/SECURITY.md
+++ b/cumulus/bridges/SECURITY.md
@@ -4,11 +4,15 @@ Thanks for helping make the Parity ecosystem more secure. Security is one of our
## Reporting a vulnerability
-If you find something that can be treated as a security vulnerability, please do not use the issue tracker or discuss it in the public forum as it can cause more damage, rather than giving real help to the ecosystem.
+If you find something that can be treated as a security vulnerability, please do not use the issue tracker or discuss it
+in the public forum as it can cause more damage, rather than giving real help to the ecosystem.
Security vulnerabilities should be reported by the [contact form](https://security-submission.parity.io/).
-If you think that your report might be eligible for the Bug Bounty Program, please mark this during the submission. Please check up-to-date [Parity Bug Bounty Program rules](https://www.parity.io/bug-bounty) to find out the information about our Bug Bounty Program.
-
-**Warning**: This is an unified SECURITY.md file for Paritytech GitHub Organization. The presence of this file does not mean that this repository is covered by the Bug Bounty program. Please always check the Bug Bounty Program scope for information.
+If you think that your report might be eligible for the Bug Bounty Program, please mark this during the submission.
+Please check up-to-date [Parity Bug Bounty Program rules](https://www.parity.io/bug-bounty) to find out the information
+about our Bug Bounty Program.
+**Warning**: This is an unified SECURITY.md file for Paritytech GitHub Organization. The presence of this file does not
+mean that this repository is covered by the Bug Bounty program. Please always check the Bug Bounty Program scope for
+information.
diff --git a/cumulus/bridges/bin/runtime-common/Cargo.toml b/cumulus/bridges/bin/runtime-common/Cargo.toml
index 6c0f576a7dd804cca06b01628187388bf0b3e587..b139f835c1a013b049f5c621f571d4377f234475 100644
--- a/cumulus/bridges/bin/runtime-common/Cargo.toml
+++ b/cumulus/bridges/bin/runtime-common/Cargo.toml
@@ -41,8 +41,8 @@ sp-std = { path = "../../../../substrate/primitives/std", default-features = fal
sp-trie = { path = "../../../../substrate/primitives/trie", default-features = false }
# Polkadot dependencies
-xcm = { path = "../../../../polkadot/xcm", default-features = false }
-xcm-builder = { path = "../../../../polkadot/xcm/xcm-builder", default-features = false }
+xcm = { package = "staging-xcm", path = "../../../../polkadot/xcm", default-features = false }
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../polkadot/xcm/xcm-builder", default-features = false }
[dev-dependencies]
bp-test-utils = { path = "../../primitives/test-utils" }
diff --git a/cumulus/bridges/bin/runtime-common/src/integrity.rs b/cumulus/bridges/bin/runtime-common/src/integrity.rs
index a0af3b981f307dfa1592b8a9199dcd8fb002aced..290c22f835d2a488e4f312f0a4811f730925fc15 100644
--- a/cumulus/bridges/bin/runtime-common/src/integrity.rs
+++ b/cumulus/bridges/bin/runtime-common/src/integrity.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/bin/runtime-common/src/lib.rs b/cumulus/bridges/bin/runtime-common/src/lib.rs
index 817922bc907d8d5f27d7c698a1df460361865f9f..ae6f40b142145dc265a69e8c78ef313f5ce9340f 100644
--- a/cumulus/bridges/bin/runtime-common/src/lib.rs
+++ b/cumulus/bridges/bin/runtime-common/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/bin/runtime-common/src/messages.rs b/cumulus/bridges/bin/runtime-common/src/messages.rs
index a650f082774618881fc1c635a75f9f211e429047..ac66adae6614b168855b285b4ef4f3cd74ecb068 100644
--- a/cumulus/bridges/bin/runtime-common/src/messages.rs
+++ b/cumulus/bridges/bin/runtime-common/src/messages.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/bin/runtime-common/src/messages_api.rs b/cumulus/bridges/bin/runtime-common/src/messages_api.rs
index 199e062fe9826cc44527ffe825a44a530fb618ef..ccf1c754041ed84dc302f0660fdd5bde8dc8d533 100644
--- a/cumulus/bridges/bin/runtime-common/src/messages_api.rs
+++ b/cumulus/bridges/bin/runtime-common/src/messages_api.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/bin/runtime-common/src/messages_benchmarking.rs b/cumulus/bridges/bin/runtime-common/src/messages_benchmarking.rs
index b067523c305b99aeb5ec9859b9c6b7b6eb77df1e..d80a88f1068c8975426105f881d963e1c3053ee5 100644
--- a/cumulus/bridges/bin/runtime-common/src/messages_benchmarking.rs
+++ b/cumulus/bridges/bin/runtime-common/src/messages_benchmarking.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
@@ -29,7 +29,7 @@ use crate::{
},
};
-use bp_messages::storage_keys;
+use bp_messages::{storage_keys, MessagePayload};
use bp_polkadot_core::parachains::ParaHash;
use bp_runtime::{
record_all_trie_keys, Chain, Parachain, RawStorageProof, StorageProofSize, UnderlyingChainOf,
@@ -45,8 +45,8 @@ use xcm::v3::prelude::*;
/// Prepare inbound bridge message according to given message proof parameters.
fn prepare_inbound_message(
params: &MessageProofParams,
- destination: InteriorMultiLocation,
-) -> Vec {
+ successful_dispatch_message_generator: impl Fn(usize) -> MessagePayload,
+) -> MessagePayload {
// we only care about **this** message size when message proof needs to be `Minimal`
let expected_size = match params.size {
StorageProofSize::Minimal(size) => size as usize,
@@ -58,20 +58,15 @@ fn prepare_inbound_message(
return vec![0u8; expected_size]
}
- // else let's prepare successful message. For XCM bridge hubs, it is the message that
- // will be pushed further to some XCM queue (XCMP/UMP)
- let location = xcm::VersionedInteriorMultiLocation::V3(destination);
- let location_encoded_size = location.encoded_size();
-
- // we don't need to be super-precise with `expected_size` here
- let xcm_size = expected_size.saturating_sub(location_encoded_size);
- let xcm = xcm::VersionedXcm::<()>::V3(vec![Instruction::ClearOrigin; xcm_size].into());
-
- // this is the `BridgeMessage` from polkadot xcm builder, but it has no constructor
- // or public fields, so just tuple
- // (double encoding, because `.encode()` is called on original Xcm BLOB when it is pushed
- // to the storage)
- (location, xcm).encode().encode()
+ // else let's prepare successful message.
+ let msg = successful_dispatch_message_generator(expected_size);
+ assert!(
+ msg.len() >= expected_size,
+ "msg.len(): {} does not match expected_size: {}",
+ expected_size,
+ msg.len()
+ );
+ msg
}
/// Prepare proof of messages for the `receive_messages_proof` call.
@@ -84,7 +79,7 @@ fn prepare_inbound_message(
/// function.
pub fn prepare_message_proof_from_grandpa_chain(
params: MessageProofParams,
- message_destination: InteriorMultiLocation,
+ message_generator: impl Fn(usize) -> MessagePayload,
) -> (FromBridgedChainMessagesProof>>, Weight)
where
R: pallet_bridge_grandpa::Config>>,
@@ -97,7 +92,7 @@ where
params.message_nonces.clone(),
params.outbound_lane_data.clone(),
params.size,
- prepare_inbound_message(¶ms, message_destination),
+ prepare_inbound_message(¶ms, message_generator),
encode_all_messages,
encode_lane_data,
);
@@ -127,7 +122,7 @@ where
/// `prepare_message_proof_from_grandpa_chain` function.
pub fn prepare_message_proof_from_parachain(
params: MessageProofParams,
- message_destination: InteriorMultiLocation,
+ message_generator: impl Fn(usize) -> MessagePayload,
) -> (FromBridgedChainMessagesProof>>, Weight)
where
R: pallet_bridge_parachains::Config,
@@ -141,7 +136,7 @@ where
params.message_nonces.clone(),
params.outbound_lane_data.clone(),
params.size,
- prepare_inbound_message(¶ms, message_destination),
+ prepare_inbound_message(¶ms, message_generator),
encode_all_messages,
encode_lane_data,
);
@@ -291,3 +286,53 @@ where
pallet_bridge_parachains::initialize_for_benchmarks::(bridged_header);
(bridged_block_number, bridged_header_hash)
}
+
+/// Returns callback which generates `BridgeMessage` from Polkadot XCM builder based on
+/// `expected_message_size` for benchmark.
+pub fn generate_xcm_builder_bridge_message_sample(
+ destination: InteriorMultiLocation,
+) -> impl Fn(usize) -> MessagePayload {
+ move |expected_message_size| -> MessagePayload {
+ // For XCM bridge hubs, it is the message that
+ // will be pushed further to some XCM queue (XCMP/UMP)
+ let location = xcm::VersionedInteriorMultiLocation::V3(destination);
+ let location_encoded_size = location.encoded_size();
+
+ // we don't need to be super-precise with `expected_size` here
+ let xcm_size = expected_message_size.saturating_sub(location_encoded_size);
+ let xcm_data_size = xcm_size.saturating_sub(
+ // minus empty instruction size
+ xcm::v3::Instruction::<()>::ExpectPallet {
+ index: 0,
+ name: vec![],
+ module_name: vec![],
+ crate_major: 0,
+ min_crate_minor: 0,
+ }
+ .encoded_size(),
+ );
+
+ log::trace!(
+ target: "runtime::bridge-benchmarks",
+ "generate_xcm_builder_bridge_message_sample with expected_message_size: {}, location_encoded_size: {}, xcm_size: {}, xcm_data_size: {}",
+ expected_message_size, location_encoded_size, xcm_size, xcm_data_size,
+ );
+
+ let xcm = xcm::VersionedXcm::<()>::V3(
+ vec![xcm::v3::Instruction::<()>::ExpectPallet {
+ index: 0,
+ name: vec![42; xcm_data_size],
+ module_name: vec![],
+ crate_major: 0,
+ min_crate_minor: 0,
+ }]
+ .into(),
+ );
+
+ // this is the `BridgeMessage` from polkadot xcm builder, but it has no constructor
+ // or public fields, so just tuple
+ // (double encoding, because `.encode()` is called on original Xcm BLOB when it is pushed
+ // to the storage)
+ (location, xcm).encode().encode()
+ }
+}
diff --git a/cumulus/bridges/bin/runtime-common/src/messages_call_ext.rs b/cumulus/bridges/bin/runtime-common/src/messages_call_ext.rs
index badb17efa0841430721ab07ce293bc086306a988..07a99d2c0a16c381799c02e58cb9c4b574e2ad1c 100644
--- a/cumulus/bridges/bin/runtime-common/src/messages_call_ext.rs
+++ b/cumulus/bridges/bin/runtime-common/src/messages_call_ext.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/bin/runtime-common/src/messages_generation.rs b/cumulus/bridges/bin/runtime-common/src/messages_generation.rs
index 8dbf3abd683cfff79e3068f70d6c4ecab5e91bd3..3c550a9bd0fd546ba90753b8871e049e65a702e3 100644
--- a/cumulus/bridges/bin/runtime-common/src/messages_generation.rs
+++ b/cumulus/bridges/bin/runtime-common/src/messages_generation.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2022 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/bin/runtime-common/src/messages_xcm_extension.rs b/cumulus/bridges/bin/runtime-common/src/messages_xcm_extension.rs
index 44e554ecb24f807cfc716f6dbf14f124382382f0..77c23db3b2ba2d01aef0d2c45a20377eaf8ea129 100644
--- a/cumulus/bridges/bin/runtime-common/src/messages_xcm_extension.rs
+++ b/cumulus/bridges/bin/runtime-common/src/messages_xcm_extension.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
@@ -29,7 +29,7 @@ use bp_messages::{
use bp_runtime::messages::MessageDispatchResult;
use bp_xcm_bridge_hub_router::XcmChannelStatusProvider;
use codec::{Decode, Encode};
-use frame_support::{dispatch::Weight, traits::Get, CloneNoBound, EqNoBound, PartialEqNoBound};
+use frame_support::{traits::Get, weights::Weight, CloneNoBound, EqNoBound, PartialEqNoBound};
use pallet_bridge_messages::{
Config as MessagesConfig, OutboundLanesCongestedSignals, Pallet as MessagesPallet,
WeightInfoExt as MessagesPalletWeights,
diff --git a/cumulus/bridges/bin/runtime-common/src/mock.rs b/cumulus/bridges/bin/runtime-common/src/mock.rs
index 9c41d17fa9957fd5dd5bf43fd868bcac06fe50f3..45ef790d74482b01948a74cdb0a53c332aa41896 100644
--- a/cumulus/bridges/bin/runtime-common/src/mock.rs
+++ b/cumulus/bridges/bin/runtime-common/src/mock.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/bin/runtime-common/src/parachains_benchmarking.rs b/cumulus/bridges/bin/runtime-common/src/parachains_benchmarking.rs
index aad53673c3ad3eb36b1b16b2543203e50986c794..63dc78385e46ebb537f06e88a139efacaeeb3832 100644
--- a/cumulus/bridges/bin/runtime-common/src/parachains_benchmarking.rs
+++ b/cumulus/bridges/bin/runtime-common/src/parachains_benchmarking.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/bin/runtime-common/src/priority_calculator.rs b/cumulus/bridges/bin/runtime-common/src/priority_calculator.rs
index 590de05fb1c66c839c711e8dce37963136488de9..3d53f9da8c20e9503959b2aa8dc97807eacd5c67 100644
--- a/cumulus/bridges/bin/runtime-common/src/priority_calculator.rs
+++ b/cumulus/bridges/bin/runtime-common/src/priority_calculator.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
@@ -51,13 +51,13 @@ mod integrity_tests {
use bp_messages::MessageNonce;
use bp_runtime::PreComputedSize;
use frame_support::{
- dispatch::{DispatchClass, DispatchInfo, Dispatchable, Pays, PostDispatchInfo},
+ dispatch::{DispatchClass, DispatchInfo, Pays, PostDispatchInfo},
traits::Get,
};
use pallet_bridge_messages::WeightInfoExt;
use pallet_transaction_payment::OnChargeTransaction;
use sp_runtime::{
- traits::{UniqueSaturatedInto, Zero},
+ traits::{Dispatchable, UniqueSaturatedInto, Zero},
transaction_validity::TransactionPriority,
FixedPointOperand, SaturatedConversion, Saturating,
};
diff --git a/cumulus/bridges/bin/runtime-common/src/refund_relayer_extension.rs b/cumulus/bridges/bin/runtime-common/src/refund_relayer_extension.rs
index 4e577e88a4118283127392db926d219411334c33..f0c2cbf44509b3340028927a5b374461c2e94d12 100644
--- a/cumulus/bridges/bin/runtime-common/src/refund_relayer_extension.rs
+++ b/cumulus/bridges/bin/runtime-common/src/refund_relayer_extension.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
@@ -27,7 +27,7 @@ use bp_relayers::{RewardsAccountOwner, RewardsAccountParams};
use bp_runtime::{Parachain, ParachainIdOf, RangeInclusiveExt, StaticStrProvider};
use codec::{Decode, Encode};
use frame_support::{
- dispatch::{CallableCallFor, DispatchInfo, Dispatchable, PostDispatchInfo},
+ dispatch::{CallableCallFor, DispatchInfo, PostDispatchInfo},
traits::IsSubType,
weights::Weight,
CloneNoBound, DefaultNoBound, EqNoBound, PartialEqNoBound, RuntimeDebugNoBound,
@@ -47,7 +47,7 @@ use pallet_transaction_payment::{Config as TransactionPaymentConfig, OnChargeTra
use pallet_utility::{Call as UtilityCall, Config as UtilityConfig, Pallet as UtilityPallet};
use scale_info::TypeInfo;
use sp_runtime::{
- traits::{DispatchInfoOf, Get, PostDispatchInfoOf, SignedExtension, Zero},
+ traits::{DispatchInfoOf, Dispatchable, Get, PostDispatchInfoOf, SignedExtension, Zero},
transaction_validity::{
TransactionPriority, TransactionValidity, TransactionValidityError, ValidTransactionBuilder,
},
diff --git a/cumulus/bridges/docs/high-level-overview.md b/cumulus/bridges/docs/high-level-overview.md
index 449224124afd77a4e53d55e7cf6b3b9a65961802..42efc8100bd080763c22ea3e4e813f3c3c87db37 100644
--- a/cumulus/bridges/docs/high-level-overview.md
+++ b/cumulus/bridges/docs/high-level-overview.md
@@ -1,83 +1,85 @@
# 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 <> Kusama Bridge](./polkadot-kusama-bridge-overview.md).
+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 <>
+Kusama Bridge](./polkadot-kusama-bridge-overview.md).
## Purpose
-This repo contains all components required to build a trustless connection between standalone Substrate chains,
-that are using GRANDPA finality, their parachains or any combination of those. On top of this connection, we
-offer a messaging pallet that provides means to organize messages exchange.
+This repo contains all components required to build a trustless connection between standalone Substrate chains, that are
+using GRANDPA finality, their parachains or any combination of those. On top of this connection, we offer a messaging
+pallet that provides means to organize messages exchange.
-On top of that layered infrastructure, anyone may build their own bridge applications - e.g. [XCM messaging](./polkadot-kusama-bridge-overview.md),
-[encoded calls messaging](https://github.com/paritytech/parity-bridges-common/releases/tag/encoded-calls-messaging) and so on.
+On top of that layered infrastructure, anyone may build their own bridge applications - e.g. [XCM
+messaging](./polkadot-kusama-bridge-overview.md), [encoded calls
+messaging](https://github.com/paritytech/parity-bridges-common/releases/tag/encoded-calls-messaging) and so on.
## Terminology
-Even though we support (and require) two-way bridging, the documentation will generally talk about
-a one-sided interaction. That's to say, we will only talk about syncing finality proofs and messages
-from a _source_ chain to a _target_ chain. This is because the two-sided interaction is really just the
-one-sided interaction with the source and target chains switched.
+Even though we support (and require) two-way bridging, the documentation will generally talk about a one-sided
+interaction. That's to say, we will only talk about syncing finality proofs and messages from a _source_ chain to a
+_target_ chain. This is because the two-sided interaction is really just the one-sided interaction with the source and
+target chains switched.
The bridge has both on-chain (pallets) and offchain (relayers) components.
## On-chain components
-On-chain bridge components are pallets that are deployed at the chain runtime. Finality pallets require
-deployment at the target chain, while messages pallet needs to be deployed at both, source
-and target chains.
+On-chain bridge components are pallets that are deployed at the chain runtime. Finality pallets require deployment at
+the target chain, while messages pallet needs to be deployed at both, source and target chains.
### Bridge GRANDPA Finality Pallet
-A GRANDPA light client of the source chain built into the target chain's runtime. It provides a "source of truth"
-about the source chain headers which have been finalized. This is useful for higher level applications.
+A GRANDPA light client of the source chain built into the target chain's runtime. It provides a "source of truth" about
+the source chain headers which have been finalized. This is useful for higher level applications.
-The pallet tracks current GRANDPA authorities set and only accepts finality proofs (GRANDPA justifications),
-generated by the current authorities set. The GRANDPA protocol itself requires current authorities set to
-generate explicit justification for the header that enacts next authorities set. Such headers and their finality
-proofs are called mandatory in the pallet and relayer pays no fee for such headers submission.
+The pallet tracks current GRANDPA authorities set and only accepts finality proofs (GRANDPA justifications), generated
+by the current authorities set. The GRANDPA protocol itself requires current authorities set to generate explicit
+justification for the header that enacts next authorities set. Such headers and their finality proofs are called
+mandatory in the pallet and relayer pays no fee for such headers submission.
-The pallet does not require all headers to be imported or provided. The relayer itself chooses which headers
-he wants to submit (with the exception of mandatory headers).
+The pallet does not require all headers to be imported or provided. The relayer itself chooses which headers he wants to
+submit (with the exception of mandatory headers).
More: [pallet level documentation and code](../modules/grandpa/).
### Bridge Parachains Finality Pallet
-Parachains are not supposed to have their own finality, so we can't use bridge GRANDPA pallet to verify their
-finality proofs. Instead, they rely on their relay chain finality. The parachain header is considered final,
-when it is accepted by the [`paras` pallet](https://github.com/paritytech/polkadot/tree/1a034bd6de0e76721d19aed02a538bcef0787260/runtime/parachains/src/paras)
-at its relay chain. Obviously, the relay chain block, where it is accepted, must also be finalized by the relay
-chain GRANDPA gadget.
+Parachains are not supposed to have their own finality, so we can't use bridge GRANDPA pallet to verify their finality
+proofs. Instead, they rely on their relay chain finality. The parachain header is considered final, when it is accepted
+by the [`paras`
+pallet](https://github.com/paritytech/polkadot/tree/1a034bd6de0e76721d19aed02a538bcef0787260/runtime/parachains/src/paras)
+at its relay chain. Obviously, the relay chain block, where it is accepted, must also be finalized by the relay chain
+GRANDPA gadget.
That said, the bridge parachains pallet accepts storage proof of one or several parachain heads, inserted to the
[`Heads`](https://github.com/paritytech/polkadot/blob/1a034bd6de0e76721d19aed02a538bcef0787260/runtime/parachains/src/paras/mod.rs#L642)
-map of the [`paras` pallet](https://github.com/paritytech/polkadot/tree/1a034bd6de0e76721d19aed02a538bcef0787260/runtime/parachains/src/paras).
+map of the [`paras`
+pallet](https://github.com/paritytech/polkadot/tree/1a034bd6de0e76721d19aed02a538bcef0787260/runtime/parachains/src/paras).
To verify this storage proof, the pallet uses relay chain header, imported earlier by the bridge GRANDPA pallet.
-The pallet may track multiple parachains at once and those parachains may use different primitives. So the
-parachain header decoding never happens at the pallet level. For maintaining the headers order, the pallet
-uses relay chain header number.
+The pallet may track multiple parachains at once and those parachains may use different primitives. So the parachain
+header decoding never happens at the pallet level. For maintaining the headers order, the pallet uses relay chain header
+number.
More: [pallet level documentation and code](../modules/parachains/).
### Bridge Messages Pallet
-The pallet is responsible for queuing messages at the source chain and receiving the messages proofs at the
-target chain. The messages are sent to the particular _lane_, where they are guaranteed to be received in the
-same order they are sent. The pallet supports many lanes.
+The pallet is responsible for queuing messages at the source chain and receiving the messages proofs at the target
+chain. The messages are sent to the particular _lane_, where they are guaranteed to be received in the same order they
+are sent. The pallet supports many lanes.
-The lane has two ends. Outbound lane end is storing number of messages that have been sent and the number of
-messages that have been received. Inbound lane end stores the number of messages that have been received and
-also a map that maps messages to relayers that have delivered those messages to the target chain.
+The lane has two ends. Outbound lane end is storing number of messages that have been sent and the number of messages
+that have been received. Inbound lane end stores the number of messages that have been received and also a map that maps
+messages to relayers that have delivered those messages to the target chain.
The pallet has three main entrypoints:
- the `send_message` may be used by the other runtime pallets to send the messages;
-- the `receive_messages_proof` is responsible for parsing the messages proof and handing messages over to the
-dispatch code;
-- the `receive_messages_delivery_proof` is responsible for parsing the messages delivery proof and rewarding
-relayers that have delivered the message.
+- the `receive_messages_proof` is responsible for parsing the messages proof and handing messages over to the dispatch
+code;
+- the `receive_messages_delivery_proof` is responsible for parsing the messages delivery proof and rewarding relayers
+that have delivered the message.
Many things are abstracted by the pallet:
- the message itself may mean anything, the pallet doesn't care about its content;
@@ -85,97 +87,98 @@ Many things are abstracted by the pallet:
- the messages proof and messages delivery proof are verified outside of the pallet;
- the relayers incentivization scheme is defined outside of the pallet.
-Outside of the messaging pallet, we have a set of adapters, where messages and delivery proofs are regular
-storage proofs. The proofs are generated at the bridged chain and require bridged chain finality. So messages
-pallet, in this case, depends on one of the finality pallets. The messages are XCM messages and we are using
-XCM executor to dispatch them on receival. You may find more info in [Polkadot <> Kusama Bridge](./polkadot-kusama-bridge-overview.md)
-document.
+Outside of the messaging pallet, we have a set of adapters, where messages and delivery proofs are regular storage
+proofs. The proofs are generated at the bridged chain and require bridged chain finality. So messages pallet, in this
+case, depends on one of the finality pallets. The messages are XCM messages and we are using XCM executor to dispatch
+them on receival. You may find more info in [Polkadot <> Kusama Bridge](./polkadot-kusama-bridge-overview.md) document.
More: [pallet level documentation and code](../modules/messages/).
### Bridge Relayers Pallet
-The pallet is quite simple. It just registers relayer rewards and has an entrypoint to collect them. When
-the rewards are registered and the reward amount is configured outside of the pallet.
+The pallet is quite simple. It just registers relayer rewards and has an entrypoint to collect them. When the rewards
+are registered and the reward amount is configured outside of the pallet.
More: [pallet level documentation and code](../modules/relayers/).
## Offchain Components
-Offchain bridge components are separate processes, called relayers. Relayers are connected both to the
-source chain and target chain nodes. Relayers are reading state of the source chain, compare it to the
-state of the target chain and, if state at target chain needs to be updated, submits target chain
-transaction.
+Offchain bridge components are separate processes, called relayers. Relayers are connected both to the source chain and
+target chain nodes. Relayers are reading state of the source chain, compare it to the state of the target chain and, if
+state at target chain needs to be updated, submits target chain transaction.
### GRANDPA Finality Relay
-The task of relay is to submit source chain GRANDPA justifications and their corresponding headers to
-the Bridge GRANDPA Finality Pallet, deployed at the target chain. For that, the relay subscribes to
-the source chain GRANDPA justifications stream and submits every new justification it sees to the
-target chain GRANDPA light client. In addition, relay is searching for mandatory headers and
-submits their justifications - without that the pallet will be unable to move forward.
+The task of relay is to submit source chain GRANDPA justifications and their corresponding headers to the Bridge GRANDPA
+Finality Pallet, deployed at the target chain. For that, the relay subscribes to the source chain GRANDPA justifications
+stream and submits every new justification it sees to the target chain GRANDPA light client. In addition, relay is
+searching for mandatory headers and submits their justifications - without that the pallet will be unable to move
+forward.
-More: [GRANDPA Finality Relay Sequence Diagram](./grandpa-finality-relay.html), [pallet level documentation and code](../relays/finality/).
+More: [GRANDPA Finality Relay Sequence Diagram](./grandpa-finality-relay.html), [pallet level documentation and
+code](../relays/finality/).
### Parachains Finality Relay
-The relay connects to the source _relay_ chain and the target chain nodes. It doesn't need to connect to the
-tracked parachain nodes. The relay looks at the [`Heads`](https://github.com/paritytech/polkadot/blob/1a034bd6de0e76721d19aed02a538bcef0787260/runtime/parachains/src/paras/mod.rs#L642)
-map of the [`paras` pallet](https://github.com/paritytech/polkadot/tree/1a034bd6de0e76721d19aed02a538bcef0787260/runtime/parachains/src/paras)
-in source chain, and compares the value with the best parachain head, stored in the bridge parachains pallet at
-the target chain. If new parachain head appears at the relay chain block `B`, the relay process **waits**
-until header `B` or one of its ancestors appears at the target chain. Once it is available, the storage
-proof of the map entry is generated and is submitted to the target chain.
+The relay connects to the source _relay_ chain and the target chain nodes. It doesn't need to connect to the tracked
+parachain nodes. The relay looks at the
+[`Heads`](https://github.com/paritytech/polkadot/blob/1a034bd6de0e76721d19aed02a538bcef0787260/runtime/parachains/src/paras/mod.rs#L642)
+map of the [`paras`
+pallet](https://github.com/paritytech/polkadot/tree/1a034bd6de0e76721d19aed02a538bcef0787260/runtime/parachains/src/paras)
+in source chain, and compares the value with the best parachain head, stored in the bridge parachains pallet at the
+target chain. If new parachain head appears at the relay chain block `B`, the relay process **waits** until header `B`
+or one of its ancestors appears at the target chain. Once it is available, the storage proof of the map entry is
+generated and is submitted to the target chain.
-As its on-chain component (which requires bridge GRANDPA pallet to be deployed nearby), the parachains
-finality relay requires GRANDPA finality relay to be running in parallel. Without it, the header `B` or
-any of its children's finality at source won't be relayed at target, and target chain
-won't be able to verify generated storage proof.
+As its on-chain component (which requires bridge GRANDPA pallet to be deployed nearby), the parachains finality relay
+requires GRANDPA finality relay to be running in parallel. Without it, the header `B` or any of its children's finality
+at source won't be relayed at target, and target chain won't be able to verify generated storage proof.
More: [Parachains Finality Relay Sequence Diagram](./parachains-finality-relay.html), [code](../relays/parachains/).
### Messages Relay
-Messages relay is actually two relays that are running in a single process: messages delivery relay and
-delivery confirmation relay. Even though they are more complex and have many caveats, the overall algorithm
-is the same as in other relays.
+Messages relay is actually two relays that are running in a single process: messages delivery relay and delivery
+confirmation relay. Even though they are more complex and have many caveats, the overall algorithm is the same as in
+other relays.
-Message delivery relay connects to the source chain and looks at the outbound lane end, waiting until new
-messages are queued there. Once they appear at the source block `B`, the relay start waiting for the block
-`B` or its descendant appear at the target chain. Then the messages storage proof is generated and submitted
-to the bridge messages pallet at the target chain. In addition, the transaction may include the storage proof
-of the outbound lane state - that proves that relayer rewards have been paid and this data (map of relay
-accounts to the delivered messages) may be pruned from the inbound lane state at the target chain.
+Message delivery relay connects to the source chain and looks at the outbound lane end, waiting until new messages are
+queued there. Once they appear at the source block `B`, the relay start waiting for the block `B` or its descendant
+appear at the target chain. Then the messages storage proof is generated and submitted to the bridge messages pallet at
+the target chain. In addition, the transaction may include the storage proof of the outbound lane state - that proves
+that relayer rewards have been paid and this data (map of relay accounts to the delivered messages) may be pruned from
+the inbound lane state at the target chain.
-Delivery confirmation relay connects to the target chain and starts watching the inbound lane end. When new
-messages are delivered to the target chain, the corresponding _source chain account_ is inserted to the
-map in the inbound lane data. Relay detects that, say, at the target chain block `B` and waits until that
-block or its descendant appears at the source chain. Once that happens, the relay crafts a storage proof of
-that data and sends it to the messages pallet, deployed at the source chain.
+Delivery confirmation relay connects to the target chain and starts watching the inbound lane end. When new messages are
+delivered to the target chain, the corresponding _source chain account_ is inserted to the map in the inbound lane data.
+Relay detects that, say, at the target chain block `B` and waits until that block or its descendant appears at the
+source chain. Once that happens, the relay crafts a storage proof of that data and sends it to the messages pallet,
+deployed at the source chain.
-As you can see, the messages relay also requires finality relay to be operating in parallel. Since messages
-relay submits transactions to both source and target chains, it requires both _source-to-target_ and
-_target-to-source_ finality relays. They can be GRANDPA finality relays or GRANDPA+parachains finality relays,
-depending on the type of connected chain.
+As you can see, the messages relay also requires finality relay to be operating in parallel. Since messages relay
+submits transactions to both source and target chains, it requires both _source-to-target_ and _target-to-source_
+finality relays. They can be GRANDPA finality relays or GRANDPA+parachains finality relays, depending on the type of
+connected chain.
-More: [Messages Relay Sequence Diagram](./messages-relay.html), [pallet level documentation and code](../relays/messages/).
+More: [Messages Relay Sequence Diagram](./messages-relay.html), [pallet level documentation and
+code](../relays/messages/).
### Complex Relay
-Every relay transaction has its cost. The only transaction, that is "free" to relayer is when the mandatory
-GRANDPA header is submitted. The relay that feeds the bridge with every relay chain and/or parachain head it
-sees, will have to pay a (quite large) cost. And if no messages are sent through the bridge, that is just
-waste of money.
+Every relay transaction has its cost. The only transaction, that is "free" to relayer is when the mandatory GRANDPA
+header is submitted. The relay that feeds the bridge with every relay chain and/or parachain head it sees, will have to
+pay a (quite large) cost. And if no messages are sent through the bridge, that is just waste of money.
-We have a special relay mode, called _complex relay_, where relay mostly sleeps and only submits transactions
-that are required for the messages/confirmations delivery. This mode starts two message relays (in both
-directions). All required finality relays are also started in a special _on-demand_ mode. In this mode they
-do not submit any headers without special request. As always, the only exception is when GRANDPA finality
-relay sees the mandatory header - it is submitted without such request.
+We have a special relay mode, called _complex relay_, where relay mostly sleeps and only submits transactions that are
+required for the messages/confirmations delivery. This mode starts two message relays (in both directions). All required
+finality relays are also started in a special _on-demand_ mode. In this mode they do not submit any headers without
+special request. As always, the only exception is when GRANDPA finality relay sees the mandatory header - it is
+submitted without such request.
-The message relays are watching their lanes and when, at some block `B`, they see new messages/confirmations
-to be delivered, they are asking on-demand relays to relay this block `B`. On-demand relays does that and
-then message relay may perform its job. If on-demand relay is a parachain finality relay, it also runs its
-own on-demand GRANDPA relay, which is used to relay required relay chain headers.
+The message relays are watching their lanes and when, at some block `B`, they see new messages/confirmations to be
+delivered, they are asking on-demand relays to relay this block `B`. On-demand relays does that and then message relay
+may perform its job. If on-demand relay is a parachain finality relay, it also runs its own on-demand GRANDPA relay,
+which is used to relay required relay chain headers.
-More: [Complex Relay Sequence Diagram](./complex-relay.html), [code](../relays/bin-substrate/src/cli/relay_headers_and_messages/).
+More: [Complex Relay Sequence Diagram](./complex-relay.html),
+[code](../relays/bin-substrate/src/cli/relay_headers_and_messages/).
diff --git a/cumulus/bridges/docs/polkadot-kusama-bridge-overview.md b/cumulus/bridges/docs/polkadot-kusama-bridge-overview.md
index b469720f65b2bb5b8b941ec34e89df505d13ac67..08036f0b0722b869786ae3d0abfc6ae7ea7c2c18 100644
--- a/cumulus/bridges/docs/polkadot-kusama-bridge-overview.md
+++ b/cumulus/bridges/docs/polkadot-kusama-bridge-overview.md
@@ -1,35 +1,35 @@
# Polkadot <> Kusama Bridge Overview
-This document describes how we use all components, described in the [High-Level Bridge Documentation](./high-level-overview.md),
-to build the XCM bridge between Kusama and Polkadot. In this case, our components merely work as a XCM transport
-(like XCMP/UMP/HRMP), between chains that are not a part of the same consensus system.
+This document describes how we use all components, described in the [High-Level Bridge
+Documentation](./high-level-overview.md), to build the XCM bridge between Kusama and Polkadot. In this case, our
+components merely work as a XCM transport (like XCMP/UMP/HRMP), between chains that are not a part of the same consensus
+system.
The overall architecture may be seen in [this diagram](./polkadot-kusama-bridge.html).
## Bridge Hubs
-All operations at relay chain are expensive. Ideally all non-mandatory transactions must happen on parachains.
-That's why we are planning to have two parachains - Polkadot Bridge Hub under Polkadot consensus and Kusama
-Bridge Hub under Kusama consensus.
+All operations at relay chain are expensive. Ideally all non-mandatory transactions must happen on parachains. That's
+why we are planning to have two parachains - Polkadot Bridge Hub under Polkadot consensus and Kusama Bridge Hub under
+Kusama consensus.
-The Bridge Hub will have all required bridge pallets in its runtime. We hope that later, other teams will be able to
-use our bridge hubs too and have their pallets there.
+The Bridge Hub will have all required bridge pallets in its runtime. We hope that later, other teams will be able to use
+our bridge hubs too and have their pallets there.
-The Bridge Hub will use the base token of the ecosystem - KSM at Kusama Bridge Hub and DOT at Polkadot Bridge Hub.
-The runtime will have minimal set of non-bridge pallets, so there's not much you can do directly on bridge hubs.
+The Bridge Hub will use the base token of the ecosystem - KSM at Kusama Bridge Hub and DOT at Polkadot Bridge Hub. The
+runtime will have minimal set of non-bridge pallets, so there's not much you can do directly on bridge hubs.
## Connecting Parachains
-You won't be able to directly use bridge hub transactions to send XCM messages over the bridge. Instead, you'll need
-to use other parachains transactions, which will use HRMP to deliver messages to the Bridge Hub. The Bridge Hub will
-just queue these messages in its outbound lane, which is dedicated to deliver messages between two parachains.
+You won't be able to directly use bridge hub transactions to send XCM messages over the bridge. Instead, you'll need to
+use other parachains transactions, which will use HRMP to deliver messages to the Bridge Hub. The Bridge Hub will just
+queue these messages in its outbound lane, which is dedicated to deliver messages between two parachains.
-Our first planned bridge will connect the Polkadot and Kusama Asset Hubs. A bridge between those two
-parachains would allow Asset Hub Polkadot accounts to hold wrapped KSM tokens and Asset Hub Kusama
-accounts to hold wrapped DOT tokens.
+Our first planned bridge will connect the Polkadot and Kusama Asset Hubs. A bridge between those two parachains would
+allow Asset Hub Polkadot accounts to hold wrapped KSM tokens and Asset Hub Kusama accounts to hold wrapped DOT tokens.
-For that bridge (pair of parachains under different consensus systems) we'll be using the lane 00000000. Later,
-when other parachains will join the bridge, they will be using other lanes for their messages.
+For that bridge (pair of parachains under different consensus systems) we'll be using the lane 00000000. Later, when
+other parachains will join the bridge, they will be using other lanes for their messages.
## Running Relayers
@@ -38,9 +38,9 @@ justifications to the bridge hubs at the other side. It'll also relay finalized
Hub heads. This will only happen when messages will be queued at hubs. So most of time relayer will be idle.
There's no any active relayer sets, or something like that. Anyone may start its own relayer and relay queued messages.
-We are not against that and, as always, appreciate any community efforts. Of course, running relayer has the cost.
-Apart from paying for the CPU and network, the relayer pays for transactions at both sides of the bridge. We have
-a mechanism for rewarding relayers.
+We are not against that and, as always, appreciate any community efforts. Of course, running relayer has the cost. Apart
+from paying for the CPU and network, the relayer pays for transactions at both sides of the bridge. We have a mechanism
+for rewarding relayers.
### Compensating the Cost of Message Delivery Transactions
@@ -56,51 +56,49 @@ is the relayer, which is following our rules:
- we compensate the cost of message delivery transactions that have actually delivered the messages. So if your
transaction has claimed to deliver messages `[42, 43, 44]`, but, because of some reasons, has actually delivered
- messages `[42, 43]`, the transaction will be free for relayer. If it has not delivered any messages, then
- the relayer pays the full cost of the transaction;
+ messages `[42, 43]`, the transaction will be free for relayer. If it has not delivered any messages, then the relayer
+ pays the full cost of the transaction;
- we compensate the cost of message delivery and all required finality calls, if they are part of the same
[`frame_utility::batch_all`](https://github.com/paritytech/substrate/blob/891d6a5c870ab88521183facafc811a203bb6541/frame/utility/src/lib.rs#L326)
- transaction. Of course, the calls inside the batch must be linked - e.g. the submitted parachain head must be used
- to prove messages. Relay header must be used to prove parachain head finality. If one of calls fails, or if they
- are not linked together, the relayer pays the full transaction cost.
+ transaction. Of course, the calls inside the batch must be linked - e.g. the submitted parachain head must be used to
+ prove messages. Relay header must be used to prove parachain head finality. If one of calls fails, or if they are not
+ linked together, the relayer pays the full transaction cost.
Please keep in mind that the fee of "zero-cost" transactions is still withdrawn from the relayer account. But the
-compensation is registered in the `pallet_bridge_relayers::RelayerRewards` map at the target bridge hub. The relayer
-may later claim all its rewards later, using the `pallet_bridge_relayers::claim_rewards` call.
+compensation is registered in the `pallet_bridge_relayers::RelayerRewards` map at the target bridge hub. The relayer may
+later claim all its rewards later, using the `pallet_bridge_relayers::claim_rewards` call.
*A side note*: why we don't simply set the cost of useful transactions to zero? That's because the bridge has its cost.
If we won't take any fees, it would mean that the sender is not obliged to pay for its messages. And Bridge Hub
-collators (and, maybe, "treasury") are not receiving any payment for including transactions. More about this later,
-in the [Who is Rewarding Relayers](#who-is-rewarding-relayers) section.
+collators (and, maybe, "treasury") are not receiving any payment for including transactions. More about this later, in
+the [Who is Rewarding Relayers](#who-is-rewarding-relayers) section.
### Message Delivery Confirmation Rewards
In addition to the "zero-cost" message delivery transactions, the relayer is also rewarded for:
-- delivering every message. The reward is registered during delivery confirmation transaction at the Source Bridge
- Hub.;
+- delivering every message. The reward is registered during delivery confirmation transaction at the Source Bridge Hub.;
-- submitting delivery confirmation transaction. The relayer may submit delivery confirmation that e.g. confirms
- delivery of four messages, of which the only one (or zero) messages is actually delivered by this relayer. It
- receives some fee for confirming messages, delivered by other relayers.
+- submitting delivery confirmation transaction. The relayer may submit delivery confirmation that e.g. confirms delivery
+ of four messages, of which the only one (or zero) messages is actually delivered by this relayer. It receives some fee
+ for confirming messages, delivered by other relayers.
Both rewards may be claimed using the `pallet_bridge_relayers::claim_rewards` call at the Source Bridge Hub.
### Who is Rewarding Relayers
Obviously, there should be someone who is paying relayer rewards. We want bridge transactions to have a cost, so we
-can't use fees for rewards. Instead, the parachains using the bridge, use sovereign accounts on both sides
-of the bridge to cover relayer rewards.
+can't use fees for rewards. Instead, the parachains using the bridge, use sovereign accounts on both sides of the bridge
+to cover relayer rewards.
-Bridged Parachains will have sovereign accounts at bridge hubs. For example, the Kusama Asset Hub will
-have an account at the Polkadot Bridge Hub. The Polkadot Asset Hub will have an account at the Kusama
-Bridge Hub. The sovereign accounts are used as a source of funds when the relayer is calling the
-`pallet_bridge_relayers::claim_rewards`.
+Bridged Parachains will have sovereign accounts at bridge hubs. For example, the Kusama Asset Hub will have an account
+at the Polkadot Bridge Hub. The Polkadot Asset Hub will have an account at the Kusama Bridge Hub. The sovereign accounts
+are used as a source of funds when the relayer is calling the `pallet_bridge_relayers::claim_rewards`.
-Since messages lane is only used by the pair of parachains, there's no collision between different bridges. E.g.
-Kusama Asset Hub will only reward relayers that are delivering messages from Kusama Asset Hub. The Kusama Asset Hub sovereign account
-is not used to cover rewards of bridging with some other Polkadot Parachain.
+Since messages lane is only used by the pair of parachains, there's no collision between different bridges. E.g. Kusama
+Asset Hub will only reward relayers that are delivering messages from Kusama Asset Hub. The Kusama Asset Hub sovereign
+account is not used to cover rewards of bridging with some other Polkadot Parachain.
### Multiple Relayers and Rewards
@@ -108,25 +106,24 @@ Our goal is to incentivize running honest relayers. But we have no relayers sets
message delivery transaction, hoping that the cost of this transaction will be compensated. So what if some message is
currently queued and two relayers are submitting two identical message delivery transactions at once? Without any
special means, the cost of first included transaction will be compensated and the cost of the other one won't. A honest,
-but unlucky relayer will lose some money. In addition, we'll waste some portion of block size and weight, which
-may be used by other useful transactions.
+but unlucky relayer will lose some money. In addition, we'll waste some portion of block size and weight, which may be
+used by other useful transactions.
-To solve the problem, we have two signed extensions ([generate_bridge_reject_obsolete_headers_and_messages! {}](../bin/runtime-common/src/lib.rs)
-and [RefundRelayerForMessagesFromParachain](../bin/runtime-common/src/refund_relayer_extension.rs)), that are
-preventing bridge transactions with obsolete data from including into the block. We are rejecting following
-transactions:
+To solve the problem, we have two signed extensions ([generate_bridge_reject_obsolete_headers_and_messages!
+{}](../bin/runtime-common/src/lib.rs) and
+[RefundRelayerForMessagesFromParachain](../bin/runtime-common/src/refund_relayer_extension.rs)), that are preventing
+bridge transactions with obsolete data from including into the block. We are rejecting following transactions:
- transactions, that are submitting the GRANDPA justification for the best finalized header, or one of its ancestors;
- transactions, that are submitting the proof of the current best parachain head, or one of its ancestors;
-- transactions, that are delivering already delivered messages. If at least one of messages is not yet delivered,
- the transaction is not rejected;
+- transactions, that are delivering already delivered messages. If at least one of messages is not yet delivered, the
+ transaction is not rejected;
-- transactions, that are confirming delivery of already confirmed messages. If at least one of confirmations is new,
- the transaction is not rejected;
+- transactions, that are confirming delivery of already confirmed messages. If at least one of confirmations is new, the
+ transaction is not rejected;
- [`frame_utility::batch_all`](https://github.com/paritytech/substrate/blob/891d6a5c870ab88521183facafc811a203bb6541/frame/utility/src/lib.rs#L326)
- transactions, that have both finality and message delivery calls. All restrictions from the
- [Compensating the Cost of Message Delivery Transactions](#compensating-the-cost-of-message-delivery-transactions)
- are applied.
+ transactions, that have both finality and message delivery calls. All restrictions from the [Compensating the Cost of
+ Message Delivery Transactions](#compensating-the-cost-of-message-delivery-transactions) are applied.
diff --git a/cumulus/bridges/modules/grandpa/src/benchmarking.rs b/cumulus/bridges/modules/grandpa/src/benchmarking.rs
index aa222d6e4de6f0ffa9eabe93436bb3726129bd31..182b2f56eb1c57a165cf2eb1e86b585d70fd1801 100644
--- a/cumulus/bridges/modules/grandpa/src/benchmarking.rs
+++ b/cumulus/bridges/modules/grandpa/src/benchmarking.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/grandpa/src/call_ext.rs b/cumulus/bridges/modules/grandpa/src/call_ext.rs
index 7a6c61007dec86def244014d8b33e964dd994cef..e0648d5dd0f1d9cd26b2d9cdcc6dc983ef082bb2 100644
--- a/cumulus/bridges/modules/grandpa/src/call_ext.rs
+++ b/cumulus/bridges/modules/grandpa/src/call_ext.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/grandpa/src/lib.rs b/cumulus/bridges/modules/grandpa/src/lib.rs
index 425712ad9a20e4d2f21fe40e47127c6bc3c6ba23..22df604bf18951073996f8f2195aefc78c62639b 100644
--- a/cumulus/bridges/modules/grandpa/src/lib.rs
+++ b/cumulus/bridges/modules/grandpa/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/grandpa/src/mock.rs b/cumulus/bridges/modules/grandpa/src/mock.rs
index bd305dfef9dc05967d6fc966fe599318c9acb6d2..f88a0a3e6a6ee187222a6fb8eb1628e22b37abbe 100644
--- a/cumulus/bridges/modules/grandpa/src/mock.rs
+++ b/cumulus/bridges/modules/grandpa/src/mock.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/grandpa/src/storage_types.rs b/cumulus/bridges/modules/grandpa/src/storage_types.rs
index 59fcb5d3f077ff624c0aa360215e46cf8be696e3..6d1a7882dd4996c600e8ae1cb149410b60af3bf4 100644
--- a/cumulus/bridges/modules/grandpa/src/storage_types.rs
+++ b/cumulus/bridges/modules/grandpa/src/storage_types.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/grandpa/src/weights.rs b/cumulus/bridges/modules/grandpa/src/weights.rs
index 4b94f7adfe73b8b65180a0652c46a72a1521342e..89ed70d13ac3359f23fa6b756d3a8e07ff8b7092 100644
--- a/cumulus/bridges/modules/grandpa/src/weights.rs
+++ b/cumulus/bridges/modules/grandpa/src/weights.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/messages/README.md b/cumulus/bridges/modules/messages/README.md
index b5250d0dca0b23be3943fecb3926be4ea7097be0..457d5f5facfa70fdb11d05c5d544e75eb44f975f 100644
--- a/cumulus/bridges/modules/messages/README.md
+++ b/cumulus/bridges/modules/messages/README.md
@@ -1,8 +1,7 @@
# Bridge Messages Pallet
-The messages pallet is used to deliver messages from source chain to target chain. Message is
-(almost) opaque to the module and the final goal is to hand message to the message dispatch
-mechanism.
+The messages pallet is used to deliver messages from source chain to target chain. Message is (almost) opaque to the
+module and the final goal is to hand message to the message dispatch mechanism.
## Contents
@@ -14,229 +13,203 @@ mechanism.
## Overview
-Message lane is an unidirectional channel, where messages are sent from source chain to the target
-chain. At the same time, a single instance of messages module supports both outbound lanes and
-inbound lanes. So the chain where the module is deployed (this chain), may act as a source chain for
-outbound messages (heading to a bridged chain) and as a target chain for inbound messages (coming
-from a bridged chain).
+Message lane is an unidirectional channel, where messages are sent from source chain to the target chain. At the same
+time, a single instance of messages module supports both outbound lanes and inbound lanes. So the chain where the module
+is deployed (this chain), may act as a source chain for outbound messages (heading to a bridged chain) and as a target
+chain for inbound messages (coming from a bridged chain).
-Messages module supports multiple message lanes. Every message lane is identified with a 4-byte
-identifier. Messages sent through the lane are assigned unique (for this lane) increasing integer
-value that is known as nonce ("number that can only be used once"). Messages that are sent over the
-same lane are guaranteed to be delivered to the target chain in the same order they're sent from
-the source chain. In other words, message with nonce `N` will be delivered right before delivering a
-message with nonce `N+1`.
+Messages module supports multiple message lanes. Every message lane is identified with a 4-byte identifier. Messages
+sent through the lane are assigned unique (for this lane) increasing integer value that is known as nonce ("number that
+can only be used once"). Messages that are sent over the same lane are guaranteed to be delivered to the target chain in
+the same order they're sent from the source chain. In other words, message with nonce `N` will be delivered right before
+delivering a message with nonce `N+1`.
-Single message lane may be seen as a transport channel for single application (onchain, offchain or
-mixed). At the same time the module itself never dictates any lane or message rules. In the end, it
-is the runtime developer who defines what message lane and message mean for this runtime.
+Single message lane may be seen as a transport channel for single application (onchain, offchain or mixed). At the same
+time the module itself never dictates any lane or message rules. In the end, it is the runtime developer who defines
+what message lane and message mean for this runtime.
-In our [Kusama<>Polkadot bridge](../../docs/polkadot-kusama-bridge-overview.md) we are using lane
-as a channel of communication between two parachains of different relay chains. For example, lane
-`[0, 0, 0, 0]` is used for Polkadot <> Kusama Asset Hub communications. Other lanes may be used to
-bridge other parachains.
+In our [Kusama<>Polkadot bridge](../../docs/polkadot-kusama-bridge-overview.md) we are using lane as a channel of
+communication between two parachains of different relay chains. For example, lane `[0, 0, 0, 0]` is used for Polkadot <>
+Kusama Asset Hub communications. Other lanes may be used to bridge other parachains.
## Message Workflow
-The pallet is not intended to be used by end users and provides no public calls to send the message.
-Instead, it provides runtime-internal method that allows other pallets (or other runtime code) to queue
-outbound messages.
-
-The message "appears" when some runtime code calls the `send_message()` method of the pallet.
-The submitter specifies the lane that they're willing to use and the message itself. If some fee must
-be paid for sending the message, it must be paid outside of the pallet. If a message passes all checks
-(that include, for example, message size check, disabled lane check, ...), the nonce is assigned and
-the message is stored in the module storage. The message is in an "undelivered" state now.
-
-We assume that there are external, offchain actors, called relayers, that are submitting module
-related transactions to both target and source chains. The pallet itself has no assumptions about
-relayers incentivization scheme, but it has some callbacks for paying rewards. See
-[Integrating Messages Module into runtime](#Integrating-Messages-Module-into-runtime)
-for details.
-
-Eventually, some relayer would notice this message in the "undelivered" state and it would decide to
-deliver this message. Relayer then crafts `receive_messages_proof()` transaction (aka delivery
-transaction) for the messages module instance, deployed at the target chain. Relayer provides
-its account id at the source chain, the proof of message (or several messages), the number of
-messages in the transaction and their cumulative dispatch weight. Once a transaction is mined, the
-message is considered "delivered".
-
-Once a message is delivered, the relayer may want to confirm delivery back to the source chain.
-There are two reasons why it would want to do that. The first is that we intentionally limit number
-of "delivered", but not yet "confirmed" messages at inbound lanes
-(see [What about other Constants in the Messages Module Configuration Trait](#What-about-other-Constants-in-the-Messages-Module-Configuration-Trait) for explanation).
-So at some point, the target chain may stop accepting new messages until relayers confirm some of
-these. The second is that if the relayer wants to be rewarded for delivery, it must prove the fact
-that it has actually delivered the message. And this proof may only be generated after the delivery
-transaction is mined. So relayer crafts the `receive_messages_delivery_proof()` transaction (aka
-confirmation transaction) for the messages module instance, deployed at the source chain. Once
-this transaction is mined, the message is considered "confirmed".
-
-The "confirmed" state is the final state of the message. But there's one last thing related to the
-message - the fact that it is now "confirmed" and reward has been paid to the relayer (or at least
-callback for this has been called), must be confirmed to the target chain. Otherwise, we may reach
-the limit of "unconfirmed" messages at the target chain and it will stop accepting new messages. So
-relayer sometimes includes a nonce of the latest "confirmed" message in the next
+The pallet is not intended to be used by end users and provides no public calls to send the message. Instead, it
+provides runtime-internal method that allows other pallets (or other runtime code) to queue outbound messages.
+
+The message "appears" when some runtime code calls the `send_message()` method of the pallet. The submitter specifies
+the lane that they're willing to use and the message itself. If some fee must be paid for sending the message, it must
+be paid outside of the pallet. If a message passes all checks (that include, for example, message size check, disabled
+lane check, ...), the nonce is assigned and the message is stored in the module storage. The message is in an
+"undelivered" state now.
+
+We assume that there are external, offchain actors, called relayers, that are submitting module related transactions to
+both target and source chains. The pallet itself has no assumptions about relayers incentivization scheme, but it has
+some callbacks for paying rewards. See [Integrating Messages Module into
+runtime](#Integrating-Messages-Module-into-runtime) for details.
+
+Eventually, some relayer would notice this message in the "undelivered" state and it would decide to deliver this
+message. Relayer then crafts `receive_messages_proof()` transaction (aka delivery transaction) for the messages module
+instance, deployed at the target chain. Relayer provides its account id at the source chain, the proof of message (or
+several messages), the number of messages in the transaction and their cumulative dispatch weight. Once a transaction is
+mined, the message is considered "delivered".
+
+Once a message is delivered, the relayer may want to confirm delivery back to the source chain. There are two reasons
+why it would want to do that. The first is that we intentionally limit number of "delivered", but not yet "confirmed"
+messages at inbound lanes (see [What about other Constants in the Messages Module Configuration
+Trait](#What-about-other-Constants-in-the-Messages-Module-Configuration-Trait) for explanation). So at some point, the
+target chain may stop accepting new messages until relayers confirm some of these. The second is that if the relayer
+wants to be rewarded for delivery, it must prove the fact that it has actually delivered the message. And this proof may
+only be generated after the delivery transaction is mined. So relayer crafts the `receive_messages_delivery_proof()`
+transaction (aka confirmation transaction) for the messages module instance, deployed at the source chain. Once this
+transaction is mined, the message is considered "confirmed".
+
+The "confirmed" state is the final state of the message. But there's one last thing related to the message - the fact
+that it is now "confirmed" and reward has been paid to the relayer (or at least callback for this has been called), must
+be confirmed to the target chain. Otherwise, we may reach the limit of "unconfirmed" messages at the target chain and it
+will stop accepting new messages. So relayer sometimes includes a nonce of the latest "confirmed" message in the next
`receive_messages_proof()` transaction, proving that some messages have been confirmed.
## Integrating Messages Module into Runtime
-As it has been said above, the messages module supports both outbound and inbound message lanes.
-So if we will integrate a module in some runtime, it may act as the source chain runtime for
-outbound messages and as the target chain runtime for inbound messages. In this section, we'll
-sometimes refer to the chain we're currently integrating with, as "this chain" and the other
-chain as "bridged chain".
-
-Messages module doesn't simply accept transactions that are claiming that the bridged chain has
-some updated data for us. Instead of this, the module assumes that the bridged chain is able to
-prove that updated data in some way. The proof is abstracted from the module and may be of any kind.
-In our Substrate-to-Substrate bridge we're using runtime storage proofs. Other bridges may use
-transaction proofs, Substrate header digests or anything else that may be proved.
-
-**IMPORTANT NOTE**: everything below in this chapter describes details of the messages module
-configuration. But if you're interested in well-probed and relatively easy integration of two
-Substrate-based chains, you may want to look at the
-[bridge-runtime-common](../../bin/runtime-common/) crate. This crate is providing a lot of
-helpers for integration, which may be directly used from within your runtime. Then if you'll decide
-to change something in this scheme, get back here for detailed information.
+As it has been said above, the messages module supports both outbound and inbound message lanes. So if we will integrate
+a module in some runtime, it may act as the source chain runtime for outbound messages and as the target chain runtime
+for inbound messages. In this section, we'll sometimes refer to the chain we're currently integrating with, as "this
+chain" and the other chain as "bridged chain".
+
+Messages module doesn't simply accept transactions that are claiming that the bridged chain has some updated data for
+us. Instead of this, the module assumes that the bridged chain is able to prove that updated data in some way. The proof
+is abstracted from the module and may be of any kind. In our Substrate-to-Substrate bridge we're using runtime storage
+proofs. Other bridges may use transaction proofs, Substrate header digests or anything else that may be proved.
+
+**IMPORTANT NOTE**: everything below in this chapter describes details of the messages module configuration. But if
+you're interested in well-probed and relatively easy integration of two Substrate-based chains, you may want to look at
+the [bridge-runtime-common](../../bin/runtime-common/) crate. This crate is providing a lot of helpers for integration,
+which may be directly used from within your runtime. Then if you'll decide to change something in this scheme, get back
+here for detailed information.
### General Information
-The messages module supports instances. Every module instance is supposed to bridge this chain
-and some bridged chain. To bridge with another chain, using another instance is suggested (this
-isn't forced anywhere in the code, though). Keep in mind, that the pallet may be used to build
-virtual channels between multiple chains, as we do in our [Polkadot <> Kusama bridge](../../docs/polkadot-kusama-bridge-overview.md).
-There, the pallet actually bridges only two parachains - Kusama Bridge Hub and Polkadot
-Bridge Hub. However, other Kusama and Polkadot parachains are able to send (XCM) messages to their
-Bridge Hubs. The messages will be delivered to the other side of the bridge and routed to the proper
+The messages module supports instances. Every module instance is supposed to bridge this chain and some bridged chain.
+To bridge with another chain, using another instance is suggested (this isn't forced anywhere in the code, though). Keep
+in mind, that the pallet may be used to build virtual channels between multiple chains, as we do in our [Polkadot <>
+Kusama bridge](../../docs/polkadot-kusama-bridge-overview.md). There, the pallet actually bridges only two parachains -
+Kusama Bridge Hub and Polkadot Bridge Hub. However, other Kusama and Polkadot parachains are able to send (XCM) messages
+to their Bridge Hubs. The messages will be delivered to the other side of the bridge and routed to the proper
destination parachain within the bridged chain consensus.
-Message submitters may track message progress by inspecting module events. When Message is accepted,
-the `MessageAccepted` event is emitted. The event contains both message lane identifier and nonce that
-has been assigned to the message. When a message is delivered to the target chain, the `MessagesDelivered`
-event is emitted from the `receive_messages_delivery_proof()` transaction. The `MessagesDelivered` contains
-the message lane identifier and inclusive range of delivered message nonces.
+Message submitters may track message progress by inspecting module events. When Message is accepted, the
+`MessageAccepted` event is emitted. The event contains both message lane identifier and nonce that has been assigned to
+the message. When a message is delivered to the target chain, the `MessagesDelivered` event is emitted from the
+`receive_messages_delivery_proof()` transaction. The `MessagesDelivered` contains the message lane identifier and
+inclusive range of delivered message nonces.
-The pallet provides no means to get the result of message dispatch at the target chain. If that is
-required, it must be done outside of the pallet. For example, XCM messages, when dispatched, have
-special instructions to send some data back to the sender. Other dispatchers may use similar
-mechanism for that.
+The pallet provides no means to get the result of message dispatch at the target chain. If that is required, it must be
+done outside of the pallet. For example, XCM messages, when dispatched, have special instructions to send some data back
+to the sender. Other dispatchers may use similar mechanism for that.
### How to plug-in Messages Module to Send Messages to the Bridged Chain?
-The `pallet_bridge_messages::Config` trait has 3 main associated types that are used to work with
-outbound messages. The `pallet_bridge_messages::Config::TargetHeaderChain` defines how we see the
-bridged chain as the target for our outbound messages. It must be able to check that the bridged
-chain may accept our message - like that the message has size below maximal possible transaction
-size of the chain and so on. And when the relayer sends us a confirmation transaction, this
-implementation must be able to parse and verify the proof of messages delivery. Normally, you would
-reuse the same (configurable) type on all chains that are sending messages to the same bridged
-chain.
-
-The `pallet_bridge_messages::Config::LaneMessageVerifier` defines a single callback to verify outbound
-messages. The simplest callback may just accept all messages. But in this case you'll need to answer
-many questions first. Who will pay for the delivery and confirmation transaction? Are we sure that
-someone will ever deliver this message to the bridged chain? Are we sure that we don't bloat our
-runtime storage by accepting this message? What if the message is improperly encoded or has some
-fields set to invalid values? Answering all those (and similar) questions would lead to correct
-implementation.
+The `pallet_bridge_messages::Config` trait has 3 main associated types that are used to work with outbound messages. The
+`pallet_bridge_messages::Config::TargetHeaderChain` defines how we see the bridged chain as the target for our outbound
+messages. It must be able to check that the bridged chain may accept our message - like that the message has size below
+maximal possible transaction size of the chain and so on. And when the relayer sends us a confirmation transaction, this
+implementation must be able to parse and verify the proof of messages delivery. Normally, you would reuse the same
+(configurable) type on all chains that are sending messages to the same bridged chain.
+
+The `pallet_bridge_messages::Config::LaneMessageVerifier` defines a single callback to verify outbound messages. The
+simplest callback may just accept all messages. But in this case you'll need to answer many questions first. Who will
+pay for the delivery and confirmation transaction? Are we sure that someone will ever deliver this message to the
+bridged chain? Are we sure that we don't bloat our runtime storage by accepting this message? What if the message is
+improperly encoded or has some fields set to invalid values? Answering all those (and similar) questions would lead to
+correct implementation.
There's another thing to consider when implementing type for use in
-`pallet_bridge_messages::Config::LaneMessageVerifier`. It is whether we treat all message lanes
-identically, or they'll have different sets of verification rules? For example, you may reserve
-lane#1 for messages coming from some 'wrapped-token' pallet - then you may verify in your
-implementation that the origin is associated with this pallet. Lane#2 may be reserved for 'system'
-messages and you may charge zero fee for such messages. You may have some rate limiting for messages
-sent over the lane#3. Or you may just verify the same rules set for all outbound messages - it is
+`pallet_bridge_messages::Config::LaneMessageVerifier`. It is whether we treat all message lanes identically, or they'll
+have different sets of verification rules? For example, you may reserve lane#1 for messages coming from some
+'wrapped-token' pallet - then you may verify in your implementation that the origin is associated with this pallet.
+Lane#2 may be reserved for 'system' messages and you may charge zero fee for such messages. You may have some rate
+limiting for messages sent over the lane#3. Or you may just verify the same rules set for all outbound messages - it is
all up to the `pallet_bridge_messages::Config::LaneMessageVerifier` implementation.
-The last type is the `pallet_bridge_messages::Config::DeliveryConfirmationPayments`. When confirmation
-transaction is received, we call the `pay_reward()` method, passing the range of delivered messages.
-You may use the [`pallet-bridge-relayers`](../relayers/) pallet and its
-[`DeliveryConfirmationPaymentsAdapter`](../relayers/src/payment_adapter.rs) adapter as a possible
-implementation. It allows you to pay fixed reward for relaying the message and some of its portion
-for confirming delivery.
+The last type is the `pallet_bridge_messages::Config::DeliveryConfirmationPayments`. When confirmation transaction is
+received, we call the `pay_reward()` method, passing the range of delivered messages. You may use the
+[`pallet-bridge-relayers`](../relayers/) pallet and its
+[`DeliveryConfirmationPaymentsAdapter`](../relayers/src/payment_adapter.rs) adapter as a possible implementation. It
+allows you to pay fixed reward for relaying the message and some of its portion for confirming delivery.
### I have a Messages Module in my Runtime, but I Want to Reject all Outbound Messages. What shall I do?
You should be looking at the `bp_messages::source_chain::ForbidOutboundMessages` structure
-[`bp_messages::source_chain`](../../primitives/messages/src/source_chain.rs). It implements
-all required traits and will simply reject all transactions, related to outbound messages.
+[`bp_messages::source_chain`](../../primitives/messages/src/source_chain.rs). It implements all required traits and will
+simply reject all transactions, related to outbound messages.
### How to plug-in Messages Module to Receive Messages from the Bridged Chain?
-The `pallet_bridge_messages::Config` trait has 2 main associated types that are used to work with
-inbound messages. The `pallet_bridge_messages::Config::SourceHeaderChain` defines how we see the
-bridged chain as the source of our inbound messages. When relayer sends us a delivery transaction,
-this implementation must be able to parse and verify the proof of messages wrapped in this
-transaction. Normally, you would reuse the same (configurable) type on all chains that are sending
-messages to the same bridged chain.
+The `pallet_bridge_messages::Config` trait has 2 main associated types that are used to work with inbound messages. The
+`pallet_bridge_messages::Config::SourceHeaderChain` defines how we see the bridged chain as the source of our inbound
+messages. When relayer sends us a delivery transaction, this implementation must be able to parse and verify the proof
+of messages wrapped in this transaction. Normally, you would reuse the same (configurable) type on all chains that are
+sending messages to the same bridged chain.
-The `pallet_bridge_messages::Config::MessageDispatch` defines a way on how to dispatch delivered
-messages. Apart from actually dispatching the message, the implementation must return the correct
-dispatch weight of the message before dispatch is called.
+The `pallet_bridge_messages::Config::MessageDispatch` defines a way on how to dispatch delivered messages. Apart from
+actually dispatching the message, the implementation must return the correct dispatch weight of the message before
+dispatch is called.
### I have a Messages Module in my Runtime, but I Want to Reject all Inbound Messages. What shall I do?
-You should be looking at the `bp_messages::target_chain::ForbidInboundMessages` structure from
-the [`bp_messages::target_chain`](../../primitives/messages/src/target_chain.rs) module. It
-implements all required traits and will simply reject all transactions, related to inbound messages.
+You should be looking at the `bp_messages::target_chain::ForbidInboundMessages` structure from the
+[`bp_messages::target_chain`](../../primitives/messages/src/target_chain.rs) module. It implements all required traits
+and will simply reject all transactions, related to inbound messages.
### What about other Constants in the Messages Module Configuration Trait?
Two settings that are used to check messages in the `send_message()` function. The
-`pallet_bridge_messages::Config::ActiveOutboundLanes` is an array of all message lanes, that
-may be used to send messages. All messages sent using other lanes are rejected. All messages that have
-size above `pallet_bridge_messages::Config::MaximalOutboundPayloadSize` will also be rejected.
-
-To be able to reward the relayer for delivering messages, we store a map of message nonces range =>
-identifier of the relayer that has delivered this range at the target chain runtime storage. If a
-relayer delivers multiple consequent ranges, they're merged into single entry. So there may be more
-than one entry for the same relayer. Eventually, this whole map must be delivered back to the source
-chain to confirm delivery and pay rewards. So to make sure we are able to craft this confirmation
-transaction, we need to: (1) keep the size of this map below a certain limit and (2) make sure that
-the weight of processing this map is below a certain limit. Both size and processing weight mostly
-depend on the number of entries. The number of entries is limited with the
-`pallet_bridge_messages::ConfigMaxUnrewardedRelayerEntriesAtInboundLane` parameter. Processing weight
-also depends on the total number of messages that are being confirmed, because every confirmed
-message needs to be read. So there's another
-`pallet_bridge_messages::Config::MaxUnconfirmedMessagesAtInboundLane` parameter for that.
-
-When choosing values for these parameters, you must also keep in mind that if proof in your scheme
-is based on finality of headers (and it is the most obvious option for Substrate-based chains with
-finality notion), then choosing too small values for these parameters may cause significant delays
-in message delivery. That's because there are too many actors involved in this scheme: 1) authorities
-that are finalizing headers of the target chain need to finalize header with non-empty map; 2) the
-headers relayer then needs to submit this header and its finality proof to the source chain; 3) the
-messages relayer must then send confirmation transaction (storage proof of this map) to the source
-chain; 4) when the confirmation transaction will be mined at some header, source chain authorities
-must finalize this header; 5) the headers relay then needs to submit this header and its finality
-proof to the target chain; 6) only now the messages relayer may submit new messages from the source
-to target chain and prune the entry from the map.
-
-Delivery transaction requires the relayer to provide both number of entries and total number of
-messages in the map. This means that the module never charges an extra cost for delivering a map -
-the relayer would need to pay exactly for the number of entries+messages it has delivered. So the
-best guess for values of these parameters would be the pair that would occupy `N` percent of the
-maximal transaction size and weight of the source chain. The `N` should be large enough to process
-large maps, at the same time keeping reserve for future source chain upgrades.
+`pallet_bridge_messages::Config::ActiveOutboundLanes` is an array of all message lanes, that may be used to send
+messages. All messages sent using other lanes are rejected. All messages that have size above
+`pallet_bridge_messages::Config::MaximalOutboundPayloadSize` will also be rejected.
+
+To be able to reward the relayer for delivering messages, we store a map of message nonces range => identifier of the
+relayer that has delivered this range at the target chain runtime storage. If a relayer delivers multiple consequent
+ranges, they're merged into single entry. So there may be more than one entry for the same relayer. Eventually, this
+whole map must be delivered back to the source chain to confirm delivery and pay rewards. So to make sure we are able to
+craft this confirmation transaction, we need to: (1) keep the size of this map below a certain limit and (2) make sure
+that the weight of processing this map is below a certain limit. Both size and processing weight mostly depend on the
+number of entries. The number of entries is limited with the
+`pallet_bridge_messages::ConfigMaxUnrewardedRelayerEntriesAtInboundLane` parameter. Processing weight also depends on
+the total number of messages that are being confirmed, because every confirmed message needs to be read. So there's
+another `pallet_bridge_messages::Config::MaxUnconfirmedMessagesAtInboundLane` parameter for that.
+
+When choosing values for these parameters, you must also keep in mind that if proof in your scheme is based on finality
+of headers (and it is the most obvious option for Substrate-based chains with finality notion), then choosing too small
+values for these parameters may cause significant delays in message delivery. That's because there are too many actors
+involved in this scheme: 1) authorities that are finalizing headers of the target chain need to finalize header with
+non-empty map; 2) the headers relayer then needs to submit this header and its finality proof to the source chain; 3)
+the messages relayer must then send confirmation transaction (storage proof of this map) to the source chain; 4) when
+the confirmation transaction will be mined at some header, source chain authorities must finalize this header; 5) the
+headers relay then needs to submit this header and its finality proof to the target chain; 6) only now the messages
+relayer may submit new messages from the source to target chain and prune the entry from the map.
+
+Delivery transaction requires the relayer to provide both number of entries and total number of messages in the map.
+This means that the module never charges an extra cost for delivering a map - the relayer would need to pay exactly for
+the number of entries+messages it has delivered. So the best guess for values of these parameters would be the pair that
+would occupy `N` percent of the maximal transaction size and weight of the source chain. The `N` should be large enough
+to process large maps, at the same time keeping reserve for future source chain upgrades.
## Non-Essential Functionality
-There may be a special account in every runtime where the messages module is deployed. This
-account, named 'module owner', is like a module-level sudo account - he's able to halt and
-resume all module operations without requiring runtime upgrade. Calls that are related to this
-account are:
+There may be a special account in every runtime where the messages module is deployed. This account, named 'module
+owner', is like a module-level sudo account - he's able to halt and resume all module operations without requiring
+runtime upgrade. Calls that are related to this account are:
- `fn set_owner()`: current module owner may call it to transfer "ownership" to another account;
-- `fn halt_operations()`: the module owner (or sudo account) may call this function to stop all
- module operations. After this call, all message-related transactions will be rejected until
- further `resume_operations` call'. This call may be used when something extraordinary happens with
- the bridge;
-- `fn resume_operations()`: module owner may call this function to resume bridge operations. The
- module will resume its regular operations after this call.
+- `fn halt_operations()`: the module owner (or sudo account) may call this function to stop all module operations. After
+ this call, all message-related transactions will be rejected until further `resume_operations` call'. This call may be
+ used when something extraordinary happens with the bridge;
+- `fn resume_operations()`: module owner may call this function to resume bridge operations. The module will resume its
+ regular operations after this call.
If pallet owner is not defined, the governance may be used to make those calls.
## Messages Relay
-We have an offchain actor, who is watching for new messages and submits them to the bridged chain.
-It is the messages relay - you may look at the [crate level documentation and the code](../../relays/messages/).
+We have an offchain actor, who is watching for new messages and submits them to the bridged chain. It is the messages
+relay - you may look at the [crate level documentation and the code](../../relays/messages/).
diff --git a/cumulus/bridges/modules/messages/src/benchmarking.rs b/cumulus/bridges/modules/messages/src/benchmarking.rs
index 04f64b53b305f74600d151d539f7b32b5dc4ce78..8c4e6fbf00ca42dd4a61c85c14d90fbff72ed042 100644
--- a/cumulus/bridges/modules/messages/src/benchmarking.rs
+++ b/cumulus/bridges/modules/messages/src/benchmarking.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/messages/src/inbound_lane.rs b/cumulus/bridges/modules/messages/src/inbound_lane.rs
index 359e9022b0b60c1e155648582ab0066b0281999d..966ec939e70e22e830ee30157d2d7da74d59733c 100644
--- a/cumulus/bridges/modules/messages/src/inbound_lane.rs
+++ b/cumulus/bridges/modules/messages/src/inbound_lane.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/messages/src/lib.rs b/cumulus/bridges/modules/messages/src/lib.rs
index 67c6fb23cf16765067ef815b91521e349b1ebf1c..b87c64d160752862a59a14f6591bf64f363004e8 100644
--- a/cumulus/bridges/modules/messages/src/lib.rs
+++ b/cumulus/bridges/modules/messages/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/messages/src/mock.rs b/cumulus/bridges/modules/messages/src/mock.rs
index 67f7b78a487aa64dfddf74cc215cbed9207de6f2..aebb7eafa7871d13cd8140d5a352978ca36433dd 100644
--- a/cumulus/bridges/modules/messages/src/mock.rs
+++ b/cumulus/bridges/modules/messages/src/mock.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/messages/src/outbound_lane.rs b/cumulus/bridges/modules/messages/src/outbound_lane.rs
index 45b0f4e680955e9faf868b3503bdbc4bc3f747dd..f92e9ccfd95c61ac9797e6423eae5d4e8f02dc2c 100644
--- a/cumulus/bridges/modules/messages/src/outbound_lane.rs
+++ b/cumulus/bridges/modules/messages/src/outbound_lane.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/messages/src/weights.rs b/cumulus/bridges/modules/messages/src/weights.rs
index 9880f1dd1ea3d45fb1aa6a3cee3255468fa11a0b..5b6863984ec78c0e250c54a0ed3363d1278f196f 100644
--- a/cumulus/bridges/modules/messages/src/weights.rs
+++ b/cumulus/bridges/modules/messages/src/weights.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/messages/src/weights_ext.rs b/cumulus/bridges/modules/messages/src/weights_ext.rs
index 3aefd6be7ca787202c83935bf25eda8d55811922..aeb3a581a69ee6ebb233ca6ec5e0f0bd4d25a408 100644
--- a/cumulus/bridges/modules/messages/src/weights_ext.rs
+++ b/cumulus/bridges/modules/messages/src/weights_ext.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
@@ -29,8 +29,8 @@ pub const EXPECTED_DEFAULT_MESSAGE_LENGTH: u32 = 128;
/// calls we're checking here would fit 1KB.
const SIGNED_EXTENSIONS_SIZE: u32 = 1024;
-/// 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.
+/// Number of extra bytes (excluding size of storage value itself) of storage proof.
+/// 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;
diff --git a/cumulus/bridges/modules/parachains/README.md b/cumulus/bridges/modules/parachains/README.md
index 5982c65ad3166107128b9256f89f337f8de7c69e..d3f52c791ab5899c438bf902acd85d3e8a96153a 100644
--- a/cumulus/bridges/modules/parachains/README.md
+++ b/cumulus/bridges/modules/parachains/README.md
@@ -19,7 +19,7 @@ validators. Validators validate the block and register the new parachain head in
[`Heads` map](https://github.com/paritytech/polkadot/blob/88013730166ba90745ae7c9eb3e0c1be1513c7cc/runtime/parachains/src/paras/mod.rs#L645)
of the [`paras`](https://github.com/paritytech/polkadot/tree/master/runtime/parachains/src/paras) pallet,
deployed at the relay chain. Keep in mind that this pallet, deployed at a relay chain, is **NOT** a bridge pallet,
-even though the names are similar.
+even though the names are similar.
And what the bridge parachains pallet does, is simply verifying storage proofs of parachain heads within that
`Heads` map. It does that using relay chain header, that has been previously imported by the
diff --git a/cumulus/bridges/modules/parachains/src/benchmarking.rs b/cumulus/bridges/modules/parachains/src/benchmarking.rs
index 59c4642cde9997b5046afa491f59fc11b88ae17b..27e06a12a1d93486d93aa258afc1d7de4713df2c 100644
--- a/cumulus/bridges/modules/parachains/src/benchmarking.rs
+++ b/cumulus/bridges/modules/parachains/src/benchmarking.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/parachains/src/call_ext.rs b/cumulus/bridges/modules/parachains/src/call_ext.rs
index ea842a61b3e800e5c745a5616a3bc2ad35b068f2..99640dadc61f4a422ec41db4fe196f752b206d06 100644
--- a/cumulus/bridges/modules/parachains/src/call_ext.rs
+++ b/cumulus/bridges/modules/parachains/src/call_ext.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/parachains/src/lib.rs b/cumulus/bridges/modules/parachains/src/lib.rs
index be46fae3c9253d5276fc4dec6d96ba8e0579623a..b2ef0bf52bd3d5b5f619a6b8e28bbf8228c1a72c 100644
--- a/cumulus/bridges/modules/parachains/src/lib.rs
+++ b/cumulus/bridges/modules/parachains/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/parachains/src/mock.rs b/cumulus/bridges/modules/parachains/src/mock.rs
index a7030f0ae0310ecacaae6361d42facf0129a3cca..14afe38417105a789f9eb13ca913c1be91e6f789 100644
--- a/cumulus/bridges/modules/parachains/src/mock.rs
+++ b/cumulus/bridges/modules/parachains/src/mock.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/parachains/src/weights.rs b/cumulus/bridges/modules/parachains/src/weights.rs
index 1e81dba72fe99ea1ecd968feb93f73d0e5417680..9182ec466117b2c642910148a1240a10ae438b8a 100644
--- a/cumulus/bridges/modules/parachains/src/weights.rs
+++ b/cumulus/bridges/modules/parachains/src/weights.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/parachains/src/weights_ext.rs b/cumulus/bridges/modules/parachains/src/weights_ext.rs
index eecdfe903593eb7b62cf3e5f7ddf9971699272fe..13bc9ad2bbce0f26d5946cf8198e689597e5f968 100644
--- a/cumulus/bridges/modules/parachains/src/weights_ext.rs
+++ b/cumulus/bridges/modules/parachains/src/weights_ext.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/relayers/src/benchmarking.rs b/cumulus/bridges/modules/relayers/src/benchmarking.rs
index d66a11ff06d027ede93518d5fb79f6b906c7998d..2d74ab38f9dbd1711b62df5e6bebd697fda1b988 100644
--- a/cumulus/bridges/modules/relayers/src/benchmarking.rs
+++ b/cumulus/bridges/modules/relayers/src/benchmarking.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/relayers/src/lib.rs b/cumulus/bridges/modules/relayers/src/lib.rs
index a71c218443b3d40f7fda1eb81d2317b2b5518075..b9b98ca7e253fdb952125e2079752484e37241a2 100644
--- a/cumulus/bridges/modules/relayers/src/lib.rs
+++ b/cumulus/bridges/modules/relayers/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/relayers/src/mock.rs b/cumulus/bridges/modules/relayers/src/mock.rs
index b3fcb24cdd20d6c5aeb4471719caffafd9c945e7..4713ec91658afa9ad4e0c2d13055a0921cf1be88 100644
--- a/cumulus/bridges/modules/relayers/src/mock.rs
+++ b/cumulus/bridges/modules/relayers/src/mock.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/relayers/src/payment_adapter.rs b/cumulus/bridges/modules/relayers/src/payment_adapter.rs
index a9536cfc0275f319c32e20d48500aacfe7eba991..b2d9c676bddc493700a45fc957235dbb9516296b 100644
--- a/cumulus/bridges/modules/relayers/src/payment_adapter.rs
+++ b/cumulus/bridges/modules/relayers/src/payment_adapter.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/relayers/src/stake_adapter.rs b/cumulus/bridges/modules/relayers/src/stake_adapter.rs
index 055b6a111ec724a457e9919b93c986d03f650137..88af9b1877bfe85614f081ee66dbb28586b1d34b 100644
--- a/cumulus/bridges/modules/relayers/src/stake_adapter.rs
+++ b/cumulus/bridges/modules/relayers/src/stake_adapter.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/relayers/src/weights.rs b/cumulus/bridges/modules/relayers/src/weights.rs
index 1bc195a5424728d2b1e4df39d058b72511091e81..2e064a3936df3a0661fc08af48be87520c04dba0 100644
--- a/cumulus/bridges/modules/relayers/src/weights.rs
+++ b/cumulus/bridges/modules/relayers/src/weights.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/relayers/src/weights_ext.rs b/cumulus/bridges/modules/relayers/src/weights_ext.rs
index d459b0686bd7e51eed4fdd88113ec9b507842559..9cd25c47c3782f709249dd9b1fd24e4c6ec8ab7f 100644
--- a/cumulus/bridges/modules/relayers/src/weights_ext.rs
+++ b/cumulus/bridges/modules/relayers/src/weights_ext.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/xcm-bridge-hub-router/Cargo.toml b/cumulus/bridges/modules/xcm-bridge-hub-router/Cargo.toml
index 4f244a9e6a7054d1949f9c6277a6cdd7acc5eb2d..6ad3c57ca73a788cc09d8fb9e9b1d3510027e4c2 100644
--- a/cumulus/bridges/modules/xcm-bridge-hub-router/Cargo.toml
+++ b/cumulus/bridges/modules/xcm-bridge-hub-router/Cargo.toml
@@ -26,8 +26,8 @@ sp-std = { path = "../../../../substrate/primitives/std", default-features = fal
# Polkadot Dependencies
-xcm = { path = "../../../../polkadot/xcm", default-features = false }
-xcm-builder = { path = "../../../../polkadot/xcm/xcm-builder", default-features = false }
+xcm = { package = "staging-xcm", path = "../../../../polkadot/xcm", default-features = false }
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../polkadot/xcm/xcm-builder", default-features = false }
[dev-dependencies]
sp-io = { path = "../../../../substrate/primitives/io" }
diff --git a/cumulus/bridges/modules/xcm-bridge-hub-router/src/benchmarking.rs b/cumulus/bridges/modules/xcm-bridge-hub-router/src/benchmarking.rs
index b32b983daf72c9ed4b104a3a28cc43011a0865d0..4bbe414f66355bfb2fc866cc74b89f7b97988837 100644
--- a/cumulus/bridges/modules/xcm-bridge-hub-router/src/benchmarking.rs
+++ b/cumulus/bridges/modules/xcm-bridge-hub-router/src/benchmarking.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
@@ -22,10 +22,7 @@ use crate::{Bridge, Call};
use bp_xcm_bridge_hub_router::{BridgeState, MINIMAL_DELIVERY_FEE_FACTOR};
use frame_benchmarking::benchmarks_instance_pallet;
-use frame_support::{
- dispatch::UnfilteredDispatchable,
- traits::{EnsureOrigin, Get, Hooks},
-};
+use frame_support::traits::{EnsureOrigin, Get, Hooks, UnfilteredDispatchable};
use sp_runtime::traits::Zero;
use xcm::prelude::*;
diff --git a/cumulus/bridges/modules/xcm-bridge-hub-router/src/lib.rs b/cumulus/bridges/modules/xcm-bridge-hub-router/src/lib.rs
index 87e050b45c73645ac169cbf68480929d3662b53f..5cf94fc83fd9dffda2e1fa614608eb53ea13922e 100644
--- a/cumulus/bridges/modules/xcm-bridge-hub-router/src/lib.rs
+++ b/cumulus/bridges/modules/xcm-bridge-hub-router/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/xcm-bridge-hub-router/src/mock.rs b/cumulus/bridges/modules/xcm-bridge-hub-router/src/mock.rs
index 5ad7be4890a176c16cd88037207361a952fafe78..cd50b98a168853eec6a37c9a4806271574454cca 100644
--- a/cumulus/bridges/modules/xcm-bridge-hub-router/src/mock.rs
+++ b/cumulus/bridges/modules/xcm-bridge-hub-router/src/mock.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/modules/xcm-bridge-hub-router/src/weights.rs b/cumulus/bridges/modules/xcm-bridge-hub-router/src/weights.rs
index 04909f3b2e838c058fc12fc9314333fa78ca3e8a..62936e997f3cd0aaea17859b49d7c0edf6b65989 100644
--- a/cumulus/bridges/modules/xcm-bridge-hub-router/src/weights.rs
+++ b/cumulus/bridges/modules/xcm-bridge-hub-router/src/weights.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/chain-asset-hub-kusama/src/lib.rs b/cumulus/bridges/primitives/chain-asset-hub-kusama/src/lib.rs
index b3b25ba6eddd7b36991db10d3a6165b7d9933e3c..94016c1da0cb1235dec6717bd6da79ff4dab74f4 100644
--- a/cumulus/bridges/primitives/chain-asset-hub-kusama/src/lib.rs
+++ b/cumulus/bridges/primitives/chain-asset-hub-kusama/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/chain-asset-hub-polkadot/src/lib.rs b/cumulus/bridges/primitives/chain-asset-hub-polkadot/src/lib.rs
index 7363e5af02a2ccff76e2f1d54883673ead3583bd..486fba60e1f8836d0eec2feece7919205cf6c372 100644
--- a/cumulus/bridges/primitives/chain-asset-hub-polkadot/src/lib.rs
+++ b/cumulus/bridges/primitives/chain-asset-hub-polkadot/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/chain-bridge-hub-cumulus/src/lib.rs b/cumulus/bridges/primitives/chain-bridge-hub-cumulus/src/lib.rs
index 525b2e62ceab0583c43791aae850c2cd6b7715e5..feef61c7f20a1655f86ffbcc52809bfd9fef41e5 100644
--- a/cumulus/bridges/primitives/chain-bridge-hub-cumulus/src/lib.rs
+++ b/cumulus/bridges/primitives/chain-bridge-hub-cumulus/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/chain-bridge-hub-kusama/src/lib.rs b/cumulus/bridges/primitives/chain-bridge-hub-kusama/src/lib.rs
index af50a97b28b3dc486023dfeb38de9a005aa0aa96..3a919648df47f091b76f0e16b9cd98b22f1970ff 100644
--- a/cumulus/bridges/primitives/chain-bridge-hub-kusama/src/lib.rs
+++ b/cumulus/bridges/primitives/chain-bridge-hub-kusama/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/chain-bridge-hub-polkadot/src/lib.rs b/cumulus/bridges/primitives/chain-bridge-hub-polkadot/src/lib.rs
index a1f6ae1a1a9a37a1ed11d52c37993c8c0b570695..bf8d8e07c3a61c83a8f1f0cc253c45557dd1b703 100644
--- a/cumulus/bridges/primitives/chain-bridge-hub-polkadot/src/lib.rs
+++ b/cumulus/bridges/primitives/chain-bridge-hub-polkadot/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/chain-bridge-hub-rococo/src/lib.rs b/cumulus/bridges/primitives/chain-bridge-hub-rococo/src/lib.rs
index 37b1a9ebb927ca5e58987d38c481b75a197ccfaf..b726c62ac42b3270d72c7eebc6d3f5faff54c166 100644
--- a/cumulus/bridges/primitives/chain-bridge-hub-rococo/src/lib.rs
+++ b/cumulus/bridges/primitives/chain-bridge-hub-rococo/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/chain-bridge-hub-wococo/src/lib.rs b/cumulus/bridges/primitives/chain-bridge-hub-wococo/src/lib.rs
index 635a4c96054ad40d4f47394c547591674c2b68f1..5e4758645d9ea63fedbd17b39c88ee208e725f96 100644
--- a/cumulus/bridges/primitives/chain-bridge-hub-wococo/src/lib.rs
+++ b/cumulus/bridges/primitives/chain-bridge-hub-wococo/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/chain-kusama/src/lib.rs b/cumulus/bridges/primitives/chain-kusama/src/lib.rs
index b758484aefeb41c3adb80f2c47189c2e4cddd8f0..e234a87b6cf680e1b0b2aba39d04704b85b8c896 100644
--- a/cumulus/bridges/primitives/chain-kusama/src/lib.rs
+++ b/cumulus/bridges/primitives/chain-kusama/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/chain-polkadot/src/lib.rs b/cumulus/bridges/primitives/chain-polkadot/src/lib.rs
index eb62c1729adfdeb4865d826fd342deecfb969bc7..9585fd4d71634ea9af59d6a64206e7dcfc3c80ca 100644
--- a/cumulus/bridges/primitives/chain-polkadot/src/lib.rs
+++ b/cumulus/bridges/primitives/chain-polkadot/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/chain-rococo/src/lib.rs b/cumulus/bridges/primitives/chain-rococo/src/lib.rs
index 140069d756959ffcfddd6b10788ef660e66ebcd4..cf7cd16990f8642fbe039310d54de36b5859330e 100644
--- a/cumulus/bridges/primitives/chain-rococo/src/lib.rs
+++ b/cumulus/bridges/primitives/chain-rococo/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/chain-wococo/src/lib.rs b/cumulus/bridges/primitives/chain-wococo/src/lib.rs
index 8247b63238ce4924a70f2797e3c82225f0df43c8..c64451993ee7a8bba32b7f7cd7e00cbeab5dd048 100644
--- a/cumulus/bridges/primitives/chain-wococo/src/lib.rs
+++ b/cumulus/bridges/primitives/chain-wococo/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/src/justification/mod.rs b/cumulus/bridges/primitives/header-chain/src/justification/mod.rs
index 44548b8d3ffd95a26bf43780c1d0b391a2886dff..24c453a0790c90c04b4573a85a66a276a8e6fa89 100644
--- a/cumulus/bridges/primitives/header-chain/src/justification/mod.rs
+++ b/cumulus/bridges/primitives/header-chain/src/justification/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2023 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/src/justification/verification/equivocation.rs b/cumulus/bridges/primitives/header-chain/src/justification/verification/equivocation.rs
index 2484fc4d6b2bf9df26e8a9cff72f4d0e65a6e2b4..e2d7a8e804c20bcaeef48e3ba96c29911a3c6012 100644
--- a/cumulus/bridges/primitives/header-chain/src/justification/verification/equivocation.rs
+++ b/cumulus/bridges/primitives/header-chain/src/justification/verification/equivocation.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2023 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/src/justification/verification/mod.rs b/cumulus/bridges/primitives/header-chain/src/justification/verification/mod.rs
index 353960734cc9dc9ccff37334e1859e672e02afbb..bb8aaadf327ecccde64365ce5860c5b3095079e7 100644
--- a/cumulus/bridges/primitives/header-chain/src/justification/verification/mod.rs
+++ b/cumulus/bridges/primitives/header-chain/src/justification/verification/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2023 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/src/justification/verification/optimizer.rs b/cumulus/bridges/primitives/header-chain/src/justification/verification/optimizer.rs
index 99ccdd50616b0facc43359d5c27a32011a3f09b1..6552b359170a89d9b9816a8e933dacaf70d6d248 100644
--- a/cumulus/bridges/primitives/header-chain/src/justification/verification/optimizer.rs
+++ b/cumulus/bridges/primitives/header-chain/src/justification/verification/optimizer.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2023 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/src/justification/verification/strict.rs b/cumulus/bridges/primitives/header-chain/src/justification/verification/strict.rs
index a9d5f4c1f7362691745130365b5365e6e6bb6ed4..f899c6c8efc06c6a1dfa38c38c4050993b09b5af 100644
--- a/cumulus/bridges/primitives/header-chain/src/justification/verification/strict.rs
+++ b/cumulus/bridges/primitives/header-chain/src/justification/verification/strict.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2023 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/src/lib.rs b/cumulus/bridges/primitives/header-chain/src/lib.rs
index ea6c58f4c09791fb9784e9a5e80fce1aef7d497c..7008dfa6063aedaa2d4869eef87f3a076a7b2380 100644
--- a/cumulus/bridges/primitives/header-chain/src/lib.rs
+++ b/cumulus/bridges/primitives/header-chain/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/src/storage_keys.rs b/cumulus/bridges/primitives/header-chain/src/storage_keys.rs
index c4dbe53bd9a7f39c41dce8c6b550058cdce08174..55d095afbf2ae5ab00848676e455bf6da3c91166 100644
--- a/cumulus/bridges/primitives/header-chain/src/storage_keys.rs
+++ b/cumulus/bridges/primitives/header-chain/src/storage_keys.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/tests/implementation_match.rs b/cumulus/bridges/primitives/header-chain/tests/implementation_match.rs
index db96961832d4ba489e58178662c67829346dddb5..f664a419621f67e7153adf3d9195546cca80fd0f 100644
--- a/cumulus/bridges/primitives/header-chain/tests/implementation_match.rs
+++ b/cumulus/bridges/primitives/header-chain/tests/implementation_match.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/tests/justification/equivocation.rs b/cumulus/bridges/primitives/header-chain/tests/justification/equivocation.rs
index f3c133481fb896a83ef42e9ffa642347822ddba9..0bc084cc1a97069dd4dff35f41ad53e6fde69319 100644
--- a/cumulus/bridges/primitives/header-chain/tests/justification/equivocation.rs
+++ b/cumulus/bridges/primitives/header-chain/tests/justification/equivocation.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/tests/justification/optimizer.rs b/cumulus/bridges/primitives/header-chain/tests/justification/optimizer.rs
index bdc90a3b07cf6d3de85d67d8e6b05137eefb85a4..21bcd7e86b51e2f898024999a86c8ac403286bba 100644
--- a/cumulus/bridges/primitives/header-chain/tests/justification/optimizer.rs
+++ b/cumulus/bridges/primitives/header-chain/tests/justification/optimizer.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/tests/justification/strict.rs b/cumulus/bridges/primitives/header-chain/tests/justification/strict.rs
index 9568f7f7cf9a3b7c71cca415e792af1a15f3ce52..188c9f5baba26b10f50fd8ed875b0cc856c3ec8d 100644
--- a/cumulus/bridges/primitives/header-chain/tests/justification/strict.rs
+++ b/cumulus/bridges/primitives/header-chain/tests/justification/strict.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/header-chain/tests/tests.rs b/cumulus/bridges/primitives/header-chain/tests/tests.rs
index 7c525a9303adcd3ca9c9d469f19da59e030cad50..269fde09bb71ce3df3d955811f9da3e10c100ef3 100644
--- a/cumulus/bridges/primitives/header-chain/tests/tests.rs
+++ b/cumulus/bridges/primitives/header-chain/tests/tests.rs
@@ -1,3 +1,19 @@
+// Copyright (C) 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 justification {
mod equivocation;
mod optimizer;
diff --git a/cumulus/bridges/primitives/messages/src/lib.rs b/cumulus/bridges/primitives/messages/src/lib.rs
index 8cafd58650f35ef7a39f065c62b1415c287bb18a..e48914f7591866a5621c791193e26edd03959b9c 100644
--- a/cumulus/bridges/primitives/messages/src/lib.rs
+++ b/cumulus/bridges/primitives/messages/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/messages/src/source_chain.rs b/cumulus/bridges/primitives/messages/src/source_chain.rs
index 5e4be53c53a521758519c018a5e1f31b591b28e0..73092c3cce0a575283dd3a856bdfc197e0e4d969 100644
--- a/cumulus/bridges/primitives/messages/src/source_chain.rs
+++ b/cumulus/bridges/primitives/messages/src/source_chain.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/messages/src/storage_keys.rs b/cumulus/bridges/primitives/messages/src/storage_keys.rs
index 4edf9828cfde02e44f65ecc0d3d869f66e5d9b50..8eedf8fcc7ac98ae300ca0485a0827afd3cd1bb5 100644
--- a/cumulus/bridges/primitives/messages/src/storage_keys.rs
+++ b/cumulus/bridges/primitives/messages/src/storage_keys.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/messages/src/target_chain.rs b/cumulus/bridges/primitives/messages/src/target_chain.rs
index 3d73ca500139a2d01eacb36b502282425ed3e3af..388ce16ccdc06d3e2c42c3a094aae4d6180a0d09 100644
--- a/cumulus/bridges/primitives/messages/src/target_chain.rs
+++ b/cumulus/bridges/primitives/messages/src/target_chain.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/parachains/src/lib.rs b/cumulus/bridges/primitives/parachains/src/lib.rs
index 21e78e0009f4f311079ddc551b6d71ba768edb82..262b9c6f977529e23d2a0b1515a578cc9455f7ac 100644
--- a/cumulus/bridges/primitives/parachains/src/lib.rs
+++ b/cumulus/bridges/primitives/parachains/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/polkadot-core/src/lib.rs b/cumulus/bridges/primitives/polkadot-core/src/lib.rs
index 36ef58eed4dd78542d200f74f5455afa3aea001c..b35d97ec79ae2275a5ab885a2f7eb4948e45969d 100644
--- a/cumulus/bridges/primitives/polkadot-core/src/lib.rs
+++ b/cumulus/bridges/primitives/polkadot-core/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/polkadot-core/src/parachains.rs b/cumulus/bridges/primitives/polkadot-core/src/parachains.rs
index 7268d9c70afa0f7016a442bb157bf662554227d8..223956171f86499397842f491d809eb2f8d81a63 100644
--- a/cumulus/bridges/primitives/polkadot-core/src/parachains.rs
+++ b/cumulus/bridges/primitives/polkadot-core/src/parachains.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
@@ -37,7 +37,8 @@ use parity_util_mem::MallocSizeOf;
/// Parachain id.
///
-/// This is an equivalent of the `polkadot_parachain::Id`, which is a compact-encoded `u32`.
+/// This is an equivalent of the `polkadot_parachain_primitives::Id`, which is a compact-encoded
+/// `u32`.
#[derive(
Clone,
CompactAs,
@@ -64,7 +65,7 @@ impl From for ParaId {
/// Parachain head.
///
-/// This is an equivalent of the `polkadot_parachain::HeadData`.
+/// This is an equivalent of the `polkadot_parachain_primitives::HeadData`.
///
/// The parachain head means (at least in Cumulus) a SCALE-encoded parachain header.
#[derive(
diff --git a/cumulus/bridges/primitives/relayers/src/lib.rs b/cumulus/bridges/primitives/relayers/src/lib.rs
index 21f66a2ffa10041107b9d02f3521ccd8f6db7309..c529eea536d73e91aa4293aa23813f9273f6f8b5 100644
--- a/cumulus/bridges/primitives/relayers/src/lib.rs
+++ b/cumulus/bridges/primitives/relayers/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/relayers/src/registration.rs b/cumulus/bridges/primitives/relayers/src/registration.rs
index 7ab20844bdf934ba37393c316f532cb7bcfbdfa1..bc2d0d127aefec3c6982b17915202cc0f87984f2 100644
--- a/cumulus/bridges/primitives/relayers/src/registration.rs
+++ b/cumulus/bridges/primitives/relayers/src/registration.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/runtime/src/chain.rs b/cumulus/bridges/primitives/runtime/src/chain.rs
index 43fdaf8da1b7ffb4c29e6e3513f81b7b461a099e..5caaebd42babc32124ec724f10129f84f39423f7 100644
--- a/cumulus/bridges/primitives/runtime/src/chain.rs
+++ b/cumulus/bridges/primitives/runtime/src/chain.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/runtime/src/extensions.rs b/cumulus/bridges/primitives/runtime/src/extensions.rs
index 96ee9d1e6ec9130e173894624fe389198acce7ac..253350d17e74faa13c97ab2a0ee1876fce69693f 100644
--- a/cumulus/bridges/primitives/runtime/src/extensions.rs
+++ b/cumulus/bridges/primitives/runtime/src/extensions.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/runtime/src/lib.rs b/cumulus/bridges/primitives/runtime/src/lib.rs
index f4f52866de95d30b8e898a753d52bceed0d5445f..ece782e352bc21e6044cd93191957ac25a040b2a 100644
--- a/cumulus/bridges/primitives/runtime/src/lib.rs
+++ b/cumulus/bridges/primitives/runtime/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/runtime/src/messages.rs b/cumulus/bridges/primitives/runtime/src/messages.rs
index e3ce37ed5922da46521d96f125e2e95d6b3dcb53..0f219e984f7289b231c888c55e0e2acfb8829a88 100644
--- a/cumulus/bridges/primitives/runtime/src/messages.rs
+++ b/cumulus/bridges/primitives/runtime/src/messages.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/runtime/src/storage_proof.rs b/cumulus/bridges/primitives/runtime/src/storage_proof.rs
index 09641376666af9feecb3f9255dc02e6fdf2adca0..1b706aa66c16fc73a21ce83f550bea8a8fe128e5 100644
--- a/cumulus/bridges/primitives/runtime/src/storage_proof.rs
+++ b/cumulus/bridges/primitives/runtime/src/storage_proof.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/runtime/src/storage_types.rs b/cumulus/bridges/primitives/runtime/src/storage_types.rs
index e555f60e87f5fb1084914d541d5405a66e8e02e5..91c5451805a9861d9e58c462f9ab5849409d59a7 100644
--- a/cumulus/bridges/primitives/runtime/src/storage_types.rs
+++ b/cumulus/bridges/primitives/runtime/src/storage_types.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/test-utils/src/keyring.rs b/cumulus/bridges/primitives/test-utils/src/keyring.rs
index a4e818a3b88806b18e3394e506bb2fc4a167196c..b99132de3ec36bf0f58a454635876708258d1c0f 100644
--- a/cumulus/bridges/primitives/test-utils/src/keyring.rs
+++ b/cumulus/bridges/primitives/test-utils/src/keyring.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/test-utils/src/lib.rs b/cumulus/bridges/primitives/test-utils/src/lib.rs
index 5a7d0cca279a0c78c94e4e80ab671c59eb7d2262..4d3b84759938b98116a7157b5445804df464cc66 100644
--- a/cumulus/bridges/primitives/test-utils/src/lib.rs
+++ b/cumulus/bridges/primitives/test-utils/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/primitives/xcm-bridge-hub-router/src/lib.rs b/cumulus/bridges/primitives/xcm-bridge-hub-router/src/lib.rs
index 0dd329f9e4a0e4fdf3571b0121793e4c78c33e3e..dbedb7a52c7fee85e35c7fadc67d11d8cfa434dc 100644
--- a/cumulus/bridges/primitives/xcm-bridge-hub-router/src/lib.rs
+++ b/cumulus/bridges/primitives/xcm-bridge-hub-router/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) 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
diff --git a/cumulus/bridges/rustfmt.toml b/cumulus/bridges/rustfmt.toml
deleted file mode 100644
index 082150daf04ee39ada660c315fd0f5bbcf99dea0..0000000000000000000000000000000000000000
--- a/cumulus/bridges/rustfmt.toml
+++ /dev/null
@@ -1,24 +0,0 @@
-# Basic
-hard_tabs = true
-max_width = 100
-use_small_heuristics = "Max"
-# Imports
-imports_granularity = "Crate"
-reorder_imports = true
-# Consistency
-newline_style = "Unix"
-# Format comments
-comment_width = 100
-wrap_comments = true
-# Misc
-chain_width = 80
-spaces_around_ranges = false
-binop_separator = "Back"
-reorder_impl_items = false
-match_arm_leading_pipes = "Preserve"
-match_arm_blocks = false
-match_block_trailing_comma = true
-trailing_comma = "Vertical"
-trailing_semicolon = false
-use_field_init_shorthand = true
-
diff --git a/cumulus/client/cli/Cargo.toml b/cumulus/client/cli/Cargo.toml
index 40c53ae919af113cb313d08bbd74199732e28b93..6c44d5f5fd3b6631a7cfa0449d9d04adaa300a1f 100644
--- a/cumulus/client/cli/Cargo.toml
+++ b/cumulus/client/cli/Cargo.toml
@@ -5,7 +5,7 @@ authors.workspace = true
edition.workspace = true
[dependencies]
-clap = { version = "4.3.24", features = ["derive"] }
+clap = { version = "4.4.2", features = ["derive"] }
codec = { package = "parity-scale-codec", version = "3.0.0" }
url = "2.4.0"
diff --git a/cumulus/client/cli/src/lib.rs b/cumulus/client/cli/src/lib.rs
index 3ad68eb04ead3722489122155eaa483250360d06..1b18ed064373fdd58224b70da022a969ad641eb6 100644
--- a/cumulus/client/cli/src/lib.rs
+++ b/cumulus/client/cli/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/collator/src/lib.rs b/cumulus/client/collator/src/lib.rs
index 647107a7c7c73a58c7301cd26a461da3c3d7354e..f17ae488310608d461238a134597cd875311ba6b 100644
--- a/cumulus/client/collator/src/lib.rs
+++ b/cumulus/client/collator/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Substrate is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/collator/src/service.rs b/cumulus/client/collator/src/service.rs
index c798cb84c23fd9a5f64df6b752b1048e7c6f98ab..c06be006fc17fd5153f0c0478a6786692f841ecb 100644
--- a/cumulus/client/collator/src/service.rs
+++ b/cumulus/client/collator/src/service.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/aura/src/collator.rs b/cumulus/client/consensus/aura/src/collator.rs
index 37cf1ea57c3d5dca7f128c89e4578f515de97cdc..b00c3952e2bc90e057dc464ac4b9179927cd67da 100644
--- a/cumulus/client/consensus/aura/src/collator.rs
+++ b/cumulus/client/consensus/aura/src/collator.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/aura/src/collators/basic.rs b/cumulus/client/consensus/aura/src/collators/basic.rs
index d6f30aa672b51b187b2694ac04e5920514afbd21..3c904915ceafb9b97fa6493d4db21b8b1609585b 100644
--- a/cumulus/client/consensus/aura/src/collators/basic.rs
+++ b/cumulus/client/consensus/aura/src/collators/basic.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/aura/src/collators/lookahead.rs b/cumulus/client/consensus/aura/src/collators/lookahead.rs
index 9663ef5ad3ab238afbd883b4c3a0507000fef892..58d8e9d1a062f7538b498f34c1f510593d2f5412 100644
--- a/cumulus/client/consensus/aura/src/collators/lookahead.rs
+++ b/cumulus/client/consensus/aura/src/collators/lookahead.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/aura/src/collators/mod.rs b/cumulus/client/consensus/aura/src/collators/mod.rs
index 55128dfdc8502c8795109d256e7c223ece59ea28..4c7b759daf736f69de48b586b082a7d01534d7e3 100644
--- a/cumulus/client/consensus/aura/src/collators/mod.rs
+++ b/cumulus/client/consensus/aura/src/collators/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/aura/src/equivocation_import_queue.rs b/cumulus/client/consensus/aura/src/equivocation_import_queue.rs
index 919e0da39b1a98663427dc632b0949037e526f7f..5cd65ed5546bae392df811e8043ac44214f6a7eb 100644
--- a/cumulus/client/consensus/aura/src/equivocation_import_queue.rs
+++ b/cumulus/client/consensus/aura/src/equivocation_import_queue.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/aura/src/import_queue.rs b/cumulus/client/consensus/aura/src/import_queue.rs
index 2f422b9edb174cf00acbacc6c4cc53d29af18aee..2611eaf532f8ffadebc1c2932f429803e561924e 100644
--- a/cumulus/client/consensus/aura/src/import_queue.rs
+++ b/cumulus/client/consensus/aura/src/import_queue.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/aura/src/lib.rs b/cumulus/client/consensus/aura/src/lib.rs
index 792f7b230d62e25093aa7fef0d10812e0f02c32f..6ededa7a92c11cb8c313f7da01017eeef256fb06 100644
--- a/cumulus/client/consensus/aura/src/lib.rs
+++ b/cumulus/client/consensus/aura/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/common/src/import_queue.rs b/cumulus/client/consensus/common/src/import_queue.rs
index e54598ac8568765e2d31b6b82913032622c7d13e..311a2b7ad8cfddf50abe0b18aeb5bf5f1f193c1d 100644
--- a/cumulus/client/consensus/common/src/import_queue.rs
+++ b/cumulus/client/consensus/common/src/import_queue.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/common/src/level_monitor.rs b/cumulus/client/consensus/common/src/level_monitor.rs
index 8a6bbef62f35752a530089297f364698a09e818c..5f115ec2c4a3c885b60da5f5dd9f0fe3faefab16 100644
--- a/cumulus/client/consensus/common/src/level_monitor.rs
+++ b/cumulus/client/consensus/common/src/level_monitor.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/common/src/lib.rs b/cumulus/client/consensus/common/src/lib.rs
index 49e157481e7aa647eab0b1d7517248ba4a4812c2..edd97cf02a2557b372f3a88234267a0a4e639929 100644
--- a/cumulus/client/consensus/common/src/lib.rs
+++ b/cumulus/client/consensus/common/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/common/src/parachain_consensus.rs b/cumulus/client/consensus/common/src/parachain_consensus.rs
index 5bbaa2893cff8c2c76c843220fde28945c3d9b0f..b4b315bb32be6ea18d7ae9399cafe4640096f2b4 100644
--- a/cumulus/client/consensus/common/src/parachain_consensus.rs
+++ b/cumulus/client/consensus/common/src/parachain_consensus.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/common/src/tests.rs b/cumulus/client/consensus/common/src/tests.rs
index b6fcc4a17643bf1ec1a9ead19e5cf30f4f05258c..15586d81d9bfff8d177cf392c89a4c90606ad3bf 100644
--- a/cumulus/client/consensus/common/src/tests.rs
+++ b/cumulus/client/consensus/common/src/tests.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/proposer/Cargo.toml b/cumulus/client/consensus/proposer/Cargo.toml
index f7edbc695e3864dc21c8b34a4eab7087998b1e6e..29720a8f4791124536095ffba44189762de47f90 100644
--- a/cumulus/client/consensus/proposer/Cargo.toml
+++ b/cumulus/client/consensus/proposer/Cargo.toml
@@ -8,7 +8,7 @@ edition.workspace = true
[dependencies]
anyhow = "1.0"
async-trait = "0.1.73"
-thiserror = "1.0.47"
+thiserror = "1.0.48"
# Substrate
sp-consensus = { path = "../../../../substrate/primitives/consensus/common" }
diff --git a/cumulus/client/consensus/proposer/src/lib.rs b/cumulus/client/consensus/proposer/src/lib.rs
index c2e95eca3a3862536222c163d3a323c22ae2566e..7404651bcd96cc40eeecc3c465b2fafffc25c567 100644
--- a/cumulus/client/consensus/proposer/src/lib.rs
+++ b/cumulus/client/consensus/proposer/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/relay-chain/src/import_queue.rs b/cumulus/client/consensus/relay-chain/src/import_queue.rs
index 72704673bf8848d7b483d96d81913c143078d77c..9ee03b95904c60fb3b26f60e54023c13c88a2808 100644
--- a/cumulus/client/consensus/relay-chain/src/import_queue.rs
+++ b/cumulus/client/consensus/relay-chain/src/import_queue.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/consensus/relay-chain/src/lib.rs b/cumulus/client/consensus/relay-chain/src/lib.rs
index ee912520d6630dd1e439d22df5c52be1b2fd6b89..fc395a9d9573fe2efd70d8322f64997670b6d8ec 100644
--- a/cumulus/client/consensus/relay-chain/src/lib.rs
+++ b/cumulus/client/consensus/relay-chain/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/network/Cargo.toml b/cumulus/client/network/Cargo.toml
index 99a567a950c173e68d05611ee421a6b01c5c872b..eaaf497ac3edcc74415ab0ba6a1c3caf6faff953 100644
--- a/cumulus/client/network/Cargo.toml
+++ b/cumulus/client/network/Cargo.toml
@@ -23,7 +23,7 @@ sp-state-machine = { path = "../../../substrate/primitives/state-machine" }
# Polkadot
polkadot-node-primitives = { path = "../../../polkadot/node/primitives" }
-polkadot-parachain = { path = "../../../polkadot/parachain" }
+polkadot-parachain-primitives = { path = "../../../polkadot/parachain" }
polkadot-primitives = { path = "../../../polkadot/primitives" }
# Cumulus
diff --git a/cumulus/client/network/src/lib.rs b/cumulus/client/network/src/lib.rs
index b42342e5b77805447e40365d771e97a3f18409ef..ebd557b805c5d7ea4362632dac8bf0a59ddc6469 100644
--- a/cumulus/client/network/src/lib.rs
+++ b/cumulus/client/network/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Polkadot.
// Polkadot is free software: you can redistribute it and/or modify
@@ -28,7 +28,7 @@ use sp_runtime::traits::{Block as BlockT, Header as HeaderT};
use cumulus_relay_chain_interface::RelayChainInterface;
use polkadot_node_primitives::{CollationSecondedSignal, Statement};
-use polkadot_parachain::primitives::HeadData;
+use polkadot_parachain_primitives::primitives::HeadData;
use polkadot_primitives::{
CandidateReceipt, CompactStatement, Hash as PHash, Id as ParaId, OccupiedCoreAssumption,
SigningContext, UncheckedSigned,
diff --git a/cumulus/client/network/src/tests.rs b/cumulus/client/network/src/tests.rs
index e1bb961c75fd22064b41334595122fef47b2e475..e03f470753bb6c32c4410a7c694dea8312c74c31 100644
--- a/cumulus/client/network/src/tests.rs
+++ b/cumulus/client/network/src/tests.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Polkadot.
// Polkadot is free software: you can redistribute it and/or modify
@@ -125,8 +125,10 @@ impl RelayChainInterface for DummyRelayChainInterface {
if self.data.lock().has_pending_availability {
Ok(Some(CommittedCandidateReceipt {
descriptor: CandidateDescriptor {
- para_head: polkadot_parachain::primitives::HeadData(default_header().encode())
- .hash(),
+ para_head: polkadot_parachain_primitives::primitives::HeadData(
+ default_header().encode(),
+ )
+ .hash(),
para_id: 0u32.into(),
relay_parent: PHash::random(),
collator: CollatorPair::generate().0.public(),
@@ -315,7 +317,7 @@ async fn make_gossip_message_and_header(
pov_hash: PHash::random(),
erasure_root: PHash::random(),
signature: sp_core::sr25519::Signature([0u8; 64]).into(),
- para_head: polkadot_parachain::primitives::HeadData(header.encode()).hash(),
+ para_head: polkadot_parachain_primitives::primitives::HeadData(header.encode()).hash(),
validation_code_hash: ValidationCodeHash::from(PHash::random()),
},
};
diff --git a/cumulus/client/pov-recovery/src/active_candidate_recovery.rs b/cumulus/client/pov-recovery/src/active_candidate_recovery.rs
index feb09d005cec4a6b84effe06dfc46ff6ae82a531..322b19c796a8c10191f3bfb261b293aba4348944 100644
--- a/cumulus/client/pov-recovery/src/active_candidate_recovery.rs
+++ b/cumulus/client/pov-recovery/src/active_candidate_recovery.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Polkadot.
// Polkadot is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/pov-recovery/src/lib.rs b/cumulus/client/pov-recovery/src/lib.rs
index a7509c54ab09d32efe444de32160ab6fb837e8e8..b050bc66799c7aa84db67374dc801890e0e7ce25 100644
--- a/cumulus/client/pov-recovery/src/lib.rs
+++ b/cumulus/client/pov-recovery/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/relay-chain-inprocess-interface/src/lib.rs b/cumulus/client/relay-chain-inprocess-interface/src/lib.rs
index 5b3ab15ed6fd9aa2d1da475c8f8bb342a80cf601..42a56b649f035bdf10aa18099fe3851a3b5d238e 100644
--- a/cumulus/client/relay-chain-inprocess-interface/src/lib.rs
+++ b/cumulus/client/relay-chain-inprocess-interface/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/relay-chain-interface/Cargo.toml b/cumulus/client/relay-chain-interface/Cargo.toml
index b81cc1b4780761fa86ca819653b90159f19749e9..3da7ab0b0e8212d7a05d972ca3fb7c82a0955bd3 100644
--- a/cumulus/client/relay-chain-interface/Cargo.toml
+++ b/cumulus/client/relay-chain-interface/Cargo.toml
@@ -16,6 +16,6 @@ sc-client-api = { path = "../../../substrate/client/api" }
futures = "0.3.28"
async-trait = "0.1.73"
-thiserror = "1.0.47"
+thiserror = "1.0.48"
jsonrpsee-core = "0.16.2"
parity-scale-codec = "3.6.4"
diff --git a/cumulus/client/relay-chain-interface/src/lib.rs b/cumulus/client/relay-chain-interface/src/lib.rs
index a0258e20632830c0da88e218936f6e873c94c2ae..a6970732447c34f485a8a066d1bec27b762352a9 100644
--- a/cumulus/client/relay-chain-interface/src/lib.rs
+++ b/cumulus/client/relay-chain-interface/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/relay-chain-minimal-node/src/blockchain_rpc_client.rs b/cumulus/client/relay-chain-minimal-node/src/blockchain_rpc_client.rs
index fc4d803002cb2ea106d9897ee8d99b9f7a5ab06a..57e16bc4283ce00eea494fb1e4c66d08008bc73d 100644
--- a/cumulus/client/relay-chain-minimal-node/src/blockchain_rpc_client.rs
+++ b/cumulus/client/relay-chain-minimal-node/src/blockchain_rpc_client.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -338,6 +338,14 @@ impl RuntimeApiSubsystemClient for BlockChainRpcClient {
.await?)
}
+ async fn minimum_backing_votes(
+ &self,
+ at: Hash,
+ session_index: polkadot_primitives::SessionIndex,
+ ) -> Result {
+ Ok(self.rpc_client.parachain_host_minimum_backing_votes(at, session_index).await?)
+ }
+
async fn staging_async_backing_params(&self, at: Hash) -> Result {
Ok(self.rpc_client.parachain_host_staging_async_backing_params(at).await?)
}
diff --git a/cumulus/client/relay-chain-minimal-node/src/collator_overseer.rs b/cumulus/client/relay-chain-minimal-node/src/collator_overseer.rs
index 0acd04e73cd83d03be20898141bed9495752a8d7..491758c1329a3427f9e206b8f118053cb4f304bf 100644
--- a/cumulus/client/relay-chain-minimal-node/src/collator_overseer.rs
+++ b/cumulus/client/relay-chain-minimal-node/src/collator_overseer.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Polkadot.
// Polkadot is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/relay-chain-minimal-node/src/lib.rs b/cumulus/client/relay-chain-minimal-node/src/lib.rs
index 8d0228219089b6e5de4734fa9aa65fcb28ae9c2f..366d428eda70036203f48e253c9d395c58b887ec 100644
--- a/cumulus/client/relay-chain-minimal-node/src/lib.rs
+++ b/cumulus/client/relay-chain-minimal-node/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2017-2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Polkadot.
// Polkadot is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/relay-chain-minimal-node/src/network.rs b/cumulus/client/relay-chain-minimal-node/src/network.rs
index 5097e6ce33a672e8c09d1a2e641e486ca8c198c5..f39d7a26dd8838d693d8c32d62d51fa147c26cda 100644
--- a/cumulus/client/relay-chain-minimal-node/src/network.rs
+++ b/cumulus/client/relay-chain-minimal-node/src/network.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/relay-chain-rpc-interface/Cargo.toml b/cumulus/client/relay-chain-rpc-interface/Cargo.toml
index 1056efd2dc8eb60cebb224a8b58813b138ffb1a4..305ab82b064c5ae29625641d1704289f0edd66a9 100644
--- a/cumulus/client/relay-chain-rpc-interface/Cargo.toml
+++ b/cumulus/client/relay-chain-rpc-interface/Cargo.toml
@@ -33,11 +33,11 @@ tracing = "0.1.37"
async-trait = "0.1.73"
url = "2.4.0"
serde_json = "1.0.105"
-serde = "1.0.183"
+serde = "1.0.188"
schnellru = "0.2.1"
smoldot = { version = "0.11.0", default_features = false, features = ["std"]}
smoldot-light = { version = "0.9.0", default_features = false, features = ["std"] }
either = "1.8.1"
-thiserror = "1.0.38"
+thiserror = "1.0.48"
rand = "0.8.5"
pin-project = "1.1.3"
diff --git a/cumulus/client/relay-chain-rpc-interface/src/lib.rs b/cumulus/client/relay-chain-rpc-interface/src/lib.rs
index c01f38433dc7b266b43445d016aed3f45b4ee9c3..96f8fc8b5563335eb7796bc8fd105fced15bc5e1 100644
--- a/cumulus/client/relay-chain-rpc-interface/src/lib.rs
+++ b/cumulus/client/relay-chain-rpc-interface/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/relay-chain-rpc-interface/src/light_client_worker.rs b/cumulus/client/relay-chain-rpc-interface/src/light_client_worker.rs
index b6773870512843549af0d38e902d2b40a0effb6d..84e66f95571096c319ab1aa05a12a11cdc4c1035 100644
--- a/cumulus/client/relay-chain-rpc-interface/src/light_client_worker.rs
+++ b/cumulus/client/relay-chain-rpc-interface/src/light_client_worker.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/relay-chain-rpc-interface/src/reconnecting_ws_client.rs b/cumulus/client/relay-chain-rpc-interface/src/reconnecting_ws_client.rs
index 5a35b2b5bfa0724a0dedc76eae871154d8044bd2..322bcc93dae6d8158a0e6cfb99ded9a29bee79c5 100644
--- a/cumulus/client/relay-chain-rpc-interface/src/reconnecting_ws_client.rs
+++ b/cumulus/client/relay-chain-rpc-interface/src/reconnecting_ws_client.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/relay-chain-rpc-interface/src/rpc_client.rs b/cumulus/client/relay-chain-rpc-interface/src/rpc_client.rs
index b079294b78421f11a6b770236bc00a95775c93dd..c1e92b249d776126f8de30db2b021898e50219fc 100644
--- a/cumulus/client/relay-chain-rpc-interface/src/rpc_client.rs
+++ b/cumulus/client/relay-chain-rpc-interface/src/rpc_client.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -588,6 +588,16 @@ impl RelayChainRpcClient {
.await
}
+ /// Get the minimum number of backing votes for a candidate.
+ pub async fn parachain_host_minimum_backing_votes(
+ &self,
+ at: RelayHash,
+ _session_index: SessionIndex,
+ ) -> Result {
+ self.call_remote_runtime_function("ParachainHost_minimum_backing_votes", at, None::<()>)
+ .await
+ }
+
#[allow(missing_docs)]
pub async fn parachain_host_staging_async_backing_params(
&self,
diff --git a/cumulus/client/relay-chain-rpc-interface/src/tokio_platform.rs b/cumulus/client/relay-chain-rpc-interface/src/tokio_platform.rs
index 7b8c69645b61bc6985119c266e5bc8a370264158..75a5604d741b4fe92e55cfe4f55fdaba747e4bb5 100644
--- a/cumulus/client/relay-chain-rpc-interface/src/tokio_platform.rs
+++ b/cumulus/client/relay-chain-rpc-interface/src/tokio_platform.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/client/service/src/lib.rs b/cumulus/client/service/src/lib.rs
index 11b6240eb73fc890033ca66b9c514b00ccb0b5c6..211a5cc3b79bc7b8d59aed9300b0a442f5372de8 100644
--- a/cumulus/client/service/src/lib.rs
+++ b/cumulus/client/service/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Substrate is free software: you can redistribute it and/or modify
diff --git a/cumulus/docs/container.md b/cumulus/docs/container.md
index 63575f37a59b93fc31d8d09030b1d97153566a42..ef7c52a44fab3bd5113b70ee6a4ff27893b3b8b1 100644
--- a/cumulus/docs/container.md
+++ b/cumulus/docs/container.md
@@ -1,19 +1,22 @@
-## Using Containers
+# Using Containers
-Using containers via **Podman** or **Docker** brings benefit, whether it is to build a container image or
-run a node while keeping a minimum footprint on your local system.
+Using containers via **Podman** or **Docker** brings benefit, whether it is to build a container image or run a node
+while keeping a minimum footprint on your local system.
-This document mentions using `podman` or `docker`. Those are usually interchangeable and it is encouraged using preferably **Podman**. If you have podman installed and want to use all the commands mentioned below, you can simply create an alias with `alias docker=podman`.
+This document mentions using `podman` or `docker`. Those are usually interchangeable and it is encouraged using
+preferably **Podman**. If you have podman installed and want to use all the commands mentioned below, you can simply
+create an alias with `alias docker=podman`.
There are a few options to build a node within a container and inject a binary inside an image.
-### Parity built container image
+## Parity built container image
Parity builds and publishes a container image that can be found as `docker.io/parity/polkadot-parachain`.
-### Parity CI image
+## Parity CI image
-Parity maintains and uses internally a generic "CI" image that can be used as a base to build binaries: [Parity CI container image](https://github.com/paritytech/scripts/tree/master/dockerfiles/ci-linux):
+Parity maintains and uses internally a generic "CI" image that can be used as a base to build binaries: [Parity CI
+container image](https://github.com/paritytech/scripts/tree/master/dockerfiles/ci-linux):
The command below allows building a Linux binary without having to even install Rust or any dependency locally:
@@ -29,19 +32,22 @@ sudo chown -R $(id -u):$(id -g) target/
If you want to reproduce other steps of CI process you can use the following
[guide](https://github.com/paritytech/scripts#gitlab-ci-for-building-docker-images).
-### Injected image
+## Injected image
-Injecting a binary inside a base image is the quickest option to get a working container image. This only works if you were able to build a Linux binary, either locally, or using a container as described above.
+Injecting a binary inside a base image is the quickest option to get a working container image. This only works if you
+were able to build a Linux binary, either locally, or using a container as described above.
-After building a Linux binary ()`polkadot-parachain`) with cargo or with Parity CI image as documented above, the following command allows producing a new container image where the compiled binary is injected:
+After building a Linux binary ()`polkadot-parachain`) with cargo or with Parity CI image as documented above, the
+following command allows producing a new container image where the compiled binary is injected:
```bash
./docker/scripts/build-injected-image.sh
```
-### Container build
+## Container build
-Alternatively, you can build an image with a builder pattern. This options takes a while but offers a simple method for anyone to get a working container image without requiring any of the Rust toolchain installed locally.
+Alternatively, you can build an image with a builder pattern. This options takes a while but offers a simple method for
+anyone to get a working container image without requiring any of the Rust toolchain installed locally.
```bash
docker build \
diff --git a/cumulus/docs/release.md b/cumulus/docs/release.md
index b04c4e844c4eda09fa82a4febeda9a47d0f527c9..38d1915013b07d67ae074a0f7606c6fd58526e3b 100644
--- a/cumulus/docs/release.md
+++ b/cumulus/docs/release.md
@@ -37,8 +37,8 @@ performed during the release process.
### Burn In
-Ensure that Parity DevOps has run the new release on Westend and Kusama Asset Hub collators for 12h
-prior to publishing the release.
+Ensure that Parity DevOps has run the new release on Westend and Kusama Asset Hub collators for 12h prior to publishing
+the release.
### Build Artifacts
@@ -75,56 +75,61 @@ function of the appropriate pallets.
### Extrinsic Ordering & Storage
-Offline signing libraries depend on a consistent ordering of call indices and
-functions. Compare the metadata of the current and new runtimes and ensure that
-the `module index, call index` tuples map to the same set of functions. It also checks if there have been any changes in `storage`. In case of a breaking change, increase `transaction_version`.
+Offline signing libraries depend on a consistent ordering of call indices and functions. Compare the metadata of the
+current and new runtimes and ensure that the `module index, call index` tuples map to the same set of functions. It also
+checks if there have been any changes in `storage`. In case of a breaking change, increase `transaction_version`.
-To verify the order has not changed, manually start the following [Github Action](https://github.com/paritytech/cumulus/actions/workflows/extrinsic-ordering-check-from-bin.yml). It takes around a minute to run and will produce the report as artifact you need to manually check.
+To verify the order has not changed, manually start the following [Github
+Action](https://github.com/paritytech/cumulus/actions/workflows/extrinsic-ordering-check-from-bin.yml). It takes around
+a minute to run and will produce the report as artifact you need to manually check.
To run it, in the _Run Workflow_ dropdown:
1. **Use workflow from**: to ignore, leave `master` as default
-2. **The WebSocket url of the reference node**:
- - Asset Hub Polkadot: `wss://statemint-rpc.polkadot.io`
+2. **The WebSocket url of the reference node**: - Asset Hub Polkadot: `wss://statemint-rpc.polkadot.io`
- Asset Hub Kusama: `wss://statemine-rpc.polkadot.io`
- Asset Hub Westend: `wss://westmint-rpc.polkadot.io`
-3. **A url to a Linux binary for the node containing the runtime to test**: Paste the URL of the latest release-candidate binary from the draft-release on Github. The binary has to previously be uploaded to S3 (Github url link to the binary is constantly changing)
+3. **A url to a Linux binary for the node containing the runtime to test**: Paste the URL of the latest
+ release-candidate binary from the draft-release on Github. The binary has to previously be uploaded to S3 (Github url
+ link to the binary is constantly changing)
- E.g: https://releases.parity.io/cumulus/v0.9.270-rc3/polkadot-parachain
-4. **The name of the chain under test. Usually, you would pass a local chain**:
- - Asset Hub Polkadot: `asset-hub-polkadot-local`
+4. **The name of the chain under test. Usually, you would pass a local chain**: - Asset Hub Polkadot:
+ `asset-hub-polkadot-local`
- Asset Hub Kusama: `asset-hub-kusama-local`
- Asset Hub Westend: `asset-hub-westend-local`
5. Click **Run workflow**
-When the workflow is done, click on it and download the zip artifact, inside you'll find an `output.txt` file. The things to look for in the output are lines like:
+When the workflow is done, click on it and download the zip artifact, inside you'll find an `output.txt` file. The
+things to look for in the output are lines like:
- `[Identity] idx 28 -> 25 (calls 15)` - indicates the index for Identity has changed
- `[+] Society, Recovery` - indicates the new version includes 2 additional modules/pallets.
- If no indices have changed, every modules line should look something like `[Identity] idx 25 (calls 15)`
-**Note**: Adding new functions to the runtime does not constitute a breaking change
-as long as the indexes did not change.
+**Note**: Adding new functions to the runtime does not constitute a breaking change as long as the indexes did not
+change.
-**Note**: Extrinsic function signatures changes (adding/removing & ordering arguments) are not caught by the job, so those changes should be reviewed "manually"
+**Note**: Extrinsic function signatures changes (adding/removing & ordering arguments) are not caught by the job, so
+those changes should be reviewed "manually"
### Benchmarks
-The Benchmarks can now be started from the CI. First find the CI pipeline from [here](https://gitlab.parity.io/parity/mirrors/cumulus/-/pipelines?page=1&scope=all&ref=release-parachains-v9220) and pick the latest.
-[Guide](https://github.com/paritytech/ci_cd/wiki/Benchmarks:-cumulus)
+The Benchmarks can now be started from the CI. First find the CI pipeline from
+[here](https://gitlab.parity.io/parity/mirrors/cumulus/-/pipelines?page=1&scope=all&ref=release-parachains-v9220) and
+pick the latest. [Guide](https://github.com/paritytech/ci_cd/wiki/Benchmarks:-cumulus)
### Integration Tests
Until https://github.com/paritytech/ci_cd/issues/499 is done, tests will have to be run manually.
-1. Go to https://github.com/paritytech/parachains-integration-tests and check out the release branch.
-E.g. https://github.com/paritytech/parachains-integration-tests/tree/release-v9270-v0.9.27
-for `release-parachains-v0.9.270`
+1. Go to https://github.com/paritytech/parachains-integration-tests and check out the release branch. E.g.
+https://github.com/paritytech/parachains-integration-tests/tree/release-v9270-v0.9.27 for `release-parachains-v0.9.270`
2. Clone `release-parachains-` branch from Cumulus
3. `cargo build --release`
4. Copy `./target/polkadot-parachain` to `./bin`
-5. Clone `it/release--fast-sudo` from Polkadot
-In case the branch does not exists (it is a manual process): cherry pick paritytech/polkadot@791c8b8 and run
-`find . -type f -name "*.toml" -print0 | xargs -0 sed -i '' -e 's/polkadot-vX.X.X/polkadot-v/g'`
+5. Clone `it/release--fast-sudo` from Polkadot In case the branch does not exists (it is a manual process):
+ cherry pick `paritytech/polkadot@791c8b8` and run:
+ `find . -type f -name "*.toml" -print0 | xargs -0 sed -i '' -e 's/polkadot-vX.X.X/polkadot-v/g'`
6. `cargo build --release --features fast-runtime`
7. Copy `./target/polkadot` into `./bin` (in Cumulus)
8. Run the tests:
- - Asset Hub Polkadot: `yarn zombienet-test -c ./examples/statemint/config.toml -t ./examples/statemint`
- - Asset Hub Kusama: `yarn zombienet-test -c ./examples/statemine/config.toml -t ./examples/statemine`
+ - Asset Hub Polkadot: `yarn zombienet-test -c ./examples/statemint/config.toml -t ./examples/statemint`
+ - Asset Hub Kusama: `yarn zombienet-test -c ./examples/statemine/config.toml -t ./examples/statemine`
diff --git a/cumulus/file_header.txt b/cumulus/file_header.txt
index 04f0c5de2716eb3f5c6037a67cca718c56b56e1e..712045bf2ca1506c47abc51d93b8e231133f0011 100644
--- a/cumulus/file_header.txt
+++ b/cumulus/file_header.txt
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/aura-ext/src/consensus_hook.rs b/cumulus/pallets/aura-ext/src/consensus_hook.rs
index 745ee7a3352d305b777ef794b4dd902d7cc05c2a..089ab5c3198b98129e53e155dc4fcc009bf0e6d8 100644
--- a/cumulus/pallets/aura-ext/src/consensus_hook.rs
+++ b/cumulus/pallets/aura-ext/src/consensus_hook.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/aura-ext/src/lib.rs b/cumulus/pallets/aura-ext/src/lib.rs
index d22202bdbaa8f8d7067288ec243ce50c3dc60da5..34a41557152d8df38e0abc2d612151b2f74dc779 100644
--- a/cumulus/pallets/aura-ext/src/lib.rs
+++ b/cumulus/pallets/aura-ext/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/collator-selection/README.md b/cumulus/pallets/collator-selection/README.md
index 9718db58b37e9ae1c81b5b627fe27e51129cf418..811207fd8c0f916f31d08d27fc53499572b6bef4 100644
--- a/cumulus/pallets/collator-selection/README.md
+++ b/cumulus/pallets/collator-selection/README.md
@@ -1 +1 @@
-License: Apache-2.0
\ No newline at end of file
+License: Apache-2.0
diff --git a/cumulus/pallets/collator-selection/src/benchmarking.rs b/cumulus/pallets/collator-selection/src/benchmarking.rs
index 5eb8a5ce65bf41d700e119db1aa091b5eed9e647..49999dc114df7bdc94dca2f8c563d7c1d8bb6083 100644
--- a/cumulus/pallets/collator-selection/src/benchmarking.rs
+++ b/cumulus/pallets/collator-selection/src/benchmarking.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/pallets/collator-selection/src/lib.rs b/cumulus/pallets/collator-selection/src/lib.rs
index 924b24d71047da62dc96c7e979f8ea97a73e7df6..24493ce9d9cdc7f451f2e997615962ee5f0662e0 100644
--- a/cumulus/pallets/collator-selection/src/lib.rs
+++ b/cumulus/pallets/collator-selection/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/pallets/collator-selection/src/migration.rs b/cumulus/pallets/collator-selection/src/migration.rs
index 3b298353386d0f8265004033a297d17575eae1e9..58b4cc5b06a1ab7da17b31ad3c457fd992c59136 100644
--- a/cumulus/pallets/collator-selection/src/migration.rs
+++ b/cumulus/pallets/collator-selection/src/migration.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Polkadot.
// Polkadot is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/collator-selection/src/mock.rs b/cumulus/pallets/collator-selection/src/mock.rs
index d8c6d783f3f3a538bf0013ba1bafda33b63485db..44d531c971ee3bee08f572ac797a93d1759a5cfa 100644
--- a/cumulus/pallets/collator-selection/src/mock.rs
+++ b/cumulus/pallets/collator-selection/src/mock.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/pallets/collator-selection/src/tests.rs b/cumulus/pallets/collator-selection/src/tests.rs
index cbfbde743f0ee583b0e729cb7718c736c491d76f..d4dae513df375145c35a83d7af274e581a94a60b 100644
--- a/cumulus/pallets/collator-selection/src/tests.rs
+++ b/cumulus/pallets/collator-selection/src/tests.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/pallets/collator-selection/src/weights.rs b/cumulus/pallets/collator-selection/src/weights.rs
index a4a30d833612a11f8ad77ba08a13aefaaad3d8b8..f8f86fb7dec2c08601eebe4d8b345a0f7c930b70 100644
--- a/cumulus/pallets/collator-selection/src/weights.rs
+++ b/cumulus/pallets/collator-selection/src/weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/pallets/dmp-queue/Cargo.toml b/cumulus/pallets/dmp-queue/Cargo.toml
index db654b4c1327f8d4000cf33ee77b3c5d88a02cf0..9d61a2c99fd35af24ac0bdd51a4dfb5aa4b5fd65 100644
--- a/cumulus/pallets/dmp-queue/Cargo.toml
+++ b/cumulus/pallets/dmp-queue/Cargo.toml
@@ -17,7 +17,7 @@ sp-runtime = { path = "../../../substrate/primitives/runtime", default-features
sp-std = { path = "../../../substrate/primitives/std", default-features = false}
# Polkadot
-xcm = { path = "../../../polkadot/xcm", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../polkadot/xcm", default-features = false}
# Cumulus
cumulus-primitives-core = { path = "../../primitives/core", default-features = false }
diff --git a/cumulus/pallets/dmp-queue/src/lib.rs b/cumulus/pallets/dmp-queue/src/lib.rs
index aca9025d9e33594a2897f383457fae6c04de5de9..eff4a625ef1b6ff88ae23cee2cc252af78921a67 100644
--- a/cumulus/pallets/dmp-queue/src/lib.rs
+++ b/cumulus/pallets/dmp-queue/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/dmp-queue/src/migration.rs b/cumulus/pallets/dmp-queue/src/migration.rs
index b2323f6a60fa6e14a333df27a2f986aaa646fed8..63457ee493697cc7e0b6cb32433cd0d55b9e2244 100644
--- a/cumulus/pallets/dmp-queue/src/migration.rs
+++ b/cumulus/pallets/dmp-queue/src/migration.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Polkadot.
// Polkadot is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/parachain-system/Cargo.toml b/cumulus/pallets/parachain-system/Cargo.toml
index 6dab4f75d7dc55d7019e9dc79bf9c02243b7d6af..3063083c0ee49d5f6e88db287de529a8eef0c80d 100644
--- a/cumulus/pallets/parachain-system/Cargo.toml
+++ b/cumulus/pallets/parachain-system/Cargo.toml
@@ -28,8 +28,8 @@ sp-trie = { path = "../../../substrate/primitives/trie", default-features = fals
sp-version = { path = "../../../substrate/primitives/version", default-features = false}
# Polkadot
-polkadot-parachain = { path = "../../../polkadot/parachain", default-features = false, features = [ "wasm-api" ]}
-xcm = { path = "../../../polkadot/xcm", default-features = false}
+polkadot-parachain-primitives = { path = "../../../polkadot/parachain", default-features = false, features = [ "wasm-api" ]}
+xcm = { package = "staging-xcm", path = "../../../polkadot/xcm", default-features = false}
# Cumulus
cumulus-pallet-parachain-system-proc-macro = { path = "proc-macro", default-features = false }
@@ -62,7 +62,7 @@ std = [
"frame-support/std",
"frame-system/std",
"log/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"scale-info/std",
"sp-core/std",
"sp-externalities/std",
@@ -79,7 +79,7 @@ std = [
runtime-benchmarks = [
"frame-support/runtime-benchmarks",
"frame-system/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
]
diff --git a/cumulus/pallets/parachain-system/proc-macro/Cargo.toml b/cumulus/pallets/parachain-system/proc-macro/Cargo.toml
index 58a4a97e0492da113b9ac9be9c8e80106ba8c769..e5e7da81d2aea4cc34833e09b517228bb7c5e0b1 100644
--- a/cumulus/pallets/parachain-system/proc-macro/Cargo.toml
+++ b/cumulus/pallets/parachain-system/proc-macro/Cargo.toml
@@ -9,7 +9,7 @@ description = "Proc macros provided by the parachain-system pallet"
proc-macro = true
[dependencies]
-syn = "2.0.29"
+syn = "2.0.31"
proc-macro2 = "1.0.64"
quote = "1.0.33"
proc-macro-crate = "1.3.1"
diff --git a/cumulus/pallets/parachain-system/proc-macro/src/lib.rs b/cumulus/pallets/parachain-system/proc-macro/src/lib.rs
index 70c6857120c73466bd3f1e9c49eec4e2bffd8701..8ab5d81efdcf486dff67db6a1f5a62a5a8454ae8 100644
--- a/cumulus/pallets/parachain-system/proc-macro/src/lib.rs
+++ b/cumulus/pallets/parachain-system/proc-macro/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -142,7 +142,7 @@ pub fn register_validate_block(input: proc_macro::TokenStream) -> proc_macro::To
#check_inherents,
>(params);
- #crate_::validate_block::polkadot_parachain::write_result(&res)
+ #crate_::validate_block::polkadot_parachain_primitives::write_result(&res)
}
}
}
diff --git a/cumulus/pallets/parachain-system/src/consensus_hook.rs b/cumulus/pallets/parachain-system/src/consensus_hook.rs
index 2566eea9bbcc2ad3d418ca9765ececcdabf77bf2..91353fc7bbda7ce05cfb5259e05bde64c758bbe4 100644
--- a/cumulus/pallets/parachain-system/src/consensus_hook.rs
+++ b/cumulus/pallets/parachain-system/src/consensus_hook.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/parachain-system/src/lib.rs b/cumulus/pallets/parachain-system/src/lib.rs
index ded869bf6f793aae860eee4e26d9f1e58515a5d6..a8e9a0bf9ae4460b7cda5ef1f7b49bb5c0629eef 100644
--- a/cumulus/pallets/parachain-system/src/lib.rs
+++ b/cumulus/pallets/parachain-system/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2020 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -36,7 +36,7 @@ use cumulus_primitives_core::{
};
use cumulus_primitives_parachain_inherent::{MessageQueueChain, ParachainInherentData};
use frame_support::{
- dispatch::{DispatchError, DispatchResult, Pays, PostDispatchInfo},
+ dispatch::{DispatchResult, Pays, PostDispatchInfo},
ensure,
inherent::{InherentData, InherentIdentifier, ProvideInherent},
storage,
@@ -44,7 +44,7 @@ use frame_support::{
weights::Weight,
};
use frame_system::{ensure_none, ensure_root, pallet_prelude::HeaderFor};
-use polkadot_parachain::primitives::RelayChainBlockNumber;
+use polkadot_parachain_primitives::primitives::RelayChainBlockNumber;
use scale_info::TypeInfo;
use sp_runtime::{
traits::{Block as BlockT, BlockNumberProvider, Hash},
@@ -52,7 +52,7 @@ use sp_runtime::{
InvalidTransaction, TransactionLongevity, TransactionSource, TransactionValidity,
ValidTransaction,
},
- RuntimeDebug,
+ DispatchError, RuntimeDebug,
};
use sp_std::{cmp, collections::btree_map::BTreeMap, prelude::*};
use xcm::latest::XcmHash;
@@ -1429,7 +1429,7 @@ impl Pallet {
pub fn initialize_for_set_code_benchmark(max_code_size: u32) {
// insert dummy ValidationData
let vfp = PersistedValidationData {
- parent_head: polkadot_parachain::primitives::HeadData(Default::default()),
+ parent_head: polkadot_parachain_primitives::primitives::HeadData(Default::default()),
relay_parent_number: 1,
relay_parent_storage_root: Default::default(),
max_pov_size: 1_000,
diff --git a/cumulus/pallets/parachain-system/src/migration.rs b/cumulus/pallets/parachain-system/src/migration.rs
index 17dce3a11a9da9d193e342df083c295d7db85294..a92f85b9cd420e9e1027d1f82c643d90fea8b97c 100644
--- a/cumulus/pallets/parachain-system/src/migration.rs
+++ b/cumulus/pallets/parachain-system/src/migration.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/parachain-system/src/relay_state_snapshot.rs b/cumulus/pallets/parachain-system/src/relay_state_snapshot.rs
index b8556485041657e9664f061d1121ba0ac4d59547..5519d1521ea6da85573f2ecdd9cca001616b5806 100644
--- a/cumulus/pallets/parachain-system/src/relay_state_snapshot.rs
+++ b/cumulus/pallets/parachain-system/src/relay_state_snapshot.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/parachain-system/src/tests.rs b/cumulus/pallets/parachain-system/src/tests.rs
index 41e8dc63808d7178a7da38d3f3b76c5a8406f6f9..626196790bc99f611c099a815019e336b4dd7df0 100755
--- a/cumulus/pallets/parachain-system/src/tests.rs
+++ b/cumulus/pallets/parachain-system/src/tests.rs
@@ -1,4 +1,4 @@
-// Copyright 2020 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -23,10 +23,9 @@ use cumulus_primitives_core::{
use cumulus_test_relay_sproof_builder::RelayStateSproofBuilder;
use frame_support::{
assert_ok,
- dispatch::UnfilteredDispatchable,
inherent::{InherentData, ProvideInherent},
parameter_types,
- traits::{OnFinalize, OnInitialize},
+ traits::{OnFinalize, OnInitialize, UnfilteredDispatchable},
weights::Weight,
};
use frame_system::{
diff --git a/cumulus/pallets/parachain-system/src/unincluded_segment.rs b/cumulus/pallets/parachain-system/src/unincluded_segment.rs
index 2598228dd60c41a53b921c805b72cfff00a526c3..1e83a945c4ee37f2ad8ee1c45d11892f47c40be4 100644
--- a/cumulus/pallets/parachain-system/src/unincluded_segment.rs
+++ b/cumulus/pallets/parachain-system/src/unincluded_segment.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/parachain-system/src/validate_block/implementation.rs b/cumulus/pallets/parachain-system/src/validate_block/implementation.rs
index 0eb83639018bf28f234907f819f2a4bdaf27b0a6..ce3b724420f1c9e50b65a81074e023c6b735227b 100644
--- a/cumulus/pallets/parachain-system/src/validate_block/implementation.rs
+++ b/cumulus/pallets/parachain-system/src/validate_block/implementation.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Substrate.
// Substrate is free software: you can redistribute it and/or modify
@@ -22,7 +22,9 @@ use cumulus_primitives_core::{
};
use cumulus_primitives_parachain_inherent::ParachainInherentData;
-use polkadot_parachain::primitives::{HeadData, RelayChainBlockNumber, ValidationResult};
+use polkadot_parachain_primitives::primitives::{
+ HeadData, RelayChainBlockNumber, ValidationResult,
+};
use codec::Encode;
diff --git a/cumulus/pallets/parachain-system/src/validate_block/mod.rs b/cumulus/pallets/parachain-system/src/validate_block/mod.rs
index 4e387bf849623f0aea2c3ab5ae82c851a166b278..db149401638aabeb65f3242fc450e27f8edb93cd 100644
--- a/cumulus/pallets/parachain-system/src/validate_block/mod.rs
+++ b/cumulus/pallets/parachain-system/src/validate_block/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Substrate.
// Substrate is free software: you can redistribute it and/or modify
@@ -34,7 +34,7 @@ pub use bytes;
pub use codec::decode_from_bytes;
#[cfg(not(feature = "std"))]
#[doc(hidden)]
-pub use polkadot_parachain;
+pub use polkadot_parachain_primitives;
#[cfg(not(feature = "std"))]
#[doc(hidden)]
pub use sp_runtime::traits::GetRuntimeBlockType;
@@ -42,15 +42,16 @@ pub use sp_runtime::traits::GetRuntimeBlockType;
#[doc(hidden)]
pub use sp_std;
-/// Basically the same as [`ValidationParams`](polkadot_parachain::primitives::ValidationParams),
-/// but a little bit optimized for our use case here.
+/// Basically the same as
+/// [`ValidationParams`](polkadot_parachain_primitives::primitives::ValidationParams), but a little
+/// bit optimized for our use case here.
///
/// `block_data` and `head_data` are represented as [`bytes::Bytes`] to make them reuse
/// the memory of the input parameter of the exported `validate_blocks` function.
///
/// The layout of this type must match exactly the layout of
-/// [`ValidationParams`](polkadot_parachain::primitives::ValidationParams) to have the same
-/// SCALE encoding.
+/// [`ValidationParams`](polkadot_parachain_primitives::primitives::ValidationParams) to have the
+/// same SCALE encoding.
#[derive(codec::Decode)]
#[cfg_attr(feature = "std", derive(codec::Encode))]
#[doc(hidden)]
diff --git a/cumulus/pallets/parachain-system/src/validate_block/tests.rs b/cumulus/pallets/parachain-system/src/validate_block/tests.rs
index 7772f6372567a70e43a8c38fe9e93aaf89a901b4..0cf68f25cc34b7be302b5983d5f7f27fcfcf13f1 100644
--- a/cumulus/pallets/parachain-system/src/validate_block/tests.rs
+++ b/cumulus/pallets/parachain-system/src/validate_block/tests.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Substrate.
// Substrate is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/session-benchmarking/src/lib.rs b/cumulus/pallets/session-benchmarking/src/lib.rs
index 5217bbae71b478b74f917a071b8144a122953353..f474def6b13762136ca90b2f812e9c5a3e26a0e2 100644
--- a/cumulus/pallets/session-benchmarking/src/lib.rs
+++ b/cumulus/pallets/session-benchmarking/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/pallets/solo-to-para/src/lib.rs b/cumulus/pallets/solo-to-para/src/lib.rs
index 5672ec4ece4ab4763be94c786eb60bf3a2366885..da948615d4e90a5f109cb56b47f796acead6535c 100644
--- a/cumulus/pallets/solo-to-para/src/lib.rs
+++ b/cumulus/pallets/solo-to-para/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/xcm/Cargo.toml b/cumulus/pallets/xcm/Cargo.toml
index 42a9d52993cfbb095b6b27fd08ddb3230bf8f5df..229edaaab4c881c7399ff6036dafbb2f0d7ba1e2 100644
--- a/cumulus/pallets/xcm/Cargo.toml
+++ b/cumulus/pallets/xcm/Cargo.toml
@@ -14,7 +14,7 @@ sp-runtime = { path = "../../../substrate/primitives/runtime", default-features
frame-support = { path = "../../../substrate/frame/support", default-features = false}
frame-system = { path = "../../../substrate/frame/system", default-features = false}
-xcm = { path = "../../../polkadot/xcm", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../polkadot/xcm", default-features = false}
cumulus-primitives-core = { path = "../../primitives/core", default-features = false }
diff --git a/cumulus/pallets/xcm/src/lib.rs b/cumulus/pallets/xcm/src/lib.rs
index f230ced5dc5581eb0e2573676391c99aa5e575da..69b4f43754003495b4e6cec9b8e9e29e1ce73a08 100644
--- a/cumulus/pallets/xcm/src/lib.rs
+++ b/cumulus/pallets/xcm/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -24,7 +24,7 @@ use codec::{Decode, DecodeLimit, Encode};
use cumulus_primitives_core::{
relay_chain::BlockNumber as RelayBlockNumber, DmpMessageHandler, ParaId,
};
-use frame_support::dispatch::Weight;
+use frame_support::weights::Weight;
pub use pallet::*;
use scale_info::TypeInfo;
use sp_runtime::{traits::BadOrigin, RuntimeDebug};
diff --git a/cumulus/pallets/xcmp-queue/Cargo.toml b/cumulus/pallets/xcmp-queue/Cargo.toml
index 919749c0f4523da69d8086b5e2f41b3d0314b028..de4ad61de9e090c3095009cde286d37137db34ce 100644
--- a/cumulus/pallets/xcmp-queue/Cargo.toml
+++ b/cumulus/pallets/xcmp-queue/Cargo.toml
@@ -19,8 +19,8 @@ sp-std = { path = "../../../substrate/primitives/std", default-features = false}
# Polkadot
polkadot-runtime-common = { path = "../../../polkadot/runtime/common", default-features = false}
-xcm = { path = "../../../polkadot/xcm", default-features = false}
-xcm-executor = { path = "../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../polkadot/xcm", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-primitives-core = { path = "../../primitives/core", default-features = false }
@@ -35,7 +35,7 @@ sp-core = { path = "../../../substrate/primitives/core" }
pallet-balances = { path = "../../../substrate/frame/balances" }
# Polkadot
-xcm-builder = { path = "../../../polkadot/xcm/xcm-builder" }
+xcm-builder = { package = "staging-xcm-builder", path = "../../../polkadot/xcm/xcm-builder" }
# Cumulus
cumulus-pallet-parachain-system = { path = "../parachain-system" }
diff --git a/cumulus/pallets/xcmp-queue/src/benchmarking.rs b/cumulus/pallets/xcmp-queue/src/benchmarking.rs
index f4167e522fa4bcb8cc6453a31e0f6c95e69df4d0..17ec60a2f3fafe9d257074fc803c6567b4422c31 100644
--- a/cumulus/pallets/xcmp-queue/src/benchmarking.rs
+++ b/cumulus/pallets/xcmp-queue/src/benchmarking.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/pallets/xcmp-queue/src/lib.rs b/cumulus/pallets/xcmp-queue/src/lib.rs
index 960af9b5b7724acd70f2dd6d82d8d4d897b4eb3a..1cb92f59518697d184ca9a6eac407ccdef86f8f2 100644
--- a/cumulus/pallets/xcmp-queue/src/lib.rs
+++ b/cumulus/pallets/xcmp-queue/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Substrate is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/xcmp-queue/src/migration.rs b/cumulus/pallets/xcmp-queue/src/migration.rs
index bda54620cd9bd07e4a8020dce892a640d087aa3f..a54ddfb9cecd0888bb0b54ab19a28d5796e41fab 100644
--- a/cumulus/pallets/xcmp-queue/src/migration.rs
+++ b/cumulus/pallets/xcmp-queue/src/migration.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Polkadot.
// Polkadot is free software: you can redistribute it and/or modify
diff --git a/cumulus/pallets/xcmp-queue/src/mock.rs b/cumulus/pallets/xcmp-queue/src/mock.rs
index 3177373e29848dab2433c8de9438ae1415342ad1..8d2b848056a822ded4343f060a617a22f0dd4338 100644
--- a/cumulus/pallets/xcmp-queue/src/mock.rs
+++ b/cumulus/pallets/xcmp-queue/src/mock.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/pallets/xcmp-queue/src/tests.rs b/cumulus/pallets/xcmp-queue/src/tests.rs
index 45c4519d3aa496b06744c5bc35f9ec2092d69c23..2929e8452bef6095aa1e2ba4f168d85482f0b3b2 100644
--- a/cumulus/pallets/xcmp-queue/src/tests.rs
+++ b/cumulus/pallets/xcmp-queue/src/tests.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/pallets/xcmp-queue/src/weights.rs b/cumulus/pallets/xcmp-queue/src/weights.rs
index cbb29ac3ae3166c9a0e2b9c03196396408b5f647..2d20bba6f8f6b18571ea4d241d57f08998d13d87 100644
--- a/cumulus/pallets/xcmp-queue/src/weights.rs
+++ b/cumulus/pallets/xcmp-queue/src/weights.rs
@@ -1,3 +1,18 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
#![allow(unused_parens)]
#![allow(unused_imports)]
diff --git a/cumulus/parachain-template/README.md b/cumulus/parachain-template/README.md
index 6dcc70c538290e16587025b652131954c8264ea3..2d71bbd71f3615a071710d9402c83f43621893d1 100644
--- a/cumulus/parachain-template/README.md
+++ b/cumulus/parachain-template/README.md
@@ -19,4 +19,4 @@ parathreads [here](https://wiki.polkadot.network/docs/learn-parathreads).
🧙 Learn about how to use this template and run your own parachain testnet for it in the
-[Devhub Cumulus Tutorial](https://docs.substrate.io/tutorials/v3/cumulus/start-relay/).
\ No newline at end of file
+[Devhub Cumulus Tutorial](https://docs.substrate.io/tutorials/v3/cumulus/start-relay/).
diff --git a/cumulus/parachain-template/node/Cargo.toml b/cumulus/parachain-template/node/Cargo.toml
index f4fdfc64facb3bc502db4470b888e57b1b768544..b1f1946e3ed457f04a9b2623969df02d6016d842 100644
--- a/cumulus/parachain-template/node/Cargo.toml
+++ b/cumulus/parachain-template/node/Cargo.toml
@@ -11,10 +11,10 @@ build = "build.rs"
publish = false
[dependencies]
-clap = { version = "4.3.24", features = ["derive"] }
+clap = { version = "4.4.2", features = ["derive"] }
log = "0.4.20"
codec = { package = "parity-scale-codec", version = "3.0.0" }
-serde = { version = "1.0.183", features = ["derive"] }
+serde = { version = "1.0.188", features = ["derive"] }
jsonrpsee = { version = "0.16.2", features = ["server"] }
futures = "0.3.28"
@@ -56,7 +56,7 @@ substrate-prometheus-endpoint = { path = "../../../substrate/utils/prometheus" }
# Polkadot
polkadot-cli = { path = "../../../polkadot/cli", features = ["rococo-native"] }
polkadot-primitives = { path = "../../../polkadot/primitives" }
-xcm = { path = "../../../polkadot/xcm", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../polkadot/xcm", default-features = false}
# Cumulus
cumulus-client-cli = { path = "../../client/cli" }
diff --git a/cumulus/parachain-template/pallets/template/Cargo.toml b/cumulus/parachain-template/pallets/template/Cargo.toml
index e06f836c3be0ebe4c77dfd846bb33758f18ba3bf..af35ab651dc48e85da2a6d138f84de367cb033f8 100644
--- a/cumulus/parachain-template/pallets/template/Cargo.toml
+++ b/cumulus/parachain-template/pallets/template/Cargo.toml
@@ -21,7 +21,7 @@ frame-support = { path = "../../../../substrate/frame/support", default-features
frame-system = { path = "../../../../substrate/frame/system", default-features = false}
[dev-dependencies]
-serde = { version = "1.0.183" }
+serde = { version = "1.0.188" }
# Substrate
sp-core = { path = "../../../../substrate/primitives/core", default-features = false}
diff --git a/cumulus/parachain-template/runtime/Cargo.toml b/cumulus/parachain-template/runtime/Cargo.toml
index b321d6e316068fda852472a8518b301aa79ae99b..f26b7be23533a284aaf2d1bdbb2232daaf7509e5 100644
--- a/cumulus/parachain-template/runtime/Cargo.toml
+++ b/cumulus/parachain-template/runtime/Cargo.toml
@@ -54,11 +54,11 @@ sp-version = { path = "../../../substrate/primitives/version", default-features
# Polkadot
pallet-xcm = { path = "../../../polkadot/xcm/pallet-xcm", default-features = false}
-polkadot-parachain = { path = "../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../polkadot/parachain", default-features = false}
polkadot-runtime-common = { path = "../../../polkadot/runtime/common", default-features = false}
-xcm = { path = "../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-aura-ext = { path = "../../pallets/aura-ext", default-features = false }
@@ -104,7 +104,7 @@ std = [
"pallet-transaction-payment/std",
"pallet-xcm/std",
"parachain-info/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"polkadot-runtime-common/std",
"scale-info/std",
"sp-api/std",
@@ -139,7 +139,7 @@ runtime-benchmarks = [
"pallet-sudo/runtime-benchmarks",
"pallet-timestamp/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"polkadot-runtime-common/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
diff --git a/cumulus/parachain-template/runtime/src/weights/block_weights.rs b/cumulus/parachain-template/runtime/src/weights/block_weights.rs
index b2092d875c8328210667da4cbb95de0642e60ae3..e7fdb2aae2a01ec06076de83d94817e540e205dd 100644
--- a/cumulus/parachain-template/runtime/src/weights/block_weights.rs
+++ b/cumulus/parachain-template/runtime/src/weights/block_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachain-template/runtime/src/weights/extrinsic_weights.rs b/cumulus/parachain-template/runtime/src/weights/extrinsic_weights.rs
index 332c3b324bb9c1b386257bf7953d37aba8f5af13..1a4adb968bb7195428ea00d59cd92dcd3b6eea5f 100644
--- a/cumulus/parachain-template/runtime/src/weights/extrinsic_weights.rs
+++ b/cumulus/parachain-template/runtime/src/weights/extrinsic_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachain-template/runtime/src/weights/mod.rs b/cumulus/parachain-template/runtime/src/weights/mod.rs
index ed0b4dbcd47fbffb125bda4b337099ae69e51ce2..30fa2c4060689ff98cc427c84f81866172845e52 100644
--- a/cumulus/parachain-template/runtime/src/weights/mod.rs
+++ b/cumulus/parachain-template/runtime/src/weights/mod.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachain-template/runtime/src/weights/paritydb_weights.rs b/cumulus/parachain-template/runtime/src/weights/paritydb_weights.rs
index 4338d928d807a41cc60ec91d86e91c81bb253631..25679703831a13b8d1bb7fb7dd4d92fa84b1f255 100644
--- a/cumulus/parachain-template/runtime/src/weights/paritydb_weights.rs
+++ b/cumulus/parachain-template/runtime/src/weights/paritydb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachain-template/runtime/src/weights/rocksdb_weights.rs b/cumulus/parachain-template/runtime/src/weights/rocksdb_weights.rs
index 1d115d963facb39fe29d6258918fda3bc8d94900..3dd817aa6f137085b0e5fdf2b11b7f50e5c8b002 100644
--- a/cumulus/parachain-template/runtime/src/weights/rocksdb_weights.rs
+++ b/cumulus/parachain-template/runtime/src/weights/rocksdb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachain-template/runtime/src/xcm_config.rs b/cumulus/parachain-template/runtime/src/xcm_config.rs
index 01321d9f12acf59f0c4126c9374b039b67b10a9a..57193ce8ab63d3c458e1b33374f9be36ed3768b5 100644
--- a/cumulus/parachain-template/runtime/src/xcm_config.rs
+++ b/cumulus/parachain-template/runtime/src/xcm_config.rs
@@ -9,7 +9,7 @@ use frame_support::{
};
use frame_system::EnsureRoot;
use pallet_xcm::XcmPassthrough;
-use polkadot_parachain::primitives::Sibling;
+use polkadot_parachain_primitives::primitives::Sibling;
use polkadot_runtime_common::impls::ToAuthor;
use xcm::latest::prelude::*;
use xcm_builder::{
diff --git a/cumulus/parachains/common/Cargo.toml b/cumulus/parachains/common/Cargo.toml
index 1b790dd5b6f116dd846029eef1bac91ea69244fd..18cafde0d30380eb53591969037fa29a77b0a68e 100644
--- a/cumulus/parachains/common/Cargo.toml
+++ b/cumulus/parachains/common/Cargo.toml
@@ -13,6 +13,7 @@ codec = { package = "parity-scale-codec", version = "3.0.0", features = ["derive
log = { version = "0.4.19", default-features = false }
scale-info = { version = "2.9.0", default-features = false, features = ["derive"] }
num-traits = { version = "0.2", default-features = false}
+smallvec = "1.11.0"
# Substrate
frame-support = { path = "../../../substrate/frame/support", default-features = false }
@@ -28,10 +29,15 @@ sp-runtime = { path = "../../../substrate/primitives/runtime", default-features
sp-std = { path = "../../../substrate/primitives/std", default-features = false }
# Polkadot
+kusama-runtime-constants = { path = "../../../polkadot/runtime/kusama/constants", default-features = false}
+polkadot-runtime-constants = { path = "../../../polkadot/runtime/polkadot/constants", default-features = false}
+rococo-runtime-constants = { path = "../../../polkadot/runtime/rococo/constants", default-features = false}
+westend-runtime-constants = { path = "../../../polkadot/runtime/westend/constants", default-features = false}
+polkadot-core-primitives = { path = "../../../polkadot/core-primitives", default-features = false}
polkadot-primitives = { path = "../../../polkadot/primitives", default-features = false}
-xcm = { path = "../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
pallet-collator-selection = { path = "../../pallets/collator-selection", default-features = false }
@@ -52,18 +58,23 @@ std = [
"cumulus-primitives-utility/std",
"frame-support/std",
"frame-system/std",
+ "kusama-runtime-constants/std",
"log/std",
"pallet-asset-tx-payment/std",
"pallet-assets/std",
"pallet-authorship/std",
"pallet-balances/std",
"pallet-collator-selection/std",
+ "polkadot-core-primitives/std",
"polkadot-primitives/std",
+ "polkadot-runtime-constants/std",
+ "rococo-runtime-constants/std",
"sp-consensus-aura/std",
"sp-core/std",
"sp-io/std",
"sp-runtime/std",
"sp-std/std",
+ "westend-runtime-constants/std",
"xcm-builder/std",
"xcm-executor/std",
"xcm/std",
diff --git a/cumulus/parachains/common/src/impls.rs b/cumulus/parachains/common/src/impls.rs
index 4a1f4f90d05571381ad22b90e02ace54f1dc518a..107cd5c687328bce1369c59cfa7d4fcbcdd377f3 100644
--- a/cumulus/parachains/common/src/impls.rs
+++ b/cumulus/parachains/common/src/impls.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/constants.rs b/cumulus/parachains/common/src/kusama.rs
similarity index 93%
rename from cumulus/parachains/runtimes/contracts/contracts-rococo/src/constants.rs
rename to cumulus/parachains/common/src/kusama.rs
index db7922ea905b8588d5bdd3289e9bd4f8fc813097..308f7d081cedcc90aba2d6c12ed25e13e716bbb4 100644
--- a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/constants.rs
+++ b/cumulus/parachains/common/src/kusama.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -13,6 +13,19 @@
// See the License for the specific language governing permissions and
// limitations under the License.
+/// Consensus-related.
+pub mod consensus {
+ /// Maximum number of blocks simultaneously accepted by the Runtime, not yet included
+ /// into the relay chain.
+ pub const UNINCLUDED_SEGMENT_CAPACITY: u32 = 1;
+ /// How many parachain blocks are processed by the relay chain per parent. Limits the
+ /// number of blocks authored per slot.
+ pub const BLOCK_PROCESSING_VELOCITY: u32 = 1;
+ /// Relay chain slot duration, in milliseconds.
+ pub const RELAY_CHAIN_SLOT_DURATION_MILLIS: u32 = 6000;
+}
+
+/// Constants relating to KSM.
pub mod currency {
use kusama_runtime_constants as constants;
use polkadot_core_primitives::Balance;
@@ -31,7 +44,7 @@ pub mod currency {
}
}
-/// Fee-related.
+/// Constants related to Kusama fee payment.
pub mod fee {
use frame_support::{
pallet_prelude::Weight,
@@ -75,8 +88,8 @@ pub mod fee {
impl WeightToFeePolynomial for RefTimeToFee {
type Balance = Balance;
fn polynomial() -> WeightToFeeCoefficients {
- // in Kusama, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
- // in Rococo Contracts, we map to 1/10 of that, or 1/100 CENT
+ // In Kusama, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
+ // The standard system parachain configuration is 1/10 of that, as in 1/100 CENT.
let p = super::currency::CENTS;
let q = 100 * Balance::from(ExtrinsicBaseWeight::get().ref_time());
@@ -107,15 +120,3 @@ pub mod fee {
}
}
}
-
-/// Consensus-related.
-pub mod consensus {
- /// Maximum number of blocks simultaneously accepted by the Runtime, not yet included
- /// into the relay chain.
- pub const UNINCLUDED_SEGMENT_CAPACITY: u32 = 1;
- /// How many parachain blocks are processed by the relay chain per parent. Limits the
- /// number of blocks authored per slot.
- pub const BLOCK_PROCESSING_VELOCITY: u32 = 1;
- /// Relay chain slot duration, in milliseconds.
- pub const RELAY_CHAIN_SLOT_DURATION_MILLIS: u32 = 6000;
-}
diff --git a/cumulus/parachains/common/src/lib.rs b/cumulus/parachains/common/src/lib.rs
index 0a9686bf8a3719499f08c9e84d7351561013d0f5..cb2ac1a1e3e45d7af1cba07c8dddbba1837cf199 100644
--- a/cumulus/parachains/common/src/lib.rs
+++ b/cumulus/parachains/common/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -16,6 +16,10 @@
#![cfg_attr(not(feature = "std"), no_std)]
pub mod impls;
+pub mod kusama;
+pub mod polkadot;
+pub mod rococo;
+pub mod westend;
pub mod xcm_config;
pub use constants::*;
pub use opaque::*;
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/constants.rs b/cumulus/parachains/common/src/polkadot.rs
similarity index 93%
rename from cumulus/parachains/runtimes/collectives/collectives-polkadot/src/constants.rs
rename to cumulus/parachains/common/src/polkadot.rs
index ac516447c7407dae82ce2b221747e3374b765db2..52cee939224cc0f276bf9f92aa896a2469346256 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/constants.rs
+++ b/cumulus/parachains/common/src/polkadot.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -13,6 +13,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
+/// Universally recognized accounts.
pub mod account {
use frame_support::PalletId;
@@ -28,6 +29,19 @@ pub mod account {
pub const REFERENDA_PALLET_ID: PalletId = PalletId(*b"py/refer");
}
+/// Consensus-related.
+pub mod consensus {
+ /// Maximum number of blocks simultaneously accepted by the Runtime, not yet included
+ /// into the relay chain.
+ pub const UNINCLUDED_SEGMENT_CAPACITY: u32 = 1;
+ /// How many parachain blocks are processed by the relay chain per parent. Limits the
+ /// number of blocks authored per slot.
+ pub const BLOCK_PROCESSING_VELOCITY: u32 = 1;
+ /// Relay chain slot duration, in milliseconds.
+ pub const RELAY_CHAIN_SLOT_DURATION_MILLIS: u32 = 6000;
+}
+
+/// Constants relating to DOT.
pub mod currency {
use polkadot_core_primitives::Balance;
use polkadot_runtime_constants as constants;
@@ -41,12 +55,12 @@ pub mod currency {
pub const MILLICENTS: Balance = constants::currency::MILLICENTS;
pub const fn deposit(items: u32, bytes: u32) -> Balance {
- // 1/100 of Polkadot.
+ // 1/100 of Polkadot
constants::currency::deposit(items, bytes) / 100
}
}
-/// Fee-related.
+/// Constants related to Polkadot fee payment.
pub mod fee {
use frame_support::{
pallet_prelude::Weight,
@@ -90,8 +104,8 @@ pub mod fee {
impl WeightToFeePolynomial for RefTimeToFee {
type Balance = Balance;
fn polynomial() -> WeightToFeeCoefficients {
- // in Polkadot, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
- // in a parachain, we map to 1/10 of that, or 1/100 CENT
+ // In Polkadot, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
+ // The standard system parachain configuration is 1/10 of that, as in 1/100 CENT.
let p = super::currency::CENTS;
let q = 100 * Balance::from(ExtrinsicBaseWeight::get().ref_time());
@@ -122,15 +136,3 @@ pub mod fee {
}
}
}
-
-/// Consensus-related.
-pub mod consensus {
- /// Maximum number of blocks simultaneously accepted by the Runtime, not yet included
- /// into the relay chain.
- pub const UNINCLUDED_SEGMENT_CAPACITY: u32 = 1;
- /// How many parachain blocks are processed by the relay chain per parent. Limits the
- /// number of blocks authored per slot.
- pub const BLOCK_PROCESSING_VELOCITY: u32 = 1;
- /// Relay chain slot duration, in milliseconds.
- pub const RELAY_CHAIN_SLOT_DURATION_MILLIS: u32 = 6000;
-}
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/constants.rs b/cumulus/parachains/common/src/rococo.rs
similarity index 95%
rename from cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/constants.rs
rename to cumulus/parachains/common/src/rococo.rs
index 860b4ad2ba96ace315287db92a0fe5fe1221c168..6e31def4b55b923f1596793e6cb114163551c017 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/constants.rs
+++ b/cumulus/parachains/common/src/rococo.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -73,8 +73,8 @@ pub mod fee {
impl WeightToFeePolynomial for RefTimeToFee {
type Balance = Balance;
fn polynomial() -> WeightToFeeCoefficients {
- // in Rococo, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
- // in Bridge Hub, we map to 1/10 of that, or 1/100 CENT
+ // In Rococo, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
+ // The standard system parachain configuration is 1/10 of that, as in 1/100 CENT.
let p = super::currency::CENTS;
let q = 100 * Balance::from(ExtrinsicBaseWeight::get().ref_time());
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/constants.rs b/cumulus/parachains/common/src/westend.rs
similarity index 95%
rename from cumulus/parachains/runtimes/assets/asset-hub-westend/src/constants.rs
rename to cumulus/parachains/common/src/westend.rs
index fe789569a8ad796c85f67adb3f0fc62b04fbebcf..9d3e0bd1a0e2a51d2dde47b5be329be0bc8b5d38 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/constants.rs
+++ b/cumulus/parachains/common/src/westend.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -75,8 +75,8 @@ pub mod fee {
impl WeightToFeePolynomial for RefTimeToFee {
type Balance = Balance;
fn polynomial() -> WeightToFeeCoefficients {
- // in Westend, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
- // in Asset Hub, we map to 1/10 of that, or 1/100 CENT
+ // In Westend, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
+ // The standard system parachain configuration is 1/10 of that, as in 1/100 CENT.
let p = super::currency::CENTS;
let q = 100 * Balance::from(ExtrinsicBaseWeight::get().ref_time());
diff --git a/cumulus/parachains/common/src/xcm_config.rs b/cumulus/parachains/common/src/xcm_config.rs
index 99dd0ace0fc59b553493129a179958ea37d45f16..146671441453df76c48776e0b202166aca37361b 100644
--- a/cumulus/parachains/common/src/xcm_config.rs
+++ b/cumulus/parachains/common/src/xcm_config.rs
@@ -1,3 +1,18 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
use crate::impls::AccountIdOf;
use core::marker::PhantomData;
use frame_support::{
diff --git a/cumulus/parachains/integration-tests/e2e/collectives/README.md b/cumulus/parachains/integration-tests/e2e/collectives/README.md
index 98ea77aac60642ac7001297bc5d3024124cd7822..9c4efe7c9504835814e1a693dd8d57710da1bc3b 100644
--- a/cumulus/parachains/integration-tests/e2e/collectives/README.md
+++ b/cumulus/parachains/integration-tests/e2e/collectives/README.md
@@ -1,19 +1,23 @@
-E2E tests concerning Polkadot Governance and the Collectives Parachain. The tests run by the Parachain Integration Tests [tool](https://github.com/paritytech/parachains-integration-tests/).
+E2E tests concerning Polkadot Governance and the Collectives Parachain. The tests run by the Parachain Integration Tests
+[tool](https://github.com/paritytech/parachains-integration-tests/).
-## Requirements
+# Requirements
The tests require some changes to the regular production runtime builds:
-RelayChain runtime:
+## RelayChain runtime
1. Alice has SUDO
-2. Public Referenda `StakingAdmin`, `FellowshipAdmin` tracks settings (see the corresponding keys of the `TRACKS_DATA` constant in the `governance::tracks` module of the Relay Chain runtime crate):
+2. Public Referenda `StakingAdmin`, `FellowshipAdmin` tracks settings (see the corresponding keys of the `TRACKS_DATA`
+ constant in the `governance::tracks` module of the Relay Chain runtime crate):
``` yaml
prepare_period: 5 Block,
decision_period: 1 Block,
confirm_period: 1 Block,
min_enactment_period: 1 Block,
```
-Collectives runtime:
-1. Fellowship Referenda `Fellows` track settings (see the corresponding key of the `TRACKS_DATA` constant in the `fellowship::tracks` module of the Collectives runtime crate):
+
+## Collectives runtime
+1. Fellowship Referenda `Fellows` track settings (see the corresponding key of the `TRACKS_DATA` constant in the
+ `fellowship::tracks` module of the Collectives runtime crate):
``` yaml
prepare_period: 5 Block,
decision_period: 1 Block,
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/Cargo.toml b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/Cargo.toml
index 7c870e0220c597b1737717488657505975578335..4f17b1ac55b52858fd1d9655ef8d6ce815b6bbac 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/Cargo.toml
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/Cargo.toml
@@ -3,6 +3,7 @@ name = "asset-hub-kusama-integration-tests"
version = "1.0.0"
authors.workspace = true
edition.workspace = true
+license = "Apache-2.0"
description = "Asset Hub Kusama runtime integration tests with xcm-emulator"
publish = false
@@ -14,28 +15,38 @@ assert_matches = "1.5.0"
sp-runtime = { path = "../../../../../../substrate/primitives/runtime", default-features = false}
frame-support = { path = "../../../../../../substrate/frame/support", default-features = false}
frame-system = { path = "../../../../../../substrate/frame/system", default-features = false}
-sp-core = { path = "../../../../../../substrate/primitives/core", default-features = false}
-sp-weights = { path = "../../../../../../substrate/primitives/weights", default-features = false}
pallet-balances = { path = "../../../../../../substrate/frame/balances", default-features = false}
pallet-assets = { path = "../../../../../../substrate/frame/assets", default-features = false}
pallet-asset-conversion = { path = "../../../../../../substrate/frame/asset-conversion", default-features = false}
# Polkadot
polkadot-core-primitives = { path = "../../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-parachains = { path = "../../../../../../polkadot/runtime/parachains" }
polkadot-runtime = { path = "../../../../../../polkadot/runtime/polkadot" }
-xcm = { path = "../../../../../../polkadot/xcm", default-features = false}
-xcm-executor = { path = "../../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../../polkadot/xcm", default-features = false}
pallet-xcm = { path = "../../../../../../polkadot/xcm/pallet-xcm", default-features = false}
# Cumulus
parachains-common = { path = "../../../../common" }
asset-hub-kusama-runtime = { path = "../../../../runtimes/assets/asset-hub-kusama" }
-cumulus-pallet-dmp-queue = { path = "../../../../../pallets/dmp-queue" }
-cumulus-pallet-xcmp-queue = { path = "../../../../../pallets/xcmp-queue", default-features = false}
-cumulus-pallet-parachain-system = { path = "../../../../../pallets/parachain-system" }
# Local
xcm-emulator = { path = "../../../../../xcm/xcm-emulator", default-features = false}
integration-tests-common = { path = "../../common", default-features = false}
+
+[features]
+runtime-benchmarks = [
+ "asset-hub-kusama-runtime/runtime-benchmarks",
+ "frame-support/runtime-benchmarks",
+ "frame-system/runtime-benchmarks",
+ "integration-tests-common/runtime-benchmarks",
+ "pallet-asset-conversion/runtime-benchmarks",
+ "pallet-assets/runtime-benchmarks",
+ "pallet-balances/runtime-benchmarks",
+ "pallet-xcm/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
+ "polkadot-runtime-parachains/runtime-benchmarks",
+ "polkadot-runtime/runtime-benchmarks",
+ "sp-runtime/runtime-benchmarks",
+]
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/lib.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/lib.rs
index 2609ba4ca8dc73b98978164030c56ec3a1734e37..ad74aa2301fc34d478b9f719f9ccfddb44b79fc8 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/lib.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/lib.rs
@@ -1,58 +1,43 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
pub use codec::Encode;
pub use frame_support::{
assert_err, assert_ok,
- instances::Instance1,
pallet_prelude::Weight,
- sp_runtime::{AccountId32, DispatchError, DispatchResult, MultiAddress},
- traits::{fungibles::Inspect, OriginTrait},
+ sp_runtime::{AccountId32, DispatchError, DispatchResult},
+ traits::fungibles::Inspect,
};
pub use integration_tests_common::{
constants::{
- accounts::{ALICE, BOB},
- asset_hub_kusama::ED as ASSET_HUB_KUSAMA_ED,
- kusama::ED as KUSAMA_ED,
- PROOF_SIZE_THRESHOLD, REF_TIME_THRESHOLD, XCM_V3,
+ asset_hub_kusama::ED as ASSET_HUB_KUSAMA_ED, kusama::ED as KUSAMA_ED, PROOF_SIZE_THRESHOLD,
+ REF_TIME_THRESHOLD, XCM_V3,
},
- lazy_static::lazy_static,
- xcm_transact_paid_execution, xcm_transact_unpaid_execution, AccountId, AssetHubKusama,
- AssetHubKusamaPallet, AssetHubKusamaReceiver, AssetHubKusamaSender, BridgeHubKusama,
- BridgeHubKusamaPallet, BridgeHubKusamaReceiver, BridgeHubKusamaSender, BridgeHubPolkadot,
- BridgeHubPolkadotPallet, BridgeHubPolkadotReceiver, BridgeHubPolkadotSender, Collectives,
- CollectivesPallet, CollectivesReceiver, CollectivesSender, Kusama, KusamaMockNet, KusamaPallet,
- KusamaReceiver, KusamaSender, PenpalKusamaA, PenpalKusamaAPallet, PenpalKusamaAReceiver,
- PenpalKusamaASender, PenpalKusamaB, PenpalKusamaBPallet, PenpalKusamaBReceiver,
- PenpalKusamaBSender, PenpalPolkadotA, PenpalPolkadotAReceiver, PenpalPolkadotASender, Polkadot,
- PolkadotMockNet, PolkadotPallet, PolkadotReceiver, PolkadotSender,
+ xcm_helpers::{xcm_transact_paid_execution, xcm_transact_unpaid_execution},
+ AssetHubKusama, AssetHubKusamaPallet, AssetHubKusamaReceiver, AssetHubKusamaSender, Kusama,
+ KusamaPallet, KusamaReceiver, KusamaSender, PenpalKusamaA, PenpalKusamaAPallet,
+ PenpalKusamaAReceiver, PenpalKusamaASender, PenpalKusamaB, PenpalKusamaBPallet,
};
-pub use parachains_common::Balance;
-pub use polkadot_core_primitives::InboundDownwardMessage;
-pub use polkadot_parachain::primitives::{HrmpChannelId, Id};
-pub use polkadot_runtime_parachains::inclusion::{AggregateMessageOrigin, UmpQueueId};
+pub use parachains_common::{AccountId, Balance};
pub use xcm::{
- prelude::*,
+ prelude::{AccountId32 as AccountId32Junction, *},
v3::{Error, NetworkId::Kusama as KusamaId},
- DoubleEncoded,
};
pub use xcm_emulator::{
- assert_expected_events, bx, cumulus_pallet_dmp_queue, helpers::weight_within_threshold,
- AccountId32Junction, Chain, ParaId, Parachain as Para, RelayChain as Relay, Test, TestArgs,
- TestContext, TestExt, TestExternalities,
+ assert_expected_events, bx, helpers::weight_within_threshold, Chain, Parachain as Para,
+ RelayChain as Relay, Test, TestArgs, TestContext, TestExt,
};
pub const ASSET_ID: u32 = 1;
@@ -101,4 +86,5 @@ pub fn system_para_test_args(
}
#[cfg(test)]
+#[cfg(not(feature = "runtime-benchmarks"))]
mod tests;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/hrmp_channels.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/hrmp_channels.rs
index 99dd042ccafb8745d0f8abfaf236b6aafb0212e3..623b3ff599c8eb85e7f7561eb415296b186bde7f 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/hrmp_channels.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/hrmp_channels.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
use crate::*;
@@ -21,7 +20,6 @@ const MAX_MESSAGE_SIZE: u32 = 8192;
/// Opening HRMP channels between Parachains should work
#[test]
-#[cfg(feature = "FIXME-IGNORED")] //
fn open_hrmp_channel_between_paras_works() {
// Parchain A init values
let para_a_id = PenpalKusamaA::para_id();
@@ -110,6 +108,8 @@ fn open_hrmp_channel_between_paras_works() {
PenpalKusamaB::assert_xcm_pallet_sent();
});
+ PenpalKusamaB::execute_with(|| {});
+
Kusama::execute_with(|| {
type RuntimeEvent = ::RuntimeEvent;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/mod.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/mod.rs
index 73dd76ec9c66b817818a4f58d0539553943b309c..b3089a3b38269bfbb6d6377099ea4acae4a034b1 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/mod.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/mod.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
mod hrmp_channels;
mod reserve_transfer;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/reserve_transfer.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/reserve_transfer.rs
index 9e11830acce2499f9918ec9334f37c173a186235..645dca5035b1d8d385d9e01c31c2570dae14c2a4 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/reserve_transfer.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/reserve_transfer.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
use crate::*;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/send.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/send.rs
index 819517ee840790eb4a8f36bee06c629a32903cd9..5891b694c8e436104b508cce7b67b8266460cc3e 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/send.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/send.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
use crate::*;
@@ -126,72 +125,71 @@ fn send_transact_native_from_system_para_to_relay_fails() {
/// Parachain should be able to send XCM paying its fee with sufficient asset
/// in the System Parachain
#[test]
-#[ignore]
fn send_xcm_from_para_to_system_para_paying_fee_with_assets_works() {
- // let para_sovereign_account = AssetHubKusama::sovereign_account_id_of(
- // AssetHubKusama::sibling_location_of(PenpalKusamaA::para_id()),
- // );
-
- // // Force create and mint assets for Parachain's sovereign account
- // AssetHubKusama::force_create_and_mint_asset(
- // ASSET_ID,
- // ASSET_MIN_BALANCE,
- // true,
- // para_sovereign_account.clone(),
- // ASSET_MIN_BALANCE * 1000000000,
- // );
-
- // // We just need a call that can pass the `SafeCallFilter`
- // // Call values are not relevant
- // let call = AssetHubKusama::force_create_asset_call(
- // ASSET_ID,
- // para_sovereign_account.clone(),
- // true,
- // ASSET_MIN_BALANCE,
- // );
-
- // let origin_kind = OriginKind::SovereignAccount;
- // let fee_amount = ASSET_MIN_BALANCE * 1000000;
- // let native_asset =
- // (X2(PalletInstance(ASSETS_PALLET_ID), GeneralIndex(ASSET_ID.into())), fee_amount).into();
-
- // let root_origin = ::RuntimeOrigin::root();
- // let system_para_destination =
- // PenpalKusamaA::sibling_location_of(AssetHubKusama::para_id()).into();
- // let xcm = xcm_transact_paid_execution(
- // call,
- // origin_kind,
- // native_asset,
- // para_sovereign_account.clone(),
- // );
-
- // PenpalKusamaA::execute_with(|| {
- // assert_ok!(::PolkadotXcm::send(
- // root_origin,
- // bx!(system_para_destination),
- // bx!(xcm),
- // ));
-
- // PenpalKusamaA::assert_xcm_pallet_sent();
- // });
-
- // AssetHubKusama::execute_with(|| {
- // type RuntimeEvent = ::RuntimeEvent;
-
- // AssetHubKusama::assert_xcmp_queue_success(Some(Weight::from_parts(2_176_414_000, 203_593)));
-
- // assert_expected_events!(
- // AssetHubKusama,
- // vec![
- // RuntimeEvent::Assets(pallet_assets::Event::Burned { asset_id, owner, balance }) => {
- // asset_id: *asset_id == ASSET_ID,
- // owner: *owner == para_sovereign_account,
- // balance: *balance == fee_amount,
- // },
- // RuntimeEvent::Assets(pallet_assets::Event::Issued { asset_id, .. }) => {
- // asset_id: *asset_id == ASSET_ID,
- // },
- // ]
- // );
- // });
+ let para_sovereign_account = AssetHubKusama::sovereign_account_id_of(
+ AssetHubKusama::sibling_location_of(PenpalKusamaA::para_id()),
+ );
+
+ // Force create and mint assets for Parachain's sovereign account
+ AssetHubKusama::force_create_and_mint_asset(
+ ASSET_ID,
+ ASSET_MIN_BALANCE,
+ true,
+ para_sovereign_account.clone(),
+ ASSET_MIN_BALANCE * 1000000000,
+ );
+
+ // We just need a call that can pass the `SafeCallFilter`
+ // Call values are not relevant
+ let call = AssetHubKusama::force_create_asset_call(
+ ASSET_ID,
+ para_sovereign_account.clone(),
+ true,
+ ASSET_MIN_BALANCE,
+ );
+
+ let origin_kind = OriginKind::SovereignAccount;
+ let fee_amount = ASSET_MIN_BALANCE * 1000000;
+ let native_asset =
+ (X2(PalletInstance(ASSETS_PALLET_ID), GeneralIndex(ASSET_ID.into())), fee_amount).into();
+
+ let root_origin = ::RuntimeOrigin::root();
+ let system_para_destination =
+ PenpalKusamaA::sibling_location_of(AssetHubKusama::para_id()).into();
+ let xcm = xcm_transact_paid_execution(
+ call,
+ origin_kind,
+ native_asset,
+ para_sovereign_account.clone(),
+ );
+
+ PenpalKusamaA::execute_with(|| {
+ assert_ok!(::PolkadotXcm::send(
+ root_origin,
+ bx!(system_para_destination),
+ bx!(xcm),
+ ));
+
+ PenpalKusamaA::assert_xcm_pallet_sent();
+ });
+
+ AssetHubKusama::execute_with(|| {
+ type RuntimeEvent = ::RuntimeEvent;
+
+ AssetHubKusama::assert_xcmp_queue_success(Some(Weight::from_parts(2_176_414_000, 203_593)));
+
+ assert_expected_events!(
+ AssetHubKusama,
+ vec![
+ RuntimeEvent::Assets(pallet_assets::Event::Burned { asset_id, owner, balance }) => {
+ asset_id: *asset_id == ASSET_ID,
+ owner: *owner == para_sovereign_account,
+ balance: *balance == fee_amount,
+ },
+ RuntimeEvent::Assets(pallet_assets::Event::Issued { asset_id, .. }) => {
+ asset_id: *asset_id == ASSET_ID,
+ },
+ ]
+ );
+ });
}
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/set_xcm_versions.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/set_xcm_versions.rs
index 0ab53b451224d1546dceac8d51ae9784ee747d6f..a7af96096cdde4a9fc6bddb86874c02ca65a1c97 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/set_xcm_versions.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/set_xcm_versions.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
use crate::*;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/swap.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/swap.rs
index eb545155a540bceb6c5aeb0591d2c07ec2ee925e..3a67b5435828184eb49c9ffbda814803d4115048 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/swap.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/swap.rs
@@ -1,6 +1,21 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
use crate::*;
-use asset_hub_kusama_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
use frame_support::{instances::Instance2, BoundedVec};
+use parachains_common::kusama::currency::EXISTENTIAL_DEPOSIT;
use sp_runtime::{DispatchError, ModuleError};
#[test]
@@ -167,11 +182,9 @@ fn swap_locally_on_chain_using_foreign_assets() {
.encode()
.into();
- let buy_execution_fee_amount =
- asset_hub_kusama_runtime::constants::fee::WeightToFee::weight_to_fee(&Weight::from_parts(
- 10_100_000_000_000,
- 300_000,
- ));
+ let buy_execution_fee_amount = parachains_common::kusama::fee::WeightToFee::weight_to_fee(
+ &Weight::from_parts(10_100_000_000_000, 300_000),
+ );
let buy_execution_fee = MultiAsset {
id: Concrete(MultiLocation { parents: 1, interior: Here }),
fun: Fungible(buy_execution_fee_amount),
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/teleport.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/teleport.rs
index cf9f5a2327206786e961f1a5e0d0db5fc324e89b..f69878f35435ded3da456756328350a1c286a471 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/teleport.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-kusama/src/tests/teleport.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
#![allow(dead_code)] //
@@ -187,7 +186,6 @@ fn limited_teleport_native_assets_from_relay_to_system_para_works() {
/// Limited Teleport of native asset from System Parachain to Relay Chain
/// should work when there is enough balance in Relay Chain's `CheckAccount`
#[test]
-#[cfg(feature = "FIXME-IGNORED")] //
fn limited_teleport_native_assets_back_from_system_para_to_relay_works() {
// Dependency - Relay Chain's `CheckAccount` should have enough balance
limited_teleport_native_assets_from_relay_to_system_para_works();
@@ -226,7 +224,6 @@ fn limited_teleport_native_assets_back_from_system_para_to_relay_works() {
/// Limited Teleport of native asset from System Parachain to Relay Chain
/// should't work when there is not enough balance in Relay Chain's `CheckAccount`
#[test]
-#[cfg(feature = "FIXME-IGNORED")] //
fn limited_teleport_native_assets_from_system_para_to_relay_fails() {
// Init values for Relay Chain
let amount_to_send: Balance = ASSET_HUB_KUSAMA_ED * 1000;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/Cargo.toml b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/Cargo.toml
index 174091d881b470e9f8398fdb9a84107b409f534a..ed383207228c2306c8896e1a895af1899f1f6980 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/Cargo.toml
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/Cargo.toml
@@ -3,6 +3,7 @@ name = "asset-hub-polkadot-integration-tests"
version = "1.0.0"
authors.workspace = true
edition.workspace = true
+license = "Apache-2.0"
description = "Asset Hub Polkadot runtime integration tests with xcm-emulator"
publish = false
@@ -13,26 +14,38 @@ codec = { package = "parity-scale-codec", version = "3.4.0", default-features =
sp-runtime = { path = "../../../../../../substrate/primitives/runtime", default-features = false}
frame-support = { path = "../../../../../../substrate/frame/support", default-features = false}
frame-system = { path = "../../../../../../substrate/frame/system", default-features = false}
-sp-core = { path = "../../../../../../substrate/primitives/core", default-features = false}
-sp-weights = { path = "../../../../../../substrate/primitives/weights", default-features = false}
pallet-balances = { path = "../../../../../../substrate/frame/balances", default-features = false}
pallet-assets = { path = "../../../../../../substrate/frame/assets", default-features = false}
+pallet-asset-conversion = { path = "../../../../../../substrate/frame/asset-conversion", default-features = false}
# Polkadot
polkadot-core-primitives = { path = "../../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-parachains = { path = "../../../../../../polkadot/runtime/parachains" }
polkadot-runtime = { path = "../../../../../../polkadot/runtime/polkadot" }
-xcm = { path = "../../../../../../polkadot/xcm", default-features = false}
-xcm-executor = { path = "../../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../../polkadot/xcm", default-features = false}
pallet-xcm = { path = "../../../../../../polkadot/xcm/pallet-xcm", default-features = false}
# Cumulus
parachains-common = { path = "../../../../common" }
-cumulus-pallet-dmp-queue = { path = "../../../../../pallets/dmp-queue" }
-cumulus-pallet-xcmp-queue = { path = "../../../../../pallets/xcmp-queue", default-features = false}
-cumulus-pallet-parachain-system = { path = "../../../../../pallets/parachain-system" }
+asset-hub-kusama-runtime = { path = "../../../../runtimes/assets/asset-hub-kusama" }
# Local
xcm-emulator = { path = "../../../../../xcm/xcm-emulator", default-features = false}
integration-tests-common = { path = "../../common", default-features = false}
+
+[features]
+runtime-benchmarks = [
+ "asset-hub-kusama-runtime/runtime-benchmarks",
+ "frame-support/runtime-benchmarks",
+ "frame-system/runtime-benchmarks",
+ "integration-tests-common/runtime-benchmarks",
+ "pallet-asset-conversion/runtime-benchmarks",
+ "pallet-assets/runtime-benchmarks",
+ "pallet-balances/runtime-benchmarks",
+ "pallet-xcm/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
+ "polkadot-runtime-parachains/runtime-benchmarks",
+ "polkadot-runtime/runtime-benchmarks",
+ "sp-runtime/runtime-benchmarks",
+]
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/lib.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/lib.rs
index 9d87458f876c4ce6fa7969315d6a9bc3a7e8545e..e8ba8e44f25c529f17cae594008d2f3e3fb2e80c 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/lib.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/lib.rs
@@ -1,56 +1,43 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
pub use codec::Encode;
pub use frame_support::{
assert_err, assert_ok,
- instances::Instance1,
pallet_prelude::Weight,
- sp_runtime::{AccountId32, DispatchError, DispatchResult, MultiAddress},
- traits::{fungibles::Inspect, OriginTrait},
+ sp_runtime::{AccountId32, DispatchError, DispatchResult},
+ traits::fungibles::Inspect,
};
pub use integration_tests_common::{
constants::{
- accounts::{ALICE, BOB},
- asset_hub_polkadot::ED as ASSET_HUB_POLKADOT_ED,
- polkadot::ED as POLKADOT_ED,
+ asset_hub_polkadot::ED as ASSET_HUB_POLKADOT_ED, polkadot::ED as POLKADOT_ED,
PROOF_SIZE_THRESHOLD, REF_TIME_THRESHOLD, XCM_V3,
},
- lazy_static::lazy_static,
- xcm_transact_paid_execution, xcm_transact_unpaid_execution, AssetHubPolkadot,
- AssetHubPolkadotPallet, AssetHubPolkadotReceiver, AssetHubPolkadotSender, BridgeHubPolkadot,
- BridgeHubPolkadotPallet, BridgeHubPolkadotReceiver, BridgeHubPolkadotSender, Collectives,
- CollectivesPallet, CollectivesReceiver, CollectivesSender, PenpalPolkadotA,
- PenpalPolkadotAPallet, PenpalPolkadotAReceiver, PenpalPolkadotASender, PenpalPolkadotB,
- PenpalPolkadotBPallet, PenpalPolkadotBReceiver, PenpalPolkadotBSender, Polkadot,
- PolkadotMockNet, PolkadotPallet, PolkadotReceiver, PolkadotSender,
+ xcm_helpers::{xcm_transact_paid_execution, xcm_transact_unpaid_execution},
+ AssetHubPolkadot, AssetHubPolkadotPallet, AssetHubPolkadotReceiver, AssetHubPolkadotSender,
+ PenpalPolkadotA, PenpalPolkadotAPallet, PenpalPolkadotAReceiver, PenpalPolkadotB,
+ PenpalPolkadotBPallet, Polkadot, PolkadotPallet, PolkadotReceiver, PolkadotSender,
};
pub use parachains_common::{AccountId, Balance};
-pub use polkadot_core_primitives::InboundDownwardMessage;
-pub use polkadot_parachain::primitives::{HrmpChannelId, Id};
-pub use polkadot_runtime_parachains::inclusion::{AggregateMessageOrigin, UmpQueueId};
pub use xcm::{
- prelude::*,
+ prelude::{AccountId32 as AccountId32Junction, *},
v3::{Error, NetworkId::Polkadot as PolkadotId},
- DoubleEncoded,
};
pub use xcm_emulator::{
- assert_expected_events, bx, cumulus_pallet_dmp_queue, helpers::weight_within_threshold,
- AccountId32Junction, Chain, ParaId, Parachain as Para, RelayChain as Relay, Test, TestArgs,
- TestContext, TestExt, TestExternalities,
+ assert_expected_events, bx, helpers::weight_within_threshold, Chain, Parachain as Para,
+ RelayChain as Relay, Test, TestArgs, TestContext, TestExt,
};
pub const ASSET_ID: u32 = 1;
@@ -99,4 +86,5 @@ pub fn system_para_test_args(
}
#[cfg(test)]
+#[cfg(not(feature = "runtime-benchmarks"))]
mod tests;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/hrmp_channels.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/hrmp_channels.rs
index 9335d69b4d7d4bcf87d07101677828ea72fd294c..a1423f2ea90b60a7c7b2136ed9301a0c34dc6666 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/hrmp_channels.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/hrmp_channels.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
use crate::*;
@@ -21,7 +20,6 @@ const MAX_MESSAGE_SIZE: u32 = 8192;
/// Opening HRMP channels between Parachains should work
#[test]
-#[cfg(feature = "FIXME-IGNORED")] //
fn open_hrmp_channel_between_paras_works() {
// Parchain A init values
let para_a_id = PenpalPolkadotA::para_id();
@@ -110,6 +108,8 @@ fn open_hrmp_channel_between_paras_works() {
PenpalPolkadotB::assert_xcm_pallet_sent();
});
+ PenpalPolkadotB::execute_with(|| {});
+
Polkadot::execute_with(|| {
type RuntimeEvent = ::RuntimeEvent;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/mod.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/mod.rs
index 00e0a663e4794d5fe1577b6f72df0624116db7fe..c22de4f1c3ebd10a3fd1135718812bd09c53bbe0 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/mod.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/mod.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
mod hrmp_channels;
mod reserve_transfer;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/reserve_transfer.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/reserve_transfer.rs
index 7d773a5865ea0781d1d6b0ebab4c4242360e3b8a..e53693d85d2bbc48ae9fc5ee473c55613cc76d63 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/reserve_transfer.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/reserve_transfer.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
use crate::*;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/send.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/send.rs
index eb4c2ae6add09d9d1c980c2e3ae061640a7b17f8..244b428a7523b36680e08696ca28f69cef8a2fc4 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/send.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/send.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
use crate::*;
@@ -129,75 +128,74 @@ fn send_transact_native_from_system_para_to_relay_fails() {
/// Parachain should be able to send XCM paying its fee with sufficient asset
/// in the System Parachain
#[test]
-#[ignore]
fn send_xcm_from_para_to_system_para_paying_fee_with_assets_works() {
- // let para_sovereign_account = AssetHubPolkadot::sovereign_account_id_of(
- // AssetHubPolkadot::sibling_location_of(PenpalPolkadotA::para_id()),
- // );
-
- // // Force create and mint assets for Parachain's sovereign account
- // AssetHubPolkadot::force_create_and_mint_asset(
- // ASSET_ID,
- // ASSET_MIN_BALANCE,
- // true,
- // para_sovereign_account.clone(),
- // ASSET_MIN_BALANCE * 1000000000,
- // );
-
- // // We just need a call that can pass the `SafeCallFilter`
- // // Call values are not relevant
- // let call = AssetHubPolkadot::force_create_asset_call(
- // ASSET_ID,
- // para_sovereign_account.clone(),
- // true,
- // ASSET_MIN_BALANCE,
- // );
-
- // let origin_kind = OriginKind::SovereignAccount;
- // let fee_amount = ASSET_MIN_BALANCE * 1000000;
- // let native_asset =
- // (X2(PalletInstance(ASSETS_PALLET_ID), GeneralIndex(ASSET_ID.into())), fee_amount).into();
-
- // let root_origin = ::RuntimeOrigin::root();
- // let system_para_destination =
- // PenpalPolkadotA::sibling_location_of(AssetHubPolkadot::para_id()).into();
- // let xcm = xcm_transact_paid_execution(
- // call,
- // origin_kind,
- // native_asset,
- // para_sovereign_account.clone(),
- // );
-
- // PenpalPolkadotA::execute_with(|| {
- // assert_ok!(::PolkadotXcm::send(
- // root_origin,
- // bx!(system_para_destination),
- // bx!(xcm),
- // ));
-
- // PenpalPolkadotA::assert_xcm_pallet_sent();
- // });
-
- // AssetHubPolkadot::execute_with(|| {
- // type RuntimeEvent = ::RuntimeEvent;
-
- // AssetHubPolkadot::assert_xcmp_queue_success(Some(Weight::from_parts(
- // 2_176_414_000,
- // 203_593,
- // )));
-
- // assert_expected_events!(
- // AssetHubPolkadot,
- // vec![
- // RuntimeEvent::Assets(pallet_assets::Event::Burned { asset_id, owner, balance }) => {
- // asset_id: *asset_id == ASSET_ID,
- // owner: *owner == para_sovereign_account,
- // balance: *balance == fee_amount,
- // },
- // RuntimeEvent::Assets(pallet_assets::Event::Issued { asset_id, .. }) => {
- // asset_id: *asset_id == ASSET_ID,
- // },
- // ]
- // );
- // });
+ let para_sovereign_account = AssetHubPolkadot::sovereign_account_id_of(
+ AssetHubPolkadot::sibling_location_of(PenpalPolkadotA::para_id()),
+ );
+
+ // Force create and mint assets for Parachain's sovereign account
+ AssetHubPolkadot::force_create_and_mint_asset(
+ ASSET_ID,
+ ASSET_MIN_BALANCE,
+ true,
+ para_sovereign_account.clone(),
+ ASSET_MIN_BALANCE * 1000000000,
+ );
+
+ // We just need a call that can pass the `SafeCallFilter`
+ // Call values are not relevant
+ let call = AssetHubPolkadot::force_create_asset_call(
+ ASSET_ID,
+ para_sovereign_account.clone(),
+ true,
+ ASSET_MIN_BALANCE,
+ );
+
+ let origin_kind = OriginKind::SovereignAccount;
+ let fee_amount = ASSET_MIN_BALANCE * 1000000;
+ let native_asset =
+ (X2(PalletInstance(ASSETS_PALLET_ID), GeneralIndex(ASSET_ID.into())), fee_amount).into();
+
+ let root_origin = ::RuntimeOrigin::root();
+ let system_para_destination =
+ PenpalPolkadotA::sibling_location_of(AssetHubPolkadot::para_id()).into();
+ let xcm = xcm_transact_paid_execution(
+ call,
+ origin_kind,
+ native_asset,
+ para_sovereign_account.clone(),
+ );
+
+ PenpalPolkadotA::execute_with(|| {
+ assert_ok!(::PolkadotXcm::send(
+ root_origin,
+ bx!(system_para_destination),
+ bx!(xcm),
+ ));
+
+ PenpalPolkadotA::assert_xcm_pallet_sent();
+ });
+
+ AssetHubPolkadot::execute_with(|| {
+ type RuntimeEvent = ::RuntimeEvent;
+
+ AssetHubPolkadot::assert_xcmp_queue_success(Some(Weight::from_parts(
+ 2_176_414_000,
+ 203_593,
+ )));
+
+ assert_expected_events!(
+ AssetHubPolkadot,
+ vec![
+ RuntimeEvent::Assets(pallet_assets::Event::Burned { asset_id, owner, balance }) => {
+ asset_id: *asset_id == ASSET_ID,
+ owner: *owner == para_sovereign_account,
+ balance: *balance == fee_amount,
+ },
+ RuntimeEvent::Assets(pallet_assets::Event::Issued { asset_id, .. }) => {
+ asset_id: *asset_id == ASSET_ID,
+ },
+ ]
+ );
+ });
}
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/set_xcm_versions.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/set_xcm_versions.rs
index 84abf630e507ee14e883b333963954ad4526b113..e121c4167993fbfedfd6ba8f7cbe51417e212591 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/set_xcm_versions.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/set_xcm_versions.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
use crate::*;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/teleport.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/teleport.rs
index 843ef6d3ccedb46bac0d788fb5860830bc0cb777..644c51d75b6620429ebdbcab1a1bdc8b37cce410 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/teleport.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-polkadot/src/tests/teleport.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
#![allow(dead_code)] //
@@ -187,7 +186,6 @@ fn limited_teleport_native_assets_from_relay_to_system_para_works() {
/// Limited Teleport of native asset from System Parachain to Relay Chain
/// should work when there is enough balance in Relay Chain's `CheckAccount`
#[test]
-#[cfg(feature = "FIXME-IGNORED")] //
fn limited_teleport_native_assets_back_from_system_para_to_relay_works() {
// Dependency - Relay Chain's `CheckAccount` should have enough balance
limited_teleport_native_assets_from_relay_to_system_para_works();
@@ -226,7 +224,6 @@ fn limited_teleport_native_assets_back_from_system_para_to_relay_works() {
/// Limited Teleport of native asset from System Parachain to Relay Chain
/// should't work when there is not enough balance in Relay Chain's `CheckAccount`
#[test]
-#[cfg(feature = "FIXME-IGNORED")] //
fn limited_teleport_native_assets_from_system_para_to_relay_fails() {
// Init values for Relay Chain
let amount_to_send: Balance = ASSET_HUB_POLKADOT_ED * 1000;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/Cargo.toml b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/Cargo.toml
index 798ba7d3f3a13b50f80c04c5c04329b27e1b3dc0..0c60a30a0b928703eba9a53e121354084fcbedaf 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/Cargo.toml
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/Cargo.toml
@@ -3,6 +3,7 @@ name = "asset-hub-westend-integration-tests"
version = "1.0.0"
authors.workspace = true
edition.workspace = true
+license = "Apache-2.0"
description = "Asset Hub Westend runtime integration tests with xcm-emulator"
publish = false
@@ -14,28 +15,38 @@ assert_matches = "1.5.0"
sp-runtime = { path = "../../../../../../substrate/primitives/runtime", default-features = false}
frame-support = { path = "../../../../../../substrate/frame/support", default-features = false}
frame-system = { path = "../../../../../../substrate/frame/system", default-features = false}
-sp-core = { path = "../../../../../../substrate/primitives/core", default-features = false}
-sp-weights = { path = "../../../../../../substrate/primitives/weights", default-features = false}
pallet-balances = { path = "../../../../../../substrate/frame/balances", default-features = false}
pallet-assets = { path = "../../../../../../substrate/frame/assets", default-features = false}
pallet-asset-conversion = { path = "../../../../../../substrate/frame/asset-conversion", default-features = false}
# Polkadot
polkadot-core-primitives = { path = "../../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-parachains = { path = "../../../../../../polkadot/runtime/parachains" }
polkadot-runtime = { path = "../../../../../../polkadot/runtime/polkadot" }
-xcm = { path = "../../../../../../polkadot/xcm", default-features = false}
-xcm-executor = { path = "../../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../../polkadot/xcm", default-features = false}
pallet-xcm = { path = "../../../../../../polkadot/xcm/pallet-xcm", default-features = false}
# Cumulus
parachains-common = { path = "../../../../common" }
asset-hub-westend-runtime = { path = "../../../../runtimes/assets/asset-hub-westend" }
-cumulus-pallet-dmp-queue = { path = "../../../../../pallets/dmp-queue" }
-cumulus-pallet-xcmp-queue = { path = "../../../../../pallets/xcmp-queue", default-features = false}
-cumulus-pallet-parachain-system = { path = "../../../../../pallets/parachain-system" }
# Local
xcm-emulator = { path = "../../../../../xcm/xcm-emulator", default-features = false}
integration-tests-common = { path = "../../common", default-features = false}
+
+[features]
+runtime-benchmarks = [
+ "asset-hub-westend-runtime/runtime-benchmarks",
+ "frame-support/runtime-benchmarks",
+ "frame-system/runtime-benchmarks",
+ "integration-tests-common/runtime-benchmarks",
+ "pallet-asset-conversion/runtime-benchmarks",
+ "pallet-assets/runtime-benchmarks",
+ "pallet-balances/runtime-benchmarks",
+ "pallet-xcm/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
+ "polkadot-runtime-parachains/runtime-benchmarks",
+ "polkadot-runtime/runtime-benchmarks",
+ "sp-runtime/runtime-benchmarks",
+]
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/lib.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/lib.rs
index b7f064e7d6ea791076b896636b2fca286ecb6ad9..6e0f3434aedf3dd7a5f630ad40729e6a61e9ba47 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/lib.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/lib.rs
@@ -1,55 +1,45 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
pub use codec::Encode;
pub use frame_support::{
assert_err, assert_ok,
- instances::{Instance1, Instance2},
+ instances::Instance2,
pallet_prelude::Weight,
- sp_runtime::{AccountId32, DispatchError, DispatchResult, ModuleError, MultiAddress},
- traits::{fungibles::Inspect, OriginTrait},
+ sp_runtime::{AccountId32, DispatchError, DispatchResult, ModuleError},
+ traits::fungibles::Inspect,
BoundedVec,
};
pub use integration_tests_common::{
constants::{
- accounts::{ALICE, BOB},
- asset_hub_westend::ED as ASSET_HUB_WESTEND_ED,
- westend::ED as WESTEND_ED,
+ asset_hub_westend::ED as ASSET_HUB_WESTEND_ED, westend::ED as WESTEND_ED,
PROOF_SIZE_THRESHOLD, REF_TIME_THRESHOLD, XCM_V3,
},
- lazy_static::lazy_static,
- xcm_transact_paid_execution, xcm_transact_unpaid_execution, AssetHubWestend,
- AssetHubWestendPallet, AssetHubWestendReceiver, AssetHubWestendSender, Collectives,
- CollectivesPallet, CollectivesReceiver, CollectivesSender, PenpalWestendA,
- PenpalWestendAPallet, PenpalWestendAReceiver, PenpalWestendASender, Westend, WestendMockNet,
+ xcm_helpers::{xcm_transact_paid_execution, xcm_transact_unpaid_execution},
+ AssetHubWestend, AssetHubWestendPallet, AssetHubWestendReceiver, AssetHubWestendSender,
+ PenpalWestendA, PenpalWestendAPallet, PenpalWestendAReceiver, PenpalWestendASender, Westend,
WestendPallet, WestendReceiver, WestendSender,
};
pub use parachains_common::{AccountId, Balance};
-pub use polkadot_core_primitives::InboundDownwardMessage;
-pub use polkadot_parachain::primitives::{HrmpChannelId, Id};
-pub use polkadot_runtime_parachains::inclusion::{AggregateMessageOrigin, UmpQueueId};
pub use xcm::{
- prelude::*,
+ prelude::{AccountId32 as AccountId32Junction, *},
v3::{Error, NetworkId::Westend as WestendId},
- DoubleEncoded,
};
pub use xcm_emulator::{
- assert_expected_events, bx, cumulus_pallet_dmp_queue, helpers::weight_within_threshold,
- AccountId32Junction, Chain, ParaId, Parachain as Para, RelayChain as Relay, Test, TestArgs,
- TestContext, TestExt, TestExternalities,
+ assert_expected_events, bx, helpers::weight_within_threshold, Chain, Parachain as Para,
+ RelayChain as Relay, Test, TestArgs, TestContext, TestExt,
};
pub const ASSET_ID: u32 = 1;
@@ -98,4 +88,5 @@ pub fn system_para_test_args(
}
#[cfg(test)]
+#[cfg(not(feature = "runtime-benchmarks"))]
mod tests;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/mod.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/mod.rs
index e45b78da1c254ef4c42b8b746d5732ea7539cfee..b3841af0e6c38372b8fb621fac468b25bdec63a1 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/mod.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/mod.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
mod reserve_transfer;
mod send;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/reserve_transfer.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/reserve_transfer.rs
index 8d3c5358a37f6d95460ecc99c51980806cc35c7f..51fac43be1255948a9ae72044bececa3d907f2c5 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/reserve_transfer.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/reserve_transfer.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
use crate::*;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/send.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/send.rs
index 87dfab93a5b5790d6bfcae39c7e300f10b893196..424d222bef3811966f55d8fbac954f33f065ffc7 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/send.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/send.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
use crate::*;
@@ -68,75 +67,74 @@ fn send_transact_sudo_from_relay_to_system_para_works() {
/// Parachain should be able to send XCM paying its fee with sufficient asset
/// in the System Parachain
#[test]
-#[ignore]
fn send_xcm_from_para_to_system_para_paying_fee_with_assets_works() {
- // let para_sovereign_account = AssetHubWestend::sovereign_account_id_of(
- // AssetHubWestend::sibling_location_of(PenpalWestendA::para_id()),
- // );
-
- // // Force create and mint assets for Parachain's sovereign account
- // AssetHubWestend::force_create_and_mint_asset(
- // ASSET_ID,
- // ASSET_MIN_BALANCE,
- // true,
- // para_sovereign_account.clone(),
- // ASSET_MIN_BALANCE * 1000000000,
- // );
-
- // // We just need a call that can pass the `SafeCallFilter`
- // // Call values are not relevant
- // let call = AssetHubWestend::force_create_asset_call(
- // ASSET_ID,
- // para_sovereign_account.clone(),
- // true,
- // ASSET_MIN_BALANCE,
- // );
-
- // let origin_kind = OriginKind::SovereignAccount;
- // let fee_amount = ASSET_MIN_BALANCE * 1000000;
- // let native_asset =
- // (X2(PalletInstance(ASSETS_PALLET_ID), GeneralIndex(ASSET_ID.into())), fee_amount).into();
-
- // let root_origin = ::RuntimeOrigin::root();
- // let system_para_destination =
- // PenpalWestendA::sibling_location_of(AssetHubWestend::para_id()).into();
- // let xcm = xcm_transact_paid_execution(
- // call,
- // origin_kind,
- // native_asset,
- // para_sovereign_account.clone(),
- // );
-
- // PenpalWestendA::execute_with(|| {
- // assert_ok!(::PolkadotXcm::send(
- // root_origin,
- // bx!(system_para_destination),
- // bx!(xcm),
- // ));
-
- // PenpalWestendA::assert_xcm_pallet_sent();
- // });
-
- // AssetHubWestend::execute_with(|| {
- // type RuntimeEvent = ::RuntimeEvent;
-
- // AssetHubWestend::assert_xcmp_queue_success(Some(Weight::from_parts(
- // 2_176_414_000,
- // 203_593,
- // )));
-
- // assert_expected_events!(
- // AssetHubWestend,
- // vec![
- // RuntimeEvent::Assets(pallet_assets::Event::Burned { asset_id, owner, balance }) => {
- // asset_id: *asset_id == ASSET_ID,
- // owner: *owner == para_sovereign_account,
- // balance: *balance == fee_amount,
- // },
- // RuntimeEvent::Assets(pallet_assets::Event::Issued { asset_id, .. }) => {
- // asset_id: *asset_id == ASSET_ID,
- // },
- // ]
- // );
- // });
+ let para_sovereign_account = AssetHubWestend::sovereign_account_id_of(
+ AssetHubWestend::sibling_location_of(PenpalWestendA::para_id()),
+ );
+
+ // Force create and mint assets for Parachain's sovereign account
+ AssetHubWestend::force_create_and_mint_asset(
+ ASSET_ID,
+ ASSET_MIN_BALANCE,
+ true,
+ para_sovereign_account.clone(),
+ ASSET_MIN_BALANCE * 1000000000,
+ );
+
+ // We just need a call that can pass the `SafeCallFilter`
+ // Call values are not relevant
+ let call = AssetHubWestend::force_create_asset_call(
+ ASSET_ID,
+ para_sovereign_account.clone(),
+ true,
+ ASSET_MIN_BALANCE,
+ );
+
+ let origin_kind = OriginKind::SovereignAccount;
+ let fee_amount = ASSET_MIN_BALANCE * 1000000;
+ let native_asset =
+ (X2(PalletInstance(ASSETS_PALLET_ID), GeneralIndex(ASSET_ID.into())), fee_amount).into();
+
+ let root_origin = ::RuntimeOrigin::root();
+ let system_para_destination =
+ PenpalWestendA::sibling_location_of(AssetHubWestend::para_id()).into();
+ let xcm = xcm_transact_paid_execution(
+ call,
+ origin_kind,
+ native_asset,
+ para_sovereign_account.clone(),
+ );
+
+ PenpalWestendA::execute_with(|| {
+ assert_ok!(::PolkadotXcm::send(
+ root_origin,
+ bx!(system_para_destination),
+ bx!(xcm),
+ ));
+
+ PenpalWestendA::assert_xcm_pallet_sent();
+ });
+
+ AssetHubWestend::execute_with(|| {
+ type RuntimeEvent = ::RuntimeEvent;
+
+ AssetHubWestend::assert_xcmp_queue_success(Some(Weight::from_parts(
+ 2_176_414_000,
+ 203_593,
+ )));
+
+ assert_expected_events!(
+ AssetHubWestend,
+ vec![
+ RuntimeEvent::Assets(pallet_assets::Event::Burned { asset_id, owner, balance }) => {
+ asset_id: *asset_id == ASSET_ID,
+ owner: *owner == para_sovereign_account,
+ balance: *balance == fee_amount,
+ },
+ RuntimeEvent::Assets(pallet_assets::Event::Issued { asset_id, .. }) => {
+ asset_id: *asset_id == ASSET_ID,
+ },
+ ]
+ );
+ });
}
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/set_xcm_versions.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/set_xcm_versions.rs
index 76e38083659edf13efeba34c288c55909647dbb7..2720095aac00d5d15c43e77224b30b7387079897 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/set_xcm_versions.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/set_xcm_versions.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
use crate::*;
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/swap.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/swap.rs
index 03ac75146089976b8a4402e3918caaa9789f8c39..7d1615c9e29182c97146ca46c966f0ae85991b11 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/swap.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/swap.rs
@@ -1,3 +1,18 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
use crate::*;
#[test]
@@ -155,11 +170,9 @@ fn swap_locally_on_chain_using_foreign_assets() {
.encode()
.into();
- let buy_execution_fee_amount =
- asset_hub_westend_runtime::constants::fee::WeightToFee::weight_to_fee(&Weight::from_parts(
- 10_100_000_000_000,
- 300_000,
- ));
+ let buy_execution_fee_amount = parachains_common::westend::fee::WeightToFee::weight_to_fee(
+ &Weight::from_parts(10_100_000_000_000, 300_000),
+ );
let buy_execution_fee = MultiAsset {
id: Concrete(MultiLocation { parents: 1, interior: Here }),
fun: Fungible(buy_execution_fee_amount),
diff --git a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/teleport.rs b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/teleport.rs
index 17f204f38077d65f8cfb8066d51b24f432f49192..8de73a7420c6b69954b2fe295a3b5f6bf4e7219c 100644
--- a/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/teleport.rs
+++ b/cumulus/parachains/integration-tests/emulated/assets/asset-hub-westend/src/tests/teleport.rs
@@ -1,18 +1,17 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
#![allow(dead_code)] //
@@ -187,7 +186,6 @@ fn limited_teleport_native_assets_from_relay_to_system_para_works() {
/// Limited Teleport of native asset from System Parachain to Relay Chain
/// should work when there is enough balance in Relay Chain's `CheckAccount`
#[test]
-#[cfg(feature = "FIXME-IGNORED")] //
fn limited_teleport_native_assets_back_from_system_para_to_relay_works() {
// Dependency - Relay Chain's `CheckAccount` should have enough balance
limited_teleport_native_assets_from_relay_to_system_para_works();
@@ -226,7 +224,6 @@ fn limited_teleport_native_assets_back_from_system_para_to_relay_works() {
/// Limited Teleport of native asset from System Parachain to Relay Chain
/// should't work when there is not enough balance in Relay Chain's `CheckAccount`
#[test]
-#[cfg(feature = "FIXME-IGNORED")] //
fn limited_teleport_native_assets_from_system_para_to_relay_fails() {
// Init values for Relay Chain
let amount_to_send: Balance = ASSET_HUB_WESTEND_ED * 1000;
diff --git a/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/Cargo.toml b/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/Cargo.toml
index e81e7a1948996075da31bb58750df7a7d39095b9..ee6896855549286c1a49fcc47d4d9d362a09fdd2 100644
--- a/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/Cargo.toml
+++ b/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/Cargo.toml
@@ -3,6 +3,7 @@ name = "bridge-hub-rococo-integration-tests"
version = "1.0.0"
authors.workspace = true
edition.workspace = true
+license = "Apache-2.0"
description = "Bridge Hub Rococo runtime integration tests with xcm-emulator"
publish = false
@@ -10,27 +11,20 @@ publish = false
codec = { package = "parity-scale-codec", version = "3.4.0", default-features = false }
# Substrate
-sp-runtime = { path = "../../../../../../substrate/primitives/runtime", default-features = false}
frame-support = { path = "../../../../../../substrate/frame/support", default-features = false}
-frame-system = { path = "../../../../../../substrate/frame/system", default-features = false}
-sp-core = { path = "../../../../../../substrate/primitives/core", default-features = false}
-sp-weights = { path = "../../../../../../substrate/primitives/weights", default-features = false}
-pallet-balances = { path = "../../../../../../substrate/frame/balances", default-features = false}
-pallet-assets = { path = "../../../../../../substrate/frame/assets", default-features = false}
# Polkadot
polkadot-core-primitives = { path = "../../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-parachains = { path = "../../../../../../polkadot/runtime/parachains" }
polkadot-runtime = { path = "../../../../../../polkadot/runtime/polkadot" }
-xcm = { path = "../../../../../../polkadot/xcm", default-features = false}
-xcm-executor = { path = "../../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../../polkadot/xcm", default-features = false}
pallet-xcm = { path = "../../../../../../polkadot/xcm/pallet-xcm", default-features = false}
# Cumulus
parachains-common = { path = "../../../../common" }
cumulus-pallet-xcmp-queue = { path = "../../../../../pallets/xcmp-queue", default-features = false}
-cumulus-pallet-parachain-system = { path = "../../../../../pallets/parachain-system" }
+cumulus-pallet-dmp-queue = { path = "../../../../../pallets/dmp-queue", default-features = false}
pallet-bridge-messages = { path = "../../../../../bridges/modules/messages", default-features = false}
bp-messages = { path = "../../../../../bridges/primitives/messages", default-features = false}
diff --git a/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/lib.rs b/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/lib.rs
index 2a4927d857c366a513307585620c8586e1d9f8e0..122d65461159d90a84888b792f35e89decf7c5be 100644
--- a/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/lib.rs
+++ b/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/lib.rs
@@ -1,62 +1,40 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
pub use bp_messages::LaneId;
-pub use codec::Encode;
-pub use frame_support::{
- assert_err, assert_ok,
- instances::Instance1,
- pallet_prelude::Weight,
- sp_runtime::{AccountId32, DispatchError, DispatchResult, MultiAddress},
- traits::{fungibles::Inspect, OriginTrait},
-};
+pub use frame_support::assert_ok;
pub use integration_tests_common::{
constants::{
- accounts::{ALICE, BOB},
- asset_hub_kusama::ED as ASSET_HUB_ROCOCO_ED,
- kusama::ED as ROCOCO_ED,
- PROOF_SIZE_THRESHOLD, REF_TIME_THRESHOLD, XCM_V3,
+ asset_hub_kusama::ED as ASSET_HUB_ROCOCO_ED, kusama::ED as ROCOCO_ED, PROOF_SIZE_THRESHOLD,
+ REF_TIME_THRESHOLD, XCM_V3,
},
- lazy_static::lazy_static,
- xcm_transact_paid_execution, xcm_transact_unpaid_execution, AssetHubRococo,
- AssetHubRococoPallet, AssetHubRococoReceiver, AssetHubRococoSender, AssetHubWococo,
- AssetHubWococoPallet, AssetHubWococoReceiver, AssetHubWococoSender, BridgeHubRococo,
- BridgeHubRococoPallet, BridgeHubRococoReceiver, BridgeHubRococoSender, BridgeHubWococo,
- BridgeHubWococoPallet, BridgeHubWococoReceiver, BridgeHubWococoSender, Collectives,
- CollectivesPallet, CollectivesReceiver, CollectivesSender, PenpalRococoA, PenpalRococoAPallet,
- PenpalRococoAReceiver, PenpalRococoASender, Rococo, RococoMockNet, RococoPallet,
- RococoReceiver, RococoSender, Wococo, WococoMockNet, WococoPallet, WococoReceiver,
- WococoSender,
+ xcm_helpers::{xcm_transact_paid_execution, xcm_transact_unpaid_execution},
+ AssetHubRococo, AssetHubRococoReceiver, AssetHubWococo, BridgeHubRococo, BridgeHubWococo,
+ PenpalRococoA, Rococo, RococoPallet,
};
pub use parachains_common::{AccountId, Balance};
-pub use polkadot_core_primitives::InboundDownwardMessage;
-pub use polkadot_parachain::primitives::{HrmpChannelId, Id};
-pub use polkadot_runtime_parachains::inclusion::{AggregateMessageOrigin, UmpQueueId};
pub use xcm::{
- prelude::*,
+ prelude::{AccountId32 as AccountId32Junction, *},
v3::{
Error,
NetworkId::{Rococo as RococoId, Wococo as WococoId},
},
- DoubleEncoded,
};
pub use xcm_emulator::{
- assert_expected_events, bx, cumulus_pallet_dmp_queue, helpers::weight_within_threshold,
- AccountId32Junction, Chain, ParaId, Parachain as Para, RelayChain as Relay, Test, TestArgs,
- TestContext, TestExt, TestExternalities,
+ assert_expected_events, bx, helpers::weight_within_threshold, Chain, Parachain as Para,
+ RelayChain as Relay, Test, TestArgs, TestContext, TestExt,
};
pub const ASSET_ID: u32 = 1;
@@ -85,4 +63,5 @@ pub fn relay_test_args(amount: Balance) -> TestArgs {
}
#[cfg(test)]
+#[cfg(not(feature = "runtime-benchmarks"))]
mod tests;
diff --git a/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/tests/example.rs b/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/tests/example.rs
index 1293f65929a886b02d7d2080c12ea009dc15a13d..f24e13bb71b875d8d68be161e5dc833198f93c39 100644
--- a/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/tests/example.rs
+++ b/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/tests/example.rs
@@ -1,98 +1,98 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
-// Cumulus 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 Cumulus. If not, see .
+use crate::*;
#[test]
-#[ignore]
fn example() {
- // // Init tests variables
- // // XcmPallet send arguments
- // let sudo_origin = ::RuntimeOrigin::root();
- // let destination = Rococo::child_location_of(BridgeHubRococo::para_id()).into();
- // let weight_limit = WeightLimit::Unlimited;
- // let check_origin = None;
+ // Init tests variables
+ // XcmPallet send arguments
+ let sudo_origin = ::RuntimeOrigin::root();
+ let destination = Rococo::child_location_of(BridgeHubRococo::para_id()).into();
+ let weight_limit = WeightLimit::Unlimited;
+ let check_origin = None;
- // let remote_xcm = Xcm(vec![ClearOrigin]);
+ let remote_xcm = Xcm(vec![ClearOrigin]);
- // let xcm = VersionedXcm::from(Xcm(vec![
- // UnpaidExecution { weight_limit, check_origin },
- // ExportMessage {
- // network: WococoId,
- // destination: X1(Parachain(AssetHubWococo::para_id().into())),
- // xcm: remote_xcm,
- // },
- // ]));
+ let xcm = VersionedXcm::from(Xcm(vec![
+ UnpaidExecution { weight_limit, check_origin },
+ ExportMessage {
+ network: WococoId,
+ destination: X1(Parachain(AssetHubWococo::para_id().into())),
+ xcm: remote_xcm,
+ },
+ ]));
- // //Rococo Global Consensus
- // // Send XCM message from Relay Chain to Bridge Hub source Parachain
- // Rococo::execute_with(|| {
- // assert_ok!(::XcmPallet::send(
- // sudo_origin,
- // bx!(destination),
- // bx!(xcm),
- // ));
+ //Rococo Global Consensus
+ // Send XCM message from Relay Chain to Bridge Hub source Parachain
+ Rococo::execute_with(|| {
+ assert_ok!(::XcmPallet::send(
+ sudo_origin,
+ bx!(destination),
+ bx!(xcm),
+ ));
- // type RuntimeEvent = ::RuntimeEvent;
+ type RuntimeEvent = ::RuntimeEvent;
- // assert_expected_events!(
- // Rococo,
- // vec![
- // RuntimeEvent::XcmPallet(pallet_xcm::Event::Sent { .. }) => {},
- // ]
- // );
- // });
- // // Receive XCM message in Bridge Hub source Parachain
- // BridgeHubRococo::execute_with(|| {
- // type RuntimeEvent = ::RuntimeEvent;
+ assert_expected_events!(
+ Rococo,
+ vec![
+ RuntimeEvent::XcmPallet(pallet_xcm::Event::Sent { .. }) => {},
+ ]
+ );
+ });
+ // Receive XCM message in Bridge Hub source Parachain
+ BridgeHubRococo::execute_with(|| {
+ type RuntimeEvent = ::RuntimeEvent;
- // assert_expected_events!(
- // BridgeHubRococo,
- // vec![
- // RuntimeEvent::DmpQueue(cumulus_pallet_dmp_queue::Event::ExecutedDownward {
- // outcome: Outcome::Complete(_),
- // ..
- // }) => {},
- // RuntimeEvent::BridgeWococoMessages(pallet_bridge_messages::Event::MessageAccepted {
- // lane_id: LaneId([0, 0, 0, 1]),
- // nonce: 1,
- // }) => {},
- // ]
- // );
- // });
+ assert_expected_events!(
+ BridgeHubRococo,
+ vec![
+ RuntimeEvent::DmpQueue(cumulus_pallet_dmp_queue::Event::ExecutedDownward {
+ outcome: Outcome::Complete(_),
+ ..
+ }) => {},
+ RuntimeEvent::BridgeWococoMessages(pallet_bridge_messages::Event::MessageAccepted {
+ lane_id: LaneId([0, 0, 0, 1]),
+ nonce: 1,
+ }) => {},
+ ]
+ );
+ });
- // // Wococo GLobal Consensus
- // // Receive XCM message in Bridge Hub target Parachain
- // BridgeHubWococo::execute_with(|| {
- // type RuntimeEvent = ::RuntimeEvent;
+ // Wococo GLobal Consensus
+ // Receive XCM message in Bridge Hub target Parachain
+ BridgeHubWococo::execute_with(|| {
+ type RuntimeEvent = ::RuntimeEvent;
- // assert_expected_events!(
- // BridgeHubWococo,
- // vec![
- // RuntimeEvent::XcmpQueue(cumulus_pallet_xcmp_queue::Event::XcmpMessageSent { .. }) => {},
- // ]
- // );
- // });
- // // Receive embeded XCM message within `ExportMessage` in Parachain destination
- // AssetHubWococo::execute_with(|| {
- // type RuntimeEvent = ::RuntimeEvent;
+ assert_expected_events!(
+ BridgeHubWococo,
+ vec![
+ RuntimeEvent::XcmpQueue(cumulus_pallet_xcmp_queue::Event::XcmpMessageSent { .. }) => {},
+ ]
+ );
+ });
+ // Receive embeded XCM message within `ExportMessage` in Parachain destination
+ AssetHubWococo::execute_with(|| {
+ type RuntimeEvent = ::RuntimeEvent;
- // assert_expected_events!(
- // AssetHubWococo,
- // vec![
- // RuntimeEvent::XcmpQueue(cumulus_pallet_xcmp_queue::Event::Fail { .. }) => {},
- // ]
- // );
- // });
+ assert_expected_events!(
+ AssetHubWococo,
+ vec![
+ RuntimeEvent::XcmpQueue(cumulus_pallet_xcmp_queue::Event::Fail { .. }) => {},
+ ]
+ );
+ });
}
diff --git a/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/tests/mod.rs b/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/tests/mod.rs
index 532e31aa1a67464f501932db1c6684afbb31bb48..48347557ae77df661d8c41726cb3fe7f24738678 100644
--- a/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/tests/mod.rs
+++ b/cumulus/parachains/integration-tests/emulated/bridges/bridge-hub-rococo/src/tests/mod.rs
@@ -1,17 +1,16 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
mod example;
diff --git a/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/Cargo.toml b/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/Cargo.toml
index accb04db7f323ab4753cb9d09a685d46ef5341b5..5a28b12741512be22a6f29c4d6a57bebf7656567 100644
--- a/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/Cargo.toml
+++ b/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/Cargo.toml
@@ -3,6 +3,7 @@ name = "collectives-polkadot-integration-tests"
version = "0.1.0"
authors.workspace = true
edition.workspace = true
+license = "Apache-2.0"
description = "Polkadot Collectives parachain runtime integration tests based on xcm-emulator"
publish = false
@@ -12,21 +13,17 @@ codec = { package = "parity-scale-codec", version = "3.4.0", default-features =
# Substrate
sp-runtime = { path = "../../../../../../substrate/primitives/runtime", default-features = false}
frame-support = { path = "../../../../../../substrate/frame/support", default-features = false}
-frame-system = { path = "../../../../../../substrate/frame/system", default-features = false}
sp-core = { path = "../../../../../../substrate/primitives/core", default-features = false}
-sp-weights = { path = "../../../../../../substrate/primitives/weights", default-features = false}
-pallet-balances = { path = "../../../../../../substrate/frame/balances", default-features = false}
pallet-assets = { path = "../../../../../../substrate/frame/assets", default-features = false}
pallet-core-fellowship = { path = "../../../../../../substrate/frame/core-fellowship", default-features = false}
pallet-salary = { path = "../../../../../../substrate/frame/salary", default-features = false}
# Polkadot
polkadot-core-primitives = { path = "../../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-parachains = { path = "../../../../../../polkadot/runtime/parachains" }
polkadot-runtime = { path = "../../../../../../polkadot/runtime/polkadot" }
-xcm = { path = "../../../../../../polkadot/xcm", default-features = false}
-xcm-executor = { path = "../../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../../polkadot/xcm", default-features = false}
pallet-xcm = { path = "../../../../../../polkadot/xcm/pallet-xcm", default-features = false}
# Cumulus
@@ -34,7 +31,6 @@ parachains-common = { path = "../../../../common" }
cumulus-pallet-xcmp-queue = { path = "../../../../../pallets/xcmp-queue", default-features = false}
cumulus-pallet-parachain-system = { path = "../../../../../pallets/parachain-system" }
collectives-polkadot-runtime = { path = "../../../../runtimes/collectives/collectives-polkadot" }
-asset-hub-polkadot-runtime = { path = "../../../../runtimes/assets/asset-hub-polkadot" }
# Local
xcm-emulator = { path = "../../../../../xcm/xcm-emulator", default-features = false}
diff --git a/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/lib.rs b/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/lib.rs
index b71ee65a22217c0ffc524f14fc5e90d9ce37e5b9..aa716c7c94855acb016056733bcd6111fa8b5599 100644
--- a/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/lib.rs
+++ b/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/lib.rs
@@ -1,56 +1,37 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
pub use codec::Encode;
-pub use frame_support::{
- assert_err, assert_ok,
- instances::Instance1,
- pallet_prelude::Weight,
- sp_runtime::{AccountId32, DispatchError, DispatchResult, MultiAddress},
- traits::{fungibles::Inspect, OriginTrait},
-};
+pub use frame_support::{assert_ok, sp_runtime::AccountId32};
pub use integration_tests_common::{
constants::{
- accounts::{ALICE, BOB},
- asset_hub_polkadot::ED as ASSET_HUB_POLKADOT_ED,
- polkadot::ED as POLKADOT_ED,
- PROOF_SIZE_THRESHOLD, REF_TIME_THRESHOLD, XCM_V3,
+ accounts::ALICE, asset_hub_polkadot::ED as ASSET_HUB_POLKADOT_ED,
+ polkadot::ED as POLKADOT_ED, PROOF_SIZE_THRESHOLD, REF_TIME_THRESHOLD, XCM_V3,
},
- lazy_static::lazy_static,
- xcm_transact_paid_execution, xcm_transact_unpaid_execution, AssetHubPolkadot,
- AssetHubPolkadotPallet, AssetHubPolkadotReceiver, AssetHubPolkadotSender, BridgeHubPolkadot,
- BridgeHubPolkadotPallet, BridgeHubPolkadotReceiver, BridgeHubPolkadotSender, Collectives,
- CollectivesPallet, CollectivesReceiver, CollectivesSender, PenpalPolkadotA,
- PenpalPolkadotAPallet, PenpalPolkadotAReceiver, PenpalPolkadotASender, PenpalPolkadotB,
- PenpalPolkadotBPallet, PenpalPolkadotBReceiver, PenpalPolkadotBSender, Polkadot,
- PolkadotMockNet, PolkadotPallet, PolkadotReceiver, PolkadotSender,
+ xcm_helpers::{xcm_transact_paid_execution, xcm_transact_unpaid_execution},
+ AssetHubPolkadot, AssetHubPolkadotPallet, AssetHubPolkadotReceiver, Collectives,
+ PenpalPolkadotA, Polkadot,
};
pub use parachains_common::{AccountId, Balance};
-pub use polkadot_core_primitives::InboundDownwardMessage;
-pub use polkadot_parachain::primitives::{HrmpChannelId, Id};
-pub use polkadot_runtime_parachains::inclusion::{AggregateMessageOrigin, UmpQueueId};
pub use xcm::{
- prelude::*,
+ prelude::{AccountId32 as AccountId32Junction, *},
v3::{Error, NetworkId::Polkadot as PolkadotId},
- DoubleEncoded,
};
pub use xcm_emulator::{
- assert_expected_events, bx, cumulus_pallet_dmp_queue, helpers::weight_within_threshold,
- AccountId32Junction, Chain, ParaId, Parachain as Para, RelayChain as Relay, Test, TestArgs,
- TestContext, TestExt, TestExternalities,
+ assert_expected_events, bx, helpers::weight_within_threshold, Chain, ParaId, Parachain as Para,
+ RelayChain as Relay, Test, TestArgs, TestContext, TestExt, TestExternalities,
};
pub const ASSET_ID: u32 = 1;
@@ -98,4 +79,5 @@ pub fn system_para_test_args(
}
#[cfg(test)]
+#[cfg(not(feature = "runtime-benchmarks"))]
mod tests;
diff --git a/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/tests/fellowship.rs b/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/tests/fellowship.rs
index a6d16a273b79122765766dbbe803a79cd35e0fa4..c08a660205f6829ed50b5643ab191b4c3005ce73 100644
--- a/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/tests/fellowship.rs
+++ b/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/tests/fellowship.rs
@@ -1,69 +1,75 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
//! Integration tests concerning the Fellowship.
+use crate::*;
+use collectives_polkadot_runtime::fellowship::FellowshipSalaryPaymaster;
+use frame_support::traits::{
+ fungibles::{Create, Mutate},
+ tokens::Pay,
+};
+use sp_core::crypto::Ss58Codec;
+use xcm_emulator::TestExt;
+
#[test]
-#[ignore]
fn pay_salary() {
- // let asset_id: u32 = 1984;
- // let pay_from: AccountId =
- // ::from_string("13w7NdvSR1Af8xsQTArDtZmVvjE8XhWNdL4yed3iFHrUNCnS")
- // .unwrap();
- // let pay_to = Polkadot::account_id_of(ALICE);
- // let pay_amount = 9000;
-
- // AssetHubPolkadot::execute_with(|| {
- // type AssetHubAssets = ::Assets;
+ let asset_id: u32 = 1984;
+ let pay_from: AccountId =
+ ::from_string("13w7NdvSR1Af8xsQTArDtZmVvjE8XhWNdL4yed3iFHrUNCnS")
+ .unwrap();
+ let pay_to = Polkadot::account_id_of(ALICE);
+ let pay_amount = 9000;
- // assert_ok!(>::create(
- // asset_id,
- // pay_to.clone(),
- // true,
- // pay_amount / 2
- // ));
- // assert_ok!(>::mint_into(asset_id, &pay_from, pay_amount * 2));
- // });
+ AssetHubPolkadot::execute_with(|| {
+ type AssetHubAssets = ::Assets;
- // Collectives::execute_with(|| {
- // type RuntimeEvent = ::RuntimeEvent;
+ assert_ok!(>::create(
+ asset_id,
+ pay_to.clone(),
+ true,
+ pay_amount / 2
+ ));
+ assert_ok!(>::mint_into(asset_id, &pay_from, pay_amount * 2));
+ });
- // assert_ok!(FellowshipSalaryPaymaster::pay(&pay_to, (), pay_amount));
- // assert_expected_events!(
- // Collectives,
- // vec![
- // RuntimeEvent::XcmpQueue(cumulus_pallet_xcmp_queue::Event::XcmpMessageSent { .. }) => {},
- // ]
- // );
- // });
+ Collectives::execute_with(|| {
+ type RuntimeEvent = ::RuntimeEvent;
- // AssetHubPolkadot::execute_with(|| {
- // type RuntimeEvent = ::RuntimeEvent;
+ assert_ok!(FellowshipSalaryPaymaster::pay(&pay_to, (), pay_amount));
+ assert_expected_events!(
+ Collectives,
+ vec![
+ RuntimeEvent::XcmpQueue(cumulus_pallet_xcmp_queue::Event::XcmpMessageSent { .. }) => {},
+ ]
+ );
+ });
- // assert_expected_events!(
- // AssetHubPolkadot,
- // vec![
- // RuntimeEvent::Assets(pallet_assets::Event::Transferred { asset_id: id, from, to, amount }) =>
- // { asset_id: id == &asset_id,
- // from: from == &pay_from,
- // to: to == &pay_to,
- // amount: amount == &pay_amount,
- // },
- // RuntimeEvent::XcmpQueue(cumulus_pallet_xcmp_queue::Event::Success { .. }) => {},
- // ]
- // );
- // });
+ AssetHubPolkadot::execute_with(|| {
+ type RuntimeEvent = ::RuntimeEvent;
+ assert_expected_events!(
+ AssetHubPolkadot,
+ vec![
+ RuntimeEvent::Assets(pallet_assets::Event::Transferred { asset_id: id, from, to, amount }) =>
+ { asset_id: id == &asset_id,
+ from: from == &pay_from,
+ to: to == &pay_to,
+ amount: amount == &pay_amount,
+ },
+ RuntimeEvent::XcmpQueue(cumulus_pallet_xcmp_queue::Event::Success { .. }) => {},
+ ]
+ );
+ });
}
diff --git a/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/tests/mod.rs b/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/tests/mod.rs
index 1ede78b59799056cf4b74386e3aa56ee57b0f53e..fb3e235a25cd48602975355abb713e39297b5aab 100644
--- a/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/tests/mod.rs
+++ b/cumulus/parachains/integration-tests/emulated/collectives/collectives-polkadot/src/tests/mod.rs
@@ -1,17 +1,16 @@
-// Copyright Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
-// Cumulus 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.
-
-// Cumulus 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 Cumulus. If not, see .
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
mod fellowship;
diff --git a/cumulus/parachains/integration-tests/emulated/common/Cargo.toml b/cumulus/parachains/integration-tests/emulated/common/Cargo.toml
index e14969deeab46dd840b5cd615bd47286b0876a73..ac1e650d5de7b2b10a6ed3e6954397986f5d9d1d 100644
--- a/cumulus/parachains/integration-tests/emulated/common/Cargo.toml
+++ b/cumulus/parachains/integration-tests/emulated/common/Cargo.toml
@@ -3,12 +3,12 @@ name = "integration-tests-common"
version = "1.0.0"
authors.workspace = true
edition.workspace = true
+license = "Apache-2.0"
description = "Common resources for integration testing with xcm-emulator"
publish = false
[dependencies]
codec = { package = "parity-scale-codec", version = "3.4.0", default-features = false }
-lazy_static = "1.4.0"
paste = "1.0.14"
# Substrate
@@ -16,12 +16,8 @@ grandpa = { package = "sc-consensus-grandpa", path = "../../../../../substrate/c
sp-authority-discovery = { path = "../../../../../substrate/primitives/authority-discovery", default-features = false}
sp-runtime = { path = "../../../../../substrate/primitives/runtime", default-features = false}
frame-support = { path = "../../../../../substrate/frame/support", default-features = false}
-frame-system = { path = "../../../../../substrate/frame/system", default-features = false}
sp-core = { path = "../../../../../substrate/primitives/core", default-features = false}
-sp-weights = { path = "../../../../../substrate/primitives/weights", default-features = false}
sp-consensus-babe = { path = "../../../../../substrate/primitives/consensus/babe", default-features = false}
-sp-tracing = { path = "../../../../../substrate/primitives/tracing" }
-pallet-balances = { path = "../../../../../substrate/frame/balances", default-features = false}
pallet-assets = { path = "../../../../../substrate/frame/assets", default-features = false}
pallet-staking = { path = "../../../../../substrate/frame/staking", default-features = false}
pallet-message-queue = { path = "../../../../../substrate/frame/message-queue", default-features = false}
@@ -30,25 +26,23 @@ beefy-primitives = { package = "sp-consensus-beefy", path = "../../../../../subs
# Polkadot
polkadot-core-primitives = { path = "../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
polkadot-service = { path = "../../../../../polkadot/node/service", default-features = false, features = ["full-node"] }
polkadot-primitives = { path = "../../../../../polkadot/primitives", default-features = false}
polkadot-runtime-parachains = { path = "../../../../../polkadot/runtime/parachains" }
polkadot-runtime = { path = "../../../../../polkadot/runtime/polkadot" }
polkadot-runtime-constants = { path = "../../../../../polkadot/runtime/polkadot/constants" }
-kusama-runtime = { path = "../../../../../polkadot/runtime/kusama" }
+kusama-runtime = { package = "staging-kusama-runtime", path = "../../../../../polkadot/runtime/kusama" }
kusama-runtime-constants = { path = "../../../../../polkadot/runtime/kusama/constants" }
rococo-runtime = { path = "../../../../../polkadot/runtime/rococo" }
rococo-runtime-constants = { path = "../../../../../polkadot/runtime/rococo/constants" }
westend-runtime = { path = "../../../../../polkadot/runtime/westend" }
westend-runtime-constants = { path = "../../../../../polkadot/runtime/westend/constants" }
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
# Cumulus
parachains-common = { path = "../../../common" }
-parachain-info = { path = "../../../pallets/parachain-info" }
cumulus-primitives-core = { path = "../../../../primitives/core" }
penpal-runtime = { path = "../../../runtimes/testing/penpal" }
asset-hub-polkadot-runtime = { path = "../../../runtimes/assets/asset-hub-polkadot" }
@@ -63,7 +57,6 @@ cumulus-pallet-dmp-queue = { path = "../../../../pallets/dmp-queue" }
cumulus-pallet-xcmp-queue = { path = "../../../../pallets/xcmp-queue", default-features = false}
cumulus-pallet-parachain-system = { path = "../../../../pallets/parachain-system" }
bp-messages = { path = "../../../../bridges/primitives/messages" }
-bp-runtime = { path = "../../../../bridges/primitives/runtime" }
pallet-bridge-messages = { path = "../../../../bridges/modules/messages" }
bridge-runtime-common = { path = "../../../../bridges/bin/runtime-common" }
@@ -80,17 +73,15 @@ runtime-benchmarks = [
"cumulus-pallet-parachain-system/runtime-benchmarks",
"cumulus-pallet-xcmp-queue/runtime-benchmarks",
"frame-support/runtime-benchmarks",
- "frame-system/runtime-benchmarks",
"kusama-runtime/runtime-benchmarks",
"pallet-assets/runtime-benchmarks",
- "pallet-balances/runtime-benchmarks",
"pallet-bridge-messages/runtime-benchmarks",
"pallet-im-online/runtime-benchmarks",
"pallet-message-queue/runtime-benchmarks",
"pallet-staking/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
"penpal-runtime/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"polkadot-primitives/runtime-benchmarks",
"polkadot-runtime-parachains/runtime-benchmarks",
"polkadot-runtime/runtime-benchmarks",
@@ -98,5 +89,4 @@ runtime-benchmarks = [
"rococo-runtime/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
"westend-runtime/runtime-benchmarks",
- "xcm-executor/runtime-benchmarks",
]
diff --git a/cumulus/parachains/integration-tests/emulated/common/src/constants.rs b/cumulus/parachains/integration-tests/emulated/common/src/constants.rs
index 3eb65fa26c162833a2a5eecafc1d68e47baa6444..8725ebd140b97272630430de324177bf5cae1484 100644
--- a/cumulus/parachains/integration-tests/emulated/common/src/constants.rs
+++ b/cumulus/parachains/integration-tests/emulated/common/src/constants.rs
@@ -1,14 +1,22 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Substrate
use beefy_primitives::ecdsa_crypto::AuthorityId as BeefyId;
use grandpa::AuthorityId as GrandpaId;
use pallet_im_online::sr25519::AuthorityId as ImOnlineId;
-use parachains_common::{AccountId, AssetHubPolkadotAuraId, AuraId, Balance, BlockNumber};
-use polkadot_parachain::primitives::{HeadData, ValidationCode};
-use polkadot_primitives::{AssignmentId, ValidatorId};
-use polkadot_runtime_parachains::{
- configuration::HostConfiguration,
- paras::{ParaGenesisArgs, ParaKind},
-};
-use polkadot_service::chain_spec::get_authority_keys_from_seed_no_beefy;
use sp_authority_discovery::AuthorityId as AuthorityDiscoveryId;
use sp_consensus_babe::AuthorityId as BabeId;
use sp_core::{sr25519, storage::Storage, Pair, Public};
@@ -16,6 +24,16 @@ use sp_runtime::{
traits::{IdentifyAccount, Verify},
BuildStorage, MultiSignature, Perbill,
};
+
+// Cumulus
+use parachains_common::{AccountId, AssetHubPolkadotAuraId, AuraId, Balance, BlockNumber};
+use polkadot_parachain_primitives::primitives::{HeadData, ValidationCode};
+use polkadot_primitives::{AssignmentId, ValidatorId};
+use polkadot_runtime_parachains::{
+ configuration::HostConfiguration,
+ paras::{ParaGenesisArgs, ParaKind},
+};
+use polkadot_service::chain_spec::get_authority_keys_from_seed_no_beefy;
use xcm;
pub const XCM_V2: u32 = 3;
@@ -613,7 +631,7 @@ pub mod rococo {
pub mod asset_hub_polkadot {
use super::*;
pub const PARA_ID: u32 = 1000;
- pub const ED: Balance = asset_hub_polkadot_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ pub const ED: Balance = parachains_common::polkadot::currency::EXISTENTIAL_DEPOSIT;
pub fn genesis() -> Storage {
let genesis_config = asset_hub_polkadot_runtime::RuntimeGenesisConfig {
@@ -670,7 +688,7 @@ pub mod asset_hub_polkadot {
pub mod asset_hub_westend {
use super::*;
pub const PARA_ID: u32 = 1000;
- pub const ED: Balance = asset_hub_westend_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ pub const ED: Balance = parachains_common::westend::currency::EXISTENTIAL_DEPOSIT;
pub fn genesis() -> Storage {
let genesis_config = asset_hub_westend_runtime::RuntimeGenesisConfig {
@@ -727,7 +745,7 @@ pub mod asset_hub_westend {
pub mod asset_hub_kusama {
use super::*;
pub const PARA_ID: u32 = 1000;
- pub const ED: Balance = asset_hub_kusama_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ pub const ED: Balance = parachains_common::kusama::currency::EXISTENTIAL_DEPOSIT;
pub fn genesis() -> Storage {
let genesis_config = asset_hub_kusama_runtime::RuntimeGenesisConfig {
@@ -845,7 +863,7 @@ pub mod penpal {
pub mod collectives {
use super::*;
pub const PARA_ID: u32 = 1001;
- pub const ED: Balance = collectives_polkadot_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ pub const ED: Balance = parachains_common::polkadot::currency::EXISTENTIAL_DEPOSIT;
pub fn genesis() -> Storage {
let genesis_config = collectives_polkadot_runtime::RuntimeGenesisConfig {
@@ -902,7 +920,7 @@ pub mod collectives {
pub mod bridge_hub_kusama {
use super::*;
pub const PARA_ID: u32 = 1002;
- pub const ED: Balance = bridge_hub_kusama_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ pub const ED: Balance = parachains_common::kusama::currency::EXISTENTIAL_DEPOSIT;
pub fn genesis() -> Storage {
let genesis_config = bridge_hub_kusama_runtime::RuntimeGenesisConfig {
@@ -959,7 +977,7 @@ pub mod bridge_hub_kusama {
pub mod bridge_hub_polkadot {
use super::*;
pub const PARA_ID: u32 = 1002;
- pub const ED: Balance = bridge_hub_polkadot_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ pub const ED: Balance = parachains_common::polkadot::currency::EXISTENTIAL_DEPOSIT;
pub fn genesis() -> Storage {
let genesis_config = bridge_hub_polkadot_runtime::RuntimeGenesisConfig {
@@ -1016,7 +1034,7 @@ pub mod bridge_hub_polkadot {
pub mod bridge_hub_rococo {
use super::*;
pub const PARA_ID: u32 = 1013;
- pub const ED: Balance = bridge_hub_rococo_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ pub const ED: Balance = parachains_common::rococo::currency::EXISTENTIAL_DEPOSIT;
pub fn genesis() -> Storage {
let genesis_config = bridge_hub_rococo_runtime::RuntimeGenesisConfig {
diff --git a/cumulus/parachains/integration-tests/emulated/common/src/impls.rs b/cumulus/parachains/integration-tests/emulated/common/src/impls.rs
index 92c68f4dd6133ac5b577cbfdeee57814851d9662..eed61d94171107a278e13b8fca8ba9a94a547f21 100644
--- a/cumulus/parachains/integration-tests/emulated/common/src/impls.rs
+++ b/cumulus/parachains/integration-tests/emulated/common/src/impls.rs
@@ -1,15 +1,63 @@
-use super::{BridgeHubRococo, BridgeHubWococo};
-// pub use paste;
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+pub use codec::{Decode, Encode};
+pub use paste;
+
+pub use crate::{
+ constants::{PROOF_SIZE_THRESHOLD, REF_TIME_THRESHOLD},
+ xcm_helpers::xcm_transact_unpaid_execution,
+ BridgeHubRococo, BridgeHubWococo,
+};
+
+// Substrate
+pub use frame_support::{assert_ok, traits::fungibles::Inspect};
+pub use pallet_assets;
+pub use pallet_message_queue;
+use sp_core::Get;
+
+// Cumulus
use bp_messages::{
target_chain::{DispatchMessage, DispatchMessageData, MessageDispatch},
LaneId, MessageKey, OutboundLaneData,
};
use bridge_runtime_common::messages_xcm_extension::XcmBlobMessageDispatchResult;
-use codec::Decode;
-pub use cumulus_primitives_core::{DmpMessageHandler, XcmpMessageHandler};
+pub use cumulus_pallet_dmp_queue;
+pub use cumulus_pallet_parachain_system;
+pub use cumulus_pallet_xcmp_queue;
+pub use cumulus_primitives_core::{
+ relay_chain::HrmpChannelId, DmpMessageHandler, ParaId, XcmpMessageHandler,
+};
use pallet_bridge_messages::{Config, Instance1, Instance2, OutboundLanes, Pallet};
-use sp_core::Get;
-use xcm_emulator::{BridgeMessage, BridgeMessageDispatchError, BridgeMessageHandler, Chain};
+pub use parachains_common::{AccountId, Balance};
+pub use xcm_emulator::{
+ assert_expected_events, bx, helpers::weight_within_threshold, BridgeMessage,
+ BridgeMessageDispatchError, BridgeMessageHandler, Chain, Parachain, RelayChain, TestExt,
+};
+
+// Polkadot
+pub use pallet_xcm;
+pub use polkadot_runtime_parachains::{
+ dmp, hrmp,
+ inclusion::{AggregateMessageOrigin, UmpQueueId},
+};
+pub use xcm::{
+ prelude::{OriginKind, Outcome, VersionedXcm, Weight},
+ v3::Error,
+ DoubleEncoded,
+};
pub struct BridgeHubMessageHandler {
_marker: std::marker::PhantomData<(S, T, I)>,
@@ -129,14 +177,14 @@ where
#[macro_export]
macro_rules! impl_accounts_helpers_for_relay_chain {
( $chain:ident ) => {
- $crate::paste::paste! {
+ $crate::impls::paste::paste! {
impl $chain {
/// Fund a set of accounts with a balance
- pub fn fund_accounts(accounts: Vec<(AccountId, Balance)>) {
- Self::execute_with(|| {
+ pub fn fund_accounts(accounts: Vec<($crate::impls::AccountId, $crate::impls::Balance)>) {
+ ::execute_with(|| {
for account in accounts {
- assert_ok!(]>::Balances::force_set_balance(
- ::RuntimeOrigin::root(),
+ $crate::impls::assert_ok!(]>::Balances::force_set_balance(
+ ::RuntimeOrigin::root(),
account.0.into(),
account.1,
));
@@ -144,8 +192,8 @@ macro_rules! impl_accounts_helpers_for_relay_chain {
});
}
/// Fund a sovereign account based on its Parachain Id
- pub fn fund_para_sovereign(amount: Balance, para_id: ParaId) -> sp_runtime::AccountId32 {
- let sovereign_account = Self::sovereign_account_id_of_child_para(para_id);
+ pub fn fund_para_sovereign(amount: $crate::impls::Balance, para_id: $crate::impls::ParaId) -> sp_runtime::AccountId32 {
+ let sovereign_account = ::sovereign_account_id_of_child_para(para_id);
Self::fund_accounts(vec![(sovereign_account.clone(), amount)]);
sovereign_account
}
@@ -157,20 +205,20 @@ macro_rules! impl_accounts_helpers_for_relay_chain {
#[macro_export]
macro_rules! impl_assert_events_helpers_for_relay_chain {
( $chain:ident ) => {
- $crate::paste::paste! {
- type [<$chain RuntimeEvent>] = <$chain as Chain>::RuntimeEvent;
+ $crate::impls::paste::paste! {
+ type [<$chain RuntimeEvent>] = <$chain as $crate::impls::Chain>::RuntimeEvent;
impl $chain {
/// Asserts a dispatchable is completely executed and XCM sent
- pub fn assert_xcm_pallet_attempted_complete(expected_weight: Option) {
- assert_expected_events!(
+ pub fn assert_xcm_pallet_attempted_complete(expected_weight: Option<$crate::impls::Weight>) {
+ $crate::impls::assert_expected_events!(
Self,
vec![
[<$chain RuntimeEvent>]::XcmPallet(
- pallet_xcm::Event::Attempted { outcome: Outcome::Complete(weight) }
+ $crate::impls::pallet_xcm::Event::Attempted { outcome: $crate::impls::Outcome::Complete(weight) }
) => {
- weight: weight_within_threshold(
- (REF_TIME_THRESHOLD, PROOF_SIZE_THRESHOLD),
+ weight: $crate::impls::weight_within_threshold(
+ ($crate::impls::REF_TIME_THRESHOLD, $crate::impls::PROOF_SIZE_THRESHOLD),
expected_weight.unwrap_or(*weight),
*weight
),
@@ -181,18 +229,18 @@ macro_rules! impl_assert_events_helpers_for_relay_chain {
/// Asserts a dispatchable is incompletely executed and XCM sent
pub fn assert_xcm_pallet_attempted_incomplete(
- expected_weight: Option,
- expected_error: Option,
+ expected_weight: Option<$crate::impls::Weight>,
+ expected_error: Option<$crate::impls::Error>,
) {
- assert_expected_events!(
+ $crate::impls::assert_expected_events!(
Self,
vec![
// Dispatchable is properly executed and XCM message sent
[<$chain RuntimeEvent>]::XcmPallet(
- pallet_xcm::Event::Attempted { outcome: Outcome::Incomplete(weight, error) }
+ $crate::impls::pallet_xcm::Event::Attempted { outcome: $crate::impls::Outcome::Incomplete(weight, error) }
) => {
- weight: weight_within_threshold(
- (REF_TIME_THRESHOLD, PROOF_SIZE_THRESHOLD),
+ weight: $crate::impls::weight_within_threshold(
+ ($crate::impls::REF_TIME_THRESHOLD, $crate::impls::PROOF_SIZE_THRESHOLD),
expected_weight.unwrap_or(*weight),
*weight
),
@@ -204,10 +252,10 @@ macro_rules! impl_assert_events_helpers_for_relay_chain {
/// Asserts a XCM message is sent
pub fn assert_xcm_pallet_sent() {
- assert_expected_events!(
+ $crate::impls::assert_expected_events!(
Self,
vec![
- [<$chain RuntimeEvent>]::XcmPallet(pallet_xcm::Event::Sent { .. }) => {},
+ [<$chain RuntimeEvent>]::XcmPallet($crate::impls::pallet_xcm::Event::Sent { .. }) => {},
]
);
}
@@ -215,22 +263,22 @@ macro_rules! impl_assert_events_helpers_for_relay_chain {
/// Asserts a XCM from System Parachain is succesfully received and proccessed
pub fn assert_ump_queue_processed(
expected_success: bool,
- expected_id: Option,
- expected_weight: Option,
+ expected_id: Option<$crate::impls::ParaId>,
+ expected_weight: Option<$crate::impls::Weight>,
) {
- assert_expected_events!(
+ $crate::impls::assert_expected_events!(
Self,
vec![
// XCM is succesfully received and proccessed
- [<$chain RuntimeEvent>]::MessageQueue(pallet_message_queue::Event::Processed {
- origin: AggregateMessageOrigin::Ump(UmpQueueId::Para(id)),
+ [<$chain RuntimeEvent>]::MessageQueue($crate::impls::pallet_message_queue::Event::Processed {
+ origin: $crate::impls::AggregateMessageOrigin::Ump($crate::impls::UmpQueueId::Para(id)),
weight_used,
success,
..
}) => {
id: *id == expected_id.unwrap_or(*id),
- weight_used: weight_within_threshold(
- (REF_TIME_THRESHOLD, PROOF_SIZE_THRESHOLD),
+ weight_used: $crate::impls::weight_within_threshold(
+ ($crate::impls::REF_TIME_THRESHOLD, $crate::impls::PROOF_SIZE_THRESHOLD),
expected_weight.unwrap_or(*weight_used),
*weight_used
),
@@ -247,16 +295,18 @@ macro_rules! impl_assert_events_helpers_for_relay_chain {
#[macro_export]
macro_rules! impl_hrmp_channels_helpers_for_relay_chain {
( $chain:ident ) => {
- $crate::paste::paste! {
+ $crate::impls::paste::paste! {
impl $chain {
/// Init open channel request with another Parachain
pub fn init_open_channel_call(
- recipient_para_id: ParaId,
+ recipient_para_id: $crate::impls::ParaId,
max_capacity: u32,
max_message_size: u32,
- ) -> DoubleEncoded<()> {
- ::RuntimeCall::Hrmp(polkadot_runtime_parachains::hrmp::Call::<
- ::Runtime,
+ ) -> $crate::impls::DoubleEncoded<()> {
+ use $crate::impls::Encode;
+
+ ::RuntimeCall::Hrmp($crate::impls::hrmp::Call::<
+ ::Runtime,
>::hrmp_init_open_channel {
recipient: recipient_para_id,
proposed_max_capacity: max_capacity,
@@ -266,9 +316,11 @@ macro_rules! impl_hrmp_channels_helpers_for_relay_chain {
.into()
}
/// Recipient Parachain accept the open request from another Parachain
- pub fn accept_open_channel_call(sender_para_id: ParaId) -> DoubleEncoded<()> {
- ::RuntimeCall::Hrmp(polkadot_runtime_parachains::hrmp::Call::<
- ::Runtime,
+ pub fn accept_open_channel_call(sender_para_id: $crate::impls::ParaId) -> $crate::impls::DoubleEncoded<()> {
+ use $crate::impls::Encode;
+
+ ::RuntimeCall::Hrmp($crate::impls::hrmp::Call::<
+ ::Runtime,
>::hrmp_accept_open_channel {
sender: sender_para_id,
})
@@ -277,19 +329,21 @@ macro_rules! impl_hrmp_channels_helpers_for_relay_chain {
}
/// A root origin force to open a channel between two Parachains
- pub fn force_process_hrmp_open(sender: ParaId, recipient: ParaId) {
- Self::execute_with(|| {
+ pub fn force_process_hrmp_open(sender: $crate::impls::ParaId, recipient: $crate::impls::ParaId) {
+ use $crate::impls::Chain;
+
+ ::execute_with(|| {
let relay_root_origin = ::RuntimeOrigin::root();
// Force process HRMP open channel requests without waiting for the next session
- assert_ok!(]>::Hrmp::force_process_hrmp_open(
+ $crate::impls::assert_ok!(]>::Hrmp::force_process_hrmp_open(
relay_root_origin,
0
));
- let channel_id = HrmpChannelId { sender, recipient };
+ let channel_id = $crate::impls::HrmpChannelId { sender, recipient };
- let hrmp_channel_exist = polkadot_runtime_parachains::hrmp::HrmpChannels::<
+ let hrmp_channel_exist = $crate::impls::hrmp::HrmpChannels::<
::Runtime,
>::contains_key(&channel_id);
@@ -305,14 +359,14 @@ macro_rules! impl_hrmp_channels_helpers_for_relay_chain {
#[macro_export]
macro_rules! impl_accounts_helpers_for_parachain {
( $chain:ident ) => {
- $crate::paste::paste! {
+ $crate::impls::paste::paste! {
impl $chain {
/// Fund a set of accounts with a balance
- pub fn fund_accounts(accounts: Vec<(AccountId, Balance)>) {
- Self::execute_with(|| {
+ pub fn fund_accounts(accounts: Vec<($crate::impls::AccountId, $crate::impls::Balance)>) {
+ ::execute_with(|| {
for account in accounts {
- assert_ok!(]>::Balances::force_set_balance(
- ::RuntimeOrigin::root(),
+ $crate::impls::assert_ok!(]>::Balances::force_set_balance(
+ ::RuntimeOrigin::root(),
account.0.into(),
account.1,
));
@@ -327,20 +381,20 @@ macro_rules! impl_accounts_helpers_for_parachain {
#[macro_export]
macro_rules! impl_assert_events_helpers_for_parachain {
( $chain:ident ) => {
- $crate::paste::paste! {
- type [<$chain RuntimeEvent>] = <$chain as Chain>::RuntimeEvent;
+ $crate::impls::paste::paste! {
+ type [<$chain RuntimeEvent>] = <$chain as $crate::impls::Chain>::RuntimeEvent;
impl $chain {
/// Asserts a dispatchable is completely executed and XCM sent
- pub fn assert_xcm_pallet_attempted_complete(expected_weight: Option) {
- assert_expected_events!(
+ pub fn assert_xcm_pallet_attempted_complete(expected_weight: Option<$crate::impls::Weight>) {
+ $crate::impls::assert_expected_events!(
Self,
vec![
[<$chain RuntimeEvent>]::PolkadotXcm(
- pallet_xcm::Event::Attempted { outcome: Outcome::Complete(weight) }
+ $crate::impls::pallet_xcm::Event::Attempted { outcome: $crate::impls::Outcome::Complete(weight) }
) => {
- weight: weight_within_threshold(
- (REF_TIME_THRESHOLD, PROOF_SIZE_THRESHOLD),
+ weight: $crate::impls::weight_within_threshold(
+ ($crate::impls::REF_TIME_THRESHOLD, $crate::impls::PROOF_SIZE_THRESHOLD),
expected_weight.unwrap_or(*weight),
*weight
),
@@ -351,18 +405,18 @@ macro_rules! impl_assert_events_helpers_for_parachain {
/// Asserts a dispatchable is incompletely executed and XCM sent
pub fn assert_xcm_pallet_attempted_incomplete(
- expected_weight: Option,
- expected_error: Option,
+ expected_weight: Option<$crate::impls::Weight>,
+ expected_error: Option<$crate::impls::Error>,
) {
- assert_expected_events!(
+ $crate::impls::assert_expected_events!(
Self,
vec![
// Dispatchable is properly executed and XCM message sent
[<$chain RuntimeEvent>]::PolkadotXcm(
- pallet_xcm::Event::Attempted { outcome: Outcome::Incomplete(weight, error) }
+ $crate::impls::pallet_xcm::Event::Attempted { outcome: $crate::impls::Outcome::Incomplete(weight, error) }
) => {
- weight: weight_within_threshold(
- (REF_TIME_THRESHOLD, PROOF_SIZE_THRESHOLD),
+ weight: $crate::impls::weight_within_threshold(
+ ($crate::impls::REF_TIME_THRESHOLD, $crate::impls::PROOF_SIZE_THRESHOLD),
expected_weight.unwrap_or(*weight),
*weight
),
@@ -373,13 +427,13 @@ macro_rules! impl_assert_events_helpers_for_parachain {
}
/// Asserts a dispatchable throws and error when trying to be sent
- pub fn assert_xcm_pallet_attempted_error(expected_error: Option) {
- assert_expected_events!(
+ pub fn assert_xcm_pallet_attempted_error(expected_error: Option<$crate::impls::Error>) {
+ $crate::impls::assert_expected_events!(
Self,
vec![
// Execution fails in the origin with `Barrier`
[<$chain RuntimeEvent>]::PolkadotXcm(
- pallet_xcm::Event::Attempted { outcome: Outcome::Error(error) }
+ $crate::impls::pallet_xcm::Event::Attempted { outcome: $crate::impls::Outcome::Error(error) }
) => {
error: *error == expected_error.unwrap_or(*error),
},
@@ -389,36 +443,36 @@ macro_rules! impl_assert_events_helpers_for_parachain {
/// Asserts a XCM message is sent
pub fn assert_xcm_pallet_sent() {
- assert_expected_events!(
+ $crate::impls::assert_expected_events!(
Self,
vec![
- [<$chain RuntimeEvent>]::PolkadotXcm(pallet_xcm::Event::Sent { .. }) => {},
+ [<$chain RuntimeEvent>]::PolkadotXcm($crate::impls::pallet_xcm::Event::Sent { .. }) => {},
]
);
}
/// Asserts a XCM message is sent to Relay Chain
pub fn assert_parachain_system_ump_sent() {
- assert_expected_events!(
+ $crate::impls::assert_expected_events!(
Self,
vec![
[<$chain RuntimeEvent>]::ParachainSystem(
- cumulus_pallet_parachain_system::Event::UpwardMessageSent { .. }
+ $crate::impls::cumulus_pallet_parachain_system::Event::UpwardMessageSent { .. }
) => {},
]
);
}
/// Asserts a XCM from Relay Chain is completely executed
- pub fn assert_dmp_queue_complete(expected_weight: Option) {
- assert_expected_events!(
+ pub fn assert_dmp_queue_complete(expected_weight: Option<$crate::impls::Weight>) {
+ $crate::impls::assert_expected_events!(
Self,
vec![
- [<$chain RuntimeEvent>]::DmpQueue(cumulus_pallet_dmp_queue::Event::ExecutedDownward {
- outcome: Outcome::Complete(weight), ..
+ [<$chain RuntimeEvent>]::DmpQueue($crate::impls::cumulus_pallet_dmp_queue::Event::ExecutedDownward {
+ outcome: $crate::impls::Outcome::Complete(weight), ..
}) => {
- weight: weight_within_threshold(
- (REF_TIME_THRESHOLD, PROOF_SIZE_THRESHOLD),
+ weight: $crate::impls::weight_within_threshold(
+ ($crate::impls::REF_TIME_THRESHOLD, $crate::impls::PROOF_SIZE_THRESHOLD),
expected_weight.unwrap_or(*weight),
*weight
),
@@ -429,17 +483,17 @@ macro_rules! impl_assert_events_helpers_for_parachain {
/// Asserts a XCM from Relay Chain is incompletely executed
pub fn assert_dmp_queue_incomplete(
- expected_weight: Option,
- expected_error: Option,
+ expected_weight: Option<$crate::impls::Weight>,
+ expected_error: Option<$crate::impls::Error>,
) {
- assert_expected_events!(
+ $crate::impls::assert_expected_events!(
Self,
vec![
- [<$chain RuntimeEvent>]::DmpQueue(cumulus_pallet_dmp_queue::Event::ExecutedDownward {
- outcome: Outcome::Incomplete(weight, error), ..
+ [<$chain RuntimeEvent>]::DmpQueue($crate::impls::cumulus_pallet_dmp_queue::Event::ExecutedDownward {
+ outcome: $crate::impls::Outcome::Incomplete(weight, error), ..
}) => {
- weight: weight_within_threshold(
- (REF_TIME_THRESHOLD, PROOF_SIZE_THRESHOLD),
+ weight: $crate::impls::weight_within_threshold(
+ ($crate::impls::REF_TIME_THRESHOLD, $crate::impls::PROOF_SIZE_THRESHOLD),
expected_weight.unwrap_or(*weight),
*weight
),
@@ -450,15 +504,15 @@ macro_rules! impl_assert_events_helpers_for_parachain {
}
/// Asserts a XCM from another Parachain is completely executed
- pub fn assert_xcmp_queue_success(expected_weight: Option) {
- assert_expected_events!(
+ pub fn assert_xcmp_queue_success(expected_weight: Option<$crate::impls::Weight>) {
+ $crate::impls::assert_expected_events!(
Self,
vec![
[<$chain RuntimeEvent>]::XcmpQueue(
- cumulus_pallet_xcmp_queue::Event::Success { weight, .. }
+ $crate::impls::cumulus_pallet_xcmp_queue::Event::Success { weight, .. }
) => {
- weight: weight_within_threshold(
- (REF_TIME_THRESHOLD, PROOF_SIZE_THRESHOLD),
+ weight: $crate::impls::weight_within_threshold(
+ ($crate::impls::REF_TIME_THRESHOLD, $crate::impls::PROOF_SIZE_THRESHOLD),
expected_weight.unwrap_or(*weight),
*weight
),
@@ -474,18 +528,20 @@ macro_rules! impl_assert_events_helpers_for_parachain {
#[macro_export]
macro_rules! impl_assets_helpers_for_parachain {
( $chain:ident, $relay_chain:ident ) => {
- $crate::paste::paste! {
+ $crate::impls::paste::paste! {
impl $chain {
/// Returns the encoded call for `force_create` from the assets pallet
pub fn force_create_asset_call(
asset_id: u32,
- owner: AccountId,
+ owner: $crate::impls::AccountId,
is_sufficient: bool,
- min_balance: Balance,
- ) -> DoubleEncoded<()> {
- ::RuntimeCall::Assets(pallet_assets::Call::<
+ min_balance: $crate::impls::Balance,
+ ) -> $crate::impls::DoubleEncoded<()> {
+ use $crate::impls::{Chain, Encode};
+
+ ::RuntimeCall::Assets($crate::impls::pallet_assets::Call::<
::Runtime,
- Instance1,
+ $crate::impls::pallet_assets::Instance1,
>::force_create {
id: asset_id.into(),
owner: owner.into(),
@@ -498,37 +554,37 @@ macro_rules! impl_assets_helpers_for_parachain {
/// Returns a `VersionedXcm` for `force_create` from the assets pallet
pub fn force_create_asset_xcm(
- origin_kind: OriginKind,
+ origin_kind: $crate::impls::OriginKind,
asset_id: u32,
- owner: AccountId,
+ owner: $crate::impls::AccountId,
is_sufficient: bool,
- min_balance: Balance,
- ) -> VersionedXcm<()> {
+ min_balance: $crate::impls::Balance,
+ ) -> $crate::impls::VersionedXcm<()> {
let call = Self::force_create_asset_call(asset_id, owner, is_sufficient, min_balance);
- xcm_transact_unpaid_execution(call, origin_kind)
+ $crate::impls::xcm_transact_unpaid_execution(call, origin_kind)
}
/// Mint assets making use of the assets pallet
pub fn mint_asset(
- signed_origin: ::RuntimeOrigin,
+ signed_origin: ::RuntimeOrigin,
id: u32,
- beneficiary: AccountId,
+ beneficiary: $crate::impls::AccountId,
amount_to_mint: u128,
) {
- Self::execute_with(|| {
- assert_ok!(]>::Assets::mint(
+ ::execute_with(|| {
+ $crate::impls::assert_ok!(]>::Assets::mint(
signed_origin,
id.into(),
beneficiary.clone().into(),
amount_to_mint
));
- type RuntimeEvent = <$chain as Chain>::RuntimeEvent;
+ type RuntimeEvent = <$chain as $crate::impls::Chain>::RuntimeEvent;
- assert_expected_events!(
+ $crate::impls::assert_expected_events!(
Self,
vec![
- RuntimeEvent::Assets(pallet_assets::Event::Issued { asset_id, owner, amount }) => {
+ RuntimeEvent::Assets($crate::impls::pallet_assets::Event::Issued { asset_id, owner, amount }) => {
asset_id: *asset_id == id,
owner: *owner == beneficiary.clone().into(),
amount: *amount == amount_to_mint,
@@ -543,14 +599,15 @@ macro_rules! impl_assets_helpers_for_parachain {
id: u32,
min_balance: u128,
is_sufficient: bool,
- asset_owner: AccountId,
+ asset_owner: $crate::impls::AccountId,
amount_to_mint: u128,
) {
+ use $crate::impls::{bx, Chain, RelayChain, Parachain, Inspect, TestExt};
// Init values for Relay Chain
let root_origin = <$relay_chain as Chain>::RuntimeOrigin::root();
let destination = <$relay_chain>::child_location_of(<$chain>::para_id());
let xcm = Self::force_create_asset_xcm(
- OriginKind::Superuser,
+ $crate::impls::OriginKind::Superuser,
id,
asset_owner.clone(),
is_sufficient,
@@ -558,7 +615,7 @@ macro_rules! impl_assets_helpers_for_parachain {
);
<$relay_chain>::execute_with(|| {
- assert_ok!(<$relay_chain as [<$relay_chain Pallet>]>::XcmPallet::send(
+ $crate::impls::assert_ok!(<$relay_chain as [<$relay_chain Pallet>]>::XcmPallet::send(
root_origin,
bx!(destination.into()),
bx!(xcm),
@@ -568,15 +625,15 @@ macro_rules! impl_assets_helpers_for_parachain {
});
Self::execute_with(|| {
- Self::assert_dmp_queue_complete(Some(Weight::from_parts(1_019_445_000, 200_000)));
+ Self::assert_dmp_queue_complete(Some($crate::impls::Weight::from_parts(1_019_445_000, 200_000)));
- type RuntimeEvent = <$chain as Chain>::RuntimeEvent;
+ type RuntimeEvent = <$chain as $crate::impls::Chain>::RuntimeEvent;
- assert_expected_events!(
+ $crate::impls::assert_expected_events!(
Self,
vec![
// Asset has been created
- RuntimeEvent::Assets(pallet_assets::Event::ForceCreated { asset_id, owner }) => {
+ RuntimeEvent::Assets($crate::impls::pallet_assets::Event::ForceCreated { asset_id, owner }) => {
asset_id: *asset_id == id,
owner: *owner == asset_owner.clone(),
},
diff --git a/cumulus/parachains/integration-tests/emulated/common/src/lib.rs b/cumulus/parachains/integration-tests/emulated/common/src/lib.rs
index f6d589700360cfafef7d59255fafe876e3de5a87..7461165f2a198e8f8b871850545bf50f6e37e885 100644
--- a/cumulus/parachains/integration-tests/emulated/common/src/lib.rs
+++ b/cumulus/parachains/integration-tests/emulated/common/src/lib.rs
@@ -1,42 +1,36 @@
-pub use lazy_static;
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
pub mod constants;
pub mod impls;
+pub mod xcm_helpers;
-pub use codec::Encode;
-pub use constants::{
+use constants::{
accounts::{ALICE, BOB},
asset_hub_kusama, asset_hub_polkadot, asset_hub_westend, bridge_hub_kusama,
bridge_hub_polkadot, bridge_hub_rococo, collectives, kusama, penpal, polkadot, rococo, westend,
- PROOF_SIZE_THRESHOLD, REF_TIME_THRESHOLD,
-};
-use frame_support::{
- assert_ok,
- instances::Instance1,
- parameter_types,
- traits::{fungibles::Inspect, Hooks},
-};
-pub use impls::{RococoWococoMessageHandler, WococoRococoMessageHandler};
-pub use parachains_common::{AccountId, Balance};
-pub use paste;
-use polkadot_parachain::primitives::HrmpChannelId;
-pub use polkadot_runtime_parachains::inclusion::{AggregateMessageOrigin, UmpQueueId};
-pub use sp_core::{sr25519, storage::Storage, Get};
-use sp_tracing;
-use xcm_emulator::{
- assert_expected_events, bx, decl_test_bridges, decl_test_networks, decl_test_parachains,
- decl_test_relay_chains, decl_test_sender_receiver_accounts_parameter_types,
- helpers::weight_within_threshold, BridgeMessageHandler, Chain, DefaultMessageProcessor, ParaId,
- Parachain, RelayChain, TestExt,
};
+use impls::{RococoWococoMessageHandler, WococoRococoMessageHandler};
-pub use xcm::{
- prelude::{
- AccountId32, All, BuyExecution, DepositAsset, MultiAsset, MultiAssets, MultiLocation,
- OriginKind, Outcome, RefundSurplus, Transact, UnpaidExecution, VersionedXcm, Weight,
- WeightLimit, WithdrawAsset, Xcm, X1,
- },
- v3::Error,
- DoubleEncoded,
+// Substrate
+use frame_support::traits::OnInitialize;
+
+// Cumulus
+use xcm_emulator::{
+ decl_test_bridges, decl_test_networks, decl_test_parachains, decl_test_relay_chains,
+ decl_test_sender_receiver_accounts_parameter_types, DefaultMessageProcessor,
};
decl_test_relay_chains! {
@@ -70,7 +64,7 @@ decl_test_relay_chains! {
Hrmp: kusama_runtime::Hrmp,
}
},
- #[api_version(5)]
+ #[api_version(6)]
pub struct Westend {
genesis = westend::genesis(),
on_init = (),
@@ -565,44 +559,3 @@ decl_test_sender_receiver_accounts_parameter_types! {
PenpalWestendA { sender: ALICE, receiver: BOB },
PenpalRococoA { sender: ALICE, receiver: BOB }
}
-
-/// Helper method to build a XCM with a `Transact` instruction and paying for its execution
-pub fn xcm_transact_paid_execution(
- call: DoubleEncoded<()>,
- origin_kind: OriginKind,
- native_asset: MultiAsset,
- beneficiary: AccountId,
-) -> VersionedXcm<()> {
- let weight_limit = WeightLimit::Unlimited;
- let require_weight_at_most = Weight::from_parts(1000000000, 200000);
- let native_assets: MultiAssets = native_asset.clone().into();
-
- VersionedXcm::from(Xcm(vec![
- WithdrawAsset(native_assets),
- BuyExecution { fees: native_asset, weight_limit },
- Transact { require_weight_at_most, origin_kind, call },
- RefundSurplus,
- DepositAsset {
- assets: All.into(),
- beneficiary: MultiLocation {
- parents: 0,
- interior: X1(AccountId32 { network: None, id: beneficiary.into() }),
- },
- },
- ]))
-}
-
-/// Helper method to build a XCM with a `Transact` instruction without paying for its execution
-pub fn xcm_transact_unpaid_execution(
- call: DoubleEncoded<()>,
- origin_kind: OriginKind,
-) -> VersionedXcm<()> {
- let weight_limit = WeightLimit::Unlimited;
- let require_weight_at_most = Weight::from_parts(1000000000, 200000);
- let check_origin = None;
-
- VersionedXcm::from(Xcm(vec![
- UnpaidExecution { weight_limit, check_origin },
- Transact { require_weight_at_most, origin_kind, call },
- ]))
-}
diff --git a/cumulus/parachains/integration-tests/emulated/common/src/xcm_helpers.rs b/cumulus/parachains/integration-tests/emulated/common/src/xcm_helpers.rs
new file mode 100644
index 0000000000000000000000000000000000000000..4096cdbba0b9154beb9f90272a459087b2443498
--- /dev/null
+++ b/cumulus/parachains/integration-tests/emulated/common/src/xcm_helpers.rs
@@ -0,0 +1,66 @@
+// Copyright Parity Technologies (UK) Ltd.
+// This file is part of Cumulus.
+
+// Cumulus 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.
+
+// Cumulus 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 Cumulus. If not, see .
+
+use parachains_common::AccountId;
+use xcm::{
+ prelude::{
+ AccountId32, All, BuyExecution, DepositAsset, MultiAsset, MultiAssets, MultiLocation,
+ OriginKind, RefundSurplus, Transact, UnpaidExecution, VersionedXcm, Weight, WeightLimit,
+ WithdrawAsset, Xcm, X1,
+ },
+ DoubleEncoded,
+};
+
+/// Helper method to build a XCM with a `Transact` instruction and paying for its execution
+pub fn xcm_transact_paid_execution(
+ call: DoubleEncoded<()>,
+ origin_kind: OriginKind,
+ native_asset: MultiAsset,
+ beneficiary: AccountId,
+) -> VersionedXcm<()> {
+ let weight_limit = WeightLimit::Unlimited;
+ let require_weight_at_most = Weight::from_parts(1000000000, 200000);
+ let native_assets: MultiAssets = native_asset.clone().into();
+
+ VersionedXcm::from(Xcm(vec![
+ WithdrawAsset(native_assets),
+ BuyExecution { fees: native_asset, weight_limit },
+ Transact { require_weight_at_most, origin_kind, call },
+ RefundSurplus,
+ DepositAsset {
+ assets: All.into(),
+ beneficiary: MultiLocation {
+ parents: 0,
+ interior: X1(AccountId32 { network: None, id: beneficiary.into() }),
+ },
+ },
+ ]))
+}
+
+/// Helper method to build a XCM with a `Transact` instruction without paying for its execution
+pub fn xcm_transact_unpaid_execution(
+ call: DoubleEncoded<()>,
+ origin_kind: OriginKind,
+) -> VersionedXcm<()> {
+ let weight_limit = WeightLimit::Unlimited;
+ let require_weight_at_most = Weight::from_parts(1000000000, 200000);
+ let check_origin = None;
+
+ VersionedXcm::from(Xcm(vec![
+ UnpaidExecution { weight_limit, check_origin },
+ Transact { require_weight_at_most, origin_kind, call },
+ ]))
+}
diff --git a/cumulus/parachains/pallets/parachain-info/src/lib.rs b/cumulus/parachains/pallets/parachain-info/src/lib.rs
index 6a9707365c372bc0a259c7708a9a729afb6ef1a5..c17a6d5e1460a2ef319109c0d867b6c73a6493e0 100644
--- a/cumulus/parachains/pallets/parachain-info/src/lib.rs
+++ b/cumulus/parachains/pallets/parachain-info/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/pallets/ping/Cargo.toml b/cumulus/parachains/pallets/ping/Cargo.toml
index e214081ab04886ab7ba759ded9d0fb9c00b71db9..f0afa63d692d458c4f5ea008bf0dee223c7e2c6c 100644
--- a/cumulus/parachains/pallets/ping/Cargo.toml
+++ b/cumulus/parachains/pallets/ping/Cargo.toml
@@ -13,7 +13,7 @@ sp-runtime = { path = "../../../../substrate/primitives/runtime", default-featur
frame-support = { path = "../../../../substrate/frame/support", default-features = false}
frame-system = { path = "../../../../substrate/frame/system", default-features = false}
-xcm = { path = "../../../../polkadot/xcm", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../polkadot/xcm", default-features = false}
cumulus-primitives-core = { path = "../../../primitives/core", default-features = false }
cumulus-pallet-xcm = { path = "../../../pallets/xcm", default-features = false }
diff --git a/cumulus/parachains/pallets/ping/src/lib.rs b/cumulus/parachains/pallets/ping/src/lib.rs
index 7425b5bd52f43d5b45fd0b1d29fa608f883c633c..feda3d0b6f9f0f52ee0294e1af6cff7c6764dc66 100644
--- a/cumulus/parachains/pallets/ping/src/lib.rs
+++ b/cumulus/parachains/pallets/ping/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/Cargo.toml b/cumulus/parachains/runtimes/assets/asset-hub-kusama/Cargo.toml
index e085ee24c6049f3914972b3c5d7ecf354591bb53..53555499842fde9684b3a5b33087ca8de80643ee 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/Cargo.toml
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/Cargo.toml
@@ -59,11 +59,11 @@ kusama-runtime-constants = { path = "../../../../../polkadot/runtime/kusama/cons
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
pallet-xcm-benchmarks = { path = "../../../../../polkadot/xcm/pallet-xcm-benchmarks", default-features = false, optional = true }
polkadot-core-primitives = { path = "../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-common = { path = "../../../../../polkadot/runtime/common", default-features = false}
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-aura-ext = { path = "../../../../pallets/aura-ext", default-features = false }
@@ -118,7 +118,7 @@ runtime-benchmarks = [
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"polkadot-runtime-common/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
@@ -200,7 +200,7 @@ std = [
"parachain-info/std",
"parachains-common/std",
"polkadot-core-primitives/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"polkadot-runtime-common/std",
"scale-info/std",
"sp-api/std",
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/constants.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/constants.rs
deleted file mode 100644
index 0ca93a8446f75a8fddc6ad87df1a0fb24c4a1c1f..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/constants.rs
+++ /dev/null
@@ -1,118 +0,0 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
-// SPDX-License-Identifier: Apache-2.0
-
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-pub mod currency {
- use kusama_runtime_constants as constants;
- use polkadot_core_primitives::Balance;
-
- /// The existential deposit. Set to 1/10 of its parent Relay Chain.
- pub const EXISTENTIAL_DEPOSIT: Balance = constants::currency::EXISTENTIAL_DEPOSIT / 10;
-
- pub const UNITS: Balance = constants::currency::UNITS;
- pub const CENTS: Balance = constants::currency::CENTS;
- pub const GRAND: Balance = constants::currency::GRAND;
- pub const MILLICENTS: Balance = constants::currency::MILLICENTS;
-
- pub const fn deposit(items: u32, bytes: u32) -> Balance {
- // map to 1/100 of what the kusama relay chain charges (v9020)
- constants::currency::deposit(items, bytes) / 100
- }
-}
-
-/// Fee-related.
-pub mod fee {
- use frame_support::weights::{
- constants::ExtrinsicBaseWeight, FeePolynomial, Weight, WeightToFeeCoefficient,
- WeightToFeeCoefficients, WeightToFeePolynomial,
- };
- use polkadot_core_primitives::Balance;
- use smallvec::smallvec;
- pub use sp_runtime::Perbill;
-
- /// The block saturation level. Fees will be updates based on this value.
- pub const TARGET_BLOCK_FULLNESS: Perbill = Perbill::from_percent(25);
-
- /// Handles converting a weight scalar to a fee value, based on the scale and granularity of the
- /// node's balance type.
- ///
- /// This should typically create a mapping between the following ranges:
- /// - [0, MAXIMUM_BLOCK_WEIGHT]
- /// - [Balance::min, Balance::max]
- ///
- /// Yet, it can be used for any other sort of change to weight-fee. Some examples being:
- /// - Setting it to `0` will essentially disable the weight fee.
- /// - Setting it to `1` will cause the literal `#[weight = x]` values to be charged.
- pub struct WeightToFee;
- impl frame_support::weights::WeightToFee for WeightToFee {
- type Balance = Balance;
-
- fn weight_to_fee(weight: &Weight) -> Self::Balance {
- let time_poly: FeePolynomial = RefTimeToFee::polynomial().into();
- let proof_poly: FeePolynomial = ProofSizeToFee::polynomial().into();
-
- // Take the maximum instead of the sum to charge by the more scarce resource.
- time_poly.eval(weight.ref_time()).max(proof_poly.eval(weight.proof_size()))
- }
- }
-
- /// Maps the reference time component of `Weight` to a fee.
- pub struct RefTimeToFee;
- impl WeightToFeePolynomial for RefTimeToFee {
- type Balance = Balance;
- fn polynomial() -> WeightToFeeCoefficients {
- // in Kusama, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
- // in Asset Hub, we map to 1/10 of that, or 1/100 CENT
- let p = super::currency::CENTS;
- let q = 100 * Balance::from(ExtrinsicBaseWeight::get().ref_time());
-
- smallvec![WeightToFeeCoefficient {
- degree: 1,
- negative: false,
- coeff_frac: Perbill::from_rational(p % q, q),
- coeff_integer: p / q,
- }]
- }
- }
-
- /// Maps the proof size component of `Weight` to a fee.
- pub struct ProofSizeToFee;
- impl WeightToFeePolynomial for ProofSizeToFee {
- type Balance = Balance;
- fn polynomial() -> WeightToFeeCoefficients {
- // Map 10kb proof to 1 CENT.
- let p = super::currency::CENTS;
- let q = 10_000;
-
- smallvec![WeightToFeeCoefficient {
- degree: 1,
- negative: false,
- coeff_frac: Perbill::from_rational(p % q, q),
- coeff_integer: p / q,
- }]
- }
- }
-}
-
-/// Consensus-related.
-pub mod consensus {
- /// Maximum number of blocks simultaneously accepted by the Runtime, not yet included
- /// into the relay chain.
- pub const UNINCLUDED_SEGMENT_CAPACITY: u32 = 1;
- /// How many parachain blocks are processed by the relay chain per parent. Limits the
- /// number of blocks authored per slot.
- pub const BLOCK_PROCESSING_VELOCITY: u32 = 1;
- /// Relay chain slot duration, in milliseconds.
- pub const RELAY_CHAIN_SLOT_DURATION_MILLIS: u32 = 6000;
-}
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/lib.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/lib.rs
index 2130c6502f8ef53e9042ebcdc21d90b07312da33..828d1b4750a3e0436bc18f7926489a04a4b2bb9e 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/lib.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021-2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -24,7 +24,6 @@
#[cfg(feature = "std")]
include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));
-pub mod constants;
mod weights;
pub mod xcm_config;
@@ -50,7 +49,6 @@ use sp_version::NativeVersion;
use sp_version::RuntimeVersion;
use codec::{Decode, Encode, MaxEncodedLen};
-use constants::{consensus::*, currency::*, fee::WeightToFee};
use frame_support::{
construct_runtime,
dispatch::DispatchClass,
@@ -70,8 +68,10 @@ use pallet_asset_conversion_tx_payment::AssetConversionAdapter;
use pallet_nfts::PalletFeatures;
pub use parachains_common as common;
use parachains_common::{
- impls::DealWithFees, AccountId, AssetIdForTrustBackedAssets, AuraId, Balance, BlockNumber,
- Hash, Header, Nonce, Signature, AVERAGE_ON_INITIALIZE_RATIO, DAYS, HOURS, MAXIMUM_BLOCK_WEIGHT,
+ impls::DealWithFees,
+ kusama::{consensus::*, currency::*, fee::WeightToFee},
+ AccountId, AssetIdForTrustBackedAssets, AuraId, Balance, BlockNumber, Hash, Header, Nonce,
+ Signature, AVERAGE_ON_INITIALIZE_RATIO, DAYS, HOURS, MAXIMUM_BLOCK_WEIGHT,
NORMAL_DISPATCH_RATIO, SLOT_DURATION,
};
use sp_runtime::RuntimeDebug;
@@ -1395,8 +1395,9 @@ fn ensure_key_ss58() {
#[cfg(test)]
mod tests {
- use super::{constants::fee, *};
+ use super::*;
use crate::{CENTS, MILLICENTS};
+ use parachains_common::kusama::fee;
use sp_runtime::traits::Zero;
use sp_weights::WeightToFee;
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/block_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/block_weights.rs
index b2092d875c8328210667da4cbb95de0642e60ae3..e7fdb2aae2a01ec06076de83d94817e540e205dd 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/block_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/block_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/cumulus_pallet_xcmp_queue.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/cumulus_pallet_xcmp_queue.rs
index df8188debddfa97be6c40b0eb632f8913488d5d4..9c7a56687b314e51ff3d77134b5d389e9568b293 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/cumulus_pallet_xcmp_queue.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/cumulus_pallet_xcmp_queue.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/extrinsic_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/extrinsic_weights.rs
index 332c3b324bb9c1b386257bf7953d37aba8f5af13..1a4adb968bb7195428ea00d59cd92dcd3b6eea5f 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/extrinsic_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/extrinsic_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/frame_system.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/frame_system.rs
index 20e421541b0d6f401b09b4677f7de3818369d559..96477ddf4bd3fab597a6d2a89ae30e30f33840cd 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/frame_system.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/frame_system.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/mod.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/mod.rs
index 955d4690634e8cb7949afe63cefc5ae66e600d14..281c013b3372f57a24b57812de91e684ffabd0c9 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/mod.rs
@@ -1,3 +1,19 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// This file is part of Cumulus.
+
+// Cumulus 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.
+
+// Cumulus 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 Cumulus. If not, see .
+
pub mod block_weights;
pub mod cumulus_pallet_xcmp_queue;
pub mod extrinsic_weights;
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_asset_conversion.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_asset_conversion.rs
index bb09a85133290d4f30e2c1561aef8aad417f7121..702f3743a7203f7103474dea554cb7aec2448ce6 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_asset_conversion.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_asset_conversion.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_foreign.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_foreign.rs
index 3a801b758cf78865e568f38e4624817456294035..7c237b20389db7af3bab0e5e231dac0097210328 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_foreign.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_foreign.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_local.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_local.rs
index d88f5991e3290ca38d73f3c18018cdc874e1cef7..10bd4b1f8b097d40bb23e9a24a1f81ee0c6fea09 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_local.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_local.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_pool.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_pool.rs
index eeac89bb453383ae94c38af0cd15196908cc8d72..444699e33ef7d714aac0f0cb11a4ead143c76c87 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_pool.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_assets_pool.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_balances.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_balances.rs
index b387e626209cd20a4196c17da3553624cebc38bf..be1ac3011f79e72f852010f8fbdbaf19c4776b8b 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_balances.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_balances.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_collator_selection.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_collator_selection.rs
index a528b0f66852fd4104c8a3f35d977fcaf14400e3..7fe56ac31f7aa11c8eb497dbacdabef522ccb294 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_collator_selection.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_collator_selection.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_multisig.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_multisig.rs
index f949a0786bfc6c04d62ec1de0ed2e6be12142f36..ee7b70736414d86fc270d08777fe606ba76c0b34 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_multisig.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_multisig.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_nft_fractionalization.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_nft_fractionalization.rs
index ab3bcbea8268846c26dce403d5f75ac7f78b9a71..c55a18adc5233d75dd05f8b35678023a548051ed 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_nft_fractionalization.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_nft_fractionalization.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_nfts.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_nfts.rs
index 453d2d477bf043f3ceeb48bd0ca3ba0050b121c4..2de706bbdc70087cb8fe8128a30644e6e1f2ce74 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_nfts.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_nfts.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_proxy.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_proxy.rs
index 6c548ac1f27c1b16fafb4536db51bcf7c390df78..9bc4ba448e5af7d50988a319f62718ac486b689c 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_proxy.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_proxy.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_session.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_session.rs
index c5064adf8b03070277c69f23614e4b09f4df7d47..56982f565ac478cc59ae9db6864e78e27a795191 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_session.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_session.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_timestamp.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_timestamp.rs
index 8edae065f1b9173a3767a037c167f05420b95a70..94914eefba04db2a068767adeb7657e328613460 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_timestamp.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_timestamp.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_uniques.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_uniques.rs
index 4da387aa872efa667226089535caacb4d55ab585..43bc74931cb0e7c7ae8c90e8dafbac12df83669c 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_uniques.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_uniques.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_utility.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_utility.rs
index 22d20c26e25ee261d05756e50791dc26d5944754..680e65a2dcf90271faf4f25e1f02656ded9d6881 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_utility.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_utility.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_xcm.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_xcm.rs
index ee76b111e83c497c9f051e6a848b9b83eced0388..c2ed67d2f5d45196894955e3e2fbe41e175454c0 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_xcm.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/pallet_xcm.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/paritydb_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/paritydb_weights.rs
index 4338d928d807a41cc60ec91d86e91c81bb253631..25679703831a13b8d1bb7fb7dd4d92fa84b1f255 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/paritydb_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/paritydb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/rocksdb_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/rocksdb_weights.rs
index 1d115d963facb39fe29d6258918fda3bc8d94900..3dd817aa6f137085b0e5fdf2b11b7f50e5c8b002 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/rocksdb_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/rocksdb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/mod.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/mod.rs
index 8608d04af069073e6e507565dc2e8e5096731dcb..9aff4902d15baa7c8040c8d37ef747fc0c08b754 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/mod.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
index 17e4ea7c8b69bcb31eeea4c344010b25bac0d66e..6e663039b0c2bcd2767dbd46b6e53c113b50be3d 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
index 4988047014beb00b8c0d3feeb389e52b000ef9b8..625549ecfccfa348e11debd99325f7ac41646445 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/xcm_config.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/xcm_config.rs
index 7352141b2f398f1fc9170828dbb052db7cd1519f..863b6f6753bbf1fc7eee769a3db66be40cb1a953 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/xcm_config.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/src/xcm_config.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -32,7 +32,7 @@ use frame_support::{
use frame_system::EnsureRoot;
use pallet_xcm::XcmPassthrough;
use parachains_common::{impls::ToStakingPot, xcm_config::AssetFeeAsExistentialDepositMultiplier};
-use polkadot_parachain::primitives::Sibling;
+use polkadot_parachain_primitives::primitives::Sibling;
use sp_runtime::traits::ConvertInto;
use xcm::latest::prelude::*;
use xcm_builder::{
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-kusama/tests/tests.rs b/cumulus/parachains/runtimes/assets/asset-hub-kusama/tests/tests.rs
index 6d9eccdf3744778af680575cbac79490732ad1ea..7d49b56e461a0a3919e2130dbb6d84f6888349ad 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-kusama/tests/tests.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-kusama/tests/tests.rs
@@ -21,7 +21,6 @@ use asset_hub_kusama_runtime::xcm_config::{
AssetFeeAsExistentialDepositMultiplierFeeCharger, KsmLocation, TrustBackedAssetsPalletLocation,
};
pub use asset_hub_kusama_runtime::{
- constants::fee::WeightToFee,
xcm_config::{CheckingAccount, ForeignCreatorsSovereignAccountOf, XcmConfig},
AllPalletsWithoutSystem, AssetDeposit, Assets, Balances, ExistentialDeposit, ForeignAssets,
ForeignAssetsInstance, MetadataDepositBase, MetadataDepositPerByte, ParachainSystem, Runtime,
@@ -35,7 +34,9 @@ use frame_support::{
traits::fungibles::InspectEnumerable,
weights::{Weight, WeightToFee as WeightToFeeT},
};
-use parachains_common::{AccountId, AssetIdForTrustBackedAssets, AuraId, Balance};
+use parachains_common::{
+ kusama::fee::WeightToFee, AccountId, AssetIdForTrustBackedAssets, AuraId, Balance,
+};
use sp_runtime::traits::MaybeEquivalence;
use xcm::latest::prelude::*;
use xcm_executor::traits::{Identity, JustTry, WeightTrader};
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/Cargo.toml b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/Cargo.toml
index b008b21b12dde4d4c4ee9d5cdbc7f0635db6dc82..dfc3d5416cc3c7c2ebc51dee2aa68a495a6a5079 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/Cargo.toml
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/Cargo.toml
@@ -53,12 +53,12 @@ sp-weights = { path = "../../../../../substrate/primitives/weights", default-fea
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
pallet-xcm-benchmarks = { path = "../../../../../polkadot/xcm/pallet-xcm-benchmarks", default-features = false, optional = true }
polkadot-core-primitives = { path = "../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-common = { path = "../../../../../polkadot/runtime/common", default-features = false}
polkadot-runtime-constants = { path = "../../../../../polkadot/runtime/polkadot/constants", default-features = false}
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-aura-ext = { path = "../../../../pallets/aura-ext", default-features = false }
@@ -105,7 +105,7 @@ runtime-benchmarks = [
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"polkadot-runtime-common/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
@@ -180,7 +180,7 @@ std = [
"parachain-info/std",
"parachains-common/std",
"polkadot-core-primitives/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"polkadot-runtime-common/std",
"polkadot-runtime-constants/std",
"scale-info/std",
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/constants.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/constants.rs
deleted file mode 100644
index d3ddab9a854fa07b59d933b4f8ca09f6d65c04c4..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/constants.rs
+++ /dev/null
@@ -1,119 +0,0 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
-// SPDX-License-Identifier: Apache-2.0
-
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-pub mod currency {
- use polkadot_core_primitives::Balance;
- use polkadot_runtime_constants as constants;
-
- /// The existential deposit. Set to 1/10 of its parent Relay Chain.
- pub const EXISTENTIAL_DEPOSIT: Balance = constants::currency::EXISTENTIAL_DEPOSIT / 10;
-
- pub const UNITS: Balance = constants::currency::UNITS;
- pub const DOLLARS: Balance = constants::currency::DOLLARS;
- pub const CENTS: Balance = constants::currency::CENTS;
- pub const MILLICENTS: Balance = constants::currency::MILLICENTS;
-
- pub const fn deposit(items: u32, bytes: u32) -> Balance {
- // 1/100 of Polkadot
- constants::currency::deposit(items, bytes) / 100
- }
-}
-
-/// Fee-related.
-pub mod fee {
- use frame_support::weights::{
- constants::ExtrinsicBaseWeight, FeePolynomial, WeightToFeeCoefficient,
- WeightToFeeCoefficients, WeightToFeePolynomial,
- };
- use polkadot_core_primitives::Balance;
- use smallvec::smallvec;
- pub use sp_runtime::Perbill;
- use sp_weights::Weight;
-
- /// The block saturation level. Fees will be updates based on this value.
- pub const TARGET_BLOCK_FULLNESS: Perbill = Perbill::from_percent(25);
-
- /// Handles converting a weight scalar to a fee value, based on the scale and granularity of the
- /// node's balance type.
- ///
- /// This should typically create a mapping between the following ranges:
- /// - [0, MAXIMUM_BLOCK_WEIGHT]
- /// - [Balance::min, Balance::max]
- ///
- /// Yet, it can be used for any other sort of change to weight-fee. Some examples being:
- /// - Setting it to `0` will essentially disable the weight fee.
- /// - Setting it to `1` will cause the literal `#[weight = x]` values to be charged.
- pub struct WeightToFee;
- impl frame_support::weights::WeightToFee for WeightToFee {
- type Balance = Balance;
-
- fn weight_to_fee(weight: &Weight) -> Self::Balance {
- let time_poly: FeePolynomial = RefTimeToFee::polynomial().into();
- let proof_poly: FeePolynomial = ProofSizeToFee::polynomial().into();
-
- // Take the maximum instead of the sum to charge by the more scarce resource.
- time_poly.eval(weight.ref_time()).max(proof_poly.eval(weight.proof_size()))
- }
- }
-
- /// Maps the reference time component of `Weight` to a fee.
- pub struct RefTimeToFee;
- impl WeightToFeePolynomial for RefTimeToFee {
- type Balance = Balance;
- fn polynomial() -> WeightToFeeCoefficients {
- // in Polkadot, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
- // in Asset Hub, we map to 1/10 of that, or 1/100 CENT
- let p = super::currency::CENTS;
- let q = 100 * Balance::from(ExtrinsicBaseWeight::get().ref_time());
-
- smallvec![WeightToFeeCoefficient {
- degree: 1,
- negative: false,
- coeff_frac: Perbill::from_rational(p % q, q),
- coeff_integer: p / q,
- }]
- }
- }
-
- /// Maps the proof size component of `Weight` to a fee.
- pub struct ProofSizeToFee;
- impl WeightToFeePolynomial for ProofSizeToFee {
- type Balance = Balance;
- fn polynomial() -> WeightToFeeCoefficients {
- // Map 10kb proof to 1 CENT.
- let p = super::currency::CENTS;
- let q = 10_000;
-
- smallvec![WeightToFeeCoefficient {
- degree: 1,
- negative: false,
- coeff_frac: Perbill::from_rational(p % q, q),
- coeff_integer: p / q,
- }]
- }
- }
-}
-
-/// Consensus-related.
-pub mod consensus {
- /// Maximum number of blocks simultaneously accepted by the Runtime, not yet included
- /// into the relay chain.
- pub const UNINCLUDED_SEGMENT_CAPACITY: u32 = 1;
- /// How many parachain blocks are processed by the relay chain per parent. Limits the
- /// number of blocks authored per slot.
- pub const BLOCK_PROCESSING_VELOCITY: u32 = 1;
- /// Relay chain slot duration, in milliseconds.
- pub const RELAY_CHAIN_SLOT_DURATION_MILLIS: u32 = 6000;
-}
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/lib.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/lib.rs
index 4a81c7fb6e3358812cfe0eb6be2459730a89a419..0051af21f9a32b67ff87b0ca3b82373ff4778715 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/lib.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021-2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -59,7 +59,6 @@
#[cfg(feature = "std")]
include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));
-pub mod constants;
mod weights;
pub mod xcm_config;
@@ -82,7 +81,6 @@ use sp_version::NativeVersion;
use sp_version::RuntimeVersion;
use codec::{Decode, Encode, MaxEncodedLen};
-use constants::{consensus::*, currency::*, fee::WeightToFee};
use frame_support::{
construct_runtime,
dispatch::DispatchClass,
@@ -102,6 +100,7 @@ use pallet_nfts::PalletFeatures;
pub use parachains_common as common;
use parachains_common::{
impls::{AssetsToBlockAuthor, DealWithFees},
+ polkadot::{consensus::*, currency::*, fee::WeightToFee},
AccountId, AssetHubPolkadotAuraId as AuraId, AssetIdForTrustBackedAssets, Balance, BlockNumber,
Hash, Header, Nonce, Signature, AVERAGE_ON_INITIALIZE_RATIO, DAYS, HOURS, MAXIMUM_BLOCK_WEIGHT,
NORMAL_DISPATCH_RATIO, SLOT_DURATION,
@@ -1228,8 +1227,9 @@ cumulus_pallet_parachain_system::register_validate_block! {
#[cfg(test)]
mod tests {
- use super::{constants::fee, *};
+ use super::*;
use crate::{CENTS, MILLICENTS};
+ use parachains_common::polkadot::fee;
use sp_runtime::traits::Zero;
use sp_weights::WeightToFee;
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/block_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/block_weights.rs
index b2092d875c8328210667da4cbb95de0642e60ae3..e7fdb2aae2a01ec06076de83d94817e540e205dd 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/block_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/block_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs
index e3c64776ae1c05edc997a7f01e70475c0227411c..65844ce194a0e66415179919a444eacbf6cccbe0 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/extrinsic_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/extrinsic_weights.rs
index 332c3b324bb9c1b386257bf7953d37aba8f5af13..1a4adb968bb7195428ea00d59cd92dcd3b6eea5f 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/extrinsic_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/extrinsic_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/frame_system.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/frame_system.rs
index a2007347211d3ed80780aab58b7ec3f6060cba2a..713c33d34f77f5cc3a5e659a2b31dbbfd5721931 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/frame_system.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/frame_system.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/mod.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/mod.rs
index 2cf514a5598139c5384cdc5fa4092cf9d33f43c7..3eb3b925e651836446a7ea771cb20f9b9444594d 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/mod.rs
@@ -1,3 +1,19 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// This file is part of Cumulus.
+
+// Cumulus 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.
+
+// Cumulus 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 Cumulus. If not, see .
+
pub mod block_weights;
pub mod cumulus_pallet_xcmp_queue;
pub mod extrinsic_weights;
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_assets_foreign.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_assets_foreign.rs
index 817d567c8637c77a4c0a0f28d770dd68f918bc75..51413bb471b953b6724def2d8d009532425c02da 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_assets_foreign.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_assets_foreign.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_assets_local.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_assets_local.rs
index 829b3543ee317022c929eded9365b4665ba18f17..c8420e72ba213fda9f11754552cf05fb84a530d4 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_assets_local.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_assets_local.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_balances.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_balances.rs
index 0da4d38eda247abceef5e0b827a565f4e881cbbf..a7f02ba24fd13ff409e599b5344d8c6a512aa9c9 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_balances.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_balances.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_collator_selection.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_collator_selection.rs
index 6d8828e836cca7fe0b2d7e8a44cdb65e80bb994f..53efb218440a87dbd5557708a42c92ef39add826 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_collator_selection.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_collator_selection.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_multisig.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_multisig.rs
index d51eb85f6dcf5f71aa3e1d88a28234ac5fb1cc03..705aca9e1a4e78222f231a11ca44dd27ac20c70e 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_multisig.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_multisig.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_nfts.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_nfts.rs
index 1a04d8b0991d0039621efe0927e61dfbbe0f976c..6d6f7cbbafb44c31b55def7c36a731aee984bf40 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_nfts.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_nfts.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_proxy.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_proxy.rs
index df0124b471d59ba581562eb0e7ba054b6549dcb3..99db2865692fc6e0316285f4985a974d85dba766 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_proxy.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_proxy.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_session.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_session.rs
index 50c77fd3bc89921a9e7032a05b9d0ffa61c819ff..8a6943d53048047641132a70d6cade4983e503b6 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_session.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_session.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_timestamp.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_timestamp.rs
index 93f7e31120ca68504342a0d3d36eed05235ece77..8c6a2b5505e56afe4b3f32c06d2a3ccb59bc36f0 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_timestamp.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_timestamp.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_uniques.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_uniques.rs
index 3917b594c3f1f113a422c590e91a3f58e965e0af..a88928be65348beb3fc0fe29c893e1de0bacacfe 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_uniques.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_uniques.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_utility.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_utility.rs
index bda0c6e1aa94891b24f726a84f3cc58cef3251f7..c6fc093cc4b44e1396d49b4a74e34eb99f07bd3c 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_utility.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_utility.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_xcm.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_xcm.rs
index 8d14734888b6798f9f205a3845dd5c9977e9edbb..bd7615895e2e96fa95d45389e3296d988fc7057e 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_xcm.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/pallet_xcm.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/paritydb_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/paritydb_weights.rs
index 4338d928d807a41cc60ec91d86e91c81bb253631..25679703831a13b8d1bb7fb7dd4d92fa84b1f255 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/paritydb_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/paritydb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/rocksdb_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/rocksdb_weights.rs
index 1d115d963facb39fe29d6258918fda3bc8d94900..3dd817aa6f137085b0e5fdf2b11b7f50e5c8b002 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/rocksdb_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/rocksdb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/mod.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/mod.rs
index 79f8e83a4f20475f5b1d8c7390c1ac494f4a65a7..55fed809e2b750d96d279c0558264918a8b60eb9 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/mod.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
index 7fea608319f0bf61fd071d1e685f0c05c5945efe..4f64ea3fa1bb37a4a91274de003dbf49349d6e4f 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
index aa7451594f5bc66c8db20f529489279c01547c00..061992691a605b42702a292eeb11e0520160272c 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/xcm_config.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/xcm_config.rs
index c2bc579e2b7152ab8d4fa57503761b95e1517597..5382e2419544f3532990409914b3c06a3f128103 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/xcm_config.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/src/xcm_config.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -28,7 +28,7 @@ use frame_support::{
use frame_system::EnsureRoot;
use pallet_xcm::XcmPassthrough;
use parachains_common::{impls::ToStakingPot, xcm_config::AssetFeeAsExistentialDepositMultiplier};
-use polkadot_parachain::primitives::Sibling;
+use polkadot_parachain_primitives::primitives::Sibling;
use sp_runtime::traits::ConvertInto;
use xcm::latest::prelude::*;
use xcm_builder::{
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/tests/tests.rs b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/tests/tests.rs
index 3eab6723ec20cd23a70f78d6e8afe93abe93199b..7200ebc16a2875336fc50e711386cab41df6c9b4 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-polkadot/tests/tests.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-polkadot/tests/tests.rs
@@ -22,10 +22,9 @@ use asset_hub_polkadot_runtime::xcm_config::{
ForeignCreatorsSovereignAccountOf, TrustBackedAssetsPalletLocation, XcmConfig,
};
pub use asset_hub_polkadot_runtime::{
- constants::fee::WeightToFee, AllPalletsWithoutSystem, AssetDeposit, Assets, Balances,
- ExistentialDeposit, ForeignAssets, ForeignAssetsInstance, MetadataDepositBase,
- MetadataDepositPerByte, ParachainSystem, Runtime, RuntimeCall, RuntimeEvent, SessionKeys,
- System, TrustBackedAssetsInstance,
+ AllPalletsWithoutSystem, AssetDeposit, Assets, Balances, ExistentialDeposit, ForeignAssets,
+ ForeignAssetsInstance, MetadataDepositBase, MetadataDepositPerByte, ParachainSystem, Runtime,
+ RuntimeCall, RuntimeEvent, SessionKeys, System, TrustBackedAssetsInstance,
};
use asset_test_utils::{CollatorSessionKeys, ExtBuilder};
use codec::{Decode, Encode};
@@ -36,7 +35,8 @@ use frame_support::{
weights::{Weight, WeightToFee as WeightToFeeT},
};
use parachains_common::{
- AccountId, AssetHubPolkadotAuraId as AuraId, AssetIdForTrustBackedAssets, Balance,
+ polkadot::fee::WeightToFee, AccountId, AssetHubPolkadotAuraId as AuraId,
+ AssetIdForTrustBackedAssets, Balance,
};
use sp_runtime::traits::MaybeEquivalence;
use xcm::latest::prelude::*;
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/Cargo.toml b/cumulus/parachains/runtimes/assets/asset-hub-westend/Cargo.toml
index 51df65914881d05d93bb13af880b562530ae626b..8c25842cbf3817c31c8e87b32025c1a5fa28c5de 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/Cargo.toml
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/Cargo.toml
@@ -56,12 +56,12 @@ primitive-types = { version = "0.12.1", default-features = false, features = ["c
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
pallet-xcm-benchmarks = { path = "../../../../../polkadot/xcm/pallet-xcm-benchmarks", default-features = false, optional = true }
polkadot-core-primitives = { path = "../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-common = { path = "../../../../../polkadot/runtime/common", default-features = false}
westend-runtime-constants = { path = "../../../../../polkadot/runtime/westend/constants", default-features = false}
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-aura-ext = { path = "../../../../pallets/aura-ext", default-features = false }
@@ -110,7 +110,7 @@ runtime-benchmarks = [
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"polkadot-runtime-common/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
@@ -189,7 +189,7 @@ std = [
"parachain-info/std",
"parachains-common/std",
"polkadot-core-primitives/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"polkadot-runtime-common/std",
"scale-info/std",
"sp-api/std",
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/lib.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/lib.rs
index 48f2bfa45d80637632f02e151c143333bd9fd749..4887fce1b0a4a5d633907cae17697b7793e781c8 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/lib.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021-2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -24,7 +24,6 @@
#[cfg(feature = "std")]
include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));
-pub mod constants;
mod weights;
pub mod xcm_config;
@@ -36,7 +35,6 @@ use assets_common::{
AssetIdForTrustBackedAssetsConvert,
};
use codec::{Decode, Encode, MaxEncodedLen};
-use constants::{consensus::*, currency::*, fee::WeightToFee};
use cumulus_pallet_parachain_system::RelayNumberStrictlyIncreases;
use frame_support::{
construct_runtime,
@@ -57,8 +55,10 @@ use pallet_asset_conversion_tx_payment::AssetConversionAdapter;
use pallet_nfts::PalletFeatures;
pub use parachains_common as common;
use parachains_common::{
- impls::DealWithFees, AccountId, AssetIdForTrustBackedAssets, AuraId, Balance, BlockNumber,
- Hash, Header, Nonce, Signature, AVERAGE_ON_INITIALIZE_RATIO, DAYS, HOURS, MAXIMUM_BLOCK_WEIGHT,
+ impls::DealWithFees,
+ westend::{consensus::*, currency::*, fee::WeightToFee},
+ AccountId, AssetIdForTrustBackedAssets, AuraId, Balance, BlockNumber, Hash, Header, Nonce,
+ Signature, AVERAGE_ON_INITIALIZE_RATIO, DAYS, HOURS, MAXIMUM_BLOCK_WEIGHT,
NORMAL_DISPATCH_RATIO, SLOT_DURATION,
};
use sp_api::impl_runtime_apis;
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/block_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/block_weights.rs
index b2092d875c8328210667da4cbb95de0642e60ae3..e7fdb2aae2a01ec06076de83d94817e540e205dd 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/block_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/block_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/cumulus_pallet_xcmp_queue.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/cumulus_pallet_xcmp_queue.rs
index 55ddfea38d1512e8853f73c6f5c544811bdebd04..cda66f6ea7eee25ece39733cf266dbf16c5c0338 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/cumulus_pallet_xcmp_queue.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/cumulus_pallet_xcmp_queue.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/extrinsic_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/extrinsic_weights.rs
index 332c3b324bb9c1b386257bf7953d37aba8f5af13..1a4adb968bb7195428ea00d59cd92dcd3b6eea5f 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/extrinsic_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/extrinsic_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/frame_system.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/frame_system.rs
index 9ec9befa97c94d9aff38844b0ee0961295db6ea2..c70ea9d58b2649c5f6fbf53cf620757c4aa19f1b 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/frame_system.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/frame_system.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/mod.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/mod.rs
index 955d4690634e8cb7949afe63cefc5ae66e600d14..281c013b3372f57a24b57812de91e684ffabd0c9 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/mod.rs
@@ -1,3 +1,19 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// This file is part of Cumulus.
+
+// Cumulus 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.
+
+// Cumulus 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 Cumulus. If not, see .
+
pub mod block_weights;
pub mod cumulus_pallet_xcmp_queue;
pub mod extrinsic_weights;
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_asset_conversion.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_asset_conversion.rs
index 1744fcbe3977868687b07ce4dabc85263fe010ad..2f39df65403043dad536ccb180c396108c73f487 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_asset_conversion.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_asset_conversion.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_foreign.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_foreign.rs
index 5deffe235cc263cd2dbab3cf412e2d5b65541d11..5be1319b10dfb221230a66429c578248fc30a9d0 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_foreign.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_foreign.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_local.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_local.rs
index 15f4fdecbd2f21b84d60a7399848d8b27ebc94b3..aa09be829c85c6e19d252ad03dd584e34024abc4 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_local.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_local.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_pool.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_pool.rs
index 6101141e3ae1e73ed8034f7ab02599d57f2bd9d6..bfe73e1cfafa5dda9690f4b57f07e08c6ea3b740 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_pool.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_assets_pool.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_balances.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_balances.rs
index db6dd8fef51fd649657a6de9450e2c0823c565b1..f6bf09d63bae20a899301bda372a48ad389c935c 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_balances.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_balances.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_collator_selection.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_collator_selection.rs
index 80da7446bcd6f490ccfb5cfd827a1d4d339bc740..2473c58e45818145674d62c31f6c6a07b6f6794f 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_collator_selection.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_collator_selection.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_multisig.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_multisig.rs
index 230539e94df79b21b36163ed5b107c4624f5e6ff..107d78c98f978f6500f721193fc81ec009204b98 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_multisig.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_multisig.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_nft_fractionalization.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_nft_fractionalization.rs
index 38387a1df0631a123a63cfc655bc4f37cfd1bf1d..e155e1bada3abc8f959404b112d7d393c40c0a61 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_nft_fractionalization.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_nft_fractionalization.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_nfts.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_nfts.rs
index 5c0a53e9333ae469b8d4a9806c9a8cd9fdc9adcf..687dfa07f75148de35519507e1721f61dcf7cee8 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_nfts.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_nfts.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_proxy.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_proxy.rs
index 076d79ff6275e0c351d4cf9d7d19c10aa8957915..657bd2764cf2d88bdb22d322fc7a67f881c9f3be 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_proxy.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_proxy.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_session.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_session.rs
index 8b8e5500d10f87879c95d78b0e5b1dee84bd6c81..926021917441904d3553f996e3fe9074ba1fe97a 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_session.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_session.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_timestamp.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_timestamp.rs
index 40c5f3536097d04ceb13c1b7232129903bd5e5e6..13f18861d37e8d715e0fb19d71bd60af8dcb8321 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_timestamp.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_timestamp.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_uniques.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_uniques.rs
index 813d472709d26d069ce73067fca666a8c8f82bf3..53bead08f5d4cd9ed4388555a58eca1ae183a2ab 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_uniques.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_uniques.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_utility.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_utility.rs
index ca0ead95b15b73181c19850ada621d66b998cd74..7db443ebbf19967d00676518a53909130ae77a86 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_utility.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_utility.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_xcm.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_xcm.rs
index 0256b49be3fe1c25eb011f23d53d9f9b7c0c9c84..1cc4c2d0e24cf205e5ad33bf40e93dd22f864d80 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_xcm.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_xcm.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/paritydb_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/paritydb_weights.rs
index 4338d928d807a41cc60ec91d86e91c81bb253631..25679703831a13b8d1bb7fb7dd4d92fa84b1f255 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/paritydb_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/paritydb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/rocksdb_weights.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/rocksdb_weights.rs
index 1d115d963facb39fe29d6258918fda3bc8d94900..3dd817aa6f137085b0e5fdf2b11b7f50e5c8b002 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/rocksdb_weights.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/rocksdb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/mod.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/mod.rs
index 763cb6c10f13560b9504b5c6843cea6d9c64194d..bb850ac72c07d3ebfe576041bc56a6da5051ab9d 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/mod.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
index ee435559f46ffbeaefbb8517ad2a51124be11fe2..d6763d2fc66f4fb68b9a0b2ed1ade7a7858d6e3d 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
index a1d06914aa64672227bed6b2fba6007652478dcd..e776529eb7f8e0cfdc70dcc76200e1ec21de7aeb 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/xcm_config.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/xcm_config.rs
index ab9439fb67239942d9066543e9055ede56cf25f6..3a5af11465fce27dc6b6aa5099a49d893b8c3ed6 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/xcm_config.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/xcm_config.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -32,7 +32,7 @@ use frame_support::{
use frame_system::EnsureRoot;
use pallet_xcm::XcmPassthrough;
use parachains_common::{impls::ToStakingPot, xcm_config::AssetFeeAsExistentialDepositMultiplier};
-use polkadot_parachain::primitives::Sibling;
+use polkadot_parachain_primitives::primitives::Sibling;
use sp_runtime::traits::ConvertInto;
use xcm::latest::prelude::*;
use xcm_builder::{
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/tests/tests.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/tests/tests.rs
index b2bb511182eb2091dc1fd5c4d9a95baa0e51e970..599ff90e254aa5f4fb745e153b8a3e9b9addb0e8 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/tests/tests.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/tests/tests.rs
@@ -17,13 +17,6 @@
//! Tests for the Westmint (Westend Assets Hub) chain.
-pub use asset_hub_westend_runtime::{
- constants::fee::WeightToFee,
- xcm_config::{CheckingAccount, TrustBackedAssetsPalletLocation, XcmConfig},
- AllowMultiAssetPools, AssetDeposit, Assets, Balances, ExistentialDeposit, ForeignAssets,
- ForeignAssetsInstance, ParachainSystem, Runtime, SessionKeys, System,
- TrustBackedAssetsInstance,
-};
use asset_hub_westend_runtime::{
xcm_config::{
AssetFeeAsExistentialDepositMultiplierFeeCharger, ForeignCreatorsSovereignAccountOf,
@@ -32,6 +25,12 @@ use asset_hub_westend_runtime::{
AllPalletsWithoutSystem, MetadataDepositBase, MetadataDepositPerByte, RuntimeCall,
RuntimeEvent,
};
+pub use asset_hub_westend_runtime::{
+ xcm_config::{CheckingAccount, TrustBackedAssetsPalletLocation, XcmConfig},
+ AllowMultiAssetPools, AssetDeposit, Assets, Balances, ExistentialDeposit, ForeignAssets,
+ ForeignAssetsInstance, ParachainSystem, Runtime, SessionKeys, System,
+ TrustBackedAssetsInstance,
+};
use asset_test_utils::{CollatorSessionKeys, ExtBuilder, XcmReceivedFrom};
use codec::{Decode, DecodeLimit, Encode};
use cumulus_primitives_utility::ChargeWeightInFungibles;
@@ -40,7 +39,9 @@ use frame_support::{
traits::fungibles::InspectEnumerable,
weights::{Weight, WeightToFee as WeightToFeeT},
};
-use parachains_common::{AccountId, AssetIdForTrustBackedAssets, AuraId, Balance};
+use parachains_common::{
+ westend::fee::WeightToFee, AccountId, AssetIdForTrustBackedAssets, AuraId, Balance,
+};
use sp_io;
use sp_runtime::traits::MaybeEquivalence;
use std::convert::Into;
diff --git a/cumulus/parachains/runtimes/assets/common/Cargo.toml b/cumulus/parachains/runtimes/assets/common/Cargo.toml
index cdb7b87dacbffbcd64c2e9fdf2e70a114a071cdf..a8b5f3f8c6b9db84e8c18b654cc0379a641ced1c 100644
--- a/cumulus/parachains/runtimes/assets/common/Cargo.toml
+++ b/cumulus/parachains/runtimes/assets/common/Cargo.toml
@@ -21,9 +21,9 @@ pallet-asset-tx-payment = { path = "../../../../../substrate/frame/transaction-p
# Polkadot
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
parachains-common = { path = "../../../common", default-features = false }
diff --git a/cumulus/parachains/runtimes/assets/common/src/foreign_creators.rs b/cumulus/parachains/runtimes/assets/common/src/foreign_creators.rs
index 00f336f9c68239f8d51b83fa15dd5553fd5fce9a..1ed7bd0538c287bba5255c41145a1c3fa3a10064 100644
--- a/cumulus/parachains/runtimes/assets/common/src/foreign_creators.rs
+++ b/cumulus/parachains/runtimes/assets/common/src/foreign_creators.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/common/src/fungible_conversion.rs b/cumulus/parachains/runtimes/assets/common/src/fungible_conversion.rs
index 5aa5a69caa941de30a40a2930fd08a0f84fe472f..80f8a971d21781004e264600c67a62f9a18c2ce4 100644
--- a/cumulus/parachains/runtimes/assets/common/src/fungible_conversion.rs
+++ b/cumulus/parachains/runtimes/assets/common/src/fungible_conversion.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/common/src/lib.rs b/cumulus/parachains/runtimes/assets/common/src/lib.rs
index 25ab296ff1c6c068d01e420e907e1115f59238dc..560a89b131c03520da8a574620f8641f87e66ccf 100644
--- a/cumulus/parachains/runtimes/assets/common/src/lib.rs
+++ b/cumulus/parachains/runtimes/assets/common/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/common/src/local_and_foreign_assets.rs b/cumulus/parachains/runtimes/assets/common/src/local_and_foreign_assets.rs
index 72fd9e7a9165de2227d9d26b59eb557727740040..5c66d1cabe571a5098f85fba47a81a4058cacbd6 100644
--- a/cumulus/parachains/runtimes/assets/common/src/local_and_foreign_assets.rs
+++ b/cumulus/parachains/runtimes/assets/common/src/local_and_foreign_assets.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -13,19 +13,16 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-use frame_support::{
- pallet_prelude::DispatchError,
- traits::{
- fungibles::{Balanced, Create, HandleImbalanceDrop, Inspect, Mutate, Unbalanced},
- tokens::{
- DepositConsequence, Fortitude, Precision, Preservation, Provenance, WithdrawConsequence,
- },
- AccountTouch, Contains, ContainsPair, Get, PalletInfoAccess,
+use frame_support::traits::{
+ fungibles::{Balanced, Create, HandleImbalanceDrop, Inspect, Mutate, Unbalanced},
+ tokens::{
+ DepositConsequence, Fortitude, Precision, Preservation, Provenance, WithdrawConsequence,
},
+ AccountTouch, Contains, ContainsPair, Get, PalletInfoAccess,
};
use pallet_asset_conversion::{MultiAssetIdConversionResult, MultiAssetIdConverter};
use parachains_common::AccountId;
-use sp_runtime::{traits::MaybeEquivalence, DispatchResult};
+use sp_runtime::{traits::MaybeEquivalence, DispatchError, DispatchResult};
use sp_std::{boxed::Box, marker::PhantomData};
use xcm::latest::MultiLocation;
diff --git a/cumulus/parachains/runtimes/assets/common/src/matching.rs b/cumulus/parachains/runtimes/assets/common/src/matching.rs
index 964f25cda35194633ca7a2c84b9989c7e219dc8e..08d391170014cfb0958887c09372f6e368910a56 100644
--- a/cumulus/parachains/runtimes/assets/common/src/matching.rs
+++ b/cumulus/parachains/runtimes/assets/common/src/matching.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/common/src/runtime_api.rs b/cumulus/parachains/runtimes/assets/common/src/runtime_api.rs
index 7eee95bb3b648d4a1bf64973d2243eb132fc2826..0a166a048193998fe15b1f35f3e667a76d71540b 100644
--- a/cumulus/parachains/runtimes/assets/common/src/runtime_api.rs
+++ b/cumulus/parachains/runtimes/assets/common/src/runtime_api.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/assets/test-utils/Cargo.toml b/cumulus/parachains/runtimes/assets/test-utils/Cargo.toml
index baf66a15872532e7b492336538457d155d1e2190..7fee710f000c0d2bd44f6ddfba81e0b5c7eb1d3f 100644
--- a/cumulus/parachains/runtimes/assets/test-utils/Cargo.toml
+++ b/cumulus/parachains/runtimes/assets/test-utils/Cargo.toml
@@ -35,10 +35,10 @@ parachain-info = { path = "../../../pallets/parachain-info", default-features =
parachains-runtimes-test-utils = { path = "../../test-utils", default-features = false }
# Polkadot
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
[dev-dependencies]
hex-literal = "0.4.1"
@@ -66,7 +66,7 @@ std = [
"parachain-info/std",
"parachains-common/std",
"parachains-runtimes-test-utils/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"sp-consensus-aura/std",
"sp-core/std",
"sp-io/std",
diff --git a/cumulus/parachains/runtimes/assets/test-utils/src/lib.rs b/cumulus/parachains/runtimes/assets/test-utils/src/lib.rs
index 9a24867592e2adbf6b6a79d4baada39a04786a0c..7177726e07046e1d55a015016e88924db418077a 100644
--- a/cumulus/parachains/runtimes/assets/test-utils/src/lib.rs
+++ b/cumulus/parachains/runtimes/assets/test-utils/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/assets/test-utils/src/test_cases.rs b/cumulus/parachains/runtimes/assets/test-utils/src/test_cases.rs
index f11d590f4afa2effbff97a4b59fc7854eb32d568..7a8d571403c6b5c5f856dd30c08eaa092423cda5 100644
--- a/cumulus/parachains/runtimes/assets/test-utils/src/test_cases.rs
+++ b/cumulus/parachains/runtimes/assets/test-utils/src/test_cases.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/README.md b/cumulus/parachains/runtimes/bridge-hubs/README.md
index 1520065b7e3a47656c7215bdf2c3883c03c0c379..487c601ef84023310fe7e15c5642ca060c9e550b 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/README.md
+++ b/cumulus/parachains/runtimes/bridge-hubs/README.md
@@ -1,26 +1,26 @@
- [Bridge-hub Parachains](#bridge-hub-parachains)
- * [Requirements for local run/testing](#requirements-for-local-runtesting)
- * [How to test local Rococo <-> Wococo bridge](#how-to-test-local-rococo---wococo-bridge)
- + [Run chains (Rococo + BridgeHub, Wococo + BridgeHub) with zombienet](#run-chains-rococo--bridgehub-wococo--bridgehub-with-zombienet)
- + [Run relayer (BridgeHubRococo, BridgeHubWococo)](#run-relayer-bridgehubrococo-bridgehubwococo)
+ - [Requirements for local run/testing](#requirements-for-local-runtesting)
+ - [How to test local Rococo <-> Wococo bridge](#how-to-test-local-rococo---wococo-bridge)
+ - [Run chains (Rococo + BridgeHub, Wococo + BridgeHub) with
+ zombienet](#run-chains-rococo--bridgehub-wococo--bridgehub-with-zombienet)
+ - [Run relayer (BridgeHubRococo, BridgeHubWococo)](#run-relayer-bridgehubrococo-bridgehubwococo)
- [Run with script (alternative 1)](#run-with-script-alternative-1)
- [Run with binary (alternative 2)](#run-with-binary-alternative-2)
- + [Send messages - transfer asset over bridge](#send-messages---transfer-asset-over-bridge)
- * [How to test live BridgeHubRococo/BridgeHubWococo](#how-to-test-live-bridgehubrococobridgehubwococo)
- * [How to test local BridgeHubKusama/BridgeHubPolkadot](#how-to-test-local-bridgehubkusamabridgehubpolkadot)
+ - [Send messages - transfer asset over bridge](#send-messages---transfer-asset-over-bridge)
+ - [How to test live BridgeHubRococo/BridgeHubWococo](#how-to-test-live-bridgehubrococobridgehubwococo)
+ - [How to test local BridgeHubKusama/BridgeHubPolkadot](#how-to-test-local-bridgehubkusamabridgehubpolkadot)
# Bridge-hub Parachains
-_BridgeHub(s)_ are **_system parachains_** that will house trustless bridges from the local
-ecosystem to others.
-The current trustless bridges planned for the BridgeHub(s) are:
+_BridgeHub(s)_ are **_system parachains_** that will house trustless bridges from the local ecosystem to others. The
+current trustless bridges planned for the BridgeHub(s) are:
- `BridgeHubPolkadot` system parachain:
1. Polkadot <-> Kusama bridge
2. Polkadot <-> Ethereum bridge (Snowbridge)
- `BridgeHubKusama` system parachain:
1. Kusama <-> Polkadot bridge
- 2. Kusama <-> Ethereum bridge
- The high-level responsibilities of each bridge living on BridgeHub:
+ 2. Kusama <-> Ethereum bridge The high-level
+ responsibilities of each bridge living on BridgeHub:
- sync finality proofs between relay chains (or equivalent)
- sync finality proofs between BridgeHub parachains
- pass (XCM) messages between different BridgeHub parachains
@@ -192,43 +192,40 @@ RUST_LOG=runtime=trace,rpc=trace,bridge=trace \
```
**Check relay-chain headers relaying:**
-- Rococo parachain:
- - https://polkadot.js.org/apps/?rpc=ws%3A%2F%2F127.0.0.1%3A8943#/chainstate
- - Pallet: **bridgeWococoGrandpa**
- - Keys: **bestFinalized()**
-- Wococo parachain:
- - https://polkadot.js.org/apps/?rpc=ws%3A%2F%2F127.0.0.1%3A8945#/chainstate
- - Pallet: **bridgeRococoGrandpa**
- - Keys: **bestFinalized()**
+- Rococo parachain: - https://polkadot.js.org/apps/?rpc=ws%3A%2F%2F127.0.0.1%3A8943#/chainstate - Pallet:
+ **bridgeWococoGrandpa** - Keys: **bestFinalized()**
+- Wococo parachain: - https://polkadot.js.org/apps/?rpc=ws%3A%2F%2F127.0.0.1%3A8945#/chainstate - Pallet:
+ **bridgeRococoGrandpa** - Keys: **bestFinalized()**
**Check parachain headers relaying:**
-- Rococo parachain:
- - https://polkadot.js.org/apps/?rpc=ws%3A%2F%2F127.0.0.1%3A8943#/chainstate
- - Pallet: **bridgeWococoParachain**
- - Keys: **bestParaHeads()**
-- Wococo parachain:
- - https://polkadot.js.org/apps/?rpc=ws%3A%2F%2F127.0.0.1%3A8945#/chainstate
- - Pallet: **bridgeRococoParachain**
- - Keys: **bestParaHeads()**
+- Rococo parachain: - https://polkadot.js.org/apps/?rpc=ws%3A%2F%2F127.0.0.1%3A8943#/chainstate - Pallet:
+ **bridgeWococoParachain** - Keys: **bestParaHeads()**
+- Wococo parachain: - https://polkadot.js.org/apps/?rpc=ws%3A%2F%2F127.0.0.1%3A8945#/chainstate - Pallet:
+ **bridgeRococoParachain** - Keys: **bestParaHeads()**
### Send messages - transfer asset over bridge
TODO: see `# !!! READ HERE` above
## How to test live BridgeHubRococo/BridgeHubWococo
-(here is still deployed older PoC from branch `origin/bko-transfer-asset-via-bridge`, which uses custom extrinsic, which is going to be replaced by `pallet_xcm` usage)
+(here is still deployed older PoC from branch `origin/bko-transfer-asset-via-bridge`, which uses custom extrinsic, which
+is going to be replaced by `pallet_xcm` usage)
- uses account seed on Live Rococo:Rockmine2
```
cd
./scripts/bridges_rococo_wococo.sh transfer-asset-from-asset-hub-rococo
```
-- open explorers:
- - Rockmine2 (see events `xcmpQueue.XcmpMessageSent`, `bridgeTransfer.ReserveAssetsDeposited`, `bridgeTransfer.TransferInitiated`) https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fws-rococo-rockmine2-collator-node-0.parity-testnet.parity.io#/explorer
- - BridgeHubRococo (see `bridgeWococoMessages.MessageAccepted`) https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Frococo-bridge-hub-rpc.polkadot.io#/explorer
- - BridgeHubWococo (see `bridgeRococoMessages.MessagesReceived`) https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fwococo-bridge-hub-rpc.polkadot.io#/explorer
- - Wockmint (see `xcmpQueue.Success` for `transfer-asset` and `xcmpQueue.Fail` for `ping-via-bridge`) https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fwococo-wockmint-rpc.polkadot.io#/explorer
- - BridgeHubRococo (see `bridgeWococoMessages.MessagesDelivered`)
+- open explorers: - Rockmine2 (see events `xcmpQueue.XcmpMessageSent`, `bridgeTransfer.ReserveAssetsDeposited`,
+ `bridgeTransfer.TransferInitiated`)
+ https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fws-rococo-rockmine2-collator-node-0.parity-testnet.parity.io#/explorer
+ - BridgeHubRococo (see `bridgeWococoMessages.MessageAccepted`)
+ https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Frococo-bridge-hub-rpc.polkadot.io#/explorer - BridgeHubWococo (see
+ `bridgeRococoMessages.MessagesReceived`)
+ https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fwococo-bridge-hub-rpc.polkadot.io#/explorer - Wockmint (see
+ `xcmpQueue.Success` for `transfer-asset` and `xcmpQueue.Fail` for `ping-via-bridge`)
+ https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fwococo-wockmint-rpc.polkadot.io#/explorer - BridgeHubRococo (see
+ `bridgeWococoMessages.MessagesDelivered`)
## How to test local BridgeHubKusama/BridgeHubPolkadot
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/Cargo.toml b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/Cargo.toml
index f29ee82b7cb58dc4db995df591395711f9f03fba..91eb7adc61feeafb4d060e59039a40df999eaa3d 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/Cargo.toml
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/Cargo.toml
@@ -13,7 +13,7 @@ codec = { package = "parity-scale-codec", version = "3.0.0", default-features =
hex-literal = { version = "0.4.1" }
log = { version = "0.4.20", default-features = false }
scale-info = { version = "2.9.0", default-features = false, features = ["derive"] }
-serde = { version = "1.0.183", optional = true, features = ["derive"] }
+serde = { version = "1.0.188", optional = true, features = ["derive"] }
smallvec = "1.11.0"
# Substrate
@@ -52,11 +52,11 @@ kusama-runtime-constants = { path = "../../../../../polkadot/runtime/kusama/cons
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
pallet-xcm-benchmarks = { path = "../../../../../polkadot/xcm/pallet-xcm-benchmarks", default-features = false, optional = true }
polkadot-core-primitives = { path = "../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-common = { path = "../../../../../polkadot/runtime/common", default-features = false}
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-aura-ext = { path = "../../../../pallets/aura-ext", default-features = false }
@@ -110,7 +110,7 @@ std = [
"parachain-info/std",
"parachains-common/std",
"polkadot-core-primitives/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"polkadot-runtime-common/std",
"scale-info/std",
"serde",
@@ -148,7 +148,7 @@ runtime-benchmarks = [
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"polkadot-runtime-common/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/constants.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/constants.rs
deleted file mode 100644
index f0908fcd4395095378ef7721d88fc59e65591e3b..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/constants.rs
+++ /dev/null
@@ -1,117 +0,0 @@
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
-// SPDX-License-Identifier: Apache-2.0
-
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-pub mod currency {
- use kusama_runtime_constants as constants;
- use polkadot_core_primitives::Balance;
-
- /// The existential deposit. Set to 1/10 of its parent Relay Chain.
- pub const EXISTENTIAL_DEPOSIT: Balance = constants::currency::EXISTENTIAL_DEPOSIT / 10;
-
- pub const UNITS: Balance = constants::currency::UNITS;
- pub const CENTS: Balance = constants::currency::CENTS;
- pub const MILLICENTS: Balance = constants::currency::MILLICENTS;
-
- pub const fn deposit(items: u32, bytes: u32) -> Balance {
- // map to 1/100 of what the kusama relay chain charges (v9020)
- constants::currency::deposit(items, bytes) / 100
- }
-}
-
-/// Fee-related.
-pub mod fee {
- use frame_support::{
- pallet_prelude::Weight,
- weights::{
- constants::ExtrinsicBaseWeight, FeePolynomial, WeightToFeeCoefficient,
- WeightToFeeCoefficients, WeightToFeePolynomial,
- },
- };
- use polkadot_core_primitives::Balance;
- use smallvec::smallvec;
- pub use sp_runtime::Perbill;
-
- /// Handles converting a weight scalar to a fee value, based on the scale and granularity of the
- /// node's balance type.
- ///
- /// This should typically create a mapping between the following ranges:
- /// - [0, MAXIMUM_BLOCK_WEIGHT]
- /// - [Balance::min, Balance::max]
- ///
- /// Yet, it can be used for any other sort of change to weight-fee. Some examples being:
- /// - Setting it to `0` will essentially disable the weight fee.
- /// - Setting it to `1` will cause the literal `#[weight = x]` values to be charged.
- pub struct WeightToFee;
- impl frame_support::weights::WeightToFee for WeightToFee {
- type Balance = Balance;
-
- fn weight_to_fee(weight: &Weight) -> Self::Balance {
- let time_poly: FeePolynomial = RefTimeToFee::polynomial().into();
- let proof_poly: FeePolynomial = ProofSizeToFee::polynomial().into();
-
- // Take the maximum instead of the sum to charge by the more scarce resource.
- time_poly.eval(weight.ref_time()).max(proof_poly.eval(weight.proof_size()))
- }
- }
-
- /// Maps the reference time component of `Weight` to a fee.
- pub struct RefTimeToFee;
- impl WeightToFeePolynomial for RefTimeToFee {
- type Balance = Balance;
- fn polynomial() -> WeightToFeeCoefficients {
- // in Kusama, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
- // in Bridge Hub, we map to 1/10 of that, or 1/100 CENT
- let p = super::currency::CENTS;
- let q = 100 * Balance::from(ExtrinsicBaseWeight::get().ref_time());
-
- smallvec![WeightToFeeCoefficient {
- degree: 1,
- negative: false,
- coeff_frac: Perbill::from_rational(p % q, q),
- coeff_integer: p / q,
- }]
- }
- }
-
- /// Maps the proof size component of `Weight` to a fee.
- pub struct ProofSizeToFee;
- impl WeightToFeePolynomial for ProofSizeToFee {
- type Balance = Balance;
- fn polynomial() -> WeightToFeeCoefficients {
- // Map 10kb proof to 1 CENT.
- let p = super::currency::CENTS;
- let q = 10_000;
-
- smallvec![WeightToFeeCoefficient {
- degree: 1,
- negative: false,
- coeff_frac: Perbill::from_rational(p % q, q),
- coeff_integer: p / q,
- }]
- }
- }
-}
-
-/// Consensus-related.
-pub mod consensus {
- /// Maximum number of blocks simultaneously accepted by the Runtime, not yet included
- /// into the relay chain.
- pub const UNINCLUDED_SEGMENT_CAPACITY: u32 = 1;
- /// How many parachain blocks are processed by the relay chain per parent. Limits the
- /// number of blocks authored per slot.
- pub const BLOCK_PROCESSING_VELOCITY: u32 = 1;
- /// Relay chain slot duration, in milliseconds.
- pub const RELAY_CHAIN_SLOT_DURATION_MILLIS: u32 = 6000;
-}
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/lib.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/lib.rs
index af00e06c78113e42f29bdab1c358e91ef8741848..54b15e6b327b51eefefcb22e9987aac287401192 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/lib.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -22,7 +22,6 @@
#[cfg(feature = "std")]
include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));
-pub mod constants;
mod weights;
pub mod xcm_config;
@@ -41,7 +40,6 @@ use sp_std::prelude::*;
use sp_version::NativeVersion;
use sp_version::RuntimeVersion;
-use constants::{consensus::*, currency::*, fee::WeightToFee};
use frame_support::{
construct_runtime,
dispatch::DispatchClass,
@@ -69,8 +67,10 @@ use polkadot_runtime_common::{BlockHashCount, SlowAdjustingFeeUpdate};
use weights::{BlockExecutionWeight, ExtrinsicBaseWeight, RocksDbWeight};
use parachains_common::{
- impls::DealWithFees, AccountId, Balance, BlockNumber, Hash, Header, Nonce, Signature,
- AVERAGE_ON_INITIALIZE_RATIO, HOURS, MAXIMUM_BLOCK_WEIGHT, NORMAL_DISPATCH_RATIO, SLOT_DURATION,
+ impls::DealWithFees,
+ kusama::{consensus::*, currency::*, fee::WeightToFee},
+ AccountId, Balance, BlockNumber, Hash, Header, Nonce, Signature, AVERAGE_ON_INITIALIZE_RATIO,
+ HOURS, MAXIMUM_BLOCK_WEIGHT, NORMAL_DISPATCH_RATIO, SLOT_DURATION,
};
// XCM Imports
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/block_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/block_weights.rs
index b2092d875c8328210667da4cbb95de0642e60ae3..e7fdb2aae2a01ec06076de83d94817e540e205dd 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/block_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/block_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/cumulus_pallet_xcmp_queue.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/cumulus_pallet_xcmp_queue.rs
index 83b242f045992b54f12e199366282463b516ea2a..991cba573bf2a64bf917f5c50a246354c7f82355 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/cumulus_pallet_xcmp_queue.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/cumulus_pallet_xcmp_queue.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/extrinsic_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/extrinsic_weights.rs
index 332c3b324bb9c1b386257bf7953d37aba8f5af13..1a4adb968bb7195428ea00d59cd92dcd3b6eea5f 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/extrinsic_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/extrinsic_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/frame_system.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/frame_system.rs
index 83b8ec960fb12a71399b7d8461fedb9e49c07823..5a0a60cc9952dc8f7eb98458a848b24b9c166f3a 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/frame_system.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/frame_system.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/mod.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/mod.rs
index d5722374defcfc6c9efc6579031a369208807187..e226021e77ab58d51bda2eaa23ff732d53e7f4cb 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/mod.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_balances.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_balances.rs
index 1387ee30c7d37485a1c1c42636150b9bb624fe41..51ca2e660b3b578a5d23e38eb215e2b4a5c5debc 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_balances.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_balances.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_collator_selection.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_collator_selection.rs
index 7854bf88e404aeac79e2361c884f9d45ab40d1fb..fa0ac199ca2c06d07a757e191d9a00e9e1f9cb7e 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_collator_selection.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_collator_selection.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_multisig.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_multisig.rs
index 14b11f9380a6720afecea7479f02d648d1c6a79a..96b2d859ed864d8a368bc258038890825c8b4d36 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_multisig.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_multisig.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_session.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_session.rs
index 69371604e796013cdad7edfbfd2290c23590307a..cc1b4aeb0ddb6718b57ebfd65c985fc4071867b1 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_session.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_session.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_timestamp.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_timestamp.rs
index 31830fbc722e69d942ace4d5cfb6dadff215480d..32f6e4a6b43598cf3b3b6a6df7a571bd38f44697 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_timestamp.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_timestamp.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_utility.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_utility.rs
index f871f81b756f3f14cf3984b32073f59581b088d9..15b06676cd364efcd9d80361f7f7437cab032efe 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_utility.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_utility.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_xcm.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_xcm.rs
index e2effcd36df687b9bdaac1f5a74a25f504086462..71bc583077100ecb9edfbca039a9c7b539ff6d66 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_xcm.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/pallet_xcm.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/paritydb_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/paritydb_weights.rs
index 4338d928d807a41cc60ec91d86e91c81bb253631..25679703831a13b8d1bb7fb7dd4d92fa84b1f255 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/paritydb_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/paritydb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/rocksdb_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/rocksdb_weights.rs
index 1d115d963facb39fe29d6258918fda3bc8d94900..3dd817aa6f137085b0e5fdf2b11b7f50e5c8b002 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/rocksdb_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/rocksdb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/mod.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/mod.rs
index 295e222f27ac54af2ab24cc3880efae03971910c..0e740922f339de717f04f0881c165786c36ba47a 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/mod.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
index 4ebc6eacb9fb081dc995336d372d5f9b9b1393dd..6c8c7ab66bbdb8e149a04e56b59f9a4fe7a75722 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
index d38d177a605c7d485130dd78bd37bb3594c110ac..b1e8107b30bbddb9e30f0bf3c648627993fa4448 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/xcm_config.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/xcm_config.rs
index 8723b57083f9816370b45f3064eb0691305e16fe..518a55d78c59e67a6ea3a85e8e0689b4d915da31 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/xcm_config.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/src/xcm_config.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -25,7 +25,7 @@ use frame_support::{
use frame_system::EnsureRoot;
use pallet_xcm::XcmPassthrough;
use parachains_common::{impls::ToStakingPot, xcm_config::ConcreteNativeAssetFrom};
-use polkadot_parachain::primitives::Sibling;
+use polkadot_parachain_primitives::primitives::Sibling;
use xcm::latest::prelude::*;
use xcm_builder::{
AccountId32Aliases, AllowExplicitUnpaidExecutionFrom, AllowKnownQueryResponses,
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/tests/tests.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/tests/tests.rs
index c9215b6157c37c6ffff820aa8d6b956c3ee5bf96..893524e12f66230f5de2a48966344b8b93f08489 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/tests/tests.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-kusama/tests/tests.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -15,12 +15,12 @@
// along with Cumulus. If not, see .
pub use bridge_hub_kusama_runtime::{
- constants::fee::WeightToFee, xcm_config::XcmConfig, AllPalletsWithoutSystem, Balances,
- ExistentialDeposit, ParachainSystem, PolkadotXcm, Runtime, RuntimeEvent, SessionKeys,
+ xcm_config::XcmConfig, AllPalletsWithoutSystem, Balances, ExistentialDeposit, ParachainSystem,
+ PolkadotXcm, Runtime, RuntimeEvent, SessionKeys,
};
use codec::Decode;
use frame_support::parameter_types;
-use parachains_common::{AccountId, AuraId};
+use parachains_common::{kusama::fee::WeightToFee, AccountId, AuraId};
const ALICE: [u8; 32] = [1u8; 32];
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/Cargo.toml b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/Cargo.toml
index 87afb20eb9066d1708dbf10f0aff5cd2df5c557f..52a866b7097149da2be98bf32403bbb4877f0292 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/Cargo.toml
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/Cargo.toml
@@ -13,7 +13,7 @@ codec = { package = "parity-scale-codec", version = "3.0.0", default-features =
hex-literal = { version = "0.4.1" }
log = { version = "0.4.20", default-features = false }
scale-info = { version = "2.9.0", default-features = false, features = ["derive"] }
-serde = { version = "1.0.183", optional = true, features = ["derive"] }
+serde = { version = "1.0.188", optional = true, features = ["derive"] }
smallvec = "1.11.0"
# Substrate
@@ -52,11 +52,11 @@ polkadot-runtime-constants = { path = "../../../../../polkadot/runtime/polkadot/
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
pallet-xcm-benchmarks = { path = "../../../../../polkadot/xcm/pallet-xcm-benchmarks", default-features = false, optional = true }
polkadot-core-primitives = { path = "../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-common = { path = "../../../../../polkadot/runtime/common", default-features = false}
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-aura-ext = { path = "../../../../pallets/aura-ext", default-features = false }
@@ -109,7 +109,7 @@ std = [
"parachain-info/std",
"parachains-common/std",
"polkadot-core-primitives/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"polkadot-runtime-common/std",
"polkadot-runtime-constants/std",
"scale-info/std",
@@ -148,7 +148,7 @@ runtime-benchmarks = [
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"polkadot-runtime-common/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/constants.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/constants.rs
deleted file mode 100644
index a42c3e4f85d2a061639a95ac6866df0e07700a28..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/constants.rs
+++ /dev/null
@@ -1,117 +0,0 @@
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
-// SPDX-License-Identifier: Apache-2.0
-
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-pub mod currency {
- use polkadot_core_primitives::Balance;
- use polkadot_runtime_constants as constants;
-
- /// The existential deposit. Set to 1/10 of its parent Relay Chain.
- pub const EXISTENTIAL_DEPOSIT: Balance = constants::currency::EXISTENTIAL_DEPOSIT / 10;
-
- pub const UNITS: Balance = constants::currency::UNITS;
- pub const CENTS: Balance = constants::currency::CENTS;
- pub const MILLICENTS: Balance = constants::currency::MILLICENTS;
-
- pub const fn deposit(items: u32, bytes: u32) -> Balance {
- // 1/100 of Polkadot
- constants::currency::deposit(items, bytes) / 100
- }
-}
-
-/// Fee-related.
-pub mod fee {
- use frame_support::{
- pallet_prelude::Weight,
- weights::{
- constants::ExtrinsicBaseWeight, FeePolynomial, WeightToFeeCoefficient,
- WeightToFeeCoefficients, WeightToFeePolynomial,
- },
- };
- use polkadot_core_primitives::Balance;
- use smallvec::smallvec;
- pub use sp_runtime::Perbill;
-
- /// Handles converting a weight scalar to a fee value, based on the scale and granularity of the
- /// node's balance type.
- ///
- /// This should typically create a mapping between the following ranges:
- /// - [0, MAXIMUM_BLOCK_WEIGHT]
- /// - [Balance::min, Balance::max]
- ///
- /// Yet, it can be used for any other sort of change to weight-fee. Some examples being:
- /// - Setting it to `0` will essentially disable the weight fee.
- /// - Setting it to `1` will cause the literal `#[weight = x]` values to be charged.
- pub struct WeightToFee;
- impl frame_support::weights::WeightToFee for WeightToFee {
- type Balance = Balance;
-
- fn weight_to_fee(weight: &Weight) -> Self::Balance {
- let time_poly: FeePolynomial = RefTimeToFee::polynomial().into();
- let proof_poly: FeePolynomial = ProofSizeToFee::polynomial().into();
-
- // Take the maximum instead of the sum to charge by the more scarce resource.
- time_poly.eval(weight.ref_time()).max(proof_poly.eval(weight.proof_size()))
- }
- }
-
- /// Maps the reference time component of `Weight` to a fee.
- pub struct RefTimeToFee;
- impl WeightToFeePolynomial for RefTimeToFee {
- type Balance = Balance;
- fn polynomial() -> WeightToFeeCoefficients {
- // in Polkadot, extrinsic base weight (smallest non-zero weight) is mapped to 1/10 CENT:
- // in Bridge Hub, we map to 1/10 of that, or 1/100 CENT
- let p = super::currency::CENTS;
- let q = 100 * Balance::from(ExtrinsicBaseWeight::get().ref_time());
-
- smallvec![WeightToFeeCoefficient {
- degree: 1,
- negative: false,
- coeff_frac: Perbill::from_rational(p % q, q),
- coeff_integer: p / q,
- }]
- }
- }
-
- /// Maps the proof size component of `Weight` to a fee.
- pub struct ProofSizeToFee;
- impl WeightToFeePolynomial for ProofSizeToFee {
- type Balance = Balance;
- fn polynomial() -> WeightToFeeCoefficients {
- // Map 10kb proof to 1 CENT.
- let p = super::currency::CENTS;
- let q = 10_000;
-
- smallvec![WeightToFeeCoefficient {
- degree: 1,
- negative: false,
- coeff_frac: Perbill::from_rational(p % q, q),
- coeff_integer: p / q,
- }]
- }
- }
-}
-
-/// Consensus-related.
-pub mod consensus {
- /// Maximum number of blocks simultaneously accepted by the Runtime, not yet included
- /// into the relay chain.
- pub const UNINCLUDED_SEGMENT_CAPACITY: u32 = 1;
- /// How many parachain blocks are processed by the relay chain per parent. Limits the
- /// number of blocks authored per slot.
- pub const BLOCK_PROCESSING_VELOCITY: u32 = 1;
- /// Relay chain slot duration, in milliseconds.
- pub const RELAY_CHAIN_SLOT_DURATION_MILLIS: u32 = 6000;
-}
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/lib.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/lib.rs
index 0a6bddb225717341d7c6c2abcf745160b59c825e..dbfdc249a3cd7aad3cb5482f4f4a5e3a5493e0a0 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/lib.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -22,7 +22,6 @@
#[cfg(feature = "std")]
include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));
-pub mod constants;
mod weights;
pub mod xcm_config;
@@ -41,7 +40,6 @@ use sp_std::prelude::*;
use sp_version::NativeVersion;
use sp_version::RuntimeVersion;
-use constants::{consensus::*, currency::*, fee::WeightToFee};
use frame_support::{
construct_runtime,
dispatch::DispatchClass,
@@ -70,8 +68,10 @@ use polkadot_runtime_common::{BlockHashCount, SlowAdjustingFeeUpdate};
use weights::{BlockExecutionWeight, ExtrinsicBaseWeight, RocksDbWeight};
use parachains_common::{
- impls::DealWithFees, AccountId, Balance, BlockNumber, Hash, Header, Nonce, Signature,
- AVERAGE_ON_INITIALIZE_RATIO, HOURS, MAXIMUM_BLOCK_WEIGHT, NORMAL_DISPATCH_RATIO, SLOT_DURATION,
+ impls::DealWithFees,
+ polkadot::{consensus::*, currency::*, fee::WeightToFee},
+ AccountId, Balance, BlockNumber, Hash, Header, Nonce, Signature, AVERAGE_ON_INITIALIZE_RATIO,
+ HOURS, MAXIMUM_BLOCK_WEIGHT, NORMAL_DISPATCH_RATIO, SLOT_DURATION,
};
// XCM Imports
use xcm::latest::prelude::BodyId;
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/block_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/block_weights.rs
index 2bd7975bf98c36996520716c9dc11822d8287234..e7fdb2aae2a01ec06076de83d94817e540e205dd 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/block_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/block_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs
index 740c3e9dd0a189ccefdc54a20763bfcb2e036816..98834cc44e880e432c13c4b1b3d8a5dfe3cbf624 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/extrinsic_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/extrinsic_weights.rs
index 898d72ec5b19519a77ec0b75bb65d757213b35d4..1a4adb968bb7195428ea00d59cd92dcd3b6eea5f 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/extrinsic_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/extrinsic_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/frame_system.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/frame_system.rs
index 62883b2d9073faf1a68cd69bc07b7af64145caf5..4aeb4660d8786b81100e26f1309dc2be8898e874 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/frame_system.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/frame_system.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/mod.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/mod.rs
index 457d00f36bd9ab44b2a72828eee6d2fc81a3e495..e226021e77ab58d51bda2eaa23ff732d53e7f4cb 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/mod.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_balances.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_balances.rs
index d58126b3fd61aa6bfb2e8498b51d5d496f73d251..5abe64bb411750f714e65038a2c750932240f2f7 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_balances.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_balances.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_collator_selection.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_collator_selection.rs
index 0b153be27193d75b5a135278b4cca96520ccce5e..e0f4156fe4d4c4d3f31229bdaa6308456a5cabb7 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_collator_selection.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_collator_selection.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_multisig.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_multisig.rs
index 9984823b1c16ae6a232c30fa4edfac5d91d9b198..4625c4f474ea2f807652e549898a0f38be510554 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_multisig.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_multisig.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_session.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_session.rs
index 3b74d0afd189d112ddb3f6a767118e4184487307..29bc576ebc80d13e02f52837a5eae57436f278ff 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_session.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_session.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_timestamp.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_timestamp.rs
index fdb3c2ac9596999d30f0c8398c882a1ce7b66ea2..8252834cc11e3cebb131332a92ffc80d25921dd4 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_timestamp.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_timestamp.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_utility.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_utility.rs
index a7b31d3d38530ef685410dd83d5d41835b2de131..5205e9fff8593dda91a9f4b1433c1c5ff4fb3e55 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_utility.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_utility.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_xcm.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_xcm.rs
index c9e13f2bdb2fdb488ec3862044fa3a5406111f49..ffc5fa2fc23ed2c4cb5a0624866dc800ab5ae1e3 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_xcm.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/pallet_xcm.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/paritydb_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/paritydb_weights.rs
index 1c6d2ebe568cc81e91167ec723102eebde49259c..25679703831a13b8d1bb7fb7dd4d92fa84b1f255 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/paritydb_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/paritydb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/rocksdb_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/rocksdb_weights.rs
index aa0cb2b4bc377bae5bce9b18cbb78820c91f344d..3dd817aa6f137085b0e5fdf2b11b7f50e5c8b002 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/rocksdb_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/rocksdb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/mod.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/mod.rs
index 4d7b626cb72536b739da3c1ef209890d3ea9ed74..4f8c2dec7a8c890f1b4cd9ccd2cf24e92cea3817 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/mod.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
index b02cfcbf75f3c2075fd26b9af80e04f46427bc47..7c525dca051d277497e9c64395bd69d6fa5eabc2 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
index 87bd0a6173bc8ff0cd7ba0165bb92a3a5b0d35ce..7968649d143c1ca54d05285d0958379a2124fe7a 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/xcm_config.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/xcm_config.rs
index 88a0caa141e778a06ced5fe5ff8674905d00d627..940747119d812ba177aa0e8c84d2e9988f77cb78 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/xcm_config.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/src/xcm_config.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -25,7 +25,7 @@ use frame_support::{
use frame_system::EnsureRoot;
use pallet_xcm::XcmPassthrough;
use parachains_common::{impls::ToStakingPot, xcm_config::ConcreteNativeAssetFrom};
-use polkadot_parachain::primitives::Sibling;
+use polkadot_parachain_primitives::primitives::Sibling;
use xcm::latest::prelude::*;
use xcm_builder::{
AccountId32Aliases, AllowExplicitUnpaidExecutionFrom, AllowKnownQueryResponses,
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/tests/tests.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/tests/tests.rs
index f9fbf35e9f145ea8f9ce90237a6ff54c596c41ed..0be87bd46facfc079cda4a1ea4cf6b7a34114d75 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/tests/tests.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-polkadot/tests/tests.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -15,12 +15,12 @@
// along with Cumulus. If not, see .
pub use bridge_hub_polkadot_runtime::{
- constants::fee::WeightToFee, xcm_config::XcmConfig, AllPalletsWithoutSystem, Balances,
- ExistentialDeposit, ParachainSystem, PolkadotXcm, Runtime, RuntimeEvent, SessionKeys,
+ xcm_config::XcmConfig, AllPalletsWithoutSystem, Balances, ExistentialDeposit, ParachainSystem,
+ PolkadotXcm, Runtime, RuntimeEvent, SessionKeys,
};
use codec::Decode;
use frame_support::parameter_types;
-use parachains_common::{AccountId, AuraId};
+use parachains_common::{polkadot::fee::WeightToFee, AccountId, AuraId};
const ALICE: [u8; 32] = [1u8; 32];
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/Cargo.toml b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/Cargo.toml
index 95bf4c16967a1c5d242177500cb19bcae2b01410..d65fb9b72cd1cdcb263eb006ff82326cb71a28c2 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/Cargo.toml
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/Cargo.toml
@@ -13,7 +13,7 @@ codec = { package = "parity-scale-codec", version = "3.0.0", default-features =
hex-literal = { version = "0.4.1" }
log = { version = "0.4.20", default-features = false }
scale-info = { version = "2.9.0", default-features = false, features = ["derive"] }
-serde = { version = "1.0.183", optional = true, features = ["derive"] }
+serde = { version = "1.0.188", optional = true, features = ["derive"] }
smallvec = "1.11.0"
# Substrate
@@ -52,11 +52,11 @@ rococo-runtime-constants = { path = "../../../../../polkadot/runtime/rococo/cons
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
pallet-xcm-benchmarks = { path = "../../../../../polkadot/xcm/pallet-xcm-benchmarks", default-features = false, optional = true }
polkadot-core-primitives = { path = "../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-common = { path = "../../../../../polkadot/runtime/common", default-features = false}
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-aura-ext = { path = "../../../../pallets/aura-ext", default-features = false }
@@ -144,7 +144,7 @@ std = [
"parachain-info/std",
"parachains-common/std",
"polkadot-core-primitives/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"polkadot-runtime-common/std",
"rococo-runtime-constants/std",
"scale-info/std",
@@ -188,7 +188,7 @@ runtime-benchmarks = [
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"polkadot-runtime-common/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_hub_rococo_config.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_hub_rococo_config.rs
index d45238b0f4239412acb2a3b1b0960a50c22d8421..bc8f97ad97c1c15232a19b062a8f5f2bb674a809 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_hub_rococo_config.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_hub_rococo_config.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_hub_wococo_config.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_hub_wococo_config.rs
index b676e2c5994bb41eb7cf4233b47d5f0424095f50..5178b75c30390a21e8319b0d80ed58b000430311 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_hub_wococo_config.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_hub_wococo_config.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/lib.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/lib.rs
index a00dd30a870ad0cc8e167e1219b2551d8403c94f..4311a6a629f92b7bfd6160121df627e3a25abe2a 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/lib.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -24,11 +24,9 @@ include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));
pub mod bridge_hub_rococo_config;
pub mod bridge_hub_wococo_config;
-pub mod constants;
mod weights;
pub mod xcm_config;
-use constants::{consensus::*, currency::*};
use cumulus_pallet_parachain_system::RelayNumberStrictlyIncreases;
use sp_api::impl_runtime_apis;
use sp_core::{crypto::KeyTypeId, OpaqueMetadata};
@@ -79,7 +77,6 @@ use crate::{
BridgeRefundBridgeHubRococoMessages, OnBridgeHubWococoBlobDispatcher,
WithBridgeHubRococoMessageBridge,
},
- constants::fee::WeightToFee,
xcm_config::XcmRouter,
};
use bridge_runtime_common::{
@@ -87,8 +84,10 @@ use bridge_runtime_common::{
messages_xcm_extension::{XcmAsPlainPayload, XcmBlobMessageDispatch},
};
use parachains_common::{
- impls::DealWithFees, AccountId, Balance, BlockNumber, Hash, Header, Nonce, Signature,
- AVERAGE_ON_INITIALIZE_RATIO, HOURS, MAXIMUM_BLOCK_WEIGHT, NORMAL_DISPATCH_RATIO, SLOT_DURATION,
+ impls::DealWithFees,
+ rococo::{consensus::*, currency::*, fee::WeightToFee},
+ AccountId, Balance, BlockNumber, Hash, Header, Nonce, Signature, AVERAGE_ON_INITIALIZE_RATIO,
+ HOURS, MAXIMUM_BLOCK_WEIGHT, NORMAL_DISPATCH_RATIO, SLOT_DURATION,
};
use xcm_executor::XcmExecutor;
@@ -1040,7 +1039,11 @@ impl_runtime_apis! {
type XcmBalances = pallet_xcm_benchmarks::fungible::Pallet::;
type XcmGeneric = pallet_xcm_benchmarks::generic::Pallet::;
- use bridge_runtime_common::messages_benchmarking::{prepare_message_delivery_proof_from_parachain, prepare_message_proof_from_parachain};
+ use bridge_runtime_common::messages_benchmarking::{
+ prepare_message_delivery_proof_from_parachain,
+ prepare_message_proof_from_parachain,
+ generate_xcm_builder_bridge_message_sample,
+ };
use pallet_bridge_messages::benchmarking::{
Config as BridgeMessagesConfig,
Pallet as BridgeMessagesBench,
@@ -1072,7 +1075,7 @@ impl_runtime_apis! {
Runtime,
BridgeGrandpaWococoInstance,
bridge_hub_rococo_config::WithBridgeHubWococoMessageBridge,
- >(params, X2(GlobalConsensus(Rococo), Parachain(42)))
+ >(params, generate_xcm_builder_bridge_message_sample(X2(GlobalConsensus(Rococo), Parachain(42))))
}
fn prepare_message_delivery_proof(
@@ -1115,7 +1118,7 @@ impl_runtime_apis! {
Runtime,
BridgeGrandpaRococoInstance,
bridge_hub_wococo_config::WithBridgeHubRococoMessageBridge,
- >(params, X2(GlobalConsensus(Wococo), Parachain(42)))
+ >(params, generate_xcm_builder_bridge_message_sample(X2(GlobalConsensus(Wococo), Parachain(42))))
}
fn prepare_message_delivery_proof(
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/block_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/block_weights.rs
index b2092d875c8328210667da4cbb95de0642e60ae3..e7fdb2aae2a01ec06076de83d94817e540e205dd 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/block_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/block_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/cumulus_pallet_xcmp_queue.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/cumulus_pallet_xcmp_queue.rs
index 23bdc6fa4d723e95c9bd67060219f3d4972ddbf8..0106d6398f45938ae89603622db23abf300ec3ca 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/cumulus_pallet_xcmp_queue.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/cumulus_pallet_xcmp_queue.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/extrinsic_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/extrinsic_weights.rs
index 332c3b324bb9c1b386257bf7953d37aba8f5af13..1a4adb968bb7195428ea00d59cd92dcd3b6eea5f 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/extrinsic_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/extrinsic_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/frame_system.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/frame_system.rs
index 7146e59f1d04605b0f4b680be61c8403df289b29..3dec4cc7f182c9aede28084122747dca63b24431 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/frame_system.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/frame_system.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/mod.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/mod.rs
index 81ecd10512f9327d473fad146d2e8df13fff0814..54c7c03fb6085dca07eebd9ddfb052d9a5dbb969 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/mod.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_balances.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_balances.rs
index 9f16d8b8141b133fee299be2b7082d53ca7c136b..26a188a98610a7ecc822eb5e7e448ad7f1867eb8 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_balances.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_balances.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa.rs
index 2465d52cbe6425371fd972c5a5f012c613b1f582..5fbe2da8eaa31ae2689a389709fa468ee2d975a7 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa_bridge_rococo_grandpa.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa_bridge_rococo_grandpa.rs
index 746db2a421cfbbc7463318d753699bf743b8328c..f646ddc3a387b1cf8a0b712e98a94c0dbea42492 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa_bridge_rococo_grandpa.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa_bridge_rococo_grandpa.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa_bridge_wococo_grandpa.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa_bridge_wococo_grandpa.rs
index 377569f1aebda393e8dfce68354b1b5e6afb87a9..5c7c824624748cf1df16cd3c8e198ae52c0fa5fc 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa_bridge_wococo_grandpa.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_grandpa_bridge_wococo_grandpa.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages.rs
index f5ab0edddde372be7ca87e5473a97c5c76410bdc..ec40615dc133949d8c880e00c687cb106d55cdc3 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages_bridge_messages_bench_runtime_with_bridge_hub_rococo_messages_instance.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages_bridge_messages_bench_runtime_with_bridge_hub_rococo_messages_instance.rs
index 3fe496036f16c24d0f16b64e58440805ba389701..7c25ae337ad6e731d97ed887bbf7e22e95354e0e 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages_bridge_messages_bench_runtime_with_bridge_hub_rococo_messages_instance.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages_bridge_messages_bench_runtime_with_bridge_hub_rococo_messages_instance.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages_bridge_messages_bench_runtime_with_bridge_hub_wococo_messages_instance.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages_bridge_messages_bench_runtime_with_bridge_hub_wococo_messages_instance.rs
index 112eb22714869e620e07561aa7e3e5ec4cd47545..c3dbc19518bcd420338dbc810c3c8ed4889517f0 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages_bridge_messages_bench_runtime_with_bridge_hub_wococo_messages_instance.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_messages_bridge_messages_bench_runtime_with_bridge_hub_wococo_messages_instance.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains.rs
index d77c43e729f5049ea2a8a11a3a3043396380f898..c9f1d7e05d34e00fcb1f7b28939e93a01dece2de 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains_bridge_parachains_bench_runtime_bridge_parachain_rococo_instance.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains_bridge_parachains_bench_runtime_bridge_parachain_rococo_instance.rs
index 3ba8fabf7797361078c755130f1a636ed3996e95..147e8447ee87ed33740393299ffee3d8d92d772e 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains_bridge_parachains_bench_runtime_bridge_parachain_rococo_instance.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains_bridge_parachains_bench_runtime_bridge_parachain_rococo_instance.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains_bridge_parachains_bench_runtime_bridge_parachain_wococo_instance.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains_bridge_parachains_bench_runtime_bridge_parachain_wococo_instance.rs
index da5ec6c14187a27a8dcc9359c7c23f046b6f5757..432f9f9969db11ccd9f38f51473bccc700bb9133 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains_bridge_parachains_bench_runtime_bridge_parachain_wococo_instance.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_parachains_bridge_parachains_bench_runtime_bridge_parachain_wococo_instance.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_relayers.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_relayers.rs
index 426b098d54e3676d84ec7777d2fe049e69fc58d2..a934a1be58271fa610733c597d1fce9bc97f588d 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_relayers.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_bridge_relayers.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_collator_selection.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_collator_selection.rs
index 956b7b7b43cdcf161c8f93182857124752a815f0..9cbfa6ce80e3e4b45338786c3705500bf27a220f 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_collator_selection.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_collator_selection.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_multisig.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_multisig.rs
index f3a2e7f0268b50b678c2cd8a18c35c2361d2085c..91840ae0c6d77cfb4507d5f7d7b8f2aca7c84b35 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_multisig.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_multisig.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_session.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_session.rs
index afa64ae7537c2755a1e44b688f344d1a83dc7ec9..c9d04f9c6df65892243220531ac9d42dc885702d 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_session.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_session.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_timestamp.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_timestamp.rs
index 61742f36995077bd0730b5b2c3c6e47210fb88e7..0a5bf9b9f9c1f8c483c2e2f86ae471b28e7f609a 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_timestamp.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_timestamp.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_utility.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_utility.rs
index 4941bd661544940ac4bb4989a7b7ec8c753cbbb6..44cd0cf91e7998cb504587c481d13b110c9db072 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_utility.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_utility.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_xcm.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_xcm.rs
index f6d61f9e6c29d9984c3dabc687eab4d1136f1dbd..72bdb282585dec0533662bad5620f2434bcc15b1 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_xcm.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_xcm.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/paritydb_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/paritydb_weights.rs
index 4338d928d807a41cc60ec91d86e91c81bb253631..25679703831a13b8d1bb7fb7dd4d92fa84b1f255 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/paritydb_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/paritydb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/rocksdb_weights.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/rocksdb_weights.rs
index 1d115d963facb39fe29d6258918fda3bc8d94900..3dd817aa6f137085b0e5fdf2b11b7f50e5c8b002 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/rocksdb_weights.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/rocksdb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/mod.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/mod.rs
index a5c6bf858f649d847273331304f98880c39c83df..40a2036fb49a9b3ec7c121c5c1dd2a8451118497 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/mod.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
index 25ec8777cd3cb73f05e9f7dfb37e1314f1013cd0..8f9fbc912454b5c89759fad5faf440c3275cbcf1 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
index 3cb066bc53df6e453227af12a4ecf58dab831394..da3404909f31ca9418a9f2d21117178833bb1a11 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/xcm_config.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/xcm_config.rs
index 664edef13aea8134f67453ee20ae3f62a4d4bc92..7c28656e52feef360bcba8d39f17fe97a7185693 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/xcm_config.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/xcm_config.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -31,7 +31,7 @@ use frame_support::{
use frame_system::EnsureRoot;
use pallet_xcm::XcmPassthrough;
use parachains_common::{impls::ToStakingPot, xcm_config::ConcreteNativeAssetFrom};
-use polkadot_parachain::primitives::Sibling;
+use polkadot_parachain_primitives::primitives::Sibling;
use sp_core::Get;
use xcm::latest::prelude::*;
use xcm_builder::{
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/tests.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/tests.rs
index 1d8439d23e0d7c273cc6d5cc1ded6763ea619c7e..e5fe67f2a8e5b29a46adcf2a133ce9e956df9d5b 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/tests.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/tests.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -19,7 +19,6 @@
use bp_polkadot_core::Signature;
use bridge_hub_rococo_runtime::{
bridge_hub_rococo_config, bridge_hub_wococo_config,
- constants::fee::WeightToFee,
xcm_config::{RelayNetwork, XcmConfig},
AllPalletsWithoutSystem, BridgeRejectObsoleteHeadersAndMessages, DeliveryRewardInBalance,
Executive, ExistentialDeposit, ParachainSystem, PolkadotXcm, RequiredStakeForStakeAndSlash,
@@ -28,7 +27,7 @@ use bridge_hub_rococo_runtime::{
use codec::{Decode, Encode};
use frame_support::parameter_types;
use frame_system::pallet_prelude::HeaderFor;
-use parachains_common::{AccountId, AuraId, Balance};
+use parachains_common::{rococo::fee::WeightToFee, AccountId, AuraId, Balance};
use sp_keyring::AccountKeyring::Alice;
use sp_runtime::{
generic::{Era, SignedPayload},
diff --git a/cumulus/parachains/runtimes/bridge-hubs/test-utils/Cargo.toml b/cumulus/parachains/runtimes/bridge-hubs/test-utils/Cargo.toml
index 18a8d56a60ef126b83e3ca5f63c297411f6c3598..73678e8f91a363a3c6f5ccbcfb86d77b50543428 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/test-utils/Cargo.toml
+++ b/cumulus/parachains/runtimes/bridge-hubs/test-utils/Cargo.toml
@@ -37,9 +37,9 @@ parachains-runtimes-test-utils = { path = "../../test-utils", default-features =
# Polkadot
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
pallet-xcm-benchmarks = { path = "../../../../../polkadot/xcm/pallet-xcm-benchmarks", default-features = false, optional = true }
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Bridges
bp-bridge-hub-rococo = { path = "../../../../bridges/primitives/chain-bridge-hub-rococo", default-features = false }
diff --git a/cumulus/parachains/runtimes/bridge-hubs/test-utils/src/lib.rs b/cumulus/parachains/runtimes/bridge-hubs/test-utils/src/lib.rs
index 289d3f5b4d31affa08bb444849842d1c81701895..26eb09b73fa6c9755ee613ae6bf4ff776c541ec6 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/test-utils/src/lib.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/test-utils/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/bridge-hubs/test-utils/src/test_cases.rs b/cumulus/parachains/runtimes/bridge-hubs/test-utils/src/test_cases.rs
index bd0f070f9dcd375081890c83a86ca2d237821912..aa7fa16a9791c626eaa4473f6de5914e6f5867ca 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/test-utils/src/test_cases.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/test-utils/src/test_cases.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/Cargo.toml b/cumulus/parachains/runtimes/collectives/collectives-polkadot/Cargo.toml
index 59046ff1209e8ede300be14ad0d17389ed26b0eb..1f17a0ef0e69ee4837ccf48b2d53aad54808c2d3 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/Cargo.toml
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/Cargo.toml
@@ -55,12 +55,12 @@ sp-version = { path = "../../../../../substrate/primitives/version", default-fea
# Polkadot
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
polkadot-core-primitives = { path = "../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-common = { path = "../../../../../polkadot/runtime/common", default-features = false}
polkadot-runtime-constants = { path = "../../../../../polkadot/runtime/polkadot/constants", default-features = false}
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-aura-ext = { path = "../../../../pallets/aura-ext", default-features = false }
@@ -106,7 +106,7 @@ runtime-benchmarks = [
"pallet-timestamp/runtime-benchmarks",
"pallet-utility/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"polkadot-runtime-common/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
@@ -186,7 +186,7 @@ std = [
"parachain-info/std",
"parachains-common/std",
"polkadot-core-primitives/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"polkadot-runtime-common/std",
"polkadot-runtime-constants/std",
"scale-info/std",
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/migration.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/migration.rs
index 6f5b8aff8d4a059a36b25f90bf0bafd2cd608a7f..9350d03a2c9fbdd0806a80d94f2ccfa080e34848 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/migration.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/migration.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/mod.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/mod.rs
index 489b868eff347ecd866002c587b18e95eb3862ab..b97e44dda1be6d263e9c3d19249e159153a508a3 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/mod.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -20,7 +20,7 @@ pub(crate) mod migration;
mod origins;
mod tracks;
use crate::{
- constants, impls::ToParentTreasury, weights, AccountId, Balance, Balances, FellowshipReferenda,
+ impls::ToParentTreasury, weights, AccountId, Balance, Balances, FellowshipReferenda,
GovernanceLocation, PolkadotTreasuryAccount, Preimage, Runtime, RuntimeCall, RuntimeEvent,
RuntimeOrigin, Scheduler, DAYS,
};
@@ -36,6 +36,7 @@ pub use origins::{
};
use pallet_ranked_collective::EnsureOfRank;
use pallet_xcm::{EnsureXcm, IsVoiceOfBody};
+use parachains_common::polkadot::account;
use polkadot_runtime_constants::{time::HOURS, xcm::body::FELLOWSHIP_ADMIN_INDEX};
use sp_core::{ConstU128, ConstU32};
use sp_runtime::traits::{AccountIdConversion, ConstU16, ConvertToValue, Replace, TakeFirst};
@@ -62,7 +63,7 @@ pub mod ranks {
parameter_types! {
// Referenda pallet account, used to temporarily deposit slashed imbalance before teleporting.
- pub ReferendaPalletAccount: AccountId = constants::account::REFERENDA_PALLET_ID.into_account_truncating();
+ pub ReferendaPalletAccount: AccountId = account::REFERENDA_PALLET_ID.into_account_truncating();
pub const FellowshipAdminBodyId: BodyId = BodyId::Index(FELLOWSHIP_ADMIN_INDEX);
}
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/origins.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/origins.rs
index 04663aeecf3b7894a44b1d173b0d53e07f246937..5ed2c19f79e6464fc09a349d8dce3c09afad2d55 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/origins.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/origins.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/tracks.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/tracks.rs
index fc53efdd7e8caf7622a06b766773f9683e66c376..f4ba4e05ec166d9d9b7e5e5ed9b679042067ba13 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/tracks.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/fellowship/tracks.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/impls.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/impls.rs
index c28b4e2dc1e6b20d0bb18dd9ec18de2e23eeb33a..c970d82cfe50d358ebe765c1c4472bb7aaab6f7f 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/impls.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/impls.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -15,13 +15,14 @@
use crate::OriginCaller;
use frame_support::{
- dispatch::{DispatchError, DispatchResultWithPostInfo},
+ dispatch::DispatchResultWithPostInfo,
traits::{Currency, Get, Imbalance, OnUnbalanced, OriginTrait, PrivilegeCmp},
weights::Weight,
};
use log;
use pallet_alliance::{ProposalIndex, ProposalProvider};
use parachains_common::impls::NegativeImbalance;
+use sp_runtime::DispatchError;
use sp_std::{cmp::Ordering, marker::PhantomData, prelude::*};
use xcm::latest::{Fungibility, Junction, Parent};
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/lib.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/lib.rs
index a9af3b0f29fc7fe750002b132bf6d13378305a29..238db08a0c9e6f66f3d9bea1db844fac8f33a992 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/lib.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -36,7 +36,6 @@
#[cfg(feature = "std")]
include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));
-pub mod constants;
pub mod impls;
mod weights;
pub mod xcm_config;
@@ -64,7 +63,6 @@ use sp_version::NativeVersion;
use sp_version::RuntimeVersion;
use codec::{Decode, Encode, MaxEncodedLen};
-use constants::{consensus::*, currency::*, fee::WeightToFee};
use frame_support::{
construct_runtime,
dispatch::DispatchClass,
@@ -79,7 +77,9 @@ use frame_system::{
};
pub use parachains_common as common;
use parachains_common::{
- impls::DealWithFees, AccountId, AuraId, Balance, BlockNumber, Hash, Header, Nonce, Signature,
+ impls::DealWithFees,
+ polkadot::{account::*, consensus::*, currency::*, fee::WeightToFee},
+ AccountId, AuraId, Balance, BlockNumber, Hash, Header, Nonce, Signature,
AVERAGE_ON_INITIALIZE_RATIO, DAYS, HOURS, MAXIMUM_BLOCK_WEIGHT, MINUTES, NORMAL_DISPATCH_RATIO,
SLOT_DURATION,
};
@@ -484,8 +484,8 @@ parameter_types! {
pub const AllyDeposit: Balance = 1_000 * UNITS; // 1,000 DOT bond to join as an Ally
// The Alliance pallet account, used as a temporary place to deposit a slashed imbalance
// before the teleport to the Treasury.
- pub AlliancePalletAccount: AccountId = constants::account::ALLIANCE_PALLET_ID.into_account_truncating();
- pub PolkadotTreasuryAccount: AccountId = constants::account::POLKADOT_TREASURY_PALLET_ID.into_account_truncating();
+ pub AlliancePalletAccount: AccountId = ALLIANCE_PALLET_ID.into_account_truncating();
+ pub PolkadotTreasuryAccount: AccountId = POLKADOT_TREASURY_PALLET_ID.into_account_truncating();
// The number of blocks a member must wait between giving a retirement notice and retiring.
// Supposed to be greater than time required to `kick_member` with alliance motion.
pub const AllianceRetirementPeriod: BlockNumber = (90 * DAYS) + ALLIANCE_MOTION_DURATION;
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/block_weights.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/block_weights.rs
index b2092d875c8328210667da4cbb95de0642e60ae3..e7fdb2aae2a01ec06076de83d94817e540e205dd 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/block_weights.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/block_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs
index 28e1cd902b503075e701742db6159bc87fd65e0d..ccd9478bf10eab85eef8b80c0354b59e33e08d3d 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/cumulus_pallet_xcmp_queue.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/extrinsic_weights.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/extrinsic_weights.rs
index 332c3b324bb9c1b386257bf7953d37aba8f5af13..1a4adb968bb7195428ea00d59cd92dcd3b6eea5f 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/extrinsic_weights.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/extrinsic_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/frame_system.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/frame_system.rs
index 75cc6580a39d52f9ae0c78746c634dc98d70b85c..31cd502d1927b0cfeac64774567c937d7ee33050 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/frame_system.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/frame_system.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/mod.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/mod.rs
index b0e49549914286ad7615cf056681ae6bca832816..9ddf53792ea4f56fd7460f697d8ec4835dfdaa06 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/mod.rs
@@ -1,3 +1,19 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// This file is part of Cumulus.
+
+// Cumulus 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.
+
+// Cumulus 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 Cumulus. If not, see .
+
pub mod block_weights;
pub mod cumulus_pallet_xcmp_queue;
pub mod extrinsic_weights;
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_alliance.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_alliance.rs
index c822a0c85cd8fb38c4a3e9f232dc743a11fa470a..9e3acac46a4c9e7bc39d55cc5d928150aab3aaad 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_alliance.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_alliance.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_balances.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_balances.rs
index 80b90aadc0db56d1bee6b607f03719be78e753a2..dd0c02ab87306ac8d311c223a0c4b297b67552c4 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_balances.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_balances.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_collator_selection.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_collator_selection.rs
index 8376006e30c9da1c2393646dfc3e998720a03aa6..ea237d602a9b5a1190b89aaf4fdf955bdbc9df58 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_collator_selection.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_collator_selection.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_collective.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_collective.rs
index 013cfee7ba9dbc41b618d70b5cf8630f38f4d6e2..2d344ad0db7ba9e7b98303624e4f3f4a11c4087a 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_collective.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_collective.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_core_fellowship.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_core_fellowship.rs
index 50a8bcea50004ed2266d85bdc6c7cdb2b961c2ae..d053513b53accc68cc3332ee1e123b6c3a08bd83 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_core_fellowship.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_core_fellowship.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_multisig.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_multisig.rs
index b2e36af383b8aa61a04f090fd60bedba242ee12e..a8dd58320cc204382c0160f9629e386ddd7851fb 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_multisig.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_multisig.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_preimage.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_preimage.rs
index ef2406230b20d2564fb12c684157d6ec55a273a3..cf2f0ae39da61e05a9816a445742022e6c4ba939 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_preimage.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_preimage.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_proxy.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_proxy.rs
index 9732251e5aae026eb0ab40baccf25e7dd94e583d..faf100d23bb0d5c68b1da4d4421b05315ddfd3de 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_proxy.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_proxy.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_ranked_collective.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_ranked_collective.rs
index 0ce5de87c8f28304d85ac7e03fc3f75f7ba8dc21..561edda953b9a75df47a3388245eede3ec78ba51 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_ranked_collective.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_ranked_collective.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_referenda.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_referenda.rs
index 1e8b3ecae2e2c6e66de57ff0d865c9245e17e9f1..12d92a803cad9be870465264539c438b9a7487e7 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_referenda.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_referenda.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_salary.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_salary.rs
index 351834c5e3adab42a7448cfe8d4a600ddf532a3a..3a6825cf6415887dc284555aaad14d52628de58c 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_salary.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_salary.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_scheduler.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_scheduler.rs
index b647f7eba87357d61e298c83951e079492a6eec3..d30ac82bf059bc8a2c75b1e8bce75024da38bea3 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_scheduler.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_scheduler.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_session.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_session.rs
index 909f9a64f5aabfa3ae5abdc9c65690a51fce5e2c..2af8ce29a196ef21d8f203ccb5d62a1bfeb9a6b6 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_session.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_session.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_timestamp.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_timestamp.rs
index bb8f0e0b37690fcc8e88509d889bf7d8b944554e..bc149ec63a176f09e226988d3344f29f9cf3e530 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_timestamp.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_timestamp.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_utility.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_utility.rs
index f16ffc4c0c3b0b49476b19f6b44db9da7468854d..5d6b0cb8285c91a98c99e97c7eb948086d1fb2b8 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_utility.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_utility.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_xcm.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_xcm.rs
index 030d754ec4ce5ff7a0eb59acf761f271d73f14d6..738742b6108b79bb11520fdca1d191735cee1a0c 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_xcm.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/pallet_xcm.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/paritydb_weights.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/paritydb_weights.rs
index 4338d928d807a41cc60ec91d86e91c81bb253631..25679703831a13b8d1bb7fb7dd4d92fa84b1f255 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/paritydb_weights.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/paritydb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/rocksdb_weights.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/rocksdb_weights.rs
index 1d115d963facb39fe29d6258918fda3bc8d94900..3dd817aa6f137085b0e5fdf2b11b7f50e5c8b002 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/rocksdb_weights.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/weights/rocksdb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/xcm_config.rs b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/xcm_config.rs
index a5fc545509711791e70ac55d3c2c0ea8135f9c8e..4c6fc19b3ebf766c1535273e78f0bf18500216a5 100644
--- a/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/xcm_config.rs
+++ b/cumulus/parachains/runtimes/collectives/collectives-polkadot/src/xcm_config.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -25,7 +25,7 @@ use frame_support::{
use frame_system::EnsureRoot;
use pallet_xcm::XcmPassthrough;
use parachains_common::{impls::ToStakingPot, xcm_config::ConcreteNativeAssetFrom};
-use polkadot_parachain::primitives::Sibling;
+use polkadot_parachain_primitives::primitives::Sibling;
use xcm::latest::prelude::*;
use xcm_builder::{
AccountId32Aliases, AllowExplicitUnpaidExecutionFrom, AllowKnownQueryResponses,
diff --git a/cumulus/parachains/runtimes/contracts/contracts-rococo/Cargo.toml b/cumulus/parachains/runtimes/contracts/contracts-rococo/Cargo.toml
index 266437a4821e76a71d2cecbce1f7664d316d24e4..2e298e05ec76b8ec79a39caeeb6f74acbb52c997 100644
--- a/cumulus/parachains/runtimes/contracts/contracts-rococo/Cargo.toml
+++ b/cumulus/parachains/runtimes/contracts/contracts-rococo/Cargo.toml
@@ -55,11 +55,11 @@ pallet-contracts-primitives = { path = "../../../../../substrate/frame/contracts
kusama-runtime-constants = { path = "../../../../../polkadot/runtime/kusama/constants", default-features = false}
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
polkadot-core-primitives = { path = "../../../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-common = { path = "../../../../../polkadot/runtime/common", default-features = false}
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-aura-ext = { path = "../../../../pallets/aura-ext", default-features = false }
@@ -113,7 +113,7 @@ std = [
"parachain-info/std",
"parachains-common/std",
"polkadot-core-primitives/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"polkadot-runtime-common/std",
"scale-info/std",
"sp-api/std",
@@ -151,7 +151,7 @@ runtime-benchmarks = [
"pallet-timestamp/runtime-benchmarks",
"pallet-utility/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"polkadot-runtime-common/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
diff --git a/cumulus/parachains/runtimes/contracts/contracts-rococo/README.md b/cumulus/parachains/runtimes/contracts/contracts-rococo/README.md
index e4f15ccf92d655d8358ba460a4c7e02ae262a6fd..387bb24bb0e07ef982b89634ae98d7a663c47ef7 100644
--- a/cumulus/parachains/runtimes/contracts/contracts-rococo/README.md
+++ b/cumulus/parachains/runtimes/contracts/contracts-rococo/README.md
@@ -33,8 +33,8 @@ There are also different user interfaces and command-line tools you can use to d
or interact with contracts:
* [Contracts UI](https://paritytech.github.io/contracts-ui/) ‒ a beginner-friendly UI for smart contract developers.
-* [polkadot-js](https://polkadot.js.org/apps/) ‒ the go-to expert UI for smart contract developers.
-* [cargo-contract](https://github.com/paritytech/cargo-contract) ‒ a CLI tool, ideal for scripting or your terminal workflow.
+* [`polkadot-js`](https://polkadot.js.org/apps/) ‒ the go-to expert UI for smart contract developers.
+* [`cargo-contract`](https://github.com/paritytech/cargo-contract) ‒ a CLI tool, ideal for scripting or your terminal workflow.
If you are looking for a quickstart, we can recommend
[ink!'s Guided Tutorial for Beginners](https://docs.substrate.io/tutorials/v3/ink-workshop/pt1/).
diff --git a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/contracts.rs b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/contracts.rs
index 1c2b24d88a874de13ac7613ca8f571749b978aec..1c99393d5e52fccf427b40f232d55a833d082c9e 100644
--- a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/contracts.rs
+++ b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/contracts.rs
@@ -1,6 +1,21 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
use crate::{
- constants::currency::deposit, Balance, Balances, RandomnessCollectiveFlip, Runtime,
- RuntimeCall, RuntimeEvent, RuntimeHoldReason, Timestamp,
+ Balance, Balances, RandomnessCollectiveFlip, Runtime, RuntimeCall, RuntimeEvent,
+ RuntimeHoldReason, Timestamp,
};
use frame_support::{
parameter_types,
@@ -13,7 +28,7 @@ use pallet_contracts::{
};
use sp_runtime::Perbill;
-pub use parachains_common::AVERAGE_ON_INITIALIZE_RATIO;
+pub use parachains_common::{rococo::currency::deposit, AVERAGE_ON_INITIALIZE_RATIO};
// Prints debug output of the `contracts` pallet to stdout if the node is
// started with `-lruntime::contracts=debug`.
diff --git a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/lib.rs b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/lib.rs
index 9f381d4417a076bacb68fe0543989f5a988d73f2..399ada1be2c739c6ea4931fa99c6a38f3c039dd9 100644
--- a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/lib.rs
+++ b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2018-2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: GPL-3.0-or-later WITH Classpath-exception-2.0
//
// This program is free software: you can redistribute it and/or modify
@@ -25,7 +25,6 @@
#[cfg(feature = "std")]
include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));
-pub mod constants;
mod contracts;
mod weights;
mod xcm_config;
@@ -45,7 +44,6 @@ use sp_std::prelude::*;
use sp_version::NativeVersion;
use sp_version::RuntimeVersion;
-use constants::{consensus::*, currency::*, fee::WeightToFee};
use frame_support::{
construct_runtime,
dispatch::DispatchClass,
@@ -57,9 +55,10 @@ use frame_support::{
use frame_system::limits::{BlockLength, BlockWeights};
pub use parachains_common as common;
use parachains_common::{
- impls::DealWithFees, AccountId, BlockNumber, Hash, Header, Nonce, Signature,
- AVERAGE_ON_INITIALIZE_RATIO, MAXIMUM_BLOCK_WEIGHT, MINUTES, NORMAL_DISPATCH_RATIO,
- SLOT_DURATION,
+ impls::DealWithFees,
+ rococo::{consensus::*, currency::*, fee::WeightToFee},
+ AccountId, BlockNumber, Hash, Header, Nonce, Signature, AVERAGE_ON_INITIALIZE_RATIO,
+ MAXIMUM_BLOCK_WEIGHT, MINUTES, NORMAL_DISPATCH_RATIO, SLOT_DURATION,
};
pub use parachains_common::{AuraId, Balance};
use xcm_config::CollatorSelectionUpdateOrigin;
diff --git a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/block_weights.rs b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/block_weights.rs
index b2092d875c8328210667da4cbb95de0642e60ae3..e7fdb2aae2a01ec06076de83d94817e540e205dd 100644
--- a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/block_weights.rs
+++ b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/block_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/extrinsic_weights.rs b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/extrinsic_weights.rs
index 332c3b324bb9c1b386257bf7953d37aba8f5af13..1a4adb968bb7195428ea00d59cd92dcd3b6eea5f 100644
--- a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/extrinsic_weights.rs
+++ b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/extrinsic_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/mod.rs b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/mod.rs
index ed0b4dbcd47fbffb125bda4b337099ae69e51ce2..30fa2c4060689ff98cc427c84f81866172845e52 100644
--- a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/mod.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/paritydb_weights.rs b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/paritydb_weights.rs
index 4338d928d807a41cc60ec91d86e91c81bb253631..25679703831a13b8d1bb7fb7dd4d92fa84b1f255 100644
--- a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/paritydb_weights.rs
+++ b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/paritydb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/rocksdb_weights.rs b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/rocksdb_weights.rs
index 1d115d963facb39fe29d6258918fda3bc8d94900..3dd817aa6f137085b0e5fdf2b11b7f50e5c8b002 100644
--- a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/rocksdb_weights.rs
+++ b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/weights/rocksdb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/xcm_config.rs b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/xcm_config.rs
index 7c576e50bbcd8d31ed229bf913e5d35b08d73b25..31575cc4922e2e1c032f3f424e7ffcf6b3609f29 100644
--- a/cumulus/parachains/runtimes/contracts/contracts-rococo/src/xcm_config.rs
+++ b/cumulus/parachains/runtimes/contracts/contracts-rococo/src/xcm_config.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -24,7 +24,7 @@ use frame_support::{
};
use frame_system::EnsureRoot;
use pallet_xcm::{EnsureXcm, IsMajorityOfBody, XcmPassthrough};
-use polkadot_parachain::primitives::Sibling;
+use polkadot_parachain_primitives::primitives::Sibling;
use xcm::latest::prelude::*;
use xcm_builder::{
AccountId32Aliases, AllowExplicitUnpaidExecutionFrom, AllowKnownQueryResponses,
diff --git a/cumulus/parachains/runtimes/glutton/glutton-kusama/Cargo.toml b/cumulus/parachains/runtimes/glutton/glutton-kusama/Cargo.toml
index 4973021d30061ece3d25d1055788346463c1e865..0caf00340d3a3ea63549983c92d37e622a88770e 100644
--- a/cumulus/parachains/runtimes/glutton/glutton-kusama/Cargo.toml
+++ b/cumulus/parachains/runtimes/glutton/glutton-kusama/Cargo.toml
@@ -31,9 +31,9 @@ sp-transaction-pool = { path = "../../../../../substrate/primitives/transaction-
sp-version = { path = "../../../../../substrate/primitives/version", default-features = false}
# Polkadot
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-parachain-system = { path = "../../../../pallets/parachain-system", default-features = false, features = ["parameterized-consensus-hook",] }
diff --git a/cumulus/parachains/runtimes/glutton/glutton-kusama/build.rs b/cumulus/parachains/runtimes/glutton/glutton-kusama/build.rs
index 9b53d2457dffdc09ea4789b644e6d2b2a3cfc0f5..1580e6f07bec466c644ccab1f4591d384632135e 100644
--- a/cumulus/parachains/runtimes/glutton/glutton-kusama/build.rs
+++ b/cumulus/parachains/runtimes/glutton/glutton-kusama/build.rs
@@ -1,3 +1,18 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
use substrate_wasm_builder::WasmBuilder;
fn main() {
diff --git a/cumulus/parachains/runtimes/glutton/glutton-kusama/src/lib.rs b/cumulus/parachains/runtimes/glutton/glutton-kusama/src/lib.rs
index cd9d31a4d989f40cc78b35ae4dfc786d60f9118c..dde8f747d4633bb3a8bbcd9dca471431dea99414 100644
--- a/cumulus/parachains/runtimes/glutton/glutton-kusama/src/lib.rs
+++ b/cumulus/parachains/runtimes/glutton/glutton-kusama/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/frame_system.rs b/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/frame_system.rs
index 1aff76714bb35d9e5879b56fcef54c8b59d54849..36c4abc400634fd9ec857675031b11b3c33d3fd2 100644
--- a/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/frame_system.rs
+++ b/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/frame_system.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/mod.rs b/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/mod.rs
index 234ce34bf420bcf7484fc537760a699ad2f304db..990558538acfcc97590325d2573a06f6026d35fb 100644
--- a/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/mod.rs
@@ -1 +1,17 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// This file is part of Cumulus.
+
+// Cumulus 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.
+
+// Cumulus 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 Cumulus. If not, see .
+
pub mod pallet_glutton;
diff --git a/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/pallet_glutton.rs b/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/pallet_glutton.rs
index f43a487826568839f4ec0c6171371e21770941b3..f278d246b33b1b4f0854b943fef8a1da22122e93 100644
--- a/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/pallet_glutton.rs
+++ b/cumulus/parachains/runtimes/glutton/glutton-kusama/src/weights/pallet_glutton.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/glutton/glutton-kusama/src/xcm_config.rs b/cumulus/parachains/runtimes/glutton/glutton-kusama/src/xcm_config.rs
index 8a2d99395f9d47a6fbb82ec4a4467afd6b3d5ca2..d278a859cb3bb376fe5a7edb10b47b847ed97b95 100644
--- a/cumulus/parachains/runtimes/glutton/glutton-kusama/src/xcm_config.rs
+++ b/cumulus/parachains/runtimes/glutton/glutton-kusama/src/xcm_config.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/starters/seedling/src/lib.rs b/cumulus/parachains/runtimes/starters/seedling/src/lib.rs
index edca2b093948c2c41917201e23e2bde79029323f..5f6733faf70679933fd177ee6ff2fdcbffe3500f 100644
--- a/cumulus/parachains/runtimes/starters/seedling/src/lib.rs
+++ b/cumulus/parachains/runtimes/starters/seedling/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/starters/shell/Cargo.toml b/cumulus/parachains/runtimes/starters/shell/Cargo.toml
index d7afc8be864cb142a502f489f0662bb4d933d572..6f9046057102fdd42b2a588a14b66a99199afcaf 100644
--- a/cumulus/parachains/runtimes/starters/shell/Cargo.toml
+++ b/cumulus/parachains/runtimes/starters/shell/Cargo.toml
@@ -25,9 +25,9 @@ sp-transaction-pool = { path = "../../../../../substrate/primitives/transaction-
sp-version = { path = "../../../../../substrate/primitives/version", default-features = false}
# Polkadot
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-parachain-system = { path = "../../../../pallets/parachain-system", default-features = false, features = ["parameterized-consensus-hook",] }
diff --git a/cumulus/parachains/runtimes/starters/shell/build.rs b/cumulus/parachains/runtimes/starters/shell/build.rs
index 256e9fb765b7c6a152bbb229e9318e16d81b9ea7..9c9cde9a25a1a8ab1780b7df7e068264459a31af 100644
--- a/cumulus/parachains/runtimes/starters/shell/build.rs
+++ b/cumulus/parachains/runtimes/starters/shell/build.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Substrate is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/starters/shell/src/lib.rs b/cumulus/parachains/runtimes/starters/shell/src/lib.rs
index 205462fac39baffc707bfad5693b262045056592..ef914a246efc9f310176b3c46bf277a16b372082 100644
--- a/cumulus/parachains/runtimes/starters/shell/src/lib.rs
+++ b/cumulus/parachains/runtimes/starters/shell/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/starters/shell/src/xcm_config.rs b/cumulus/parachains/runtimes/starters/shell/src/xcm_config.rs
index b57c315ed2ae330d3e30018d16f245c0c533df91..c878bb6a70cd150d0af38506e9e64c9a8b52d9ee 100644
--- a/cumulus/parachains/runtimes/starters/shell/src/xcm_config.rs
+++ b/cumulus/parachains/runtimes/starters/shell/src/xcm_config.rs
@@ -1,4 +1,4 @@
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/test-utils/Cargo.toml b/cumulus/parachains/runtimes/test-utils/Cargo.toml
index 76ce2b9907e29a4b76b3e8a34af8a20d55beec15..681e5e64d41280ef4ded74ff2bf347031e74bb04 100644
--- a/cumulus/parachains/runtimes/test-utils/Cargo.toml
+++ b/cumulus/parachains/runtimes/test-utils/Cargo.toml
@@ -35,10 +35,10 @@ cumulus-test-relay-sproof-builder = { path = "../../../test/relay-sproof-builder
parachain-info = { path = "../../pallets/parachain-info", default-features = false }
# Polkadot
-xcm = { path = "../../../../polkadot/xcm", default-features = false}
-xcm-executor = { path = "../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../polkadot/xcm", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../polkadot/xcm/xcm-executor", default-features = false}
pallet-xcm = { path = "../../../../polkadot/xcm/pallet-xcm", default-features = false}
-polkadot-parachain = { path = "../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../polkadot/parachain", default-features = false}
[dev-dependencies]
hex-literal = "0.4.1"
@@ -65,7 +65,7 @@ std = [
"pallet-xcm/std",
"parachain-info/std",
"parachains-common/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"sp-consensus-aura/std",
"sp-core/std",
"sp-io/std",
diff --git a/cumulus/parachains/runtimes/test-utils/src/lib.rs b/cumulus/parachains/runtimes/test-utils/src/lib.rs
index 93183a73c22e4753bb3c3eb404fb771a178bf107..8289a80baa11a8542210b7b691765bed05a9a0ae 100644
--- a/cumulus/parachains/runtimes/test-utils/src/lib.rs
+++ b/cumulus/parachains/runtimes/test-utils/src/lib.rs
@@ -22,14 +22,14 @@ use cumulus_primitives_core::{
use cumulus_primitives_parachain_inherent::ParachainInherentData;
use cumulus_test_relay_sproof_builder::RelayStateSproofBuilder;
use frame_support::{
- dispatch::{DispatchResult, RawOrigin, UnfilteredDispatchable},
+ dispatch::{DispatchResult, RawOrigin},
inherent::{InherentData, ProvideInherent},
- traits::{OnFinalize, OnInitialize, OriginTrait},
+ traits::{OnFinalize, OnInitialize, OriginTrait, UnfilteredDispatchable},
weights::Weight,
};
use frame_system::pallet_prelude::{BlockNumberFor, HeaderFor};
use parachains_common::{AccountId, SLOT_DURATION};
-use polkadot_parachain::primitives::{
+use polkadot_parachain_primitives::primitives::{
HeadData, HrmpChannelId, RelayChainBlockNumber, XcmpMessageFormat,
};
use sp_consensus_aura::{SlotDuration, AURA_ENGINE_ID};
diff --git a/cumulus/parachains/runtimes/testing/penpal/Cargo.toml b/cumulus/parachains/runtimes/testing/penpal/Cargo.toml
index cd36927afec868e46c48ac2c981ae7377e748c91..99caf2f27d0391f7e942b531071bbb5c00ac6b39 100644
--- a/cumulus/parachains/runtimes/testing/penpal/Cargo.toml
+++ b/cumulus/parachains/runtimes/testing/penpal/Cargo.toml
@@ -56,11 +56,11 @@ sp-version = { path = "../../../../../substrate/primitives/version", default-fea
# Polkadot
polkadot-primitives = { path = "../../../../../polkadot/primitives", default-features = false}
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
polkadot-runtime-common = { path = "../../../../../polkadot/runtime/common", default-features = false}
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-aura-ext = { path = "../../../../pallets/aura-ext", default-features = false }
@@ -109,7 +109,7 @@ std = [
"pallet-xcm/std",
"parachain-info/std",
"parachains-common/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"polkadot-primitives/std",
"polkadot-runtime-common/std",
"scale-info/std",
@@ -147,7 +147,7 @@ runtime-benchmarks = [
"pallet-sudo/runtime-benchmarks",
"pallet-timestamp/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"polkadot-primitives/runtime-benchmarks",
"polkadot-runtime-common/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
diff --git a/cumulus/parachains/runtimes/testing/penpal/build.rs b/cumulus/parachains/runtimes/testing/penpal/build.rs
index 256e9fb765b7c6a152bbb229e9318e16d81b9ea7..9c9cde9a25a1a8ab1780b7df7e068264459a31af 100644
--- a/cumulus/parachains/runtimes/testing/penpal/build.rs
+++ b/cumulus/parachains/runtimes/testing/penpal/build.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Substrate is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/testing/penpal/src/lib.rs b/cumulus/parachains/runtimes/testing/penpal/src/lib.rs
index 4bc7dfacc053c422b1a56c8c520d9f783575db78..9a758cdd97827359ac546c204f66787c36c208b2 100644
--- a/cumulus/parachains/runtimes/testing/penpal/src/lib.rs
+++ b/cumulus/parachains/runtimes/testing/penpal/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/parachains/runtimes/testing/penpal/src/weights/block_weights.rs b/cumulus/parachains/runtimes/testing/penpal/src/weights/block_weights.rs
index b2092d875c8328210667da4cbb95de0642e60ae3..e7fdb2aae2a01ec06076de83d94817e540e205dd 100644
--- a/cumulus/parachains/runtimes/testing/penpal/src/weights/block_weights.rs
+++ b/cumulus/parachains/runtimes/testing/penpal/src/weights/block_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/testing/penpal/src/weights/extrinsic_weights.rs b/cumulus/parachains/runtimes/testing/penpal/src/weights/extrinsic_weights.rs
index 332c3b324bb9c1b386257bf7953d37aba8f5af13..1a4adb968bb7195428ea00d59cd92dcd3b6eea5f 100644
--- a/cumulus/parachains/runtimes/testing/penpal/src/weights/extrinsic_weights.rs
+++ b/cumulus/parachains/runtimes/testing/penpal/src/weights/extrinsic_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/testing/penpal/src/weights/mod.rs b/cumulus/parachains/runtimes/testing/penpal/src/weights/mod.rs
index ed0b4dbcd47fbffb125bda4b337099ae69e51ce2..30fa2c4060689ff98cc427c84f81866172845e52 100644
--- a/cumulus/parachains/runtimes/testing/penpal/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/testing/penpal/src/weights/mod.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/testing/penpal/src/weights/paritydb_weights.rs b/cumulus/parachains/runtimes/testing/penpal/src/weights/paritydb_weights.rs
index 4338d928d807a41cc60ec91d86e91c81bb253631..25679703831a13b8d1bb7fb7dd4d92fa84b1f255 100644
--- a/cumulus/parachains/runtimes/testing/penpal/src/weights/paritydb_weights.rs
+++ b/cumulus/parachains/runtimes/testing/penpal/src/weights/paritydb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/testing/penpal/src/weights/rocksdb_weights.rs b/cumulus/parachains/runtimes/testing/penpal/src/weights/rocksdb_weights.rs
index 1d115d963facb39fe29d6258918fda3bc8d94900..3dd817aa6f137085b0e5fdf2b11b7f50e5c8b002 100644
--- a/cumulus/parachains/runtimes/testing/penpal/src/weights/rocksdb_weights.rs
+++ b/cumulus/parachains/runtimes/testing/penpal/src/weights/rocksdb_weights.rs
@@ -1,6 +1,6 @@
// This file is part of Substrate.
-// Copyright (C) 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: Apache-2.0
// Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/cumulus/parachains/runtimes/testing/penpal/src/xcm_config.rs b/cumulus/parachains/runtimes/testing/penpal/src/xcm_config.rs
index 2a88a63d5fc13bda4f8b8ca44c98f5d58b3d3b71..ee167c1c11d76b42251b0c9c9e578bf9af9957c9 100644
--- a/cumulus/parachains/runtimes/testing/penpal/src/xcm_config.rs
+++ b/cumulus/parachains/runtimes/testing/penpal/src/xcm_config.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -39,7 +39,7 @@ use frame_support::{
use frame_system::EnsureRoot;
use pallet_asset_tx_payment::HandleCredit;
use pallet_xcm::XcmPassthrough;
-use polkadot_parachain::primitives::Sibling;
+use polkadot_parachain_primitives::primitives::Sibling;
use polkadot_runtime_common::impls::ToAuthor;
use sp_runtime::traits::Zero;
use xcm::latest::prelude::*;
diff --git a/cumulus/parachains/runtimes/testing/rococo-parachain/Cargo.toml b/cumulus/parachains/runtimes/testing/rococo-parachain/Cargo.toml
index 361f77591999d88605c15e1f0d2a8153156eb63e..863b9edd72581dd358e89f94ccdfd3b3675240eb 100644
--- a/cumulus/parachains/runtimes/testing/rococo-parachain/Cargo.toml
+++ b/cumulus/parachains/runtimes/testing/rococo-parachain/Cargo.toml
@@ -37,10 +37,10 @@ sp-version = { path = "../../../../../substrate/primitives/version", default-fea
# Polkadot
pallet-xcm = { path = "../../../../../polkadot/xcm/pallet-xcm", default-features = false}
-polkadot-parachain = { path = "../../../../../polkadot/parachain", default-features = false}
-xcm = { path = "../../../../../polkadot/xcm", default-features = false}
-xcm-builder = { path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
-xcm-executor = { path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
+polkadot-parachain-primitives = { path = "../../../../../polkadot/parachain", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../../../polkadot/xcm", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
# Cumulus
cumulus-pallet-aura-ext = { path = "../../../../pallets/aura-ext", default-features = false }
@@ -84,7 +84,7 @@ std = [
"pallet-xcm/std",
"parachain-info/std",
"parachains-common/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"scale-info/std",
"sp-api/std",
"sp-block-builder/std",
@@ -113,7 +113,7 @@ runtime-benchmarks = [
"pallet-sudo/runtime-benchmarks",
"pallet-timestamp/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
- "polkadot-parachain/runtime-benchmarks",
+ "polkadot-parachain-primitives/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
"xcm-executor/runtime-benchmarks",
diff --git a/cumulus/parachains/runtimes/testing/rococo-parachain/src/lib.rs b/cumulus/parachains/runtimes/testing/rococo-parachain/src/lib.rs
index 7aa50b008377d4cae55c87c847f24ead659a230b..f6d7c849de90a420bfe48a0d606458e8539b4508 100644
--- a/cumulus/parachains/runtimes/testing/rococo-parachain/src/lib.rs
+++ b/cumulus/parachains/runtimes/testing/rococo-parachain/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -77,7 +77,7 @@ use xcm_executor::traits::JustTry;
// XCM imports
use pallet_xcm::{EnsureXcm, IsMajorityOfBody, XcmPassthrough};
-use polkadot_parachain::primitives::Sibling;
+use polkadot_parachain_primitives::primitives::Sibling;
use xcm::latest::prelude::*;
use xcm_builder::{
AccountId32Aliases, AllowExplicitUnpaidExecutionFrom, AllowTopLevelPaidExecutionFrom,
diff --git a/cumulus/polkadot-parachain/Cargo.toml b/cumulus/polkadot-parachain/Cargo.toml
index 8ae7a1f25f3288279859497f4293f935fd1bc6eb..dc59b8207528f8b4fe2171fb17eb67853101b690 100644
--- a/cumulus/polkadot-parachain/Cargo.toml
+++ b/cumulus/polkadot-parachain/Cargo.toml
@@ -12,12 +12,12 @@ path = "src/main.rs"
[dependencies]
async-trait = "0.1.73"
-clap = { version = "4.3.24", features = ["derive"] }
+clap = { version = "4.4.2", features = ["derive"] }
codec = { package = "parity-scale-codec", version = "3.0.0" }
futures = "0.3.28"
hex-literal = "0.4.1"
log = "0.4.20"
-serde = { version = "1.0.183", features = ["derive"] }
+serde = { version = "1.0.188", features = ["derive"] }
serde_json = "1.0.105"
# Local
@@ -77,7 +77,7 @@ substrate-state-trie-migration-rpc = { path = "../../substrate/utils/frame/rpc/s
polkadot-cli = { path = "../../polkadot/cli", features = ["rococo-native"] }
polkadot-primitives = { path = "../../polkadot/primitives" }
polkadot-service = { path = "../../polkadot/node/service" }
-xcm = { path = "../../polkadot/xcm" }
+xcm = { package = "staging-xcm", path = "../../polkadot/xcm" }
# Cumulus
cumulus-client-cli = { path = "../client/cli" }
diff --git a/cumulus/polkadot-parachain/build.rs b/cumulus/polkadot-parachain/build.rs
index ae164d6cb0f4264a96e264c61de8b4cf00b909bc..dd0d112bca7018bac1ca250d9efc3a3972b6ca41 100644
--- a/cumulus/polkadot-parachain/build.rs
+++ b/cumulus/polkadot-parachain/build.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Substrate is free software: you can redistribute it and/or modify
diff --git a/cumulus/polkadot-parachain/chain-specs/asset-hub-kusama.json b/cumulus/polkadot-parachain/chain-specs/asset-hub-kusama.json
new file mode 120000
index 0000000000000000000000000000000000000000..89a3015b50aad9f65910327732c3cee6f5ed837a
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/asset-hub-kusama.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/asset-hub-kusama.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/asset-hub-polkadot.json b/cumulus/polkadot-parachain/chain-specs/asset-hub-polkadot.json
new file mode 120000
index 0000000000000000000000000000000000000000..43a1cb41131af77676d78a2ec71b95c59fd46eda
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/asset-hub-polkadot.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/asset-hub-polkadot.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/asset-hub-westend.json b/cumulus/polkadot-parachain/chain-specs/asset-hub-westend.json
new file mode 120000
index 0000000000000000000000000000000000000000..03742c401622a34c444b57433e31cfdfd4ee75a8
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/asset-hub-westend.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/asset-hub-westend.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/bridge-hub-kusama.json b/cumulus/polkadot-parachain/chain-specs/bridge-hub-kusama.json
new file mode 120000
index 0000000000000000000000000000000000000000..fc91654c6ff4098675485eb6a114fd5f636b04b9
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/bridge-hub-kusama.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/bridge-hub-kusama.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/bridge-hub-polkadot.json b/cumulus/polkadot-parachain/chain-specs/bridge-hub-polkadot.json
new file mode 120000
index 0000000000000000000000000000000000000000..df22d3e8800157c5dfbedca008cac4c971b83ef6
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/bridge-hub-polkadot.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/bridge-hub-polkadot.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/bridge-hub-rococo.json b/cumulus/polkadot-parachain/chain-specs/bridge-hub-rococo.json
new file mode 120000
index 0000000000000000000000000000000000000000..8970d92bcf5135e7578fe50b5c2af2e257131669
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/bridge-hub-rococo.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/bridge-hub-rococo.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/bridge-hub-westend.json b/cumulus/polkadot-parachain/chain-specs/bridge-hub-westend.json
new file mode 120000
index 0000000000000000000000000000000000000000..9f9e4dad5c18510904dc3cff01d27978575b9e6c
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/bridge-hub-westend.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/bridge-hub-westend.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/bridge-hub-wococo.json b/cumulus/polkadot-parachain/chain-specs/bridge-hub-wococo.json
new file mode 120000
index 0000000000000000000000000000000000000000..e13ab77265d59d31fcf822420413d3b5240bf574
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/bridge-hub-wococo.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/bridge-hub-wococo.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/collectives-polkadot.json b/cumulus/polkadot-parachain/chain-specs/collectives-polkadot.json
new file mode 120000
index 0000000000000000000000000000000000000000..afece75567be9a10e4beed8799e5acd854d923bb
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/collectives-polkadot.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/collectives-polkadot.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/collectives-westend.json b/cumulus/polkadot-parachain/chain-specs/collectives-westend.json
new file mode 120000
index 0000000000000000000000000000000000000000..84e23b06fb4c5f44990b22922403c9f6ac5d6fb6
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/collectives-westend.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/collectives-westend.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/contracts-rococo.json b/cumulus/polkadot-parachain/chain-specs/contracts-rococo.json
new file mode 120000
index 0000000000000000000000000000000000000000..b9f8e8f31e84587c8bb148b96eefff3d7f87d682
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/contracts-rococo.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/contracts-rococo.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/tick.json b/cumulus/polkadot-parachain/chain-specs/tick.json
new file mode 120000
index 0000000000000000000000000000000000000000..47c93a98405349f8aad7bd45e60edd4f2bc33da5
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/tick.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/tick.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/track.json b/cumulus/polkadot-parachain/chain-specs/track.json
new file mode 120000
index 0000000000000000000000000000000000000000..9474c223a9469113a58b0a3e601df43397897638
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/track.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/track.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/chain-specs/trick.json b/cumulus/polkadot-parachain/chain-specs/trick.json
new file mode 120000
index 0000000000000000000000000000000000000000..de1fb9edf3070fd167ccc3ea866e3cc1cc652a5d
--- /dev/null
+++ b/cumulus/polkadot-parachain/chain-specs/trick.json
@@ -0,0 +1 @@
+../../parachains/chain-specs/trick.json
\ No newline at end of file
diff --git a/cumulus/polkadot-parachain/src/chain_spec/asset_hubs.rs b/cumulus/polkadot-parachain/src/chain_spec/asset_hubs.rs
index 0523c3b7e65fb0037ceda16ae6066ba8d82c70a8..c1edeb98cd0aa3b50e1c8efbe47085144f70900e 100644
--- a/cumulus/polkadot-parachain/src/chain_spec/asset_hubs.rs
+++ b/cumulus/polkadot-parachain/src/chain_spec/asset_hubs.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -32,11 +32,11 @@ pub type AssetHubWestendChainSpec =
sc_service::GenericChainSpec;
const ASSET_HUB_POLKADOT_ED: AssetHubBalance =
- asset_hub_polkadot_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ parachains_common::polkadot::currency::EXISTENTIAL_DEPOSIT;
const ASSET_HUB_KUSAMA_ED: AssetHubBalance =
- asset_hub_kusama_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ parachains_common::kusama::currency::EXISTENTIAL_DEPOSIT;
const ASSET_HUB_WESTEND_ED: AssetHubBalance =
- asset_hub_westend_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ parachains_common::westend::currency::EXISTENTIAL_DEPOSIT;
/// Generate the session keys from individual elements.
///
diff --git a/cumulus/polkadot-parachain/src/chain_spec/bridge_hubs.rs b/cumulus/polkadot-parachain/src/chain_spec/bridge_hubs.rs
index 911368073d59e3c8626226cf065cff690111ae24..5de4a49f8275122c3c86fbf18409068a653ce054 100644
--- a/cumulus/polkadot-parachain/src/chain_spec/bridge_hubs.rs
+++ b/cumulus/polkadot-parachain/src/chain_spec/bridge_hubs.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -97,7 +97,7 @@ impl BridgeHubRuntimeType {
match self {
BridgeHubRuntimeType::Polkadot =>
Ok(Box::new(polkadot::BridgeHubChainSpec::from_json_bytes(
- &include_bytes!("../../../parachains/chain-specs/bridge-hub-polkadot.json")[..],
+ &include_bytes!("../../chain-specs/bridge-hub-polkadot.json")[..],
)?)),
BridgeHubRuntimeType::PolkadotLocal => Ok(Box::new(polkadot::local_config(
polkadot::BRIDGE_HUB_POLKADOT_LOCAL,
@@ -113,7 +113,7 @@ impl BridgeHubRuntimeType {
))),
BridgeHubRuntimeType::Kusama =>
Ok(Box::new(kusama::BridgeHubChainSpec::from_json_bytes(
- &include_bytes!("../../../parachains/chain-specs/bridge-hub-kusama.json")[..],
+ &include_bytes!("../../chain-specs/bridge-hub-kusama.json")[..],
)?)),
BridgeHubRuntimeType::KusamaLocal => Ok(Box::new(kusama::local_config(
kusama::BRIDGE_HUB_KUSAMA_LOCAL,
@@ -129,11 +129,11 @@ impl BridgeHubRuntimeType {
))),
BridgeHubRuntimeType::Westend =>
Ok(Box::new(westend::BridgeHubChainSpec::from_json_bytes(
- &include_bytes!("../../../parachains/chain-specs/bridge-hub-westend.json")[..],
+ &include_bytes!("../../chain-specs/bridge-hub-westend.json")[..],
)?)),
BridgeHubRuntimeType::Rococo =>
Ok(Box::new(rococo::BridgeHubChainSpec::from_json_bytes(
- &include_bytes!("../../../parachains/chain-specs/bridge-hub-rococo.json")[..],
+ &include_bytes!("../../chain-specs/bridge-hub-rococo.json")[..],
)?)),
BridgeHubRuntimeType::RococoLocal => Ok(Box::new(rococo::local_config(
rococo::BRIDGE_HUB_ROCOCO_LOCAL,
@@ -153,7 +153,7 @@ impl BridgeHubRuntimeType {
))),
BridgeHubRuntimeType::Wococo =>
Ok(Box::new(wococo::BridgeHubChainSpec::from_json_bytes(
- &include_bytes!("../../../parachains/chain-specs/bridge-hub-wococo.json")[..],
+ &include_bytes!("../../chain-specs/bridge-hub-wococo.json")[..],
)?)),
BridgeHubRuntimeType::WococoLocal => Ok(Box::new(wococo::local_config(
wococo::BRIDGE_HUB_WOCOCO_LOCAL,
@@ -192,7 +192,7 @@ pub mod rococo {
pub(crate) const BRIDGE_HUB_ROCOCO_LOCAL: &str = "bridge-hub-rococo-local";
pub(crate) const BRIDGE_HUB_ROCOCO_DEVELOPMENT: &str = "bridge-hub-rococo-dev";
const BRIDGE_HUB_ROCOCO_ED: BridgeHubBalance =
- bridge_hub_rococo_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ parachains_common::rococo::currency::EXISTENTIAL_DEPOSIT;
/// Specialized `ChainSpec` for the normal parachain runtime.
pub type BridgeHubChainSpec =
@@ -372,7 +372,7 @@ pub mod kusama {
pub(crate) const BRIDGE_HUB_KUSAMA_LOCAL: &str = "bridge-hub-kusama-local";
pub(crate) const BRIDGE_HUB_KUSAMA_DEVELOPMENT: &str = "bridge-hub-kusama-dev";
const BRIDGE_HUB_KUSAMA_ED: BridgeHubBalance =
- bridge_hub_kusama_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ parachains_common::kusama::currency::EXISTENTIAL_DEPOSIT;
/// Specialized `ChainSpec` for the normal parachain runtime.
pub type BridgeHubChainSpec =
@@ -509,7 +509,7 @@ pub mod polkadot {
pub(crate) const BRIDGE_HUB_POLKADOT_LOCAL: &str = "bridge-hub-polkadot-local";
pub(crate) const BRIDGE_HUB_POLKADOT_DEVELOPMENT: &str = "bridge-hub-polkadot-dev";
const BRIDGE_HUB_POLKADOT_ED: BridgeHubBalance =
- bridge_hub_polkadot_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ parachains_common::polkadot::currency::EXISTENTIAL_DEPOSIT;
/// Specialized `ChainSpec` for the normal parachain runtime.
pub type BridgeHubChainSpec =
diff --git a/cumulus/polkadot-parachain/src/chain_spec/collectives.rs b/cumulus/polkadot-parachain/src/chain_spec/collectives.rs
index 82c925c5d493b0d5234a59a582e03db9f0d14560..fbf49b9535a42f632df29931e7515745414eb9c6 100644
--- a/cumulus/polkadot-parachain/src/chain_spec/collectives.rs
+++ b/cumulus/polkadot-parachain/src/chain_spec/collectives.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -26,7 +26,7 @@ pub type CollectivesPolkadotChainSpec =
sc_service::GenericChainSpec;
const COLLECTIVES_POLKADOT_ED: CollectivesBalance =
- collectives_polkadot_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ parachains_common::polkadot::currency::EXISTENTIAL_DEPOSIT;
/// Generate the session keys from individual elements.
///
diff --git a/cumulus/polkadot-parachain/src/chain_spec/contracts.rs b/cumulus/polkadot-parachain/src/chain_spec/contracts.rs
index b8af83a0d70edc8cb508d1f99360edba3f589dcf..0d5012858edc6f81a1554996fbafe4a1f6973072 100644
--- a/cumulus/polkadot-parachain/src/chain_spec/contracts.rs
+++ b/cumulus/polkadot-parachain/src/chain_spec/contracts.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -31,7 +31,7 @@ const CONTRACTS_PARACHAIN_ID: u32 = 1002;
/// The existential deposit is determined by the runtime "contracts-rococo".
const CONTRACTS_ROCOCO_ED: contracts_rococo_runtime::Balance =
- contracts_rococo_runtime::constants::currency::EXISTENTIAL_DEPOSIT;
+ parachains_common::rococo::currency::EXISTENTIAL_DEPOSIT;
pub fn contracts_rococo_development_config() -> ContractsRococoChainSpec {
let mut properties = sc_chain_spec::Properties::new();
diff --git a/cumulus/polkadot-parachain/src/chain_spec/glutton.rs b/cumulus/polkadot-parachain/src/chain_spec/glutton.rs
index 5ea51c3a918196d39cae5397181d4e31e6c8265c..acd5b5bfbe132fe1df8c75636522763d47c21335 100644
--- a/cumulus/polkadot-parachain/src/chain_spec/glutton.rs
+++ b/cumulus/polkadot-parachain/src/chain_spec/glutton.rs
@@ -1,4 +1,4 @@
-// Copyright Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/polkadot-parachain/src/chain_spec/mod.rs b/cumulus/polkadot-parachain/src/chain_spec/mod.rs
index d7014a9f43cd9d906f79f17054b4695c8c0a32a7..9cd0a37ad633ba069cdf8beae71d3324af4485c5 100644
--- a/cumulus/polkadot-parachain/src/chain_spec/mod.rs
+++ b/cumulus/polkadot-parachain/src/chain_spec/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/polkadot-parachain/src/chain_spec/penpal.rs b/cumulus/polkadot-parachain/src/chain_spec/penpal.rs
index 264898991eb84e1c8aff0327140c4a1c6a48c129..479d1701e379ea4b2ce9d3520205365c1b07201f 100644
--- a/cumulus/polkadot-parachain/src/chain_spec/penpal.rs
+++ b/cumulus/polkadot-parachain/src/chain_spec/penpal.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/polkadot-parachain/src/chain_spec/rococo_parachain.rs b/cumulus/polkadot-parachain/src/chain_spec/rococo_parachain.rs
index 1ed1a3e35fba4a001cb3e9da2a21324931789bab..fb66efbf9ae1c68eedcc42b8ef6436b979885272 100644
--- a/cumulus/polkadot-parachain/src/chain_spec/rococo_parachain.rs
+++ b/cumulus/polkadot-parachain/src/chain_spec/rococo_parachain.rs
@@ -1,4 +1,4 @@
-// Copyright 2022 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/polkadot-parachain/src/chain_spec/seedling.rs b/cumulus/polkadot-parachain/src/chain_spec/seedling.rs
index 4a43b4cf476483b618f4c41055185c68a78581cc..3ebfb80d4685f67b9a43835fdc54609b5ca564dc 100644
--- a/cumulus/polkadot-parachain/src/chain_spec/seedling.rs
+++ b/cumulus/polkadot-parachain/src/chain_spec/seedling.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/polkadot-parachain/src/chain_spec/shell.rs b/cumulus/polkadot-parachain/src/chain_spec/shell.rs
index eca605b10df032bfd2b3f25ac9ef60b57ee317dc..7eb65591b12f38cb4f5de15967aa4d398a1eb183 100644
--- a/cumulus/polkadot-parachain/src/chain_spec/shell.rs
+++ b/cumulus/polkadot-parachain/src/chain_spec/shell.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/polkadot-parachain/src/cli.rs b/cumulus/polkadot-parachain/src/cli.rs
index 11b2e105ecbb98443c1c0613b18c7e517501b55e..63e4baf27aeb24bbf0d0647c5b2fda5ff34f0fa8 100644
--- a/cumulus/polkadot-parachain/src/cli.rs
+++ b/cumulus/polkadot-parachain/src/cli.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/polkadot-parachain/src/command.rs b/cumulus/polkadot-parachain/src/command.rs
index 008e5435f0b11d91f3ec12daf1fa1368e2111d7f..596b7baf6710ea1af53d988d6f5b3d0f93921c7d 100644
--- a/cumulus/polkadot-parachain/src/command.rs
+++ b/cumulus/polkadot-parachain/src/command.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
@@ -121,15 +121,15 @@ fn load_spec(id: &str) -> std::result::Result, String> {
Box::new(chain_spec::rococo_parachain::staging_rococo_parachain_local_config()),
"tick" =>
Box::new(chain_spec::rococo_parachain::RococoParachainChainSpec::from_json_bytes(
- &include_bytes!("../../parachains/chain-specs/tick.json")[..],
+ &include_bytes!("../chain-specs/tick.json")[..],
)?),
"trick" =>
Box::new(chain_spec::rococo_parachain::RococoParachainChainSpec::from_json_bytes(
- &include_bytes!("../../parachains/chain-specs/trick.json")[..],
+ &include_bytes!("../chain-specs/trick.json")[..],
)?),
"track" =>
Box::new(chain_spec::rococo_parachain::RococoParachainChainSpec::from_json_bytes(
- &include_bytes!("../../parachains/chain-specs/track.json")[..],
+ &include_bytes!("../chain-specs/track.json")[..],
)?),
// -- Starters
@@ -147,7 +147,7 @@ fn load_spec(id: &str) -> std::result::Result, String> {
// the shell-based chain spec as used for syncing
"asset-hub-polkadot" | "statemint" =>
Box::new(chain_spec::asset_hubs::AssetHubPolkadotChainSpec::from_json_bytes(
- &include_bytes!("../../parachains/chain-specs/asset-hub-polkadot.json")[..],
+ &include_bytes!("../chain-specs/asset-hub-polkadot.json")[..],
)?),
// -- Asset Hub Kusama
@@ -161,7 +161,7 @@ fn load_spec(id: &str) -> std::result::Result, String> {
// the shell-based chain spec as used for syncing
"asset-hub-kusama" | "statemine" =>
Box::new(chain_spec::asset_hubs::AssetHubKusamaChainSpec::from_json_bytes(
- &include_bytes!("../../parachains/chain-specs/asset-hub-kusama.json")[..],
+ &include_bytes!("../chain-specs/asset-hub-kusama.json")[..],
)?),
// -- Asset Hub Westend
@@ -175,7 +175,7 @@ fn load_spec(id: &str) -> std::result::Result, String> {
// the shell-based chain spec as used for syncing
"asset-hub-westend" | "westmint" =>
Box::new(chain_spec::asset_hubs::AssetHubWestendChainSpec::from_json_bytes(
- &include_bytes!("../../parachains/chain-specs/asset-hub-westend.json")[..],
+ &include_bytes!("../chain-specs/asset-hub-westend.json")[..],
)?),
// -- Polkadot Collectives
@@ -185,11 +185,11 @@ fn load_spec(id: &str) -> std::result::Result, String> {
Box::new(chain_spec::collectives::collectives_polkadot_local_config()),
"collectives-polkadot" =>
Box::new(chain_spec::collectives::CollectivesPolkadotChainSpec::from_json_bytes(
- &include_bytes!("../../parachains/chain-specs/collectives-polkadot.json")[..],
+ &include_bytes!("../chain-specs/collectives-polkadot.json")[..],
)?),
"collectives-westend" =>
Box::new(chain_spec::collectives::CollectivesPolkadotChainSpec::from_json_bytes(
- &include_bytes!("../../parachains/chain-specs/collectives-westend.json")[..],
+ &include_bytes!("../chain-specs/collectives-westend.json")[..],
)?),
// -- Contracts on Rococo
@@ -200,7 +200,7 @@ fn load_spec(id: &str) -> std::result::Result, String> {
"contracts-rococo-genesis" => Box::new(chain_spec::contracts::contracts_rococo_config()),
"contracts-rococo" =>
Box::new(chain_spec::contracts::ContractsRococoChainSpec::from_json_bytes(
- &include_bytes!("../../parachains/chain-specs/contracts-rococo.json")[..],
+ &include_bytes!("../chain-specs/contracts-rococo.json")[..],
)?),
// -- BridgeHub
diff --git a/cumulus/polkadot-parachain/src/main.rs b/cumulus/polkadot-parachain/src/main.rs
index d114d2f5f2c8a3208b0bf572fbdce59630377178..e40af8128f7166697a7e4f7571dd541a11d626a8 100644
--- a/cumulus/polkadot-parachain/src/main.rs
+++ b/cumulus/polkadot-parachain/src/main.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/polkadot-parachain/src/rpc.rs b/cumulus/polkadot-parachain/src/rpc.rs
index df6283388f9deafb6c00fbb8a2ee0854955c84d2..d106c52a364290dad54d3d278ce76dad8ef55c26 100644
--- a/cumulus/polkadot-parachain/src/rpc.rs
+++ b/cumulus/polkadot-parachain/src/rpc.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/polkadot-parachain/src/service.rs b/cumulus/polkadot-parachain/src/service.rs
index 3899814cb0e8c0c0de564d1ce2a8fb959555b67c..f7b053b4b6a9def2fb7c4dd76f757213ca630f1d 100644
--- a/cumulus/polkadot-parachain/src/service.rs
+++ b/cumulus/polkadot-parachain/src/service.rs
@@ -1,4 +1,4 @@
-// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/polkadot-parachain/tests/benchmark_storage_works.rs b/cumulus/polkadot-parachain/tests/benchmark_storage_works.rs
index df3078b4dab82f8853b349cd2ae338ae5c801a06..c2850b64e458adca9bb0918667cf912eb16796df 100644
--- a/cumulus/polkadot-parachain/tests/benchmark_storage_works.rs
+++ b/cumulus/polkadot-parachain/tests/benchmark_storage_works.rs
@@ -1,3 +1,19 @@
+// Copyright (C) Parity Technologies (UK) Ltd.
+// This file is part of Substrate.
+
+// Substrate 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.
+
+// Substrate 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 Cumulus. If not, see .
+
#![cfg(feature = "runtime-benchmarks")]
use assert_cmd::cargo::cargo_bin;
diff --git a/cumulus/polkadot-parachain/tests/common.rs b/cumulus/polkadot-parachain/tests/common.rs
index d8ecfe9bcbe5adbb8cfc5b2d18263ccbef489845..20926ddd91db53de52d32fb952ded38f8f868b97 100644
--- a/cumulus/polkadot-parachain/tests/common.rs
+++ b/cumulus/polkadot-parachain/tests/common.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Substrate.
// Substrate is free software: you can redistribute it and/or modify
@@ -12,7 +12,7 @@
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
-// along with Substrate. If not, see .
+// along with Cumulus. If not, see .
#![cfg(unix)]
diff --git a/cumulus/polkadot-parachain/tests/polkadot_argument_parsing.rs b/cumulus/polkadot-parachain/tests/polkadot_argument_parsing.rs
index 0538a47aa93ac02c951143ce2806cec3cac6878e..9337da85d74b16f594aa7baacf3e76a35b1bb976 100644
--- a/cumulus/polkadot-parachain/tests/polkadot_argument_parsing.rs
+++ b/cumulus/polkadot-parachain/tests/polkadot_argument_parsing.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Substrate.
// Substrate is free software: you can redistribute it and/or modify
@@ -12,7 +12,7 @@
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
-// along with Substrate. If not, see .
+// along with Cumulus. If not, see .
use tempfile::tempdir;
diff --git a/cumulus/polkadot-parachain/tests/polkadot_mdns_issue.rs b/cumulus/polkadot-parachain/tests/polkadot_mdns_issue.rs
index c88c81230b04c03987c60a1c8450f70dd69fee32..e3ccb7fe0fbdc2a7de5e04553985657b8b87733d 100644
--- a/cumulus/polkadot-parachain/tests/polkadot_mdns_issue.rs
+++ b/cumulus/polkadot-parachain/tests/polkadot_mdns_issue.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Substrate.
// Substrate is free software: you can redistribute it and/or modify
@@ -12,7 +12,7 @@
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
-// along with Substrate. If not, see .
+// along with Cumulus. If not, see .
use tempfile::tempdir;
diff --git a/cumulus/polkadot-parachain/tests/purge_chain_works.rs b/cumulus/polkadot-parachain/tests/purge_chain_works.rs
index 8a41ee780c5607234019d8eac608896f7c7cb13d..6415a914c7a3c8e1f381a08c29eef9cb3c1ebe55 100644
--- a/cumulus/polkadot-parachain/tests/purge_chain_works.rs
+++ b/cumulus/polkadot-parachain/tests/purge_chain_works.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Substrate.
// Substrate is free software: you can redistribute it and/or modify
@@ -12,7 +12,7 @@
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
-// along with Substrate. If not, see .
+// along with Cumulus. If not, see .
use assert_cmd::cargo::cargo_bin;
use nix::sys::signal::SIGINT;
diff --git a/cumulus/polkadot-parachain/tests/running_the_node_and_interrupt.rs b/cumulus/polkadot-parachain/tests/running_the_node_and_interrupt.rs
index 254602a21844b9aa7d5cce3d4c861febb9fe379e..0f4ae6992382c7a8a58da25ac110b97b6db72f62 100644
--- a/cumulus/polkadot-parachain/tests/running_the_node_and_interrupt.rs
+++ b/cumulus/polkadot-parachain/tests/running_the_node_and_interrupt.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Substrate.
// Substrate is free software: you can redistribute it and/or modify
@@ -12,7 +12,7 @@
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
-// along with Substrate. If not, see .
+// along with Cumulus. If not, see .
use tempfile::tempdir;
diff --git a/cumulus/primitives/aura/src/lib.rs b/cumulus/primitives/aura/src/lib.rs
index a0d7a0206a632191f366f966f08bd2715ea44201..826b65fddd2c695f0c0a1c63d77e9eab68fe0f30 100644
--- a/cumulus/primitives/aura/src/lib.rs
+++ b/cumulus/primitives/aura/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2023 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Substrate is free software: you can redistribute it and/or modify
diff --git a/cumulus/primitives/core/Cargo.toml b/cumulus/primitives/core/Cargo.toml
index fdbef574773727bb88e11b965553c5de75ab0fb0..fc7573be138357bab6757b59119e0891c37953fb 100644
--- a/cumulus/primitives/core/Cargo.toml
+++ b/cumulus/primitives/core/Cargo.toml
@@ -16,16 +16,16 @@ sp-trie = { path = "../../../substrate/primitives/trie", default-features = fals
# Polkadot
polkadot-core-primitives = { path = "../../../polkadot/core-primitives", default-features = false}
-polkadot-parachain = { path = "../../../polkadot/parachain", default-features = false}
+polkadot-parachain-primitives = { path = "../../../polkadot/parachain", default-features = false}
polkadot-primitives = { path = "../../../polkadot/primitives", default-features = false}
-xcm = { path = "../../../polkadot/xcm", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../polkadot/xcm", default-features = false}
[features]
default = [ "std" ]
std = [
"codec/std",
"polkadot-core-primitives/std",
- "polkadot-parachain/std",
+ "polkadot-parachain-primitives/std",
"polkadot-primitives/std",
"scale-info/std",
"sp-api/std",
diff --git a/cumulus/primitives/core/src/lib.rs b/cumulus/primitives/core/src/lib.rs
index 19cc69ea3013175d6de28ad7dc7093d35ad241b7..faaef09b26e174c151144e8a52bb76d8a495c285 100644
--- a/cumulus/primitives/core/src/lib.rs
+++ b/cumulus/primitives/core/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Substrate is free software: you can redistribute it and/or modify
@@ -19,13 +19,13 @@
#![cfg_attr(not(feature = "std"), no_std)]
use codec::{Decode, Encode};
-use polkadot_parachain::primitives::HeadData;
+use polkadot_parachain_primitives::primitives::HeadData;
use scale_info::TypeInfo;
use sp_runtime::RuntimeDebug;
use sp_std::prelude::*;
pub use polkadot_core_primitives::InboundDownwardMessage;
-pub use polkadot_parachain::primitives::{
+pub use polkadot_parachain_primitives::primitives::{
DmpMessageHandler, Id as ParaId, IsSystem, UpwardMessage, ValidationParams, XcmpMessageFormat,
XcmpMessageHandler,
};
diff --git a/cumulus/primitives/parachain-inherent/src/client_side.rs b/cumulus/primitives/parachain-inherent/src/client_side.rs
index 1d936239104d06fa0c62756ea01125ce287ed360..52987d2da44ceee275b88a441f5a64951cf245f2 100644
--- a/cumulus/primitives/parachain-inherent/src/client_side.rs
+++ b/cumulus/primitives/parachain-inherent/src/client_side.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Substrate is free software: you can redistribute it and/or modify
diff --git a/cumulus/primitives/parachain-inherent/src/lib.rs b/cumulus/primitives/parachain-inherent/src/lib.rs
index 34b9064090c2d0ba4b227421eefb8e8058d5104b..08407023bb4604933ff4de97a6669e45b85d6bc5 100644
--- a/cumulus/primitives/parachain-inherent/src/lib.rs
+++ b/cumulus/primitives/parachain-inherent/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Substrate is free software: you can redistribute it and/or modify
diff --git a/cumulus/primitives/parachain-inherent/src/mock.rs b/cumulus/primitives/parachain-inherent/src/mock.rs
index 18e23ba23af09c29b709ac3079429c80edd07497..5168b46a14d03def1ccfe72c9244e71bfb202d84 100644
--- a/cumulus/primitives/parachain-inherent/src/mock.rs
+++ b/cumulus/primitives/parachain-inherent/src/mock.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/primitives/timestamp/src/lib.rs b/cumulus/primitives/timestamp/src/lib.rs
index c8030fb09c4d5acfb319bb5ceecf9745578cafc9..535c4a2a7268b9df053021d824fd0fbb0599845b 100644
--- a/cumulus/primitives/timestamp/src/lib.rs
+++ b/cumulus/primitives/timestamp/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Cumulus is free software: you can redistribute it and/or modify
diff --git a/cumulus/primitives/utility/Cargo.toml b/cumulus/primitives/utility/Cargo.toml
index 27f3996b885e06b0d497f480a49c3b2354827baf..47c5442574fb6aea3a52b0ac9a11c9c6aff20fa4 100644
--- a/cumulus/primitives/utility/Cargo.toml
+++ b/cumulus/primitives/utility/Cargo.toml
@@ -16,9 +16,9 @@ sp-std = { path = "../../../substrate/primitives/std", default-features = false}
# Polkadot
polkadot-runtime-common = { path = "../../../polkadot/runtime/common", default-features = false}
-xcm = { path = "../../../polkadot/xcm", default-features = false}
-xcm-executor = { path = "../../../polkadot/xcm/xcm-executor", default-features = false}
-xcm-builder = { path = "../../../polkadot/xcm/xcm-builder", default-features = false}
+xcm = { package = "staging-xcm", path = "../../../polkadot/xcm", default-features = false}
+xcm-executor = { package = "staging-xcm-executor", path = "../../../polkadot/xcm/xcm-executor", default-features = false}
+xcm-builder = { package = "staging-xcm-builder", path = "../../../polkadot/xcm/xcm-builder", default-features = false}
# Cumulus
diff --git a/cumulus/primitives/utility/src/lib.rs b/cumulus/primitives/utility/src/lib.rs
index 136c476ad58287e64212b51f3fa09a186373bdcd..be9c38a6aabb945e6b50c2ae9e51594335847bc1 100644
--- a/cumulus/primitives/utility/src/lib.rs
+++ b/cumulus/primitives/utility/src/lib.rs
@@ -1,4 +1,4 @@
-// Copyright 2020-2021 Parity Technologies (UK) Ltd.
+// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.
// Substrate is free software: you can redistribute it and/or modify
@@ -328,11 +328,11 @@ mod tests {
use cumulus_primitives_core::UpwardMessage;
use frame_support::{
assert_ok,
- dispatch::DispatchError,
traits::tokens::{
DepositConsequence, Fortitude, Preservation, Provenance, WithdrawConsequence,
},
};
+ use sp_runtime::DispatchError;
use xcm_executor::{traits::Error, Assets};
/// Validates [`validate`] for required Some(destination) and Some(message)
diff --git a/cumulus/scripts/ci/changelog/.gitignore b/cumulus/scripts/ci/changelog/.gitignore
deleted file mode 100644
index 4fbcc523b04cf0aba6c866a38250a83c16deb8d8..0000000000000000000000000000000000000000
--- a/cumulus/scripts/ci/changelog/.gitignore
+++ /dev/null
@@ -1,4 +0,0 @@
-changelog.md
-*.json
-release*.md
-.env
diff --git a/cumulus/scripts/ci/changelog/Gemfile b/cumulus/scripts/ci/changelog/Gemfile
deleted file mode 100644
index 46b058e3c5004c85f4ef79b867d2a6638a7e8cd4..0000000000000000000000000000000000000000
--- a/cumulus/scripts/ci/changelog/Gemfile
+++ /dev/null
@@ -1,23 +0,0 @@
-# frozen_string_literal: true
-
-source 'https://rubygems.org'
-
-git_source(:github) { |repo_name| "https://github.com/#{repo_name}" }
-
-gem 'octokit', '~> 4'
-
-gem 'git_diff_parser', '~> 3'
-
-gem 'toml', '~> 0.3.0'
-
-gem 'rake', group: :dev
-
-gem 'optparse', '~> 0.1.1'
-
-gem 'logger', '~> 1.4'
-
-gem 'changelogerator', '0.10.1'
-
-gem 'test-unit', group: :dev
-
-gem 'rubocop', group: :dev, require: false
diff --git a/cumulus/scripts/ci/changelog/Gemfile.lock b/cumulus/scripts/ci/changelog/Gemfile.lock
deleted file mode 100644
index 893bec54919513e84cdda9313ea4f02edb4b51bf..0000000000000000000000000000000000000000
--- a/cumulus/scripts/ci/changelog/Gemfile.lock
+++ /dev/null
@@ -1,84 +0,0 @@
-GEM
- remote: https://rubygems.org/
- specs:
- addressable (2.8.0)
- public_suffix (>= 2.0.2, < 5.0)
- ast (2.4.2)
- changelogerator (0.10.1)
- git_diff_parser (~> 3)
- octokit (~> 4)
- faraday (1.8.0)
- faraday-em_http (~> 1.0)
- faraday-em_synchrony (~> 1.0)
- faraday-excon (~> 1.1)
- faraday-httpclient (~> 1.0.1)
- faraday-net_http (~> 1.0)
- faraday-net_http_persistent (~> 1.1)
- faraday-patron (~> 1.0)
- faraday-rack (~> 1.0)
- multipart-post (>= 1.2, < 3)
- ruby2_keywords (>= 0.0.4)
- faraday-em_http (1.0.0)
- faraday-em_synchrony (1.0.0)
- faraday-excon (1.1.0)
- faraday-httpclient (1.0.1)
- faraday-net_http (1.0.1)
- faraday-net_http_persistent (1.2.0)
- faraday-patron (1.0.0)
- faraday-rack (1.0.0)
- git_diff_parser (3.2.0)
- logger (1.4.4)
- multipart-post (2.1.1)
- octokit (4.21.0)
- faraday (>= 0.9)
- sawyer (~> 0.8.0, >= 0.5.3)
- optparse (0.1.1)
- parallel (1.21.0)
- parser (3.0.2.0)
- ast (~> 2.4.1)
- parslet (2.0.0)
- power_assert (2.0.1)
- public_suffix (4.0.6)
- rainbow (3.0.0)
- rake (13.0.6)
- regexp_parser (2.1.1)
- rexml (3.2.5)
- rubocop (1.23.0)
- parallel (~> 1.10)
- parser (>= 3.0.0.0)
- rainbow (>= 2.2.2, < 4.0)
- regexp_parser (>= 1.8, < 3.0)
- rexml
- rubocop-ast (>= 1.12.0, < 2.0)
- ruby-progressbar (~> 1.7)
- unicode-display_width (>= 1.4.0, < 3.0)
- rubocop-ast (1.13.0)
- parser (>= 3.0.1.1)
- ruby-progressbar (1.11.0)
- ruby2_keywords (0.0.5)
- sawyer (0.8.2)
- addressable (>= 2.3.5)
- faraday (> 0.8, < 2.0)
- test-unit (3.5.1)
- power_assert
- toml (0.3.0)
- parslet (>= 1.8.0, < 3.0.0)
- unicode-display_width (2.1.0)
-
-PLATFORMS
- x86_64-darwin-20
- x86_64-darwin-22
-
-DEPENDENCIES
- changelogerator (= 0.10.1)
- git_diff_parser (~> 3)
- logger (~> 1.4)
- octokit (~> 4)
- optparse (~> 0.1.1)
- rake
- rubocop
- test-unit
- toml (~> 0.3.0)
-
-BUNDLED WITH
- 2.2.22
diff --git a/cumulus/scripts/ci/changelog/README.md b/cumulus/scripts/ci/changelog/README.md
index 478e0b56d9ca317895b2430afdb8e19fbff87ebe..e274b4919473fdf9a1b0fb3d35d854db8d870d65 100644
--- a/cumulus/scripts/ci/changelog/README.md
+++ b/cumulus/scripts/ci/changelog/README.md
@@ -7,7 +7,8 @@ For now, a bit of preparation is required before you can run the script:
- store them under the `digests` folder as `-srtool-digest.json`
- ensure the `.env` file is up to date with correct information
-The content of the release notes is generated from the template files under the `scripts/ci/changelog/templates` folder. For readability and maintenance, the template is split into several small snippets.
+The content of the release notes is generated from the template files under the `scripts/ci/changelog/templates` folder.
+For readability and maintenance, the template is split into several small snippets.
Run:
```
@@ -37,17 +38,16 @@ DEBUG=1
NO_CACHE=1
```
-By default, the template will include all the information, including the runtime data.
-For clients releases, we don't need those and they can be skipped by setting the following env:
+By default, the template will include all the information, including the runtime data. For clients releases, we don't
+need those and they can be skipped by setting the following env:
```
RELEASE_TYPE=client
```
## Considered labels
-The following list will likely evolve over time and it will be hard to keep it in sync.
-In any case, if you want to find all the labels that are used, search for `meta` in the templates.
-Currently, the considered labels are:
+The following list will likely evolve over time and it will be hard to keep it in sync. In any case, if you want to find
+all the labels that are used, search for `meta` in the templates. Currently, the considered labels are:
- Priority: C labels
- Audit: D labels
@@ -58,9 +58,8 @@ Currently, the considered labels are:
- B7-runtimenoteworthy (runtime changes)
- T6-XCM
-Note that labels with the same letter are mutually exclusive.
-A PR should not have both `B0` and `B5`, or both `C1` and `C9`. In case of conflicts, the template will
-decide which label will be considered.
+Note that labels with the same letter are mutually exclusive. A PR should not have both `B0` and `B5`, or both `C1` and
+`C9`. In case of conflicts, the template will decide which label will be considered.
## Dev and debuggin
@@ -72,7 +71,7 @@ fswatch templates -e ".*\.md$" | xargs -n1 -I{} ./bin/changelog statemine-v5.0.0
```
### Caching
-By default, if the changelog data from Github is already present, the calls to the Github API will be skipped
-and the local version of the data will be used. This is much faster.
-If you know that some labels have changed in Github, you probably want to refresh the data.
-You can then either delete manually the `cumulus.json` file or `export NO_CACHE=1` to force refreshing the data.
+By default, if the changelog data from Github is already present, the calls to the Github API will be skipped and the
+local version of the data will be used. This is much faster. If you know that some labels have changed in Github, you
+probably want to refresh the data. You can then either delete manually the `cumulus.json` file or `export NO_CACHE=1` to
+force refreshing the data.
diff --git a/cumulus/scripts/ci/changelog/bin/changelog b/cumulus/scripts/ci/changelog/bin/changelog
deleted file mode 100755
index 6cd012a29edb791334a80b4cc830d6757c4416b6..0000000000000000000000000000000000000000
--- a/cumulus/scripts/ci/changelog/bin/changelog
+++ /dev/null
@@ -1,164 +0,0 @@
-#!/usr/bin/env ruby
-
-# frozen_string_literal: true
-
-# call for instance as:
-# ./bin/changelog statemine-v5.0.0
-#
-# You may set the ENV NO_CACHE to force fetching from Github
-# You should also ensure you set the ENV: GITHUB_TOKEN
-
-require_relative '../lib/changelog'
-require 'logger'
-
-logger = Logger.new($stdout)
-logger.level = Logger::DEBUG
-logger.debug('Starting')
-
-changelogerator_version = `changelogerator --version`
-logger.debug(changelogerator_version)
-
-owner = 'paritytech'
-repo = 'cumulus'
-ref1 = ARGV[0]
-ref2 = ARGV[1] || 'HEAD'
-output = ARGV[2] || 'release-notes.md'
-
-ENV['REF1'] = ref1
-ENV['REF2'] = ref2
-
-gh_cumulus = SubRef.new(format('%s/%s', { owner: owner, repo: repo }))
-
-polkadot_ref1 = gh_cumulus.get_dependency_reference(ref1, 'polkadot-primitives')
-polkadot_ref2 = gh_cumulus.get_dependency_reference(ref2, 'polkadot-primitives')
-
-substrate_ref1 = gh_cumulus.get_dependency_reference(ref1, 'sp-io')
-substrate_ref2 = gh_cumulus.get_dependency_reference(ref2, 'sp-io')
-
-logger.debug("Cumulus from: #{ref1}")
-logger.debug("Cumulus to: #{ref2}")
-
-logger.debug("Polkadot from: #{polkadot_ref1}")
-logger.debug("Polkadot to: #{polkadot_ref2}")
-
-logger.debug("Substrate from: #{substrate_ref1}")
-logger.debug("Substrate to: #{substrate_ref2}")
-
-cumulus_data = 'cumulus.json'
-substrate_data = 'substrate.json'
-polkadot_data = 'polkadot.json'
-
-logger.debug("Using CUMULUS: #{cumulus_data}")
-logger.debug("Using SUBSTRATE: #{substrate_data}")
-logger.debug("Using POLKADOT: #{polkadot_data}")
-
-logger.warn('NO_CACHE set') if ENV['NO_CACHE']
-
-# This is acting as cache so we don't spend time querying while testing
-if ENV['NO_CACHE'] || !File.file?(cumulus_data)
- logger.debug(format('Fetching data for Cumulus into %s', cumulus_data))
- cmd = format('changelogerator %s/%s -f %s -t %s > %