diff --git a/.config/lychee.toml b/.config/lychee.toml
index 200521ac41eeb739228d202ac0fb2d80be305464..733b77ec0cff9e616ecc0f851d9a3ed5e8574636 100644
--- a/.config/lychee.toml
+++ b/.config/lychee.toml
@@ -2,9 +2,9 @@
# Run with `lychee -c .config/lychee.toml ./**/*.rs ./**/*.prdoc`
cache = true
-max_cache_age = "1d"
+max_cache_age = "10d"
max_redirects = 10
-max_retries = 6
+max_retries = 3
# Exclude localhost et.al.
exclude_all_private = true
@@ -51,4 +51,7 @@ exclude = [
# Behind a captcha (code 403):
"https://iohk.io/en/blog/posts/2023/11/03/partner-chains-are-coming-to-cardano/",
"https://www.reddit.com/r/rust/comments/3spfh1/does_collect_allocate_more_than_once_while/",
+ # 403 rate limited:
+ "https://etherscan.io/block/11090290",
+ "https://substrate.stackexchange.com/.*",
]
diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS
index fdaa0c8628f766e241ba9043698b611a0bd78811..4fc5b97caae0735058337c8b23e4ca7471761d24 100644
--- a/.github/CODEOWNERS
+++ b/.github/CODEOWNERS
@@ -13,7 +13,7 @@
# - Multiple owners are supported.
# - Either handle (e.g, @github_user or @github/team) or email can be used. Keep in mind,
# that handles might work better because they are more recognizable on GitHub,
-# eyou can use them for mentioning unlike an email.
+# you can use them for mentioning unlike an email.
# - The latest matching rule, if multiple, takes precedence.
# CI
diff --git a/.github/scripts/common/lib.sh b/.github/scripts/common/lib.sh
index 29dc269ffd23b1f51e1eb2b87a61544de0cbb57f..f844e962c41def7625fa3d45ae3cbf81ecb57147 100755
--- a/.github/scripts/common/lib.sh
+++ b/.github/scripts/common/lib.sh
@@ -237,7 +237,7 @@ fetch_release_artifacts() {
popd > /dev/null
}
-# Fetch the release artifacts like binary and sigantures from S3. Assumes the ENV are set:
+# Fetch the release artifacts like binary and signatures from S3. Assumes the ENV are set:
# - RELEASE_ID
# - GITHUB_TOKEN
# - REPO in the form paritytech/polkadot
@@ -369,7 +369,7 @@ function relative_parent() {
# used as Github Workflow Matrix. This call is exposed by the `scan` command and can be used as:
# podman run --rm -it -v /.../fellowship-runtimes:/build docker.io/chevdor/srtool:1.70.0-0.11.1 scan
function find_runtimes() {
- libs=($(git grep -I -r --cached --max-depth 20 --files-with-matches 'construct_runtime!' -- '*lib.rs'))
+ libs=($(git grep -I -r --cached --max-depth 20 --files-with-matches '[frame_support::runtime]!' -- '*lib.rs'))
re=".*-runtime$"
JSON=$(jq --null-input '{ "include": [] }')
@@ -434,3 +434,13 @@ check_release_id() {
fi
}
+
+# Get latest release tag
+#
+# input: none
+# output: latest_release_tag
+get_latest_release_tag() {
+ TOKEN="Authorization: Bearer $GITHUB_TOKEN"
+ latest_release_tag=$(curl -s -H "$TOKEN" $api_base/paritytech/polkadot-sdk/releases/latest | jq -r '.tag_name')
+ printf $latest_release_tag
+}
diff --git a/.github/workflows/auto-add-parachain-issues.yml b/.github/workflows/auto-add-parachain-issues.yml
new file mode 100644
index 0000000000000000000000000000000000000000..6b5222b6ff74147b063d913ec0dcdec299a6fcea
--- /dev/null
+++ b/.github/workflows/auto-add-parachain-issues.yml
@@ -0,0 +1,30 @@
+# If there are new issues related to the async backing feature,
+# add it to the parachain team's board and set a custom "meta" field.
+
+name: Add selected issues to Parachain team board
+on:
+ issues:
+ types:
+ - labeled
+
+jobs:
+ add-parachain-issues:
+ if: github.event.label.name == 'T16-async_backing'
+ runs-on: ubuntu-latest
+ steps:
+ - name: Generate token
+ id: generate_token
+ uses: tibdex/github-app-token@v2.1.0
+ with:
+ app_id: ${{ secrets.PROJECT_APP_ID }}
+ private_key: ${{ secrets.PROJECT_APP_KEY }}
+ - name: Sync issues
+ uses: paritytech/github-issue-sync@v0.3.2
+ with:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ PROJECT_TOKEN: ${{ steps.generate_token.outputs.token }}
+ project: 119 # Parachain team board
+ project_field: 'meta'
+ project_value: 'async backing'
+ labels: |
+ T16-async_backing
diff --git a/.github/workflows/check-links.yml b/.github/workflows/check-links.yml
index 903d7a3fcb3d94bb6913d94627418d9212397bf3..58065f369c9cf160b0b94c233df9df1016426d07 100644
--- a/.github/workflows/check-links.yml
+++ b/.github/workflows/check-links.yml
@@ -3,8 +3,8 @@ name: Check links
on:
pull_request:
paths:
- - "*.rs"
- - "*.prdoc"
+ - "**.rs"
+ - "**.prdoc"
- ".github/workflows/check-links.yml"
- ".config/lychee.toml"
types: [opened, synchronize, reopened, ready_for_review]
diff --git a/.github/workflows/release-30_publish_release_draft.yml b/.github/workflows/release-30_publish_release_draft.yml
new file mode 100644
index 0000000000000000000000000000000000000000..12891ef70af36b4e848c68e292f9ba2881ee20d2
--- /dev/null
+++ b/.github/workflows/release-30_publish_release_draft.yml
@@ -0,0 +1,155 @@
+name: Release - Publish draft
+
+on:
+ push:
+ tags:
+ # Catches v1.2.3 and v1.2.3-rc1
+ - v[0-9]+.[0-9]+.[0-9]+*
+
+ workflow_dispatch:
+ inputs:
+ version:
+ description: Current release/rc version
+
+jobs:
+ get-rust-versions:
+ runs-on: ubuntu-latest
+ outputs:
+ rustc-stable: ${{ steps.get-rust-versions.outputs.stable }}
+ steps:
+ - id: get-rust-versions
+ run: |
+ RUST_STABLE_VERSION=$(curl -sS https://raw.githubusercontent.com/paritytech/scripts/master/dockerfiles/ci-unified/Dockerfile | grep -oP 'ARG RUST_STABLE_VERSION=\K[^ ]+')
+ echo "stable=$RUST_STABLE_VERSION" >> $GITHUB_OUTPUT
+
+ build-runtimes:
+ uses: "./.github/workflows/srtool.yml"
+ with:
+ excluded_runtimes: "substrate-test bp cumulus-test kitchensink minimal-template parachain-template penpal polkadot-test seedling shell frame-try sp solochain-template"
+
+ publish-release-draft:
+ runs-on: ubuntu-latest
+ needs: [get-rust-versions, build-runtimes]
+ outputs:
+ release_url: ${{ steps.create-release.outputs.html_url }}
+ asset_upload_url: ${{ steps.create-release.outputs.upload_url }}
+ steps:
+ - name: Checkout
+ uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4.0.0
+
+ - name: Prepare tooling
+ run: |
+ URL=https://github.com/chevdor/tera-cli/releases/download/v0.2.4/tera-cli_linux_amd64.deb
+ wget $URL -O tera.deb
+ sudo dpkg -i tera.deb
+ tera --version
+
+ - name: Download artifacts
+ uses: actions/download-artifact@c850b930e6ba138125429b7e5c93fc707a7f8427 # v4.1.4
+
+ - name: Prepare draft
+ id: draft
+ env:
+ RUSTC_STABLE: ${{ needs.get-rust-versions.outputs.rustc-stable }}
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ ASSET_HUB_ROCOCO_DIGEST: ${{ github.workspace}}/asset-hub-rococo-runtime/asset-hub-rococo-srtool-digest.json
+ ASSET_HUB_WESTEND_DIGEST: ${{ github.workspace}}/asset-hub-westend-runtime/asset-hub-westend-srtool-digest.json
+ BRIDGE_HUB_ROCOCO_DIGEST: ${{ github.workspace}}/bridge-hub-rococo-runtime/bridge-hub-rococo-srtool-digest.json
+ BRIDGE_HUB_WESTEND_DIGEST: ${{ github.workspace}}/bridge-hub-westend-runtime/bridge-hub-westend-srtool-digest.json
+ COLLECTIVES_WESTEND_DIGEST: ${{ github.workspace}}/collectives-westend-runtime/collectives-westend-srtool-digest.json
+ CONTRACTS_ROCOCO_DIGEST: ${{ github.workspace}}/contracts-rococo-runtime/contracts-rococo-srtool-digest.json
+ CORETIME_ROCOCO_DIGEST: ${{ github.workspace}}/coretime-rococo-runtime/coretime-rococo-srtool-digest.json
+ CORETIME_WESTEND_DIGEST: ${{ github.workspace}}/coretime-westend-runtime/coretime-westend-srtool-digest.json
+ GLUTTON_WESTEND_DIGEST: ${{ github.workspace}}/glutton-westend-runtime/glutton-westend-srtool-digest.json
+ PEOPLE_ROCOCO_DIGEST: ${{ github.workspace}}/people-rococo-runtime/people-rococo-srtool-digest.json
+ PEOPLE_WESTEND_DIGEST: ${{ github.workspace}}/people-westend-runtime/people-westend-srtool-digest.json
+ ROCOCO_DIGEST: ${{ github.workspace}}/rococo-runtime/rococo-srtool-digest.json
+ WESTEND_DIGEST: ${{ github.workspace}}/westend-runtime/westend-srtool-digest.json
+ run: |
+ . ./.github/scripts/common/lib.sh
+
+ export REF1=$(get_latest_release_tag)
+ if [[ -z "${{ inputs.version }}" ]]; then
+ export REF2="${{ github.ref }}"
+ else
+ export REF2="${{ inputs.version }}"
+ fi
+ echo "REL_TAG=$REF2" >> $GITHUB_ENV
+ export VERSION=$(echo "$REF2" | sed -E 's/^v([0-9]+\.[0-9]+\.[0-9]+).*$/\1/')
+
+ ./scripts/release/build-changelogs.sh
+
+ echo "Checking the folder state"
+ pwd
+ ls -la scripts/release
+
+ - name: Archive artifact context.json
+ uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
+ with:
+ name: release-notes-context
+ path: |
+ scripts/release/context.json
+ **/*-srtool-digest.json
+
+ - name: Create draft release
+ id: create-release
+ uses: actions/create-release@0cb9c9b65d5d1901c1f53e5e66eaf4afd303e70e # v1.1.4
+ env:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ with:
+ tag_name: ${{ env.REL_TAG }}
+ release_name: Polkadot ${{ env.REL_TAG }}
+ body_path: ${{ github.workspace}}/scripts/release/RELEASE_DRAFT.md
+ draft: true
+
+ publish-runtimes:
+ needs: [ build-runtimes, publish-release-draft ]
+ continue-on-error: true
+ runs-on: ubuntu-latest
+ strategy:
+ matrix: ${{ fromJSON(needs.build-runtimes.outputs.published_runtimes) }}
+
+ steps:
+ - name: Checkout sources
+ uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4.0.0
+
+ - name: Download artifacts
+ uses: actions/download-artifact@c850b930e6ba138125429b7e5c93fc707a7f8427 # v4.1.4
+
+ - name: Get runtime info
+ env:
+ JSON: release-notes-context/${{ matrix.chain }}-runtime/${{ matrix.chain }}-srtool-digest.json
+ run: |
+ >>$GITHUB_ENV echo ASSET=$(find ${{ matrix.chain }}-runtime -name '*.compact.compressed.wasm')
+ >>$GITHUB_ENV echo SPEC=$(<${JSON} jq -r .runtimes.compact.subwasm.core_version.specVersion)
+
+ - name: Upload compressed ${{ matrix.chain }} v${{ env.SPEC }} wasm
+ if: ${{ matrix.chain != 'rococo-parachain' }}
+ uses: actions/upload-release-asset@e8f9f06c4b078e705bd2ea027f0926603fc9b4d5 #v1.0.2
+ env:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ with:
+ upload_url: ${{ needs.publish-release-draft.outputs.asset_upload_url }}
+ asset_path: ${{ env.ASSET }}
+ asset_name: ${{ matrix.chain }}_runtime-v${{ env.SPEC }}.compact.compressed.wasm
+ asset_content_type: application/wasm
+
+ post_to_matrix:
+ runs-on: ubuntu-latest
+ needs: publish-release-draft
+ strategy:
+ matrix:
+ channel:
+ - name: "Team: RelEng Internal"
+ room: '!GvAyzgCDgaVrvibaAF:parity.io'
+
+ steps:
+ - name: Send Matrix message to ${{ matrix.channel.name }}
+ uses: s3krit/matrix-message-action@70ad3fb812ee0e45ff8999d6af11cafad11a6ecf # v0.0.3
+ with:
+ room_id: ${{ matrix.channel.room }}
+ access_token: ${{ secrets.RELEASENOTES_MATRIX_V2_ACCESS_TOKEN }}
+ server: m.parity.io
+ message: |
+ **New version of polkadot tagged**: ${{ github.ref }}
+ Draft release created: ${{ needs.publish-release-draft.outputs.release_url }}
diff --git a/.github/workflows/srtool.yml b/.github/workflows/srtool.yml
index eb15538f559d2145700a73fb0e383d4103ce582a..95b1846b98e0c47cc6de2c92cadc16adc0cab487 100644
--- a/.github/workflows/srtool.yml
+++ b/.github/workflows/srtool.yml
@@ -12,6 +12,13 @@ on:
- release-v[0-9]+.[0-9]+.[0-9]+*
- release-cumulus-v[0-9]+*
- release-polkadot-v[0-9]+*
+ workflow_call:
+ inputs:
+ excluded_runtimes:
+ type: string
+ outputs:
+ published_runtimes:
+ value: ${{ jobs.find-runtimes.outputs.runtime }}
schedule:
- cron: "00 02 * * 1" # 2AM weekly on monday
@@ -39,7 +46,7 @@ jobs:
- name: Scan runtimes
env:
- EXCLUDED_RUNTIMES: "substrate-test"
+ EXCLUDED_RUNTIMES: ${{ inputs.excluded_runtimes }}:"substrate-test"
run: |
. ./.github/scripts/common/lib.sh
@@ -85,16 +92,6 @@ jobs:
echo "Compact Runtime: ${{ steps.srtool_build.outputs.wasm }}"
echo "Compressed Runtime: ${{ steps.srtool_build.outputs.wasm_compressed }}"
- # it takes a while to build the runtime, so let's save the artifact as soon as we have it
- - name: Archive Artifacts for ${{ matrix.chain }}
- uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3.1.2
- with:
- name: ${{ matrix.chain }}-runtime
- path: |
- ${{ steps.srtool_build.outputs.wasm }}
- ${{ steps.srtool_build.outputs.wasm_compressed }}
- ${{ matrix.chain }}-srtool-digest.json
-
# We now get extra information thanks to subwasm
- name: Install subwasm
run: |
@@ -125,7 +122,7 @@ jobs:
tee ${{ matrix.chain }}-diff.txt
- name: Archive Subwasm results
- uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3.1.2
+ uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
with:
name: ${{ matrix.chain }}-runtime
path: |
@@ -133,3 +130,6 @@ jobs:
${{ matrix.chain }}-compressed-info.json
${{ matrix.chain }}-metadata.json
${{ matrix.chain }}-diff.txt
+ ${{ steps.srtool_build.outputs.wasm }}
+ ${{ steps.srtool_build.outputs.wasm_compressed }}
+ ${{ matrix.chain }}-srtool-digest.json
diff --git a/.github/workflows/subsystem-benchmarks.yml b/.github/workflows/subsystem-benchmarks.yml
new file mode 100644
index 0000000000000000000000000000000000000000..1a726b669e9094e8be53ef5a1ddb1b3198210d33
--- /dev/null
+++ b/.github/workflows/subsystem-benchmarks.yml
@@ -0,0 +1,55 @@
+# The actions takes json file as input and runs github-action-benchmark for it.
+
+on:
+ workflow_dispatch:
+ inputs:
+ benchmark-data-dir-path:
+ description: "Path to the benchmark data directory"
+ required: true
+ type: string
+ output-file-path:
+ description: "Path to the benchmark data file"
+ required: true
+ type: string
+
+jobs:
+ subsystem-benchmarks:
+ runs-on: ubuntu-latest
+ environment: subsystem-benchmarks
+ steps:
+ - name: Validate inputs
+ run: |
+ echo "${{ github.event.inputs.benchmark-data-dir-path }}" | grep -P '^[a-z\-]'
+ echo "${{ github.event.inputs.output-file-path }}" | grep -P '^[a-z\-]+\.json'
+
+ - name: Checkout Sources
+ uses: actions/checkout@v4.1.2
+ with:
+ fetch-depth: 0
+ ref: "gh-pages"
+
+ - name: Copy bench results
+ id: step_one
+ run: |
+ cp bench/gitlab/${{ github.event.inputs.output-file-path }} ${{ github.event.inputs.output-file-path }}
+
+ - name: Switch branch
+ id: step_two
+ run: |
+ git checkout master --
+
+ - uses: actions/create-github-app-token@v1
+ id: app-token
+ with:
+ app-id: ${{ secrets.POLKADOTSDK_GHPAGES_APP_ID }}
+ private-key: ${{ secrets.POLKADOTSDK_GHPAGES_APP_KEY }}
+
+ - name: Store benchmark result
+ uses: benchmark-action/github-action-benchmark@v1
+ with:
+ tool: "customSmallerIsBetter"
+ name: ${{ github.event.inputs.benchmark-data-dir-path }}
+ output-file-path: ${{ github.event.inputs.output-file-path }}
+ benchmark-data-dir-path: "bench/${{ github.event.inputs.benchmark-data-dir-path }}"
+ github-token: ${{ steps.app-token.outputs.token }}
+ auto-push: true
diff --git a/.github/workflows/sync-templates.yml b/.github/workflows/sync-templates.yml
new file mode 100644
index 0000000000000000000000000000000000000000..511c9d0e8cd06f7b4b7b16126d6565cae9047a00
--- /dev/null
+++ b/.github/workflows/sync-templates.yml
@@ -0,0 +1,159 @@
+name: Synchronize templates
+
+
+# This job is used to keep the repository templates up-to-date.
+# The code of the templates exist inside the monorepo, and upon releases we synchronize the repositories:
+# - https://github.com/paritytech/polkadot-sdk-minimal-template
+# - https://github.com/paritytech/polkadot-sdk-parachain-template
+# - https://github.com/paritytech/polkadot-sdk-solochain-template
+#
+# The job moves the template code out of the monorepo,
+# replaces any references to the monorepo workspace using psvm and toml-cli,
+# checks that it builds successfully,
+# and commits and pushes the result to each respective repository.
+# If the build fails, a PR is created instead for manual inspection.
+
+
+on:
+ # A manual dispatch for now - automatic on releases later.
+ workflow_dispatch:
+ inputs:
+ crate_release_version:
+ description: 'A release version to use, e.g. 1.9.0'
+ required: true
+
+
+jobs:
+ sync-templates:
+ runs-on: ubuntu-latest
+ environment: master
+ strategy:
+ fail-fast: false
+ matrix:
+ template: ["minimal", "solochain", "parachain"]
+ env:
+ template-path: "polkadot-sdk-${{ matrix.template }}-template"
+ steps:
+
+ # 1. Prerequisites.
+
+ - name: Configure git identity
+ run: |
+ git config --global user.name "Template Bot"
+ git config --global user.email "163342540+paritytech-polkadotsdk-templatebot[bot]@users.noreply.github.com"
+ - uses: actions/checkout@v3
+ with:
+ path: polkadot-sdk
+ ref: "release-crates-io-v${{ github.event.inputs.crate_release_version }}"
+ - name: Generate a token for the template repository
+ id: app_token
+ uses: actions/create-github-app-token@v1.9.3
+ with:
+ owner: "paritytech"
+ repositories: "polkadot-sdk-${{ matrix.template }}-template"
+ app-id: ${{ secrets.TEMPLATE_APP_ID }}
+ private-key: ${{ secrets.TEMPLATE_APP_KEY }}
+ - uses: actions/checkout@v3
+ with:
+ repository: "paritytech/polkadot-sdk-${{ matrix.template }}-template"
+ path: "${{ env.template-path }}"
+ token: ${{ steps.app_token.outputs.token }}
+ - name: Install toml-cli
+ run: cargo install --git https://github.com/gnprice/toml-cli --rev ea69e9d2ca4f0f858110dc7a5ae28bcb918c07fb # v0.2.3
+ - name: Install Polkadot SDK Version Manager
+ run: cargo install --git https://github.com/paritytech/psvm --rev c41261ffb52ab0c115adbbdb17e2cb7900d2bdfd psvm # master
+ - name: Rust compilation prerequisites
+ run: |
+ sudo apt update
+ sudo apt install -y \
+ protobuf-compiler
+ rustup target add wasm32-unknown-unknown
+ rustup component add rustfmt clippy rust-src
+
+ # 2. Yanking the template out of the monorepo workspace.
+
+ - name: Use psvm to replace git references with released creates.
+ run: find . -type f -name 'Cargo.toml' -exec psvm -o -v ${{ github.event.inputs.crate_release_version }} -p {} \;
+ working-directory: polkadot-sdk/templates/${{ matrix.template }}/
+ - name: Create a new workspace Cargo.toml
+ run: |
+ cat << EOF > Cargo.toml
+ [workspace.package]
+ license = "MIT-0"
+ authors = ["Parity Technologies "]
+ homepage = "https://substrate.io"
+
+ [workspace]
+ members = [
+ "node",
+ "pallets/template",
+ "runtime",
+ ]
+ resolver = "2"
+ EOF
+ shell: bash
+ working-directory: polkadot-sdk/templates/${{ matrix.template }}/
+ - name: Update workspace configuration
+ run: |
+ set -euo pipefail
+ # toml-cli has no overwrite functionality yet, so we use temporary files.
+ # We cannot pipe the output straight to the same file while the CLI still reads and processes it.
+
+ toml set templates/${{ matrix.template }}/Cargo.toml 'workspace.package.repository' "https://github.com/paritytech/polkadot-sdk-${{ matrix.template }}-template.git" > Cargo.temp
+ mv Cargo.temp ./templates/${{ matrix.template }}/Cargo.toml
+
+ toml set templates/${{ matrix.template }}/Cargo.toml 'workspace.package.edition' "$(toml get --raw Cargo.toml 'workspace.package.edition')" > Cargo.temp
+ mv Cargo.temp ./templates/${{ matrix.template }}/Cargo.toml
+
+ toml get Cargo.toml 'workspace.lints' --output-toml >> ./templates/${{ matrix.template }}/Cargo.toml
+
+ toml get Cargo.toml 'workspace.dependencies' --output-toml >> ./templates/${{ matrix.template }}/Cargo.toml
+ working-directory: polkadot-sdk
+ - name: Print the result Cargo.tomls for debugging
+ if: runner.debug == '1'
+ run: find . -type f -name 'Cargo.toml' -exec cat {} \;
+ working-directory: polkadot-sdk/templates/${{ matrix.template }}/
+
+ - name: Clean the destination repository
+ run: rm -rf ./*
+ working-directory: "${{ env.template-path }}"
+ - name: Copy over the new changes
+ run: |
+ cp -r polkadot-sdk/templates/${{ matrix.template }}/* "${{ env.template-path }}/"
+
+ # 3. Verify the build. Push the changes or create a PR.
+
+ # We've run into out-of-disk error when compiling in the next step, so we free up some space this way.
+ - name: Free Disk Space (Ubuntu)
+ uses: jlumbroso/free-disk-space@54081f138730dfa15788a46383842cd2f914a1be # 1.3.1
+ with:
+ android: true # This alone is a 12 GB save.
+ # We disable the rest because it caused some problems. (they're enabled by default)
+ # The Android removal is enough.
+ dotnet: false
+ haskell: false
+ large-packages: false
+ swap-storage: false
+
+ - name: Check if it compiles
+ id: check-compilation
+ run: cargo check && cargo test
+ working-directory: "${{ env.template-path }}"
+ timeout-minutes: 90
+ - name: Create PR on failure
+ if: failure() && steps.check-compilation.outcome == 'failure'
+ uses: peter-evans/create-pull-request@5b4a9f6a9e2af26e5f02351490b90d01eb8ec1e5 # v5
+ with:
+ path: "${{ env.template-path }}"
+ token: ${{ steps.app_token.outputs.token }}
+ add-paths: |
+ ./*
+ title: "[Don't merge] Update the ${{ matrix.template }} template"
+ body: "The template has NOT been successfully built and needs to be inspected."
+ branch: "update-template/${{ github.event_name }}"
+ - name: Push changes
+ run: |
+ git add -A .
+ git commit --allow-empty -m "Update template triggered by ${{ github.event_name }}"
+ git push
+ working-directory: "${{ env.template-path }}"
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 7f8796ca51248acb8be92fcb9f76e280b18e605e..5e57dd86f14166e695f1c64b6b5aee56529a4781 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -119,19 +119,26 @@ default:
#
.forklift-cache:
before_script:
- - 'curl --header "PRIVATE-TOKEN: $FL_CI_GROUP_TOKEN" -o forklift -L "${CI_API_V4_URL}/projects/676/packages/generic/forklift/${FL_FORKLIFT_VERSION}/forklift_${FL_FORKLIFT_VERSION}_linux_amd64"'
- - chmod +x forklift
- mkdir ~/.forklift
- cp $FL_FORKLIFT_CONFIG ~/.forklift/config.toml
- - shopt -s expand_aliases
- - export PATH=$PATH:$(pwd)
- - |
+ - >
if [ "$FORKLIFT_BYPASS" != "true" ]; then
- echo "FORKLIFT_BYPASS not set, creating alias cargo='forklift cargo'"
- alias cargo="forklift cargo"
+ echo "FORKLIFT_BYPASS not set";
+ if command -v forklift >/dev/null 2>&1; then
+ echo "forklift already exists";
+ forklift version
+ else
+ echo "forklift does not exist, downloading";
+ curl --header "PRIVATE-TOKEN: $FL_CI_GROUP_TOKEN" -o forklift -L "${CI_API_V4_URL}/projects/676/packages/generic/forklift/${FL_FORKLIFT_VERSION}/forklift_${FL_FORKLIFT_VERSION}_linux_amd64";
+ chmod +x forklift;
+ export PATH=$PATH:$(pwd);
+ echo ${FL_FORKLIFT_VERSION};
+ fi
+ echo "Creating alias cargo='forklift cargo'";
+ shopt -s expand_aliases;
+ alias cargo="forklift cargo";
fi
#
- - echo "FL_FORKLIFT_VERSION ${FL_FORKLIFT_VERSION}"
.common-refs:
rules:
@@ -147,6 +154,13 @@ default:
- if: $CI_COMMIT_REF_NAME =~ /^[0-9]+$/ # PRs
- if: $CI_COMMIT_REF_NAME =~ /^gh-readonly-queue.*$/ # merge queues
+.publish-gh-pages-refs:
+ rules:
+ - if: $CI_PIPELINE_SOURCE == "pipeline"
+ when: never
+ - if: $CI_PIPELINE_SOURCE == "web" && $CI_COMMIT_REF_NAME == "master"
+ - if: $CI_COMMIT_REF_NAME == "master"
+
# handle the specific case where benches could store incorrect bench data because of the downstream staging runs
# exclude cargo-check-benches from such runs
.test-refs-check-benches:
diff --git a/.gitlab/pipeline/build.yml b/.gitlab/pipeline/build.yml
index f8de6135572565d9d16465e68aa3f0bace915cc5..8658e92efc8f9f7ae463a67a52eaf3d3d37df2f7 100644
--- a/.gitlab/pipeline/build.yml
+++ b/.gitlab/pipeline/build.yml
@@ -91,7 +91,7 @@ build-rustdoc:
- .run-immediately
variables:
SKIP_WASM_BUILD: 1
- RUSTDOCFLAGS: "--default-theme=ayu --html-in-header ./docs/sdk/headers/header.html --extend-css ./docs/sdk/headers/theme.css"
+ RUSTDOCFLAGS: "-Dwarnings --default-theme=ayu --html-in-header ./docs/sdk/assets/header.html --extend-css ./docs/sdk/assets/theme.css --html-after-content ./docs/sdk/assets/after-content.html"
artifacts:
name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}-doc"
when: on_success
@@ -99,32 +99,31 @@ build-rustdoc:
paths:
- ./crate-docs/
script:
- # FIXME: it fails with `RUSTDOCFLAGS="-Dwarnings"` and `--all-features`
- - time cargo doc --features try-runtime,experimental --workspace --no-deps
+ - time cargo doc --all-features --workspace --no-deps
- rm -f ./target/doc/.lock
- mv ./target/doc ./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=""
+ 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
- # xargs runs process_file in seperate shells without access to outer variables.
- # to make script_content available inside process_file, export it as an env var here.
- export script_content
+ local file="$1";
+ echo "Adding Simple Analytics script to $file";
+ sed -i "s||$script_content|" "$file";
+ };
+ export -f process_file;
+ # xargs runs process_file in separate shells without access to outer variables.
+ # make script_content available inside process_file, export it as an env var here.
+ export script_content;
# 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"
+ 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:
@@ -350,7 +349,7 @@ build-runtimes-polkavm:
- .run-immediately
# - .collect-artifact
variables:
- # this variable gets overriden by "rusty-cachier environment inject", use the value as default
+ # this variable gets overridden by "rusty-cachier environment inject", use the value as default
CARGO_TARGET_DIR: "$CI_PROJECT_DIR/target"
before_script:
- mkdir -p ./artifacts/subkey
diff --git a/.gitlab/pipeline/check.yml b/.gitlab/pipeline/check.yml
index 52da33550508ede16c9577346e6985d869b5e8ae..89b2c00db9b2b13187a562987e00abcb232e0e32 100644
--- a/.gitlab/pipeline/check.yml
+++ b/.gitlab/pipeline/check.yml
@@ -7,8 +7,8 @@ cargo-clippy:
variables:
RUSTFLAGS: "-D warnings"
script:
- - SKIP_WASM_BUILD=1 cargo clippy --all-targets --locked --workspace
- - SKIP_WASM_BUILD=1 cargo clippy --all-targets --all-features --locked --workspace
+ - SKIP_WASM_BUILD=1 cargo clippy --all-targets --locked --workspace --quiet
+ - SKIP_WASM_BUILD=1 cargo clippy --all-targets --all-features --locked --workspace --quiet
check-try-runtime:
stage: check
@@ -104,23 +104,20 @@ check-toml-format:
- .docker-env
- .test-pr-refs
script:
- - |
- export RUST_LOG=remote-ext=debug,runtime=debug
-
- echo "---------- Downloading try-runtime CLI ----------"
- curl -sL https://github.com/paritytech/try-runtime-cli/releases/download/v0.5.4/try-runtime-x86_64-unknown-linux-musl -o try-runtime
- chmod +x ./try-runtime
- echo "Using try-runtime-cli version:"
- ./try-runtime --version
-
- echo "---------- Building ${PACKAGE} runtime ----------"
- time cargo build --release --locked -p "$PACKAGE" --features try-runtime
-
- echo "---------- Executing on-runtime-upgrade for ${NETWORK} ----------"
+ - export RUST_LOG=remote-ext=debug,runtime=debug
+ - echo "---------- Downloading try-runtime CLI ----------"
+ - curl -sL https://github.com/paritytech/try-runtime-cli/releases/download/v0.5.4/try-runtime-x86_64-unknown-linux-musl -o try-runtime
+ - chmod +x ./try-runtime
+ - echo "Using try-runtime-cli version:"
+ - ./try-runtime --version
+ - echo "---------- Building ${PACKAGE} runtime ----------"
+ - time cargo build --release --locked -p "$PACKAGE" --features try-runtime
+ - echo "---------- Executing on-runtime-upgrade for ${NETWORK} ----------"
+ - >
time ./try-runtime ${COMMAND_EXTRA_ARGS} \
- --runtime ./target/release/wbuild/"$PACKAGE"/"$WASM" \
- on-runtime-upgrade --disable-spec-version-check --checks=all ${SUBCOMMAND_EXTRA_ARGS} live --uri ${URI}
- sleep 5
+ --runtime ./target/release/wbuild/"$PACKAGE"/"$WASM" \
+ on-runtime-upgrade --disable-spec-version-check --checks=all ${SUBCOMMAND_EXTRA_ARGS} live --uri ${URI}
+ - sleep 5
# Check runtime migrations for Parity managed relay chains
check-runtime-migration-westend:
diff --git a/.gitlab/pipeline/publish.yml b/.gitlab/pipeline/publish.yml
index b73acb560f67f93e540826b95fcf075374189846..d8f5d5832291f7afced292d3b0fdeb6238de26a8 100644
--- a/.gitlab/pipeline/publish.yml
+++ b/.gitlab/pipeline/publish.yml
@@ -3,16 +3,13 @@
publish-rustdoc:
stage: publish
- extends: .kubernetes-env
+ extends:
+ - .kubernetes-env
+ - .publish-gh-pages-refs
variables:
CI_IMAGE: node:18
GIT_DEPTH: 100
RUSTDOCS_DEPLOY_REFS: "master"
- rules:
- - if: $CI_PIPELINE_SOURCE == "pipeline"
- when: never
- - if: $CI_PIPELINE_SOURCE == "web" && $CI_COMMIT_REF_NAME == "master"
- - if: $CI_COMMIT_REF_NAME == "master"
needs:
- job: build-rustdoc
artifacts: true
@@ -60,9 +57,80 @@ publish-rustdoc:
- git commit -m "___Updated docs for ${CI_COMMIT_REF_NAME}___" ||
echo "___Nothing to commit___"
- git push origin gh-pages --force
+ # artificial sleep to publish gh-pages
+ - sleep 300
+ after_script:
+ - rm -rf .git/ ./*
+
+publish-subsystem-benchmarks:
+ stage: publish
+ variables:
+ CI_IMAGE: "paritytech/tools:latest"
+ extends:
+ - .kubernetes-env
+ - .publish-gh-pages-refs
+ needs:
+ - job: subsystem-benchmark-availability-recovery
+ artifacts: true
+ - job: subsystem-benchmark-availability-distribution
+ artifacts: true
+ - job: publish-rustdoc
+ artifacts: false
+ script:
+ # setup ssh
+ - eval $(ssh-agent)
+ - ssh-add - <<< ${GITHUB_SSH_PRIV_KEY}
+ - mkdir ~/.ssh && touch ~/.ssh/known_hosts
+ - ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts
+ # Set git config
+ - rm -rf .git/config
+ - git config user.email "devops-team@parity.io"
+ - git config user.name "${GITHUB_USER}"
+ - git config remote.origin.url "git@github.com:/paritytech/${CI_PROJECT_NAME}.git"
+ - git config remote.origin.fetch "+refs/heads/*:refs/remotes/origin/*"
+ - git fetch origin gh-pages
+ # Push result to github
+ - git checkout gh-pages --force
+ - mkdir -p bench/gitlab/ || echo "Directory exists"
+ - rm -rf bench/gitlab/*.json || echo "No json files"
+ - cp -r charts/*.json bench/gitlab/
+ - git add bench/gitlab/
+ - git commit -m "Add json files with benchmark results for ${CI_COMMIT_REF_NAME}"
+ - git push origin gh-pages
+ # artificial sleep to publish gh-pages
+ - sleep 300
+ allow_failure: true
after_script:
- rm -rf .git/ ./*
+trigger_workflow:
+ stage: deploy
+ extends:
+ - .kubernetes-env
+ - .publish-gh-pages-refs
+ needs:
+ - job: publish-subsystem-benchmarks
+ artifacts: false
+ - job: subsystem-benchmark-availability-recovery
+ artifacts: true
+ - job: subsystem-benchmark-availability-distribution
+ artifacts: true
+ script:
+ - echo "Triggering workflow"
+ - >
+ for benchmark in $(ls charts/*.json); do
+ export benchmark_name=$(basename $benchmark);
+ echo "Benchmark: $benchmark_name";
+ export benchmark_dir=$(echo $benchmark_name | sed 's/\.json//');
+ curl -q -X POST \
+ -H "Accept: application/vnd.github.v3+json" \
+ -H "Authorization: token $GITHUB_TOKEN" \
+ https://api.github.com/repos/paritytech/${CI_PROJECT_NAME}/actions/workflows/subsystem-benchmarks.yml/dispatches \
+ -d "{\"ref\":\"refs/heads/master\",\"inputs\":{\"benchmark-data-dir-path\":\"$benchmark_dir\",\"output-file-path\":\"$benchmark_name\"}}";
+ sleep 300;
+ done
+ allow_failure: true
+
# note: images are used not only in zombienet but also in rococo, wococo and versi
.build-push-image:
image: $BUILDAH_IMAGE
diff --git a/.gitlab/pipeline/test.yml b/.gitlab/pipeline/test.yml
index d244316000aaf152810c396e37e470694be506cc..1d6efd7b9fd1a91c3c49aa26faa9263216e9cb4e 100644
--- a/.gitlab/pipeline/test.yml
+++ b/.gitlab/pipeline/test.yml
@@ -23,9 +23,8 @@ test-linux-stable:
- echo "Node index - ${CI_NODE_INDEX}. Total amount - ${CI_NODE_TOTAL}"
# add experimental to features after https://github.com/paritytech/substrate/pull/14502 is merged
# "upgrade_version_checks_should_work" is currently failing
- - |
+ - >
time cargo nextest run \
- --filter-expr 'not deps(/polkadot-subsystem-bench/)' \
--workspace \
--locked \
--release \
@@ -35,7 +34,7 @@ test-linux-stable:
# Upload tests results to Elasticsearch
- echo "Upload test results to Elasticsearch"
- cat target/nextest/default/junit.xml | xq . > target/nextest/default/junit.json
- - |
+ - >
curl -v -XPOST --http1.1 \
-u ${ELASTIC_USERNAME}:${ELASTIC_PASSWORD} \
https://elasticsearch.parity-build.parity.io/unit-tests/_doc/${CI_JOB_ID} \
@@ -70,7 +69,7 @@ test-linux-stable-runtime-benchmarks:
# but still want to have debug assertions.
RUSTFLAGS: "-Cdebug-assertions=y -Dwarnings"
script:
- - time cargo nextest run --filter-expr 'not deps(/polkadot-subsystem-bench/)' --workspace --features runtime-benchmarks benchmark --locked --cargo-profile testnet
+ - time cargo nextest run --workspace --features runtime-benchmarks benchmark --locked --cargo-profile testnet
# can be used to run all tests
# test-linux-stable-all:
@@ -88,7 +87,7 @@ test-linux-stable-runtime-benchmarks:
# script:
# # Build all but only execute 'runtime' tests.
# - echo "Node index - ${CI_NODE_INDEX}. Total amount - ${CI_NODE_TOTAL}"
-# - |
+# - >
# time cargo nextest run \
# --workspace \
# --locked \
@@ -323,7 +322,24 @@ quick-benchmarks:
WASM_BUILD_NO_COLOR: 1
WASM_BUILD_RUSTFLAGS: "-C debug-assertions -D warnings"
script:
- - time cargo run --locked --release -p staging-node-cli --bin substrate-node --features runtime-benchmarks -- benchmark pallet --execution wasm --wasm-execution compiled --chain dev --pallet "*" --extrinsic "*" --steps 2 --repeat 1
+ - time cargo run --locked --release -p staging-node-cli --bin substrate-node --features runtime-benchmarks --quiet -- benchmark pallet --chain dev --pallet "*" --extrinsic "*" --steps 2 --repeat 1 --quiet
+
+quick-benchmarks-omni:
+ stage: test
+ extends:
+ - .docker-env
+ - .common-refs
+ - .run-immediately
+ variables:
+ # Enable debug assertions since we are running optimized builds for testing
+ # but still want to have debug assertions.
+ RUSTFLAGS: "-C debug-assertions"
+ RUST_BACKTRACE: "full"
+ WASM_BUILD_NO_COLOR: 1
+ WASM_BUILD_RUSTFLAGS: "-C debug-assertions"
+ script:
+ - time cargo build --locked --quiet --release -p asset-hub-westend-runtime --features runtime-benchmarks
+ - time cargo run --locked --release -p frame-omni-bencher --quiet -- v1 benchmark pallet --runtime target/release/wbuild/asset-hub-westend-runtime/asset_hub_westend_runtime.compact.compressed.wasm --all --steps 2 --repeat 1 --quiet
test-frame-examples-compile-to-wasm:
# into one job
@@ -495,14 +511,38 @@ test-syscalls:
fi
allow_failure: false # this rarely triggers in practice
-subsystem-regression-tests:
+subsystem-benchmark-availability-recovery:
stage: test
+ artifacts:
+ name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}"
+ when: always
+ expire_in: 1 hour
+ paths:
+ - charts/
+ extends:
+ - .docker-env
+ - .common-refs
+ - .run-immediately
+ script:
+ - cargo bench -p polkadot-availability-recovery --bench availability-recovery-regression-bench --features subsystem-benchmarks
+ tags:
+ - benchmark
+ allow_failure: true
+
+subsystem-benchmark-availability-distribution:
+ stage: test
+ artifacts:
+ name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}"
+ when: always
+ expire_in: 1 hour
+ paths:
+ - charts/
extends:
- .docker-env
- .common-refs
- .run-immediately
script:
- - cargo bench --profile=testnet -p polkadot-availability-recovery --bench availability-recovery-regression-bench --features subsystem-benchmarks
+ - cargo bench -p polkadot-availability-distribution --bench availability-distribution-regression-bench --features subsystem-benchmarks
tags:
- benchmark
allow_failure: true
diff --git a/.gitlab/pipeline/zombienet.yml b/.gitlab/pipeline/zombienet.yml
index 8d308714fab3cb44827bb202fce0939f52f730ad..52948e1eb719d9f8669523d9762f5662fd1b6e96 100644
--- a/.gitlab/pipeline/zombienet.yml
+++ b/.gitlab/pipeline/zombienet.yml
@@ -1,7 +1,8 @@
.zombienet-refs:
extends: .build-refs
variables:
- ZOMBIENET_IMAGE: "docker.io/paritytech/zombienet:v1.3.95"
+ ZOMBIENET_IMAGE: "docker.io/paritytech/zombienet:v1.3.99"
+ PUSHGATEWAY_URL: "http://zombienet-prometheus-pushgateway.managed-monitoring:9091/metrics/job/zombie-metrics"
include:
# substrate tests
diff --git a/.gitlab/pipeline/zombienet/polkadot.yml b/.gitlab/pipeline/zombienet/polkadot.yml
index 97572f029d0020f090a8fd16839028ac9f088cf9..6b72075c513b73c075d1dc10c90d0461bf0e1a82 100644
--- a/.gitlab/pipeline/zombienet/polkadot.yml
+++ b/.gitlab/pipeline/zombienet/polkadot.yml
@@ -158,13 +158,23 @@ zombienet-polkadot-functional-0011-async-backing-6-seconds-rate:
--local-dir="${LOCAL_DIR}/functional"
--test="0011-async-backing-6-seconds-rate.zndsl"
-zombienet-polkadot-functional-0012-elastic-scaling-mvp:
+zombienet-polkadot-elastic-scaling-0001-basic-3cores-6s-blocks:
extends:
- .zombienet-polkadot-common
+ variables:
+ FORCED_INFRA_INSTANCE: "spot-iops"
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
- --local-dir="${LOCAL_DIR}/functional"
- --test="0012-elastic-scaling-mvp.zndsl"
+ --local-dir="${LOCAL_DIR}/elastic_scaling"
+ --test="0001-basic-3cores-6s-blocks.zndsl"
+
+zombienet-polkadot-elastic-scaling-0002-elastic-scaling-doesnt-break-parachains:
+ extends:
+ - .zombienet-polkadot-common
+ script:
+ - /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
+ --local-dir="${LOCAL_DIR}/elastic_scaling"
+ --test="0002-elastic-scaling-doesnt-break-parachains.zndsl"
zombienet-polkadot-smoke-0001-parachains-smoke-test:
extends:
diff --git a/.gitlab/rust-features.sh b/.gitlab/rust-features.sh
index c0ac192a6ec69ba16abb3bad2ec49de7e9cebb61..c3ec61ab8714768c9a49f2eb2e1e544706a1d875 100755
--- a/.gitlab/rust-features.sh
+++ b/.gitlab/rust-features.sh
@@ -15,7 +15,7 @@
#
# The steps of this script:
# 1. Check that all required dependencies are installed.
-# 2. Check that all rules are fullfilled for the whole workspace. If not:
+# 2. Check that all rules are fulfilled for the whole workspace. If not:
# 4. Check all crates to find the offending ones.
# 5. Print all offending crates and exit with code 1.
#
diff --git a/BRIDGES.md b/BRIDGES.md
deleted file mode 100644
index a6f00aec09283e10d1a697bcef3f523881941663..0000000000000000000000000000000000000000
--- a/BRIDGES.md
+++ /dev/null
@@ -1,91 +0,0 @@
-# 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.
-
-(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)
-
-## 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
-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)
-
-
-## How to pull latest Bridges code to the `bridges` subtree
-(in practice)
-
-The `bridges` repo has a stabilized branch `polkadot-staging` dedicated for releasing.
-
-```
-cd
-
-# this will update new git branches from bridges repo
-# 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
-
-# so, after fetch and before solving conflicts just run patch,
-# this will remove unneeded files and checks if subtree modules compiles
-./scripts/bridges_update_subtree.sh patch
-
-# if there are conflicts, this could help,
-# this removes locally deleted files at least (move changes to git stash for commit)
-./scripts/bridges_update_subtree.sh merge
-
-# (optional) when conflicts resolved, you can check build again - should pass
-# also important: this updates global Cargo.lock
-./scripts/bridges_update_subtree.sh patch
-
-# add changes to the commit, first command `fetch` starts merge,
-# so after all conflicts are solved and patch passes and compiles,
-# then we need to finish merge with:
-git merge --continue
-```
-
-## 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
-of adding the code as `git subtree` is to **reduce maintenance cost** for Cumulus/Polkadot
-developers.
-
-If you still would like to either update the code to match latest code from the repo
-or create an upstream PR read below. The following commands should be run in the
-current (`polkadot`) repo.
-
-### Add Bridges repo as a local remote
-```
-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
-```
-
-### To update Bridges
-```
-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.
-
-### Clean unneeded files here
-```
-./bridges/scripts/verify-pallets-build.sh --ignore-git-state --no-revert
-```
-
-### Contributing back to Bridges (creating upstream PR)
-```
-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/Cargo.lock b/Cargo.lock
index 14464317a16ec01fba6931ae62c9b42b6aedd0ad..5fb22c7f1b32998670fc0e0f340be4b2a328631c 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -165,7 +165,7 @@ dependencies = [
"hex-literal",
"itoa",
"proptest",
- "rand",
+ "rand 0.8.5",
"ruint",
"serde",
"tiny-keccak",
@@ -177,23 +177,11 @@ version = "0.3.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "cc0fac0fc16baf1f63f78b47c3d24718f3619b0714076f6a02957d808d52cbef"
dependencies = [
- "alloy-rlp-derive",
"arrayvec 0.7.4",
"bytes",
"smol_str",
]
-[[package]]
-name = "alloy-rlp-derive"
-version = "0.3.3"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c0391754c09fab4eae3404d19d0d297aa1c670c1775ab51d8a5312afeca23157"
-dependencies = [
- "proc-macro2",
- "quote",
- "syn 2.0.53",
-]
-
[[package]]
name = "alloy-sol-macro"
version = "0.4.2"
@@ -204,8 +192,8 @@ dependencies = [
"dunce",
"heck 0.4.1",
"proc-macro-error",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
"syn-solidity",
"tiny-keccak",
@@ -275,9 +263,9 @@ dependencies = [
[[package]]
name = "anstyle"
-version = "1.0.2"
+version = "1.0.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "15c4c2c83f81532e5845a733998b6971faca23490340a418e9b72a3ec9de12ea"
+checksum = "8901269c6307e8d93993578286ac0edf7f195079ffff5ebdeea6a59ffb7e36bc"
[[package]]
name = "anstyle-parse"
@@ -331,8 +319,8 @@ dependencies = [
"include_dir",
"itertools 0.10.5",
"proc-macro-error",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -345,8 +333,8 @@ dependencies = [
"include_dir",
"itertools 0.10.5",
"proc-macro-error",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -542,7 +530,7 @@ version = "0.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "db02d390bf6643fb404d3d22d31aee1c4bc4459600aef9113833d17e786c6e44"
dependencies = [
- "quote",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -552,7 +540,7 @@ version = "0.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3ed4aa4fe255d0bc6d79373f7e31d2ea147bcf486cba1be5ba7ea85abdb92348"
dependencies = [
- "quote",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -564,7 +552,7 @@ checksum = "db2fd794a08ccb318058009eefdf15bcaaaaf6f8161eb3345f907222bac38b20"
dependencies = [
"num-bigint",
"num-traits",
- "quote",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -576,8 +564,8 @@ checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565"
dependencies = [
"num-bigint",
"num-traits",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -678,8 +666,8 @@ version = "0.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ae3281bc6d0fd7e549af32b52511e1302185bd688fd3359fa36423346ff682ea"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -690,7 +678,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1df2c09229cbc5a028b1d70e00fdb2acee28b1055dfb5ca73eea49c5a25c4e7c"
dependencies = [
"num-traits",
- "rand",
+ "rand 0.8.5",
]
[[package]]
@@ -700,7 +688,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "94893f1e0c6eeab764ade8dc4c0db24caf4fe7cbbaafc0eba0a9030f447b5185"
dependencies = [
"num-traits",
- "rand",
+ "rand 0.8.5",
"rayon",
]
@@ -772,8 +760,8 @@ version = "0.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "726535892e8eae7e70657b4c8ea93d26b8553afb1ce617caee529ef96d7dee6c"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
"synstructure",
]
@@ -784,8 +772,8 @@ version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2777730b2039ac0f95f093556e61b6d26cebed5393ca6f152717777cec3a42ed"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -821,6 +809,7 @@ dependencies = [
"parachains-common",
"rococo-emulated-chain",
"sp-core",
+ "staging-xcm",
"testnet-parachains-constants",
]
@@ -831,7 +820,6 @@ dependencies = [
"assert_matches",
"asset-hub-rococo-runtime",
"asset-test-utils",
- "cumulus-pallet-parachain-system",
"emulated-integration-tests-common",
"frame-support",
"pallet-asset-conversion",
@@ -847,7 +835,6 @@ dependencies = [
"sp-runtime",
"staging-xcm",
"staging-xcm-executor",
- "testnet-parachains-constants",
]
[[package]]
@@ -867,6 +854,7 @@ dependencies = [
"cumulus-pallet-xcmp-queue",
"cumulus-primitives-aura",
"cumulus-primitives-core",
+ "cumulus-primitives-storage-weight-reclaim",
"cumulus-primitives-utility",
"frame-benchmarking",
"frame-executive",
@@ -941,6 +929,7 @@ dependencies = [
"frame-support",
"parachains-common",
"sp-core",
+ "staging-xcm",
"testnet-parachains-constants",
"westend-emulated-chain",
]
@@ -969,7 +958,6 @@ dependencies = [
"sp-runtime",
"staging-xcm",
"staging-xcm-executor",
- "testnet-parachains-constants",
"westend-runtime",
"westend-system-emulated-network",
]
@@ -991,6 +979,7 @@ dependencies = [
"cumulus-pallet-xcmp-queue",
"cumulus-primitives-aura",
"cumulus-primitives-core",
+ "cumulus-primitives-storage-weight-reclaim",
"cumulus-primitives-utility",
"frame-benchmarking",
"frame-executive",
@@ -1104,6 +1093,16 @@ dependencies = [
"substrate-wasm-builder",
]
+[[package]]
+name = "async-attributes"
+version = "1.1.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a3203e79f4dd9bdda415ed03cf14dae5a2bf775c683a00f94e9cd1faf0f596e5"
+dependencies = [
+ "quote 1.0.35",
+ "syn 1.0.109",
+]
+
[[package]]
name = "async-channel"
version = "1.9.0"
@@ -1141,6 +1140,21 @@ dependencies = [
"futures-lite",
]
+[[package]]
+name = "async-global-executor"
+version = "2.3.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f1b6f5d7df27bd294849f8eec66ecfc63d11814df7a4f5d74168a2394467b776"
+dependencies = [
+ "async-channel",
+ "async-executor",
+ "async-io",
+ "async-lock 2.8.0",
+ "blocking",
+ "futures-lite",
+ "once_cell",
+]
+
[[package]]
name = "async-io"
version = "1.13.0"
@@ -1211,6 +1225,33 @@ dependencies = [
"windows-sys 0.48.0",
]
+[[package]]
+name = "async-std"
+version = "1.12.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "62565bb4402e926b29953c785397c6dc0391b7b446e45008b0049eb43cec6f5d"
+dependencies = [
+ "async-attributes",
+ "async-channel",
+ "async-global-executor",
+ "async-io",
+ "async-lock 2.8.0",
+ "crossbeam-utils",
+ "futures-channel",
+ "futures-core",
+ "futures-io",
+ "futures-lite",
+ "gloo-timers",
+ "kv-log-macro",
+ "log",
+ "memchr",
+ "once_cell",
+ "pin-project-lite 0.2.12",
+ "pin-utils",
+ "slab",
+ "wasm-bindgen-futures",
+]
+
[[package]]
name = "async-stream"
version = "0.3.5"
@@ -1228,8 +1269,8 @@ version = "0.3.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -1241,12 +1282,12 @@ checksum = "ecc7ab41815b3c653ccd2978ec3255c81349336702dfdf62ee6f7069b12a3aae"
[[package]]
name = "async-trait"
-version = "0.1.74"
+version = "0.1.79"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a66537f1bb974b254c98ed142ff995236e81b9d0fe4db0575f46612cb15eb0f9"
+checksum = "a507401cad91ec6a857ed5513a2073c82a9b9048762b885bb98655b306964681"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -1293,8 +1334,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "fee3da8ef1276b0bee5dd1c7258010d8fffd31801447323115a25560e1327b89"
dependencies = [
"proc-macro-error",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -1304,6 +1345,17 @@ version = "1.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa"
+[[package]]
+name = "backoff"
+version = "0.4.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b62ddb9cb1ec0a098ad4bbf9344d0713fa193ae1a80af55febcff2627b6a00c1"
+dependencies = [
+ "getrandom 0.2.10",
+ "instant",
+ "rand 0.8.5",
+]
+
[[package]]
name = "backtrace"
version = "0.3.69"
@@ -1395,7 +1447,7 @@ name = "binary-merkle-tree"
version = "13.0.0"
dependencies = [
"array-bytes 6.1.0",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"hash-db",
"log",
"sp-core",
@@ -1424,8 +1476,8 @@ dependencies = [
"lazycell",
"peeking_take_while",
"prettyplease 0.2.12",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"regex",
"rustc-hash",
"shlex",
@@ -1646,6 +1698,23 @@ dependencies = [
"scale-info",
]
+[[package]]
+name = "bp-beefy"
+version = "0.1.0"
+dependencies = [
+ "binary-merkle-tree",
+ "bp-runtime",
+ "frame-support",
+ "pallet-beefy-mmr",
+ "pallet-mmr",
+ "parity-scale-codec",
+ "scale-info",
+ "serde",
+ "sp-consensus-beefy",
+ "sp-runtime",
+ "sp-std 14.0.0",
+]
+
[[package]]
name = "bp-bridge-hub-cumulus"
version = "0.7.0"
@@ -1880,7 +1949,7 @@ dependencies = [
"bp-parachains",
"bp-polkadot-core",
"bp-runtime",
- "ed25519-dalek",
+ "ed25519-dalek 2.1.0",
"finality-grandpa",
"parity-scale-codec",
"sp-application-crypto",
@@ -1922,7 +1991,7 @@ dependencies = [
[[package]]
name = "bridge-hub-common"
-version = "0.0.0"
+version = "0.1.0"
dependencies = [
"cumulus-primitives-core",
"frame-support",
@@ -1954,7 +2023,6 @@ name = "bridge-hub-rococo-integration-tests"
version = "1.0.0"
dependencies = [
"asset-hub-rococo-runtime",
- "bp-messages",
"bridge-hub-rococo-runtime",
"cumulus-pallet-xcmp-queue",
"emulated-integration-tests-common",
@@ -1972,7 +2040,6 @@ dependencies = [
"rococo-westend-system-emulated-network",
"scale-info",
"snowbridge-core",
- "snowbridge-pallet-inbound-queue",
"snowbridge-pallet-inbound-queue-fixtures",
"snowbridge-pallet-outbound-queue",
"snowbridge-pallet-system",
@@ -2012,6 +2079,7 @@ dependencies = [
"cumulus-pallet-xcmp-queue",
"cumulus-primitives-aura",
"cumulus-primitives-core",
+ "cumulus-primitives-storage-weight-reclaim",
"cumulus-primitives-utility",
"frame-benchmarking",
"frame-executive",
@@ -2138,7 +2206,6 @@ dependencies = [
name = "bridge-hub-westend-integration-tests"
version = "1.0.0"
dependencies = [
- "bp-messages",
"bridge-hub-westend-runtime",
"cumulus-pallet-xcmp-queue",
"emulated-integration-tests-common",
@@ -2150,6 +2217,7 @@ dependencies = [
"pallet-message-queue",
"pallet-xcm",
"parachains-common",
+ "parity-scale-codec",
"rococo-westend-system-emulated-network",
"sp-runtime",
"staging-xcm",
@@ -2182,6 +2250,7 @@ dependencies = [
"cumulus-pallet-xcmp-queue",
"cumulus-primitives-aura",
"cumulus-primitives-core",
+ "cumulus-primitives-storage-weight-reclaim",
"cumulus-primitives-utility",
"frame-benchmarking",
"frame-executive",
@@ -2408,6 +2477,12 @@ version = "0.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "37b2a672a2cb129a2e41c10b1224bb368f9f37a2b16b612598138befd7b37eb5"
+[[package]]
+name = "castaway"
+version = "0.1.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a2698f953def977c68f935bb0dfa959375ad4638570e969e2f1e9f433cbf1af6"
+
[[package]]
name = "cc"
version = "1.0.83"
@@ -2548,6 +2623,19 @@ dependencies = [
"unsigned-varint",
]
+[[package]]
+name = "cid"
+version = "0.10.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "fd94671561e36e4e7de75f753f577edafb0e7c05d6e4547229fdf7938fbcd2c3"
+dependencies = [
+ "core2",
+ "multibase",
+ "multihash 0.18.1",
+ "serde",
+ "unsigned-varint",
+]
+
[[package]]
name = "cipher"
version = "0.2.5"
@@ -2596,6 +2684,21 @@ dependencies = [
"libloading",
]
+[[package]]
+name = "clap"
+version = "2.34.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a0610544180c38b88101fecf2dd634b174a62eef6946f84dfc6a7127512b381c"
+dependencies = [
+ "ansi_term",
+ "atty",
+ "bitflags 1.3.2",
+ "strsim 0.8.0",
+ "textwrap 0.11.0",
+ "unicode-width",
+ "vec_map",
+]
+
[[package]]
name = "clap"
version = "3.2.25"
@@ -2610,7 +2713,7 @@ dependencies = [
"once_cell",
"strsim 0.10.0",
"termcolor",
- "textwrap",
+ "textwrap 0.16.0",
]
[[package]]
@@ -2625,9 +2728,9 @@ dependencies = [
[[package]]
name = "clap-num"
-version = "1.1.1"
+version = "1.0.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "0e063d263364859dc54fb064cedb7c122740cd4733644b14b176c097f51e8ab7"
+checksum = "488557e97528174edaa2ee268b23a809e0c598213a4bbcb4f34575a46fda147e"
dependencies = [
"num-traits",
]
@@ -2662,8 +2765,8 @@ checksum = "ae6371b8bdc8b7d3959e9cf7b22d4435ef3e79e138688421ec654acf8c81b008"
dependencies = [
"heck 0.4.1",
"proc-macro-error",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -2674,8 +2777,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "90239a040c80f5e14809ca132ddc4176ab33d5e17e49691793296e3fcb34d72f"
dependencies = [
"heck 0.5.0",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -2740,6 +2843,7 @@ dependencies = [
"cumulus-pallet-xcmp-queue",
"cumulus-primitives-aura",
"cumulus-primitives-core",
+ "cumulus-primitives-storage-weight-reclaim",
"cumulus-primitives-utility",
"frame-benchmarking",
"frame-executive",
@@ -2832,8 +2936,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d51beaa537d73d2d1ff34ee70bc095f170420ab2ec5d687ecd3ec2b0d092514b"
dependencies = [
"nom",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -2845,14 +2949,25 @@ checksum = "acbf1af155f9b9ef647e42cdc158db4b64a1b61f743629225fde6f3e0be2a7c7"
[[package]]
name = "colored"
-version = "2.1.0"
+version = "2.0.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8"
+checksum = "2674ec482fbc38012cf31e6c42ba0177b431a0cb6f15fe40efa5aab1bda516f6"
dependencies = [
+ "is-terminal",
"lazy_static",
"windows-sys 0.48.0",
]
+[[package]]
+name = "combine"
+version = "4.6.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "35ed6e9d84f0b51a7f52daf1c7d71dd136fd7a3f41a8462b8cdb8c78d920fad4"
+dependencies = [
+ "bytes",
+ "memchr",
+]
+
[[package]]
name = "comfy-table"
version = "7.1.0"
@@ -2994,6 +3109,7 @@ dependencies = [
"cumulus-pallet-xcmp-queue",
"cumulus-primitives-aura",
"cumulus-primitives-core",
+ "cumulus-primitives-storage-weight-reclaim",
"cumulus-primitives-utility",
"frame-benchmarking",
"frame-executive",
@@ -3088,6 +3204,7 @@ dependencies = [
"cumulus-pallet-xcmp-queue",
"cumulus-primitives-aura",
"cumulus-primitives-core",
+ "cumulus-primitives-storage-weight-reclaim",
"cumulus-primitives-utility",
"frame-benchmarking",
"frame-executive",
@@ -3152,6 +3269,7 @@ dependencies = [
"cumulus-pallet-xcmp-queue",
"cumulus-primitives-aura",
"cumulus-primitives-core",
+ "cumulus-primitives-storage-weight-reclaim",
"cumulus-primitives-utility",
"frame-benchmarking",
"frame-executive",
@@ -3339,6 +3457,21 @@ dependencies = [
"wasmtime-types",
]
+[[package]]
+name = "crc"
+version = "3.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c2b432c56615136f8dba245fed7ec3d5518c500a31108661067e61e72fe7e6bc"
+dependencies = [
+ "crc-catalog",
+]
+
+[[package]]
+name = "crc-catalog"
+version = "2.4.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "19d374276b40fb8bbdee95aef7c7fa6b5316ec764510eb64b8dd0e2ed0d7e7f5"
+
[[package]]
name = "crc32fast"
version = "1.3.2"
@@ -3414,16 +3547,6 @@ dependencies = [
"itertools 0.10.5",
]
-[[package]]
-name = "crossbeam-channel"
-version = "0.5.8"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a33c2bf77f2df06183c3aa30d1e96c0695a313d4f9c453cc3762a6db39f99200"
-dependencies = [
- "cfg-if",
- "crossbeam-utils",
-]
-
[[package]]
name = "crossbeam-deque"
version = "0.8.3"
@@ -3761,7 +3884,7 @@ dependencies = [
"polkadot-overseer",
"polkadot-primitives",
"portpicker",
- "rand",
+ "rand 0.8.5",
"sc-cli",
"sc-client-api",
"sc-consensus",
@@ -3804,6 +3927,7 @@ dependencies = [
"sp-blockchain",
"sp-consensus",
"sp-core",
+ "sp-io",
"sp-runtime",
"sp-transaction-pool",
]
@@ -3856,6 +3980,7 @@ dependencies = [
"cumulus-primitives-proof-size-hostfunction",
"cumulus-test-client",
"cumulus-test-relay-sproof-builder",
+ "cumulus-test-runtime",
"environmental",
"frame-benchmarking",
"frame-support",
@@ -3870,9 +3995,10 @@ dependencies = [
"polkadot-parachain-primitives",
"polkadot-runtime-common",
"polkadot-runtime-parachains",
- "rand",
+ "rand 0.8.5",
"sc-client-api",
"scale-info",
+ "sp-consensus-slots",
"sp-core",
"sp-crypto-hashing",
"sp-externalities 0.25.0",
@@ -3895,8 +4021,8 @@ name = "cumulus-pallet-parachain-system-proc-macro"
version = "0.6.0"
dependencies = [
"proc-macro-crate 3.0.0",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -4049,7 +4175,7 @@ dependencies = [
"cumulus-primitives-core",
"cumulus-primitives-proof-size-hostfunction",
"cumulus-test-runtime",
- "docify 0.2.7",
+ "docify",
"frame-support",
"frame-system",
"log",
@@ -4192,7 +4318,7 @@ dependencies = [
"parity-scale-codec",
"pin-project",
"polkadot-overseer",
- "rand",
+ "rand 0.8.5",
"sc-client-api",
"sc-rpc-api",
"sc-service",
@@ -4235,15 +4361,19 @@ dependencies = [
"polkadot-primitives",
"sc-block-builder",
"sc-consensus",
+ "sc-consensus-aura",
"sc-executor",
"sc-executor-common",
"sc-service",
"sp-api",
+ "sp-application-crypto",
"sp-blockchain",
+ "sp-consensus-aura",
"sp-core",
"sp-inherents",
"sp-io",
"sp-keyring",
+ "sp-keystore",
"sp-runtime",
"sp-timestamp",
"substrate-test-client",
@@ -4266,16 +4396,22 @@ dependencies = [
name = "cumulus-test-runtime"
version = "0.1.0"
dependencies = [
+ "cumulus-pallet-aura-ext",
"cumulus-pallet-parachain-system",
+ "cumulus-primitives-aura",
"cumulus-primitives-core",
"cumulus-primitives-storage-weight-reclaim",
"frame-executive",
"frame-support",
"frame-system",
"frame-system-rpc-runtime-api",
+ "pallet-aura",
+ "pallet-authorship",
"pallet-balances",
+ "pallet-collator-selection",
"pallet-glutton",
"pallet-message-queue",
+ "pallet-session",
"pallet-sudo",
"pallet-timestamp",
"pallet-transaction-payment",
@@ -4283,6 +4419,7 @@ dependencies = [
"scale-info",
"sp-api",
"sp-block-builder",
+ "sp-consensus-aura",
"sp-core",
"sp-genesis-builder",
"sp-inherents",
@@ -4304,7 +4441,10 @@ dependencies = [
"clap 4.5.3",
"criterion 0.5.1",
"cumulus-client-cli",
+ "cumulus-client-collator",
+ "cumulus-client-consensus-aura",
"cumulus-client-consensus-common",
+ "cumulus-client-consensus-proposer",
"cumulus-client-consensus-relay-chain",
"cumulus-client-parachain-inherent",
"cumulus-client-pov-recovery",
@@ -4322,7 +4462,6 @@ dependencies = [
"frame-system-rpc-runtime-api",
"futures",
"jsonrpsee",
- "pallet-im-online",
"pallet-timestamp",
"pallet-transaction-payment",
"parachains-common",
@@ -4334,7 +4473,7 @@ dependencies = [
"polkadot-service",
"polkadot-test-service",
"portpicker",
- "rand",
+ "rand 0.8.5",
"rococo-parachain-runtime",
"sc-basic-authorship",
"sc-block-builder",
@@ -4342,6 +4481,7 @@ dependencies = [
"sc-cli",
"sc-client-api",
"sc-consensus",
+ "sc-consensus-aura",
"sc-executor",
"sc-executor-common",
"sc-executor-wasmtime",
@@ -4358,6 +4498,7 @@ dependencies = [
"sp-authority-discovery",
"sp-blockchain",
"sp-consensus",
+ "sp-consensus-aura",
"sp-consensus-grandpa",
"sp-core",
"sp-io",
@@ -4374,6 +4515,37 @@ dependencies = [
"url",
]
+[[package]]
+name = "curl"
+version = "0.4.46"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1e2161dd6eba090ff1594084e95fd67aeccf04382ffea77999ea94ed42ec67b6"
+dependencies = [
+ "curl-sys",
+ "libc",
+ "openssl-probe",
+ "openssl-sys",
+ "schannel",
+ "socket2 0.5.6",
+ "windows-sys 0.52.0",
+]
+
+[[package]]
+name = "curl-sys"
+version = "0.4.72+curl-8.6.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "29cbdc8314c447d11e8fd156dcdd031d9e02a7a976163e396b548c03153bc9ea"
+dependencies = [
+ "cc",
+ "libc",
+ "libnghttp2-sys",
+ "libz-sys",
+ "openssl-sys",
+ "pkg-config",
+ "vcpkg",
+ "windows-sys 0.52.0",
+]
+
[[package]]
name = "curve25519-dalek"
version = "3.2.0"
@@ -4410,8 +4582,8 @@ version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "83fdaf97f4804dcebfa5862639bc9ce4121e82140bec2a987ac5140294865b5b"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -4449,8 +4621,8 @@ dependencies = [
"cc",
"codespan-reporting",
"once_cell",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"scratch",
"syn 2.0.53",
]
@@ -4467,8 +4639,8 @@ version = "1.0.106"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "50c49547d73ba8dcfd4ad7325d64c6d5391ff4224d498fc39a6f3f49825a530d"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -4556,8 +4728,8 @@ version = "2.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -4567,11 +4739,22 @@ version = "0.1.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e79116f119dd1dba1abf1f3405f03b9b0e79a27a3883864bfebded8a3dc768cd"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
+[[package]]
+name = "derive-syn-parse"
+version = "0.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d65d7ce8132b7c0e54497a4d9a55a1c2a0912a0d786cf894472ba818fba45762"
+dependencies = [
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
+ "syn 2.0.53",
+]
+
[[package]]
name = "derive_more"
version = "0.99.17"
@@ -4579,8 +4762,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321"
dependencies = [
"convert_case",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"rustc_version 0.4.0",
"syn 1.0.109",
]
@@ -4675,8 +4858,8 @@ version = "0.2.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -4719,50 +4902,24 @@ checksum = "fea41bba32d969b513997752735605054bc0dfa92b4c56bf1189f2e174be7a10"
[[package]]
name = "docify"
-version = "0.1.16"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "af1b04e6ef3d21119d3eb7b032bca17f99fe041e9c072f30f32cc0e1a2b1f3c4"
-dependencies = [
- "docify_macros 0.1.16",
-]
-
-[[package]]
-name = "docify"
-version = "0.2.7"
+version = "0.2.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7cc4fd38aaa9fb98ac70794c82a00360d1e165a87fbf96a8a91f9dfc602aaee2"
+checksum = "43a2f138ad521dc4a2ced1a4576148a6a610b4c5923933b062a263130a6802ce"
dependencies = [
- "docify_macros 0.2.7",
-]
-
-[[package]]
-name = "docify_macros"
-version = "0.1.16"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "8b5610df7f2acf89a1bb5d1a66ae56b1c7fcdcfe3948856fb3ace3f644d70eb7"
-dependencies = [
- "common-path",
- "derive-syn-parse",
- "lazy_static",
- "proc-macro2",
- "quote",
- "regex",
- "syn 2.0.53",
- "termcolor",
- "walkdir",
+ "docify_macros",
]
[[package]]
name = "docify_macros"
-version = "0.2.7"
+version = "0.2.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "63fa215f3a0d40fb2a221b3aa90d8e1fbb8379785a990cb60d62ac71ebdc6460"
+checksum = "1a081e51fb188742f5a7a1164ad752121abcb22874b21e2c3b0dd040c515fdad"
dependencies = [
"common-path",
- "derive-syn-parse",
+ "derive-syn-parse 0.2.0",
"once_cell",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"regex",
"syn 2.0.53",
"termcolor",
@@ -4810,8 +4967,8 @@ version = "0.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "558e40ea573c374cf53507fd240b7ee2f5477df7cfebdb97323ec61c719399c5"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -4832,10 +4989,19 @@ dependencies = [
"elliptic-curve",
"rfc6979",
"serdect",
- "signature",
+ "signature 2.1.0",
"spki",
]
+[[package]]
+name = "ed25519"
+version = "1.5.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7"
+dependencies = [
+ "signature 1.6.4",
+]
+
[[package]]
name = "ed25519"
version = "2.2.2"
@@ -4843,7 +5009,21 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "60f6d271ca33075c88028be6f04d502853d63a5ece419d269c15315d4fc1cf1d"
dependencies = [
"pkcs8",
- "signature",
+ "signature 2.1.0",
+]
+
+[[package]]
+name = "ed25519-dalek"
+version = "1.0.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d"
+dependencies = [
+ "curve25519-dalek 3.2.0",
+ "ed25519 1.5.3",
+ "rand 0.7.3",
+ "serde",
+ "sha2 0.9.9",
+ "zeroize",
]
[[package]]
@@ -4853,7 +5033,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1f628eaec48bfd21b865dc2950cfa014450c01d2fa2b69a86c2fd5844ec523c0"
dependencies = [
"curve25519-dalek 4.1.2",
- "ed25519",
+ "ed25519 2.2.2",
"rand_core 0.6.4",
"serde",
"sha2 0.10.7",
@@ -4882,7 +5062,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7d9ce6874da5d4415896cd45ffbc4d1cfc0c4f9c079427bd870742c30f2f65a9"
dependencies = [
"curve25519-dalek 4.1.2",
- "ed25519",
+ "ed25519 2.2.2",
"hashbrown 0.14.3",
"hex",
"rand_core 0.6.4",
@@ -4970,11 +5150,23 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c9720bba047d567ffc8a3cba48bf19126600e249ab7f128e9233e6376976a116"
dependencies = [
"heck 0.4.1",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
+[[package]]
+name = "enum-as-inner"
+version = "0.6.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "5ffccbb6966c05b32ef8fbac435df276c4ae4d3dc55a8cd0eb9745e6c12f546a"
+dependencies = [
+ "heck 0.4.1",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
+ "syn 2.0.53",
+]
+
[[package]]
name = "enumflags2"
version = "0.7.7"
@@ -4990,8 +5182,8 @@ version = "0.7.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5e9a1f9f7d83e59740248a6e14ecf93929ade55027844dfcea78beafccc15745"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -5001,16 +5193,16 @@ version = "0.1.12"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c2ad8cef1d801a4686bfd8919f0b30eac4c8e48968c437a6405ded4fb5272d2b"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
[[package]]
-name = "env_logger"
-version = "0.8.4"
+name = "env_filter"
+version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a19187fea3ac7e84da7dacf48de0c45d63c6a76f9490dae389aead16c243fce3"
+checksum = "a009aa4810eb158359dda09d0c87378e4bbb89b5a801f016885a4707ba24f7ea"
dependencies = [
"log",
"regex",
@@ -5018,15 +5210,12 @@ dependencies = [
[[package]]
name = "env_logger"
-version = "0.9.3"
+version = "0.8.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a12e6657c4c97ebab115a42dcee77225f7f482cdd841cf7088c657a42e9e00e7"
+checksum = "a19187fea3ac7e84da7dacf48de0c45d63c6a76f9490dae389aead16c243fce3"
dependencies = [
- "atty",
- "humantime",
"log",
"regex",
- "termcolor",
]
[[package]]
@@ -5043,17 +5232,45 @@ dependencies = [
]
[[package]]
-name = "environmental"
-version = "1.1.4"
+name = "env_logger"
+version = "0.11.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e48c92028aaa870e83d51c64e5d4e0b6981b360c522198c23959f219a4e1b15b"
-
-[[package]]
+checksum = "38b35839ba51819680ba087cd351788c9a3c476841207e0b8cee0b04722343b9"
+dependencies = [
+ "anstream",
+ "anstyle",
+ "env_filter",
+ "humantime",
+ "log",
+]
+
+[[package]]
+name = "environmental"
+version = "1.1.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e48c92028aaa870e83d51c64e5d4e0b6981b360c522198c23959f219a4e1b15b"
+
+[[package]]
name = "equivalent"
version = "1.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5"
+[[package]]
+name = "equivocation-detector"
+version = "0.1.0"
+dependencies = [
+ "async-std",
+ "async-trait",
+ "bp-header-chain",
+ "finality-relay",
+ "frame-support",
+ "futures",
+ "log",
+ "num-traits",
+ "relay-utils",
+]
+
[[package]]
name = "erased-serde"
version = "0.4.4"
@@ -5179,8 +5396,8 @@ checksum = "a718c0675c555c5f976fff4ea9e2c150fa06cefa201cadef87cfbf9324075881"
dependencies = [
"blake3",
"fs-err",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
]
[[package]]
@@ -5191,8 +5408,8 @@ checksum = "5f86a749cf851891866c10515ef6c299b5c69661465e9c3bbe7e07a2b77fb0f7"
dependencies = [
"blake2 0.10.6",
"fs-err",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -5263,8 +5480,8 @@ dependencies = [
"expander 0.0.4",
"indexmap 1.9.3",
"proc-macro-crate 1.3.1",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
"thiserror",
]
@@ -5359,10 +5576,25 @@ dependencies = [
"num-traits",
"parity-scale-codec",
"parking_lot 0.12.1",
- "rand",
+ "rand 0.8.5",
"scale-info",
]
+[[package]]
+name = "finality-relay"
+version = "0.1.0"
+dependencies = [
+ "async-std",
+ "async-trait",
+ "backoff",
+ "bp-header-chain",
+ "futures",
+ "log",
+ "num-traits",
+ "parking_lot 0.12.1",
+ "relay-utils",
+]
+
[[package]]
name = "findshlibs"
version = "0.10.2"
@@ -5382,7 +5614,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "835c052cb0c08c1acf6ffd71c022172e18723949c8282f2b9f27efbc51e64534"
dependencies = [
"byteorder",
- "rand",
+ "rand 0.8.5",
"rustc-hex",
"static_assertions",
]
@@ -5419,6 +5651,21 @@ version = "1.0.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1"
+[[package]]
+name = "foreign-types"
+version = "0.3.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1"
+dependencies = [
+ "foreign-types-shared",
+]
+
+[[package]]
+name = "foreign-types-shared"
+version = "0.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b"
+
[[package]]
name = "fork-tree"
version = "12.0.0"
@@ -5451,35 +5698,6 @@ version = "2.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6c2141d6d6c8512188a7891b4b01590a45f6dac67afb4f255c4124dbb86d4eaa"
-[[package]]
-name = "frame"
-version = "0.0.1-dev"
-dependencies = [
- "docify 0.2.7",
- "frame-executive",
- "frame-support",
- "frame-system",
- "frame-system-rpc-runtime-api",
- "log",
- "pallet-examples",
- "parity-scale-codec",
- "scale-info",
- "sp-api",
- "sp-arithmetic",
- "sp-block-builder",
- "sp-consensus-aura",
- "sp-consensus-grandpa",
- "sp-core",
- "sp-inherents",
- "sp-io",
- "sp-offchain",
- "sp-runtime",
- "sp-session",
- "sp-std 14.0.0",
- "sp-transaction-pool",
- "sp-version",
-]
-
[[package]]
name = "frame-benchmarking"
version = "28.0.0"
@@ -5526,9 +5744,10 @@ dependencies = [
"linked-hash-map",
"log",
"parity-scale-codec",
- "rand",
+ "rand 0.8.5",
"rand_pcg",
"sc-block-builder",
+ "sc-chain-spec",
"sc-cli",
"sc-client-api",
"sc-client-db",
@@ -5542,6 +5761,7 @@ dependencies = [
"sp-core",
"sp-database",
"sp-externalities 0.25.0",
+ "sp-genesis-builder",
"sp-inherents",
"sp-io",
"sp-keystore",
@@ -5576,8 +5796,8 @@ dependencies = [
"frame-support",
"parity-scale-codec",
"proc-macro-crate 3.0.0",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"scale-info",
"sp-arithmetic",
"syn 2.0.53",
@@ -5592,7 +5812,7 @@ dependencies = [
"frame-support",
"frame-system",
"parity-scale-codec",
- "rand",
+ "rand 0.8.5",
"scale-info",
"sp-arithmetic",
"sp-core",
@@ -5612,7 +5832,7 @@ dependencies = [
"frame-support",
"honggfuzz",
"parity-scale-codec",
- "rand",
+ "rand 0.8.5",
"scale-info",
"sp-arithmetic",
"sp-npos-elections",
@@ -5654,6 +5874,20 @@ dependencies = [
"serde",
]
+[[package]]
+name = "frame-omni-bencher"
+version = "0.1.0"
+dependencies = [
+ "clap 4.5.3",
+ "cumulus-primitives-proof-size-hostfunction",
+ "env_logger 0.11.3",
+ "frame-benchmarking-cli",
+ "log",
+ "sc-cli",
+ "sp-runtime",
+ "sp-statement-store",
+]
+
[[package]]
name = "frame-remote-externalities"
version = "0.35.0"
@@ -5684,7 +5918,7 @@ dependencies = [
"array-bytes 6.1.0",
"assert_matches",
"bitflags 1.3.2",
- "docify 0.2.7",
+ "docify",
"environmental",
"frame-metadata",
"frame-support-procedural",
@@ -5727,14 +5961,14 @@ version = "23.0.0"
dependencies = [
"Inflector",
"cfg-expr",
- "derive-syn-parse",
+ "derive-syn-parse 0.2.0",
"expander 2.0.0",
"frame-support-procedural-tools",
"itertools 0.10.5",
"macro_magic",
"proc-macro-warning",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"regex",
"sp-crypto-hashing",
"syn 2.0.53",
@@ -5746,8 +5980,8 @@ version = "10.0.0"
dependencies = [
"frame-support-procedural-tools-derive",
"proc-macro-crate 3.0.0",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -5755,8 +5989,8 @@ dependencies = [
name = "frame-support-procedural-tools-derive"
version = "11.0.0"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -5817,8 +6051,8 @@ dependencies = [
name = "frame-support-test-stg-frame-crate"
version = "0.1.0"
dependencies = [
- "frame",
"parity-scale-codec",
+ "polkadot-sdk-frame",
"scale-info",
]
@@ -5828,7 +6062,7 @@ version = "28.0.0"
dependencies = [
"cfg-if",
"criterion 0.4.0",
- "docify 0.2.7",
+ "docify",
"frame-support",
"log",
"parity-scale-codec",
@@ -5988,8 +6222,8 @@ version = "0.3.30"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -6120,7 +6354,7 @@ version = "0.0.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6ea1015b5a70616b688dc230cfe50c8af89d972cb132d5a622814d29773b10b9"
dependencies = [
- "rand",
+ "rand 0.8.5",
"rand_core 0.6.4",
]
@@ -6171,6 +6405,18 @@ version = "0.3.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b"
+[[package]]
+name = "gloo-timers"
+version = "0.2.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9b995a66bb87bebce9a0f4a95aed01daca4872c050bfcb21653361c03bc35e5c"
+dependencies = [
+ "futures-channel",
+ "futures-core",
+ "js-sys",
+ "wasm-bindgen",
+]
+
[[package]]
name = "glutton-westend-runtime"
version = "3.0.0"
@@ -6231,7 +6477,7 @@ dependencies = [
"nonzero_ext",
"parking_lot 0.12.1",
"quanta",
- "rand",
+ "rand 0.8.5",
"smallvec",
]
@@ -6248,9 +6494,9 @@ dependencies = [
[[package]]
name = "h2"
-version = "0.3.24"
+version = "0.3.26"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "bb2c4422095b67ee78da96fbb51a4cc413b3b25883c7717ff7ca1ab31022c9c9"
+checksum = "81fe527a889e1532da5c525686d96d4c2e74cdd345badf8dfef9f6b39dd5f5e8"
dependencies = [
"bytes",
"fnv",
@@ -6338,6 +6584,15 @@ dependencies = [
"hashbrown 0.14.3",
]
+[[package]]
+name = "heck"
+version = "0.3.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c"
+dependencies = [
+ "unicode-segmentation",
+]
+
[[package]]
name = "heck"
version = "0.4.1"
@@ -6648,8 +6903,8 @@ version = "0.2.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "11d7a9f6330b71fea57921c9b61c47ee6e84f72d394754eff6163ae67e7395eb"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -6668,8 +6923,8 @@ version = "0.7.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b139284b5cf57ecfa712bcc66950bb635b31aff41c188e8a4cfc758eca374a3f"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
]
[[package]]
@@ -6774,7 +7029,7 @@ version = "0.3.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b58db92f96b720de98181bbbe63c831e87005ab460c1bf306eb2622b4707997f"
dependencies = [
- "socket2 0.5.3",
+ "socket2 0.5.6",
"widestring",
"windows-sys 0.48.0",
"winreg",
@@ -6806,6 +7061,33 @@ dependencies = [
"winapi",
]
+[[package]]
+name = "isahc"
+version = "1.7.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "334e04b4d781f436dc315cb1e7515bd96826426345d498149e4bde36b67f8ee9"
+dependencies = [
+ "async-channel",
+ "castaway",
+ "crossbeam-utils",
+ "curl",
+ "curl-sys",
+ "encoding_rs",
+ "event-listener 2.5.3",
+ "futures-lite",
+ "http",
+ "log",
+ "mime",
+ "once_cell",
+ "polling",
+ "slab",
+ "sluice",
+ "tracing",
+ "tracing-futures",
+ "url",
+ "waker-fn",
+]
+
[[package]]
name = "itertools"
version = "0.10.5"
@@ -6854,11 +7136,22 @@ version = "0.12.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "078e285eafdfb6c4b434e0d31e8cfcb5115b651496faca5749b88fafd4f23bfd"
+[[package]]
+name = "jsonpath_lib"
+version = "0.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "eaa63191d68230cccb81c5aa23abd53ed64d83337cacbb25a7b8c7979523774f"
+dependencies = [
+ "log",
+ "serde",
+ "serde_json",
+]
+
[[package]]
name = "jsonrpsee"
-version = "0.22.0"
+version = "0.22.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4a95f7cc23d5fab0cdeeaf6bad8c8f5e7a3aa7f0d211957ea78232b327ab27b0"
+checksum = "87f3ae45a64cfc0882934f963be9431b2a165d667f53140358181f262aca0702"
dependencies = [
"jsonrpsee-core",
"jsonrpsee-http-client",
@@ -6872,9 +7165,9 @@ dependencies = [
[[package]]
name = "jsonrpsee-client-transport"
-version = "0.22.0"
+version = "0.22.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6b1736cfa3845fd9f8f43751f2b8e0e83f7b6081e754502f7d63b6587692cc83"
+checksum = "455fc882e56f58228df2aee36b88a1340eafd707c76af2fa68cf94b37d461131"
dependencies = [
"futures-util",
"http",
@@ -6893,9 +7186,9 @@ dependencies = [
[[package]]
name = "jsonrpsee-core"
-version = "0.22.0"
+version = "0.22.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "82030d038658974732103e623ba2e0abec03bbbe175b39c0a2fafbada60c5868"
+checksum = "b75568f4f9696e3a47426e1985b548e1a9fcb13372a5e320372acaf04aca30d1"
dependencies = [
"anyhow",
"async-lock 3.3.0",
@@ -6907,7 +7200,7 @@ dependencies = [
"jsonrpsee-types",
"parking_lot 0.12.1",
"pin-project",
- "rand",
+ "rand 0.8.5",
"rustc-hash",
"serde",
"serde_json",
@@ -6919,9 +7212,9 @@ dependencies = [
[[package]]
name = "jsonrpsee-http-client"
-version = "0.22.0"
+version = "0.22.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "36a06ef0de060005fddf772d54597bb6a8b0413da47dcffd304b0306147b9678"
+checksum = "9e7a95e346f55df84fb167b7e06470e196e7d5b9488a21d69c5d9732043ba7ba"
dependencies = [
"async-trait",
"hyper",
@@ -6939,22 +7232,22 @@ dependencies = [
[[package]]
name = "jsonrpsee-proc-macros"
-version = "0.22.0"
+version = "0.22.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "69fc56131589f82e57805f7338b87023db4aafef813555708b159787e34ad6bc"
+checksum = "30ca066e73dd70294aebc5c2675d8ffae43be944af027c857ce0d4c51785f014"
dependencies = [
"heck 0.4.1",
"proc-macro-crate 3.0.0",
- "proc-macro2",
- "quote",
- "syn 1.0.109",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
+ "syn 2.0.53",
]
[[package]]
name = "jsonrpsee-server"
-version = "0.22.0"
+version = "0.22.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d85be77fe5b2a94589e3164fb780017f7aff7d646b49278c0d0346af16975c8e"
+checksum = "0e29c1bd1f9bba83c864977c73404e505f74f730fa0db89dd490ec174e36d7f0"
dependencies = [
"futures-util",
"http",
@@ -6976,9 +7269,9 @@ dependencies = [
[[package]]
name = "jsonrpsee-types"
-version = "0.22.0"
+version = "0.22.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9a48fdc1202eafc51c63e00406575e59493284ace8b8b61aa16f3a6db5d64f1a"
+checksum = "3467fd35feeee179f71ab294516bdf3a81139e7aeebdd860e46897c12e1a3368"
dependencies = [
"anyhow",
"beef",
@@ -6989,9 +7282,9 @@ dependencies = [
[[package]]
name = "jsonrpsee-ws-client"
-version = "0.22.0"
+version = "0.22.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c5ce25d70a8e4d3cc574bbc3cad0137c326ad64b194793d5e7bbdd3fa4504181"
+checksum = "68ca71e74983f624c0cb67828e480a981586074da8ad3a2f214c6a3f884edab9"
dependencies = [
"http",
"jsonrpsee-client-transport",
@@ -7080,6 +7373,7 @@ dependencies = [
"pallet-election-provider-multi-phase",
"pallet-election-provider-support-benchmarking",
"pallet-elections-phragmen",
+ "pallet-example-mbm",
"pallet-example-tasks",
"pallet-fast-unstake",
"pallet-glutton",
@@ -7164,6 +7458,15 @@ dependencies = [
"substrate-wasm-builder",
]
+[[package]]
+name = "kv-log-macro"
+version = "1.0.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0de8b303297635ad57c9f5059fd9cee7a47f8e8daa09df0fcd07dd39fb22977f"
+dependencies = [
+ "log",
+]
+
[[package]]
name = "kvdb"
version = "0.13.0"
@@ -7288,6 +7591,16 @@ version = "0.2.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f7012b1bbb0719e1097c47611d3898568c546d597c2e74d66f6087edd5233ff4"
+[[package]]
+name = "libnghttp2-sys"
+version = "0.1.9+1.58.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b57e858af2798e167e709b9d969325b6d8e9d50232fcbc494d7d54f976854a64"
+dependencies = [
+ "cc",
+ "libc",
+]
+
[[package]]
name = "libp2p"
version = "0.51.4"
@@ -7365,7 +7678,7 @@ dependencies = [
"parking_lot 0.12.1",
"pin-project",
"quick-protobuf",
- "rand",
+ "rand 0.8.5",
"rw-stream-sink",
"smallvec",
"thiserror",
@@ -7384,7 +7697,7 @@ dependencies = [
"log",
"parking_lot 0.12.1",
"smallvec",
- "trust-dns-resolver",
+ "trust-dns-resolver 0.22.0",
]
[[package]]
@@ -7416,12 +7729,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "276bb57e7af15d8f100d3c11cbdd32c6752b7eef4ba7a18ecf464972c07abcce"
dependencies = [
"bs58 0.4.0",
- "ed25519-dalek",
+ "ed25519-dalek 2.1.0",
"log",
"multiaddr",
"multihash 0.17.0",
"quick-protobuf",
- "rand",
+ "rand 0.8.5",
"sha2 0.10.7",
"thiserror",
"zeroize",
@@ -7446,7 +7759,7 @@ dependencies = [
"libp2p-swarm",
"log",
"quick-protobuf",
- "rand",
+ "rand 0.8.5",
"sha2 0.10.7",
"smallvec",
"thiserror",
@@ -7468,11 +7781,11 @@ dependencies = [
"libp2p-identity",
"libp2p-swarm",
"log",
- "rand",
+ "rand 0.8.5",
"smallvec",
"socket2 0.4.9",
"tokio",
- "trust-dns-proto",
+ "trust-dns-proto 0.22.0",
"void",
]
@@ -7504,7 +7817,7 @@ dependencies = [
"log",
"once_cell",
"quick-protobuf",
- "rand",
+ "rand 0.8.5",
"sha2 0.10.7",
"snow",
"static_assertions",
@@ -7526,7 +7839,7 @@ dependencies = [
"libp2p-core",
"libp2p-swarm",
"log",
- "rand",
+ "rand 0.8.5",
"void",
]
@@ -7546,7 +7859,7 @@ dependencies = [
"log",
"parking_lot 0.12.1",
"quinn-proto",
- "rand",
+ "rand 0.8.5",
"rustls 0.20.8",
"thiserror",
"tokio",
@@ -7564,7 +7877,7 @@ dependencies = [
"libp2p-core",
"libp2p-identity",
"libp2p-swarm",
- "rand",
+ "rand 0.8.5",
"smallvec",
]
@@ -7583,7 +7896,7 @@ dependencies = [
"libp2p-identity",
"libp2p-swarm-derive",
"log",
- "rand",
+ "rand 0.8.5",
"smallvec",
"tokio",
"void",
@@ -7596,7 +7909,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0fba456131824ab6acd4c7bf61e9c0f0a3014b5fc9868ccb8e10d344594cdc4f"
dependencies = [
"heck 0.4.1",
- "quote",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -7631,7 +7944,7 @@ dependencies = [
"rustls 0.20.8",
"thiserror",
"webpki",
- "x509-parser",
+ "x509-parser 0.14.0",
"yasna",
]
@@ -7709,7 +8022,7 @@ dependencies = [
"libsecp256k1-core",
"libsecp256k1-gen-ecmult",
"libsecp256k1-gen-genmult",
- "rand",
+ "rand 0.8.5",
"serde",
"sha2 0.9.9",
"typenum",
@@ -7751,6 +8064,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d97137b25e321a73eef1418d1d5d2eda4d77e12813f8e6dead84bc52c5870a7b"
dependencies = [
"cc",
+ "libc",
"pkg-config",
"vcpkg",
]
@@ -7836,6 +8150,60 @@ dependencies = [
"paste",
]
+[[package]]
+name = "litep2p"
+version = "0.3.0"
+source = "git+https://github.com/paritytech/litep2p?branch=master#b142c9eb611fb2fe78d2830266a3675b37299ceb"
+dependencies = [
+ "async-trait",
+ "bs58 0.4.0",
+ "bytes",
+ "cid 0.10.1",
+ "ed25519-dalek 1.0.1",
+ "futures",
+ "futures-timer",
+ "hex-literal",
+ "indexmap 2.2.3",
+ "libc",
+ "mockall",
+ "multiaddr",
+ "multihash 0.17.0",
+ "network-interface",
+ "nohash-hasher",
+ "parking_lot 0.12.1",
+ "pin-project",
+ "prost 0.11.9",
+ "prost-build",
+ "quinn",
+ "rand 0.8.5",
+ "rcgen",
+ "ring 0.16.20",
+ "rustls 0.20.8",
+ "serde",
+ "sha2 0.10.7",
+ "simple-dns",
+ "smallvec",
+ "snow",
+ "socket2 0.5.6",
+ "static_assertions",
+ "str0m",
+ "thiserror",
+ "tokio",
+ "tokio-stream",
+ "tokio-tungstenite 0.20.1",
+ "tokio-util",
+ "tracing",
+ "trust-dns-resolver 0.23.2",
+ "uint",
+ "unsigned-varint",
+ "url",
+ "webpki",
+ "x25519-dalek 2.0.0",
+ "x509-parser 0.15.1",
+ "yasna",
+ "zeroize",
+]
+
[[package]]
name = "lock_api"
version = "0.4.10"
@@ -7935,7 +8303,7 @@ checksum = "e03844fc635e92f3a0067e25fa4bf3e3dbf3f2927bf3aa01bb7bc8f1c428949d"
dependencies = [
"macro_magic_core",
"macro_magic_macros",
- "quote",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -7946,10 +8314,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "468155613a44cfd825f1fb0ffa532b018253920d404e6fca1e8d43155198a46d"
dependencies = [
"const-random",
- "derive-syn-parse",
+ "derive-syn-parse 0.1.5",
"macro_magic_core_macros",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -7959,8 +8327,8 @@ version = "0.5.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9ea73aa640dc01d62a590d48c0c3521ed739d53b27f919b25c3551e233481654"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -7971,7 +8339,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ef9d79ae96aaba821963320eb2b6e34d17df1e5a83d8a1985c29cc5be59577b3"
dependencies = [
"macro_magic_core",
- "quote",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -8102,6 +8470,24 @@ dependencies = [
"zeroize",
]
+[[package]]
+name = "messages-relay"
+version = "0.1.0"
+dependencies = [
+ "async-std",
+ "async-trait",
+ "bp-messages",
+ "env_logger 0.11.3",
+ "finality-relay",
+ "futures",
+ "hex",
+ "log",
+ "num-traits",
+ "parking_lot 0.12.1",
+ "relay-utils",
+ "sp-arithmetic",
+]
+
[[package]]
name = "mick-jaeger"
version = "0.1.8"
@@ -8109,7 +8495,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "69672161530e8aeca1d1400fbf3f1a1747ff60ea604265a4e906c2442df20532"
dependencies = [
"futures",
- "rand",
+ "rand 0.8.5",
"thrift",
]
@@ -8130,11 +8516,11 @@ name = "minimal-template-node"
version = "0.0.0"
dependencies = [
"clap 4.5.3",
- "frame",
"futures",
"futures-timer",
"jsonrpsee",
"minimal-template-runtime",
+ "polkadot-sdk-frame",
"sc-basic-authorship",
"sc-cli",
"sc-client-api",
@@ -8164,7 +8550,6 @@ dependencies = [
name = "minimal-template-runtime"
version = "0.0.0"
dependencies = [
- "frame",
"pallet-balances",
"pallet-minimal-template",
"pallet-sudo",
@@ -8172,8 +8557,10 @@ dependencies = [
"pallet-transaction-payment",
"pallet-transaction-payment-rpc-runtime-api",
"parity-scale-codec",
+ "polkadot-sdk-frame",
"scale-info",
"sp-genesis-builder",
+ "sp-runtime",
"substrate-wasm-builder",
]
@@ -8214,7 +8601,7 @@ dependencies = [
"lioness",
"log",
"parking_lot 0.12.1",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"rand_distr",
"subtle 2.5.0",
@@ -8282,8 +8669,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "22ce75669015c4f47b289fd4d4f56e894e4c96003ffdf3ac51313126f94c6cbb"
dependencies = [
"cfg-if",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -8340,10 +8727,14 @@ version = "0.18.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "cfd8a792c1694c6da4f68db0a9d707c72bd260994da179e6030a5dcee00bb815"
dependencies = [
+ "blake2b_simd",
+ "blake2s_simd",
+ "blake3",
"core2",
"digest 0.10.7",
"multihash-derive 0.8.0",
"sha2 0.10.7",
+ "sha3",
"unsigned-varint",
]
@@ -8385,8 +8776,8 @@ checksum = "fc076939022111618a5026d3be019fd8b366e76314538ff9a1b59ffbcbf98bcd"
dependencies = [
"proc-macro-crate 1.3.1",
"proc-macro-error",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
"synstructure",
]
@@ -8410,8 +8801,8 @@ checksum = "d38685e08adb338659871ecfc6ee47ba9b22dcc8abcf6975d379cc49145c3040"
dependencies = [
"proc-macro-crate 1.3.1",
"proc-macro-error",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
"synstructure",
]
@@ -8458,8 +8849,8 @@ version = "0.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "91761aed67d03ad966ef783ae962ef9bbaca728d2dd7ceb7939ec110fffad998"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -8470,7 +8861,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7bddcd3bf5144b6392de80e04c347cd7fab2508f6df16a85fc496ecd5cec39bc"
dependencies = [
"clap 3.2.25",
- "rand",
+ "rand 0.8.5",
]
[[package]]
@@ -8545,6 +8936,18 @@ dependencies = [
"tokio",
]
+[[package]]
+name = "network-interface"
+version = "1.1.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ae72fd9dbd7f55dda80c00d66acc3b2130436fcba9ea89118fc508eaae48dfb0"
+dependencies = [
+ "cc",
+ "libc",
+ "thiserror",
+ "winapi",
+]
+
[[package]]
name = "nix"
version = "0.24.3"
@@ -8611,7 +9014,7 @@ dependencies = [
"node-primitives",
"node-testing",
"parity-db",
- "rand",
+ "rand 0.8.5",
"sc-basic-authorship",
"sc-client-api",
"sc-transaction-pool",
@@ -8766,6 +9169,15 @@ version = "0.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "61807f77802ff30975e01f4f071c8ba10c022052f98b3294119f3e615d13e5be"
+[[package]]
+name = "ntapi"
+version = "0.4.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e8a3895c6391c39d7fe7ebc444a87eb2991b2a0bc718fdabd071eec617fc68e4"
+dependencies = [
+ "winapi",
+]
+
[[package]]
name = "nu-ansi-term"
version = "0.46.0"
@@ -8873,6 +9285,15 @@ dependencies = [
"libc",
]
+[[package]]
+name = "num_threads"
+version = "0.1.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "5c7398b9c8b70908f6371f47ed36737907c87c52af34c268fed0bf0ceb92ead9"
+dependencies = [
+ "libc",
+]
+
[[package]]
name = "number_prefix"
version = "0.4.0"
@@ -8934,14 +9355,62 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5"
[[package]]
-name = "openssl-probe"
-version = "0.1.5"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf"
-
-[[package]]
-name = "option-ext"
-version = "0.2.0"
+name = "openssl"
+version = "0.10.64"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f"
+dependencies = [
+ "bitflags 2.4.0",
+ "cfg-if",
+ "foreign-types",
+ "libc",
+ "once_cell",
+ "openssl-macros",
+ "openssl-sys",
+]
+
+[[package]]
+name = "openssl-macros"
+version = "0.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c"
+dependencies = [
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
+ "syn 2.0.53",
+]
+
+[[package]]
+name = "openssl-probe"
+version = "0.1.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf"
+
+[[package]]
+name = "openssl-src"
+version = "300.2.3+3.2.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "5cff92b6f71555b61bb9315f7c64da3ca43d87531622120fea0195fc761b4843"
+dependencies = [
+ "cc",
+]
+
+[[package]]
+name = "openssl-sys"
+version = "0.9.102"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2"
+dependencies = [
+ "cc",
+ "libc",
+ "openssl-src",
+ "pkg-config",
+ "vcpkg",
+]
+
+[[package]]
+name = "option-ext"
+version = "0.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d"
@@ -8973,8 +9442,8 @@ dependencies = [
"itertools 0.11.0",
"petgraph",
"proc-macro-crate 1.3.1",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -9240,7 +9709,7 @@ name = "pallet-bags-list"
version = "27.0.0"
dependencies = [
"aquamarine 0.5.0",
- "docify 0.2.7",
+ "docify",
"frame-benchmarking",
"frame-election-provider-support",
"frame-support",
@@ -9263,7 +9732,7 @@ dependencies = [
"frame-election-provider-support",
"honggfuzz",
"pallet-bags-list",
- "rand",
+ "rand 0.8.5",
]
[[package]]
@@ -9288,7 +9757,7 @@ dependencies = [
name = "pallet-balances"
version = "28.0.0"
dependencies = [
- "docify 0.2.7",
+ "docify",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -9374,6 +9843,30 @@ dependencies = [
"sp-std 14.0.0",
]
+[[package]]
+name = "pallet-bridge-beefy"
+version = "0.1.0"
+dependencies = [
+ "bp-beefy",
+ "bp-runtime",
+ "bp-test-utils",
+ "ckb-merkle-mountain-range",
+ "frame-support",
+ "frame-system",
+ "log",
+ "pallet-beefy-mmr",
+ "pallet-mmr",
+ "parity-scale-codec",
+ "rand 0.8.5",
+ "scale-info",
+ "serde",
+ "sp-consensus-beefy",
+ "sp-core",
+ "sp-io",
+ "sp-runtime",
+ "sp-std 14.0.0",
+]
+
[[package]]
name = "pallet-bridge-grandpa"
version = "0.7.0"
@@ -9470,6 +9963,7 @@ dependencies = [
"frame-system",
"parity-scale-codec",
"scale-info",
+ "sp-api",
"sp-arithmetic",
"sp-core",
"sp-io",
@@ -9510,7 +10004,7 @@ dependencies = [
"pallet-session",
"pallet-timestamp",
"parity-scale-codec",
- "rand",
+ "rand 0.8.5",
"scale-info",
"sp-consensus-aura",
"sp-core",
@@ -9559,7 +10053,7 @@ dependencies = [
"array-bytes 6.1.0",
"assert_matches",
"bitflags 1.3.2",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"environmental",
"frame-benchmarking",
"frame-support",
@@ -9577,8 +10071,9 @@ dependencies = [
"pallet-timestamp",
"pallet-utility",
"parity-scale-codec",
+ "paste",
"pretty_assertions",
- "rand",
+ "rand 0.8.5",
"rand_pcg",
"scale-info",
"serde",
@@ -9653,8 +10148,8 @@ dependencies = [
name = "pallet-contracts-proc-macro"
version = "18.0.0"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -9796,7 +10291,7 @@ dependencies = [
"pallet-election-provider-support-benchmarking",
"parity-scale-codec",
"parking_lot 0.12.1",
- "rand",
+ "rand 0.8.5",
"scale-info",
"sp-arithmetic",
"sp-core",
@@ -9805,7 +10300,7 @@ dependencies = [
"sp-runtime",
"sp-std 14.0.0",
"sp-tracing 16.0.0",
- "strum 0.24.1",
+ "strum 0.26.2",
]
[[package]]
@@ -9863,8 +10358,8 @@ dependencies = [
name = "pallet-example-frame-crate"
version = "0.0.1"
dependencies = [
- "frame",
"parity-scale-codec",
+ "polkadot-sdk-frame",
"scale-info",
]
@@ -9885,6 +10380,20 @@ dependencies = [
"sp-std 14.0.0",
]
+[[package]]
+name = "pallet-example-mbm"
+version = "0.1.0"
+dependencies = [
+ "frame-benchmarking",
+ "frame-support",
+ "frame-system",
+ "log",
+ "pallet-migrations",
+ "parity-scale-codec",
+ "scale-info",
+ "sp-io",
+]
+
[[package]]
name = "pallet-example-offchain-worker"
version = "28.0.0"
@@ -9906,7 +10415,7 @@ dependencies = [
name = "pallet-example-single-block-migrations"
version = "0.0.1"
dependencies = [
- "docify 0.2.7",
+ "docify",
"frame-executive",
"frame-support",
"frame-system",
@@ -9972,7 +10481,7 @@ dependencies = [
name = "pallet-fast-unstake"
version = "27.0.0"
dependencies = [
- "docify 0.2.7",
+ "docify",
"frame-benchmarking",
"frame-election-provider-support",
"frame-support",
@@ -10155,7 +10664,7 @@ dependencies = [
"frame-system",
"log",
"parity-scale-codec",
- "rand",
+ "rand 0.8.5",
"rand_distr",
"scale-info",
"serde",
@@ -10173,7 +10682,7 @@ dependencies = [
name = "pallet-migrations"
version = "1.0.0"
dependencies = [
- "docify 0.1.16",
+ "docify",
"frame-benchmarking",
"frame-executive",
"frame-support",
@@ -10197,8 +10706,8 @@ dependencies = [
name = "pallet-minimal-template"
version = "0.0.0"
dependencies = [
- "frame",
"parity-scale-codec",
+ "polkadot-sdk-frame",
"scale-info",
]
@@ -10226,7 +10735,7 @@ name = "pallet-mmr"
version = "27.0.0"
dependencies = [
"array-bytes 6.1.0",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -10388,7 +10897,7 @@ dependencies = [
"honggfuzz",
"log",
"pallet-nomination-pools",
- "rand",
+ "rand 0.8.5",
"sp-io",
"sp-runtime",
"sp-tracing 16.0.0",
@@ -10477,7 +10986,7 @@ dependencies = [
name = "pallet-paged-list"
version = "0.6.0"
dependencies = [
- "docify 0.2.7",
+ "docify",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -10517,9 +11026,9 @@ dependencies = [
[[package]]
name = "pallet-parameters"
-version = "0.0.1"
+version = "0.1.0"
dependencies = [
- "docify 0.2.7",
+ "docify",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -10680,7 +11189,7 @@ dependencies = [
name = "pallet-safe-mode"
version = "9.0.0"
dependencies = [
- "docify 0.2.7",
+ "docify",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -10737,7 +11246,7 @@ dependencies = [
name = "pallet-scheduler"
version = "29.0.0"
dependencies = [
- "docify 0.2.7",
+ "docify",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -10803,7 +11312,7 @@ dependencies = [
"pallet-staking-reward-curve",
"pallet-timestamp",
"parity-scale-codec",
- "rand",
+ "rand 0.8.5",
"scale-info",
"sp-core",
"sp-io",
@@ -10880,8 +11389,8 @@ name = "pallet-staking-reward-curve"
version = "11.0.0"
dependencies = [
"proc-macro-crate 3.0.0",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"sp-runtime",
"syn 2.0.53",
]
@@ -10950,7 +11459,7 @@ dependencies = [
name = "pallet-sudo"
version = "28.0.0"
dependencies = [
- "docify 0.2.7",
+ "docify",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -10980,7 +11489,7 @@ dependencies = [
name = "pallet-timestamp"
version = "27.0.0"
dependencies = [
- "docify 0.2.7",
+ "docify",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -11084,7 +11593,7 @@ dependencies = [
name = "pallet-treasury"
version = "27.0.0"
dependencies = [
- "docify 0.2.7",
+ "docify",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -11104,7 +11613,7 @@ dependencies = [
name = "pallet-tx-pause"
version = "9.0.0"
dependencies = [
- "docify 0.2.7",
+ "docify",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -11213,6 +11722,7 @@ dependencies = [
"staging-xcm",
"staging-xcm-builder",
"staging-xcm-executor",
+ "xcm-fee-payment-runtime-api",
]
[[package]]
@@ -11430,6 +11940,21 @@ dependencies = [
"substrate-wasm-builder",
]
+[[package]]
+name = "parachains-relay"
+version = "0.1.0"
+dependencies = [
+ "async-std",
+ "async-trait",
+ "bp-polkadot-core",
+ "futures",
+ "log",
+ "parity-scale-codec",
+ "relay-substrate-client",
+ "relay-utils",
+ "sp-core",
+]
+
[[package]]
name = "parachains-runtimes-test-utils"
version = "7.0.0"
@@ -11468,7 +11993,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4e69bf016dc406eff7d53a7d3f7cf1c2e72c82b9088aac1118591e36dd2cd3e9"
dependencies = [
"bitcoin_hashes 0.13.0",
- "rand",
+ "rand 0.8.5",
"rand_core 0.6.4",
"serde",
"unicode-normalization",
@@ -11495,7 +12020,7 @@ dependencies = [
"lz4",
"memmap2 0.5.10",
"parking_lot 0.12.1",
- "rand",
+ "rand 0.8.5",
"siphasher",
"snap",
]
@@ -11522,8 +12047,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "312270ee71e1cd70289dacf597cab7b207aa107d2f28191c2ae45b2ece18a260"
dependencies = [
"proc-macro-crate 1.3.1",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -11557,7 +12082,7 @@ version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f557c32c6d268a07c921471619c0295f5efad3a0e76d4f97a05c091a51d110b2"
dependencies = [
- "proc-macro2",
+ "proc-macro2 1.0.75",
"syn 1.0.109",
"synstructure",
]
@@ -11790,6 +12315,7 @@ dependencies = [
"cumulus-pallet-xcmp-queue",
"cumulus-primitives-aura",
"cumulus-primitives-core",
+ "cumulus-primitives-storage-weight-reclaim",
"cumulus-primitives-utility",
"enumflags2",
"frame-benchmarking",
@@ -11889,6 +12415,7 @@ dependencies = [
"cumulus-pallet-xcmp-queue",
"cumulus-primitives-aura",
"cumulus-primitives-core",
+ "cumulus-primitives-storage-weight-reclaim",
"cumulus-primitives-utility",
"enumflags2",
"frame-benchmarking",
@@ -11976,8 +12503,8 @@ checksum = "68ca01446f50dbda87c1786af8770d535423fa8a53aec03b8f4e3d7eb10e0929"
dependencies = [
"pest",
"pest_meta",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -12017,8 +12544,8 @@ version = "1.1.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -12117,7 +12644,7 @@ version = "7.0.0"
dependencies = [
"assert_matches",
"bitvec",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"futures",
"futures-timer",
"itertools 0.10.5",
@@ -12131,7 +12658,7 @@ dependencies = [
"polkadot-node-subsystem-util",
"polkadot-primitives",
"polkadot-primitives-test-helpers",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"rand_core 0.6.4",
"schnorrkel 0.11.4",
@@ -12147,7 +12674,7 @@ dependencies = [
"always-assert",
"assert_matches",
"bitvec",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"futures",
"futures-timer",
"log",
@@ -12157,7 +12684,7 @@ dependencies = [
"polkadot-node-subsystem-test-helpers",
"polkadot-node-subsystem-util",
"polkadot-primitives",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"sp-application-crypto",
"sp-authority-discovery",
@@ -12186,7 +12713,7 @@ dependencies = [
"polkadot-primitives",
"polkadot-primitives-test-helpers",
"polkadot-subsystem-bench",
- "rand",
+ "rand 0.8.5",
"sc-network",
"schnellru",
"sp-core",
@@ -12203,7 +12730,7 @@ version = "7.0.0"
dependencies = [
"assert_matches",
"async-trait",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"fatality",
"futures",
"futures-timer",
@@ -12218,7 +12745,7 @@ dependencies = [
"polkadot-primitives",
"polkadot-primitives-test-helpers",
"polkadot-subsystem-bench",
- "rand",
+ "rand 0.8.5",
"sc-network",
"schnellru",
"sp-application-crypto",
@@ -12256,7 +12783,6 @@ dependencies = [
"sp-runtime",
"substrate-build-script-utils",
"thiserror",
- "try-runtime-cli",
]
[[package]]
@@ -12265,7 +12791,7 @@ version = "7.0.0"
dependencies = [
"assert_matches",
"bitvec",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"fatality",
"futures",
"futures-timer",
@@ -12363,7 +12889,7 @@ dependencies = [
"polkadot-node-subsystem-util",
"polkadot-primitives",
"quickcheck",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"sc-network",
"sc-network-common",
@@ -12437,7 +12963,7 @@ dependencies = [
"async-trait",
"bitvec",
"derive_more",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"futures",
"futures-timer",
"itertools 0.10.5",
@@ -12455,7 +12981,7 @@ dependencies = [
"polkadot-overseer",
"polkadot-primitives",
"polkadot-primitives-test-helpers",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"rand_core 0.6.4",
"sc-keystore",
@@ -12479,7 +13005,7 @@ version = "7.0.0"
dependencies = [
"assert_matches",
"bitvec",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"futures",
"futures-timer",
"kvdb",
@@ -12733,7 +13259,7 @@ dependencies = [
"polkadot-parachain-primitives",
"polkadot-primitives",
"procfs",
- "rand",
+ "rand 0.8.5",
"rococo-runtime",
"rusty-fork",
"sc-sysinfo",
@@ -12871,6 +13397,7 @@ dependencies = [
"polkadot-node-primitives",
"polkadot-primitives",
"sc-network",
+ "sc-network-types",
"sp-core",
"thiserror",
"tokio",
@@ -12917,11 +13444,13 @@ dependencies = [
"polkadot-node-jaeger",
"polkadot-node-primitives",
"polkadot-primitives",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"sc-authority-discovery",
"sc-network",
- "strum 0.24.1",
+ "sc-network-types",
+ "sp-runtime",
+ "strum 0.26.2",
"thiserror",
"tracing-gum",
]
@@ -12995,6 +13524,7 @@ dependencies = [
"polkadot-statement-table",
"sc-client-api",
"sc-network",
+ "sc-network-types",
"sc-transaction-pool-api",
"smallvec",
"sp-api",
@@ -13013,7 +13543,7 @@ dependencies = [
"assert_matches",
"async-trait",
"derive_more",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"fatality",
"futures",
"futures-channel",
@@ -13038,7 +13568,7 @@ dependencies = [
"polkadot-primitives",
"polkadot-primitives-test-helpers",
"prioritized-metered-channel",
- "rand",
+ "rand 0.8.5",
"sc-client-api",
"schnellru",
"sp-application-crypto",
@@ -13219,7 +13749,7 @@ name = "polkadot-primitives-test-helpers"
version = "1.0.0"
dependencies = [
"polkadot-primitives",
- "rand",
+ "rand 0.8.5",
"sp-application-crypto",
"sp-core",
"sp-keyring",
@@ -13358,7 +13888,7 @@ dependencies = [
"polkadot-primitives",
"polkadot-primitives-test-helpers",
"polkadot-runtime-metrics",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"rstest",
"rustc-hex",
@@ -13392,8 +13922,7 @@ version = "0.0.1"
dependencies = [
"cumulus-pallet-aura-ext",
"cumulus-pallet-parachain-system",
- "docify 0.2.7",
- "frame",
+ "docify",
"frame-executive",
"frame-support",
"frame-system",
@@ -13411,13 +13940,17 @@ dependencies = [
"pallet-example-single-block-migrations",
"pallet-examples",
"pallet-multisig",
+ "pallet-nfts",
+ "pallet-preimage",
"pallet-proxy",
"pallet-referenda",
"pallet-scheduler",
"pallet-timestamp",
"pallet-transaction-payment",
+ "pallet-uniques",
"pallet-utility",
"parity-scale-codec",
+ "polkadot-sdk-frame",
"sc-cli",
"sc-client-db",
"sc-consensus-aura",
@@ -13447,6 +13980,35 @@ dependencies = [
"substrate-wasm-builder",
]
+[[package]]
+name = "polkadot-sdk-frame"
+version = "0.1.0"
+dependencies = [
+ "docify",
+ "frame-executive",
+ "frame-support",
+ "frame-system",
+ "frame-system-rpc-runtime-api",
+ "log",
+ "pallet-examples",
+ "parity-scale-codec",
+ "scale-info",
+ "sp-api",
+ "sp-arithmetic",
+ "sp-block-builder",
+ "sp-consensus-aura",
+ "sp-consensus-grandpa",
+ "sp-core",
+ "sp-inherents",
+ "sp-io",
+ "sp-offchain",
+ "sp-runtime",
+ "sp-session",
+ "sp-std 14.0.0",
+ "sp-transaction-pool",
+ "sp-version",
+]
+
[[package]]
name = "polkadot-service"
version = "7.0.0"
@@ -13454,7 +14016,7 @@ dependencies = [
"assert_matches",
"async-trait",
"bitvec",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"frame-benchmarking",
"frame-benchmarking-cli",
"frame-support",
@@ -13468,7 +14030,6 @@ dependencies = [
"log",
"mmr-gadget",
"pallet-babe",
- "pallet-im-online",
"pallet-staking",
"pallet-transaction-payment",
"pallet-transaction-payment-rpc-runtime-api",
@@ -13565,12 +14126,14 @@ dependencies = [
"sp-transaction-pool",
"sp-version",
"sp-weights",
+ "staging-xcm",
"substrate-prometheus-endpoint",
"tempfile",
"thiserror",
"tracing-gum",
"westend-runtime",
"westend-runtime-constants",
+ "xcm-fee-payment-runtime-api",
]
[[package]]
@@ -13629,7 +14192,7 @@ dependencies = [
"clap-num",
"color-eyre",
"colored",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"futures",
"futures-timer",
"hex",
@@ -13660,15 +14223,17 @@ dependencies = [
"prometheus",
"pyroscope",
"pyroscope_pprofrs",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"rand_core 0.6.4",
"rand_distr",
"sc-keystore",
"sc-network",
+ "sc-network-types",
"sc-service",
"schnorrkel 0.11.4",
"serde",
+ "serde_json",
"serde_yaml",
"sha1",
"sp-application-crypto",
@@ -13737,7 +14302,7 @@ dependencies = [
"polkadot-node-subsystem-types",
"polkadot-node-subsystem-util",
"polkadot-primitives",
- "rand",
+ "rand 0.8.5",
"sp-core",
"sp-keystore",
"substrate-build-script-utils",
@@ -13830,7 +14395,7 @@ dependencies = [
"polkadot-runtime-parachains",
"polkadot-service",
"polkadot-test-runtime",
- "rand",
+ "rand 0.8.5",
"sc-authority-discovery",
"sc-chain-spec",
"sc-cli",
@@ -13919,8 +14484,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5c4fdfc49717fb9a196e74a5d28e0bc764eb394a2c803eb11133a31ac996c60c"
dependencies = [
"polkavm-common",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -14029,7 +14594,7 @@ version = "0.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "be97d76faf1bfab666e1375477b23fde79eccf0276e9b63b92a39d676a889ba9"
dependencies = [
- "rand",
+ "rand 0.8.5",
]
[[package]]
@@ -14116,7 +14681,7 @@ version = "0.1.25"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6c8646e95016a7a6c4adea95bafa8a16baab64b583356217f2c85db4a39d9a86"
dependencies = [
- "proc-macro2",
+ "proc-macro2 1.0.75",
"syn 1.0.109",
]
@@ -14126,7 +14691,7 @@ version = "0.2.12"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6c64d9ba0963cdcea2e1b2230fbae2bab30eb25a174be395c41e764bfb65dd62"
dependencies = [
- "proc-macro2",
+ "proc-macro2 1.0.75",
"syn 2.0.53",
]
@@ -14187,8 +14752,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c"
dependencies = [
"proc-macro-error-attr",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
"version_check",
]
@@ -14199,8 +14764,8 @@ version = "1.0.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"version_check",
]
@@ -14216,11 +14781,20 @@ version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9b698b0b09d40e9b7c1a47b132d66a8b54bcd20583d9b6d06e4535e383b4405c"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
+[[package]]
+name = "proc-macro2"
+version = "0.4.30"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cf3d2011ab5c909338f7887f4fc896d35932e29146c12c8d01da6b22a80ba759"
+dependencies = [
+ "unicode-xid 0.1.0",
+]
+
[[package]]
name = "proc-macro2"
version = "1.0.75"
@@ -14288,8 +14862,8 @@ version = "0.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "440f724eba9f6996b75d63681b0a92b06947f1457076d503a4d2e2c8f56442b8"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -14316,7 +14890,7 @@ dependencies = [
"bitflags 2.4.0",
"lazy_static",
"num-traits",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"rand_xorshift",
"regex-syntax 0.8.2",
@@ -14375,8 +14949,8 @@ checksum = "e5d2d8d10f3c6ded6da8b05b5fb3b8a5082514344d56c9f871412d29b4e075b4"
dependencies = [
"anyhow",
"itertools 0.10.5",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -14388,8 +14962,8 @@ checksum = "efb6c9a1dd1def8e2124d17e83a20af56f1570d6c2d2bd9e266ccb768df3840e"
dependencies = [
"anyhow",
"itertools 0.11.0",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -14493,7 +15067,7 @@ checksum = "588f6378e4dd99458b60ec275b4477add41ce4fa9f64dcba6f15adccb19b50d6"
dependencies = [
"env_logger 0.8.4",
"log",
- "rand",
+ "rand 0.8.5",
]
[[package]]
@@ -14507,6 +15081,24 @@ dependencies = [
"pin-project-lite 0.1.12",
]
+[[package]]
+name = "quinn"
+version = "0.9.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "2e8b432585672228923edbbf64b8b12c14e1112f62e88737655b4a083dbcd78e"
+dependencies = [
+ "bytes",
+ "pin-project-lite 0.2.12",
+ "quinn-proto",
+ "quinn-udp",
+ "rustc-hash",
+ "rustls 0.20.8",
+ "thiserror",
+ "tokio",
+ "tracing",
+ "webpki",
+]
+
[[package]]
name = "quinn-proto"
version = "0.9.5"
@@ -14514,7 +15106,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c956be1b23f4261676aed05a0046e204e8a6836e50203902683a718af0797989"
dependencies = [
"bytes",
- "rand",
+ "rand 0.8.5",
"ring 0.16.20",
"rustc-hash",
"rustls 0.20.8",
@@ -14525,13 +15117,35 @@ dependencies = [
"webpki",
]
+[[package]]
+name = "quinn-udp"
+version = "0.3.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "641538578b21f5e5c8ea733b736895576d0fe329bb883b937db6f4d163dbaaf4"
+dependencies = [
+ "libc",
+ "quinn-proto",
+ "socket2 0.4.9",
+ "tracing",
+ "windows-sys 0.42.0",
+]
+
+[[package]]
+name = "quote"
+version = "0.6.13"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6ce23b6b870e8f94f81fb0a363d65d86675884b34a09043c81e5562f11c1f8e1"
+dependencies = [
+ "proc-macro2 0.4.30",
+]
+
[[package]]
name = "quote"
version = "1.0.35"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef"
dependencies = [
- "proc-macro2",
+ "proc-macro2 1.0.75",
]
[[package]]
@@ -14540,6 +15154,19 @@ version = "0.7.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09"
+[[package]]
+name = "rand"
+version = "0.7.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03"
+dependencies = [
+ "getrandom 0.1.16",
+ "libc",
+ "rand_chacha 0.2.2",
+ "rand_core 0.5.1",
+ "rand_hc",
+]
+
[[package]]
name = "rand"
version = "0.8.5"
@@ -14596,7 +15223,16 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "32cb0b9bc82b0a0876c2dd994a7e7a2683d3e7390ca40e6886785ef0c7e3ee31"
dependencies = [
"num-traits",
- "rand",
+ "rand 0.8.5",
+]
+
+[[package]]
+name = "rand_hc"
+version = "0.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c"
+dependencies = [
+ "rand_core 0.5.1",
]
[[package]]
@@ -14634,9 +15270,9 @@ checksum = "60a357793950651c4ed0f3f52338f53b2f809f32d83a07f72909fa13e4c6c1e3"
[[package]]
name = "rayon"
-version = "1.7.0"
+version = "1.10.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1d2df5196e37bcc87abebc0053e20787d73847bb33134a69841207dd0a47f03b"
+checksum = "b418a60154510ca1a002a752ca9714984e21e4241e804d32555251faf8b78ffa"
dependencies = [
"either",
"rayon-core",
@@ -14644,14 +15280,32 @@ dependencies = [
[[package]]
name = "rayon-core"
-version = "1.11.0"
+version = "1.12.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4b8f95bd6966f5c87776639160a66bd8ab9895d9d4ab01ddba9fc60661aebe8d"
+checksum = "1465873a3dfdaa8ae7cb14b4383657caab0b3e8a0aa9ae8e04b044854c8dfce2"
dependencies = [
- "crossbeam-channel",
"crossbeam-deque",
"crossbeam-utils",
- "num_cpus",
+]
+
+[[package]]
+name = "rbtag"
+version = "0.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "72c64936fcc0b811890a9d90020f3df5cec9c604efde88af7db6a35d365132a3"
+dependencies = [
+ "rbtag_derive",
+]
+
+[[package]]
+name = "rbtag_derive"
+version = "0.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b75511b710ccca8adbb211e04763bd8c78fed585b0ec188a20ed9b0dd95567c4"
+dependencies = [
+ "proc-macro2 0.4.30",
+ "quote 0.6.13",
+ "syn 0.15.44",
]
[[package]]
@@ -14731,8 +15385,8 @@ version = "1.0.20"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7f7473c2cfcf90008193dd0e3e16599455cb601a9fce322b5bb55de799664925"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -14817,6 +15471,72 @@ version = "1.9.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e898588f33fdd5b9420719948f9f2a32c922a246964576f71ba7f24f80610fbc"
+[[package]]
+name = "relay-substrate-client"
+version = "0.1.0"
+dependencies = [
+ "async-std",
+ "async-trait",
+ "bp-header-chain",
+ "bp-messages",
+ "bp-polkadot-core",
+ "bp-runtime",
+ "finality-relay",
+ "frame-support",
+ "frame-system",
+ "futures",
+ "jsonrpsee",
+ "log",
+ "num-traits",
+ "pallet-balances",
+ "pallet-bridge-messages",
+ "pallet-transaction-payment",
+ "pallet-transaction-payment-rpc-runtime-api",
+ "pallet-utility",
+ "parity-scale-codec",
+ "rand 0.8.5",
+ "relay-utils",
+ "sc-chain-spec",
+ "sc-rpc-api",
+ "sc-transaction-pool-api",
+ "scale-info",
+ "sp-consensus-grandpa",
+ "sp-core",
+ "sp-rpc",
+ "sp-runtime",
+ "sp-std 14.0.0",
+ "sp-trie",
+ "sp-version",
+ "staging-xcm",
+ "thiserror",
+ "tokio",
+]
+
+[[package]]
+name = "relay-utils"
+version = "0.1.0"
+dependencies = [
+ "ansi_term",
+ "anyhow",
+ "async-std",
+ "async-trait",
+ "backoff",
+ "bp-runtime",
+ "env_logger 0.11.3",
+ "futures",
+ "isahc",
+ "jsonpath_lib",
+ "log",
+ "num-traits",
+ "serde_json",
+ "sp-runtime",
+ "substrate-prometheus-endpoint",
+ "sysinfo",
+ "thiserror",
+ "time",
+ "tokio",
+]
+
[[package]]
name = "remote-ext-tests-bags-list"
version = "1.0.0"
@@ -15044,6 +15764,7 @@ name = "rococo-runtime"
version = "7.0.0"
dependencies = [
"binary-merkle-tree",
+ "bitvec",
"frame-benchmarking",
"frame-executive",
"frame-remote-externalities",
@@ -15069,7 +15790,6 @@ dependencies = [
"pallet-elections-phragmen",
"pallet-grandpa",
"pallet-identity",
- "pallet-im-online",
"pallet-indices",
"pallet-membership",
"pallet-message-queue",
@@ -15077,6 +15797,7 @@ dependencies = [
"pallet-multisig",
"pallet-nis",
"pallet-offences",
+ "pallet-parameters",
"pallet-preimage",
"pallet-proxy",
"pallet-ranked-collective",
@@ -15117,6 +15838,7 @@ dependencies = [
"sp-block-builder",
"sp-consensus-babe",
"sp-consensus-beefy",
+ "sp-consensus-grandpa",
"sp-core",
"sp-genesis-builder",
"sp-inherents",
@@ -15140,6 +15862,7 @@ dependencies = [
"substrate-wasm-builder",
"tiny-keccak",
"tokio",
+ "xcm-fee-payment-runtime-api",
]
[[package]]
@@ -15220,8 +15943,8 @@ checksum = "d428f8247852f894ee1be110b375111b586d4fa431f6c46e64ba5a0dcccbe605"
dependencies = [
"cfg-if",
"glob",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"regex",
"relative-path",
"rustc_version 0.4.0",
@@ -15270,7 +15993,7 @@ dependencies = [
"parity-scale-codec",
"primitive-types",
"proptest",
- "rand",
+ "rand 0.8.5",
"rlp",
"ruint-macro",
"serde",
@@ -15582,15 +16305,16 @@ dependencies = [
"libp2p",
"linked_hash_set",
"log",
- "multihash 0.18.1",
+ "multihash 0.17.0",
"multihash-codetable",
"parity-scale-codec",
"prost 0.12.3",
"prost-build",
"quickcheck",
- "rand",
+ "rand 0.8.5",
"sc-client-api",
"sc-network",
+ "sc-network-types",
"sp-api",
"sp-authority-discovery",
"sp-blockchain",
@@ -15646,10 +16370,10 @@ dependencies = [
[[package]]
name = "sc-chain-spec"
-version = "27.0.0"
+version = "28.0.0"
dependencies = [
"array-bytes 6.1.0",
- "docify 0.2.7",
+ "docify",
"log",
"memmap2 0.9.3",
"parity-scale-codec",
@@ -15670,6 +16394,7 @@ dependencies = [
"sp-keyring",
"sp-runtime",
"sp-state-machine",
+ "sp-tracing 16.0.0",
"substrate-test-runtime",
]
@@ -15678,8 +16403,8 @@ name = "sc-chain-spec-derive"
version = "11.0.0"
dependencies = [
"proc-macro-crate 3.0.0",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -15699,7 +16424,7 @@ dependencies = [
"names",
"parity-bip39",
"parity-scale-codec",
- "rand",
+ "rand 0.8.5",
"regex",
"rpassword",
"sc-client-api",
@@ -15772,7 +16497,7 @@ dependencies = [
"parity-scale-codec",
"parking_lot 0.12.1",
"quickcheck",
- "rand",
+ "rand 0.8.5",
"sc-client-api",
"sc-state-db",
"schnellru",
@@ -15795,11 +16520,11 @@ dependencies = [
"async-trait",
"futures",
"futures-timer",
- "libp2p-identity",
"log",
"mockall",
"parking_lot 0.12.1",
"sc-client-api",
+ "sc-network-types",
"sc-utils",
"serde",
"sp-api",
@@ -15940,6 +16665,7 @@ dependencies = [
"sc-network-gossip",
"sc-network-sync",
"sc-network-test",
+ "sc-network-types",
"sc-utils",
"serde",
"sp-api",
@@ -16013,7 +16739,7 @@ dependencies = [
"log",
"parity-scale-codec",
"parking_lot 0.12.1",
- "rand",
+ "rand 0.8.5",
"sc-block-builder",
"sc-chain-spec",
"sc-client-api",
@@ -16023,6 +16749,7 @@ dependencies = [
"sc-network-gossip",
"sc-network-sync",
"sc-network-test",
+ "sc-network-types",
"sc-telemetry",
"sc-transaction-pool-api",
"sc-utils",
@@ -16162,7 +16889,7 @@ dependencies = [
"array-bytes 6.1.0",
"assert_matches",
"criterion 0.4.0",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"num_cpus",
"parity-scale-codec",
"parking_lot 0.12.1",
@@ -16191,7 +16918,7 @@ dependencies = [
"substrate-test-runtime",
"tempfile",
"tracing",
- "tracing-subscriber 0.2.25",
+ "tracing-subscriber 0.3.18",
"wat",
]
@@ -16281,7 +17008,6 @@ dependencies = [
"bytes",
"futures",
"futures-timer",
- "libp2p-identity",
"log",
"mixnet",
"multiaddr",
@@ -16289,6 +17015,7 @@ dependencies = [
"parking_lot 0.12.1",
"sc-client-api",
"sc-network",
+ "sc-network-types",
"sc-transaction-pool-api",
"sp-api",
"sp-consensus",
@@ -16309,6 +17036,7 @@ dependencies = [
"async-trait",
"asynchronous-codec",
"bytes",
+ "cid 0.9.0",
"either",
"fnv",
"futures",
@@ -16316,25 +17044,34 @@ dependencies = [
"ip_network",
"libp2p",
"linked_hash_set",
+ "litep2p",
"log",
"mockall",
"multistream-select",
+ "once_cell",
"parity-scale-codec",
"parking_lot 0.12.1",
"partial_sort",
"pin-project",
- "rand",
+ "prost 0.11.9",
+ "prost-build",
+ "rand 0.8.5",
+ "sc-block-builder",
"sc-client-api",
"sc-network-common",
"sc-network-light",
"sc-network-sync",
+ "sc-network-types",
"sc-utils",
+ "schnellru",
"serde",
"serde_json",
"smallvec",
"sp-arithmetic",
"sp-blockchain",
+ "sp-consensus",
"sp-core",
+ "sp-crypto-hashing",
"sp-runtime",
"sp-test-primitives",
"sp-tracing 16.0.0",
@@ -16348,36 +17085,11 @@ dependencies = [
"tokio-test",
"tokio-util",
"unsigned-varint",
+ "void",
"wasm-timer",
"zeroize",
]
-[[package]]
-name = "sc-network-bitswap"
-version = "0.33.0"
-dependencies = [
- "async-channel",
- "cid",
- "futures",
- "libp2p-identity",
- "log",
- "prost 0.12.3",
- "prost-build",
- "sc-block-builder",
- "sc-client-api",
- "sc-consensus",
- "sc-network",
- "sp-blockchain",
- "sp-consensus",
- "sp-crypto-hashing",
- "sp-runtime",
- "substrate-test-runtime",
- "substrate-test-runtime-client",
- "thiserror",
- "tokio",
- "unsigned-varint",
-]
-
[[package]]
name = "sc-network-common"
version = "0.33.0"
@@ -16389,6 +17101,7 @@ dependencies = [
"parity-scale-codec",
"prost-build",
"sc-consensus",
+ "sc-network-types",
"sp-consensus",
"sp-consensus-grandpa",
"sp-runtime",
@@ -16410,6 +17123,7 @@ dependencies = [
"sc-network",
"sc-network-common",
"sc-network-sync",
+ "sc-network-types",
"schnellru",
"sp-runtime",
"substrate-prometheus-endpoint",
@@ -16425,13 +17139,13 @@ dependencies = [
"array-bytes 6.1.0",
"async-channel",
"futures",
- "libp2p-identity",
"log",
"parity-scale-codec",
"prost 0.12.3",
"prost-build",
"sc-client-api",
"sc-network",
+ "sc-network-types",
"sp-blockchain",
"sp-core",
"sp-runtime",
@@ -16451,7 +17165,9 @@ dependencies = [
"sc-network",
"sc-network-common",
"sc-network-sync",
+ "sc-network-types",
"sp-consensus",
+ "sp-runtime",
"sp-statement-store",
"substrate-prometheus-endpoint",
]
@@ -16478,6 +17194,7 @@ dependencies = [
"sc-consensus",
"sc-network",
"sc-network-common",
+ "sc-network-types",
"sc-utils",
"schnellru",
"smallvec",
@@ -16506,7 +17223,7 @@ dependencies = [
"libp2p",
"log",
"parking_lot 0.12.1",
- "rand",
+ "rand 0.8.5",
"sc-block-builder",
"sc-client-api",
"sc-consensus",
@@ -16514,6 +17231,7 @@ dependencies = [
"sc-network-common",
"sc-network-light",
"sc-network-sync",
+ "sc-network-types",
"sc-service",
"sc-utils",
"sp-blockchain",
@@ -16538,17 +17256,32 @@ dependencies = [
"sc-network",
"sc-network-common",
"sc-network-sync",
+ "sc-network-types",
"sc-utils",
"sp-consensus",
"sp-runtime",
"substrate-prometheus-endpoint",
]
+[[package]]
+name = "sc-network-types"
+version = "0.10.0-dev"
+dependencies = [
+ "bs58 0.4.0",
+ "libp2p-identity",
+ "litep2p",
+ "multiaddr",
+ "multihash 0.17.0",
+ "rand 0.8.5",
+ "thiserror",
+]
+
[[package]]
name = "sc-offchain"
version = "29.0.0"
dependencies = [
"array-bytes 6.1.0",
+ "async-trait",
"bytes",
"fnv",
"futures",
@@ -16562,12 +17295,13 @@ dependencies = [
"once_cell",
"parity-scale-codec",
"parking_lot 0.12.1",
- "rand",
+ "rand 0.8.5",
"sc-block-builder",
"sc-client-api",
"sc-client-db",
"sc-network",
"sc-network-common",
+ "sc-network-types",
"sc-transaction-pool",
"sc-transaction-pool-api",
"sc-utils",
@@ -16598,7 +17332,7 @@ name = "sc-rpc"
version = "29.0.0"
dependencies = [
"assert_matches",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"futures",
"jsonrpsee",
"log",
@@ -16685,7 +17419,7 @@ dependencies = [
"parity-scale-codec",
"parking_lot 0.12.1",
"pretty_assertions",
- "rand",
+ "rand 0.8.5",
"sc-block-builder",
"sc-chain-spec",
"sc-client-api",
@@ -16739,7 +17473,7 @@ dependencies = [
"parity-scale-codec",
"parking_lot 0.12.1",
"pin-project",
- "rand",
+ "rand 0.8.5",
"sc-chain-spec",
"sc-client-api",
"sc-client-db",
@@ -16748,11 +17482,11 @@ dependencies = [
"sc-informant",
"sc-keystore",
"sc-network",
- "sc-network-bitswap",
"sc-network-common",
"sc-network-light",
"sc-network-sync",
"sc-network-transactions",
+ "sc-network-types",
"sc-rpc",
"sc-rpc-server",
"sc-rpc-spec-v2",
@@ -16840,7 +17574,7 @@ dependencies = [
name = "sc-statement-store"
version = "10.0.0"
dependencies = [
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"log",
"parity-db",
"parking_lot 0.12.1",
@@ -16894,7 +17628,7 @@ dependencies = [
"futures",
"libc",
"log",
- "rand",
+ "rand 0.8.5",
"rand_pcg",
"regex",
"sc-telemetry",
@@ -16917,7 +17651,8 @@ dependencies = [
"log",
"parking_lot 0.12.1",
"pin-project",
- "rand",
+ "rand 0.8.5",
+ "sc-network",
"sc-utils",
"serde",
"serde_json",
@@ -16952,7 +17687,7 @@ dependencies = [
"thiserror",
"tracing",
"tracing-log 0.1.3",
- "tracing-subscriber 0.2.25",
+ "tracing-subscriber 0.3.18",
]
[[package]]
@@ -16960,8 +17695,8 @@ name = "sc-tracing-proc-macro"
version = "11.0.0"
dependencies = [
"proc-macro-crate 3.0.0",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -17032,9 +17767,9 @@ dependencies = [
[[package]]
name = "scale-info"
-version = "2.11.0"
+version = "2.11.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2ef2175c2907e7c8bc0a9c3f86aeb5ec1f3b275300ad58a44d0c3ae379a5e52e"
+checksum = "788745a868b0e751750388f4e6546eb921ef714a4317fa6954f7cde114eb2eb7"
dependencies = [
"bitvec",
"cfg-if",
@@ -17046,13 +17781,13 @@ dependencies = [
[[package]]
name = "scale-info-derive"
-version = "2.11.0"
+version = "2.11.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "634d9b8eb8fd61c5cdd3390d9b2132300a7e7618955b98b8416f118c1b4e144f"
+checksum = "7dc2f4e8bc344b9fc3d5f74f72c2e55bfc38d28dc2ebc69c194a3df424e4d9ac"
dependencies = [
"proc-macro-crate 1.3.1",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -17083,8 +17818,8 @@ version = "0.8.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ec0f696e21e10fa546b7ffb1c9672c6de8fbc7a81acf59524386d8639bf12737"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"serde_derive_internals",
"syn 1.0.109",
]
@@ -17163,6 +17898,21 @@ dependencies = [
"untrusted 0.7.1",
]
+[[package]]
+name = "sctp-proto"
+version = "0.1.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8f64cef148d3295c730c3cb340b0b252a4d570b1c7d4bf0808f88540b0a888bc"
+dependencies = [
+ "bytes",
+ "crc",
+ "fxhash",
+ "log",
+ "rand 0.8.5",
+ "slab",
+ "thiserror",
+]
+
[[package]]
name = "sec1"
version = "0.7.3"
@@ -17362,8 +18112,8 @@ version = "1.0.197"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7eb0b34b42edc17f6b7cac84a52a1c5f0e1bb2227e997ca9011ea3dd34e8610b"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -17373,8 +18123,8 @@ version = "0.26.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "85bf8229e7920a9f636479437026331ce11aa132b4dde37d121944a44d6e5f3c"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -17393,6 +18143,7 @@ version = "1.0.114"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c5f09b1bd632ef549eaa9f60a1f8de742bdbc698e6cee2095fc84dde5f549ae0"
dependencies = [
+ "indexmap 2.2.3",
"itoa",
"ryu",
"serde",
@@ -17462,8 +18213,8 @@ version = "2.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "91d129178576168c589c9ec973feedf7d3126c01ac2bf08795109aa35b69fb8f"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -17489,6 +18240,7 @@ dependencies = [
"cfg-if",
"cpufeatures",
"digest 0.10.7",
+ "sha1-asm",
]
[[package]]
@@ -17502,6 +18254,15 @@ dependencies = [
"digest 0.10.7",
]
+[[package]]
+name = "sha1-asm"
+version = "0.5.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "2ba6947745e7f86be3b8af00b7355857085dbdf8901393c89514510eb61f4e21"
+dependencies = [
+ "cc",
+]
+
[[package]]
name = "sha2"
version = "0.9.9"
@@ -17607,6 +18368,12 @@ dependencies = [
"libc",
]
+[[package]]
+name = "signature"
+version = "1.6.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c"
+
[[package]]
name = "signature"
version = "2.1.0"
@@ -17630,6 +18397,15 @@ dependencies = [
"wide",
]
+[[package]]
+name = "simple-dns"
+version = "0.5.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cae9a3fcdadafb6d97f4c0e007e4247b114ee0f119f650c3cbf3a8b3a1479694"
+dependencies = [
+ "bitflags 2.4.0",
+]
+
[[package]]
name = "simple-mermaid"
version = "0.1.1"
@@ -17677,6 +18453,17 @@ dependencies = [
"version_check",
]
+[[package]]
+name = "sluice"
+version = "0.5.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6d7400c0eff44aa2fcb5e31a5f24ba9716ed90138769e4977a2ba6014ae63eb5"
+dependencies = [
+ "async-channel",
+ "futures-core",
+ "futures-io",
+]
+
[[package]]
name = "smallvec"
version = "1.11.2"
@@ -17745,7 +18532,7 @@ dependencies = [
"pbkdf2",
"pin-project",
"poly1305 0.8.0",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"ruzstd",
"schnorrkel 0.10.2",
@@ -17788,7 +18575,7 @@ dependencies = [
"no-std-net",
"parking_lot 0.12.1",
"pin-project",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"serde",
"serde_json",
@@ -17838,7 +18625,6 @@ version = "0.2.0"
dependencies = [
"byte-slice-cast",
"frame-support",
- "frame-system",
"hex",
"hex-literal",
"parity-scale-codec",
@@ -17853,7 +18639,6 @@ dependencies = [
"sp-std 14.0.0",
"ssz_rs",
"ssz_rs_derive",
- "static_assertions",
]
[[package]]
@@ -17889,14 +18674,12 @@ dependencies = [
"hex-literal",
"parity-bytes",
"parity-scale-codec",
- "rand",
+ "rand 0.8.5",
"rlp",
- "rustc-hex",
"scale-info",
"serde",
"serde-big-array",
"serde_json",
- "sp-core",
"sp-io",
"sp-runtime",
"sp-std 14.0.0",
@@ -17912,7 +18695,7 @@ dependencies = [
"hex",
"lazy_static",
"parity-scale-codec",
- "rand",
+ "rand 0.8.5",
"scale-info",
"snowbridge-amcl",
"zeroize",
@@ -17923,7 +18706,7 @@ name = "snowbridge-outbound-queue-merkle-tree"
version = "0.3.0"
dependencies = [
"array-bytes 4.2.0",
- "env_logger 0.9.3",
+ "env_logger 0.11.3",
"hex",
"hex-literal",
"parity-scale-codec",
@@ -17942,17 +18725,13 @@ dependencies = [
"snowbridge-core",
"snowbridge-outbound-queue-merkle-tree",
"sp-api",
- "sp-core",
"sp-std 14.0.0",
- "staging-xcm",
]
[[package]]
name = "snowbridge-pallet-ethereum-client"
version = "0.2.0"
dependencies = [
- "bp-runtime",
- "byte-slice-cast",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -17960,8 +18739,7 @@ dependencies = [
"log",
"pallet-timestamp",
"parity-scale-codec",
- "rand",
- "rlp",
+ "rand 0.8.5",
"scale-info",
"serde",
"serde_json",
@@ -17974,8 +18752,6 @@ dependencies = [
"sp-keyring",
"sp-runtime",
"sp-std 14.0.0",
- "ssz_rs",
- "ssz_rs_derive",
"static_assertions",
]
@@ -17983,9 +18759,6 @@ dependencies = [
name = "snowbridge-pallet-ethereum-client-fixtures"
version = "0.9.0"
dependencies = [
- "frame-benchmarking",
- "frame-support",
- "frame-system",
"hex-literal",
"snowbridge-beacon-primitives",
"snowbridge-core",
@@ -17998,21 +18771,18 @@ name = "snowbridge-pallet-inbound-queue"
version = "0.2.0"
dependencies = [
"alloy-primitives",
- "alloy-rlp",
"alloy-sol-types",
"frame-benchmarking",
"frame-support",
"frame-system",
"hex-literal",
"log",
- "num-traits",
"pallet-balances",
"parity-scale-codec",
"scale-info",
"serde",
"snowbridge-beacon-primitives",
"snowbridge-core",
- "snowbridge-ethereum",
"snowbridge-pallet-ethereum-client",
"snowbridge-pallet-inbound-queue-fixtures",
"snowbridge-router-primitives",
@@ -18022,7 +18792,6 @@ dependencies = [
"sp-runtime",
"sp-std 14.0.0",
"staging-xcm",
- "staging-xcm-builder",
"staging-xcm-executor",
]
@@ -18030,9 +18799,6 @@ dependencies = [
name = "snowbridge-pallet-inbound-queue-fixtures"
version = "0.10.0"
dependencies = [
- "frame-benchmarking",
- "frame-support",
- "frame-system",
"hex-literal",
"snowbridge-beacon-primitives",
"snowbridge-core",
@@ -18049,7 +18815,6 @@ dependencies = [
"frame-benchmarking",
"frame-support",
"frame-system",
- "hex-literal",
"pallet-message-queue",
"parity-scale-codec",
"scale-info",
@@ -18062,14 +18827,12 @@ dependencies = [
"sp-keyring",
"sp-runtime",
"sp-std 14.0.0",
- "staging-xcm",
]
[[package]]
name = "snowbridge-pallet-system"
version = "0.2.0"
dependencies = [
- "ethabi-decode",
"frame-benchmarking",
"frame-support",
"frame-system",
@@ -18089,7 +18852,6 @@ dependencies = [
"sp-runtime",
"sp-std 14.0.0",
"staging-xcm",
- "staging-xcm-builder",
"staging-xcm-executor",
]
@@ -18097,22 +18859,18 @@ dependencies = [
name = "snowbridge-router-primitives"
version = "0.9.0"
dependencies = [
- "ethabi-decode",
"frame-support",
- "frame-system",
"hex-literal",
"log",
"parity-scale-codec",
"rustc-hex",
"scale-info",
- "serde",
"snowbridge-core",
"sp-core",
"sp-io",
"sp-runtime",
"sp-std 14.0.0",
"staging-xcm",
- "staging-xcm-builder",
"staging-xcm-executor",
]
@@ -18121,7 +18879,6 @@ name = "snowbridge-runtime-common"
version = "0.2.0"
dependencies = [
"frame-support",
- "frame-system",
"log",
"parity-scale-codec",
"snowbridge-core",
@@ -18136,77 +18893,30 @@ dependencies = [
name = "snowbridge-runtime-test-common"
version = "0.2.0"
dependencies = [
- "assets-common",
- "bridge-hub-test-utils",
- "bridge-runtime-common",
- "cumulus-pallet-aura-ext",
"cumulus-pallet-parachain-system",
- "cumulus-pallet-session-benchmarking",
- "cumulus-pallet-xcm",
- "cumulus-pallet-xcmp-queue",
- "cumulus-primitives-core",
- "cumulus-primitives-utility",
- "frame-benchmarking",
- "frame-executive",
"frame-support",
"frame-system",
- "frame-system-benchmarking",
- "frame-system-rpc-runtime-api",
- "frame-try-runtime",
- "hex-literal",
- "log",
- "pallet-aura",
- "pallet-authorship",
"pallet-balances",
"pallet-collator-selection",
"pallet-message-queue",
- "pallet-multisig",
"pallet-session",
"pallet-timestamp",
- "pallet-transaction-payment",
- "pallet-transaction-payment-rpc-runtime-api",
"pallet-utility",
"pallet-xcm",
- "pallet-xcm-benchmarks",
- "parachains-common",
"parachains-runtimes-test-utils",
"parity-scale-codec",
- "polkadot-core-primitives",
- "polkadot-parachain-primitives",
- "polkadot-runtime-common",
- "scale-info",
- "serde",
- "smallvec",
- "snowbridge-beacon-primitives",
"snowbridge-core",
- "snowbridge-outbound-queue-runtime-api",
"snowbridge-pallet-ethereum-client",
"snowbridge-pallet-ethereum-client-fixtures",
- "snowbridge-pallet-inbound-queue",
"snowbridge-pallet-outbound-queue",
"snowbridge-pallet-system",
- "snowbridge-router-primitives",
- "snowbridge-system-runtime-api",
- "sp-api",
- "sp-block-builder",
- "sp-consensus-aura",
"sp-core",
- "sp-genesis-builder",
- "sp-inherents",
"sp-io",
"sp-keyring",
- "sp-offchain",
"sp-runtime",
- "sp-session",
- "sp-std 14.0.0",
- "sp-storage 19.0.0",
- "sp-transaction-pool",
- "sp-version",
"staging-parachain-info",
"staging-xcm",
- "staging-xcm-builder",
"staging-xcm-executor",
- "static_assertions",
]
[[package]]
@@ -18216,7 +18926,6 @@ dependencies = [
"parity-scale-codec",
"snowbridge-core",
"sp-api",
- "sp-core",
"sp-std 14.0.0",
"staging-xcm",
]
@@ -18233,12 +18942,12 @@ dependencies = [
[[package]]
name = "socket2"
-version = "0.5.3"
+version = "0.5.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2538b18701741680e0322a2302176d3253a35388e2e62f172f64f4f16605f877"
+checksum = "05ffd9c0a93b7543e062e759284fcf5f5e3b098501104bfbdde4d404db792871"
dependencies = [
"libc",
- "windows-sys 0.48.0",
+ "windows-sys 0.52.0",
]
[[package]]
@@ -18254,7 +18963,7 @@ dependencies = [
"http",
"httparse",
"log",
- "rand",
+ "rand 0.8.5",
"sha-1 0.9.8",
]
@@ -18298,7 +19007,6 @@ dependencies = [
"sp-timestamp",
"substrate-build-script-utils",
"substrate-frame-rpc-system",
- "try-runtime-cli",
]
[[package]]
@@ -18370,8 +19078,8 @@ dependencies = [
"blake2 0.10.6",
"expander 2.0.0",
"proc-macro-crate 3.0.0",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -18426,12 +19134,12 @@ name = "sp-arithmetic"
version = "23.0.0"
dependencies = [
"criterion 0.4.0",
- "docify 0.2.7",
+ "docify",
"integer-sqrt",
"num-traits",
"parity-scale-codec",
"primitive-types",
- "rand",
+ "rand 0.8.5",
"scale-info",
"serde",
"sp-crypto-hashing",
@@ -18569,7 +19277,7 @@ dependencies = [
"sp-keystore",
"sp-mmr-primitives",
"sp-runtime",
- "strum 0.24.1",
+ "strum 0.26.2",
"w3f-bls",
]
@@ -18651,7 +19359,7 @@ dependencies = [
"parking_lot 0.12.1",
"paste",
"primitive-types",
- "rand",
+ "rand 0.8.5",
"regex",
"scale-info",
"schnorrkel 0.11.4",
@@ -18739,7 +19447,7 @@ dependencies = [
[[package]]
name = "sp-crypto-hashing"
-version = "0.0.0"
+version = "0.1.0"
dependencies = [
"blake2b_simd",
"byteorder",
@@ -18753,9 +19461,9 @@ dependencies = [
[[package]]
name = "sp-crypto-hashing-proc-macro"
-version = "0.0.0"
+version = "0.1.0"
dependencies = [
- "quote",
+ "quote 1.0.35",
"sp-crypto-hashing",
"syn 2.0.53",
]
@@ -18773,8 +19481,8 @@ name = "sp-debug-derive"
version = "8.0.0"
source = "git+https://github.com/paritytech/polkadot-sdk#82912acb33a9030c0ef3bf590a34fca09b72dc5f"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -18782,8 +19490,8 @@ dependencies = [
name = "sp-debug-derive"
version = "14.0.0"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -18809,8 +19517,10 @@ dependencies = [
[[package]]
name = "sp-genesis-builder"
-version = "0.7.0"
+version = "0.8.0"
dependencies = [
+ "parity-scale-codec",
+ "scale-info",
"serde_json",
"sp-api",
"sp-runtime",
@@ -18834,7 +19544,7 @@ name = "sp-io"
version = "30.0.0"
dependencies = [
"bytes",
- "ed25519-dalek",
+ "ed25519-dalek 2.1.0",
"libsecp256k1",
"log",
"parity-scale-codec",
@@ -18860,7 +19570,7 @@ version = "31.0.0"
dependencies = [
"sp-core",
"sp-runtime",
- "strum 0.24.1",
+ "strum 0.26.2",
]
[[package]]
@@ -18869,7 +19579,7 @@ version = "0.34.0"
dependencies = [
"parity-scale-codec",
"parking_lot 0.12.1",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.2.2",
"sp-core",
"sp-externalities 0.25.0",
@@ -18924,7 +19634,7 @@ name = "sp-npos-elections"
version = "26.0.0"
dependencies = [
"parity-scale-codec",
- "rand",
+ "rand 0.8.5",
"scale-info",
"serde",
"sp-arithmetic",
@@ -18939,7 +19649,7 @@ version = "2.0.0-alpha.5"
dependencies = [
"clap 4.5.3",
"honggfuzz",
- "rand",
+ "rand 0.8.5",
"sp-npos-elections",
"sp-runtime",
]
@@ -18976,14 +19686,14 @@ dependencies = [
name = "sp-runtime"
version = "31.0.1"
dependencies = [
- "docify 0.2.7",
+ "docify",
"either",
"hash256-std-hasher",
"impl-trait-for-tuples",
"log",
"parity-scale-codec",
"paste",
- "rand",
+ "rand 0.8.5",
"scale-info",
"serde",
"serde_json",
@@ -19050,8 +19760,8 @@ source = "git+https://github.com/paritytech/polkadot-sdk#82912acb33a9030c0ef3bf5
dependencies = [
"Inflector",
"proc-macro-crate 1.3.1",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -19062,8 +19772,8 @@ dependencies = [
"Inflector",
"expander 2.0.0",
"proc-macro-crate 3.0.0",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -19141,7 +19851,7 @@ dependencies = [
"parity-scale-codec",
"parking_lot 0.12.1",
"pretty_assertions",
- "rand",
+ "rand 0.8.5",
"smallvec",
"sp-core",
"sp-externalities 0.25.0",
@@ -19159,10 +19869,10 @@ version = "10.0.0"
dependencies = [
"aes-gcm 0.10.3",
"curve25519-dalek 4.1.2",
- "ed25519-dalek",
+ "ed25519-dalek 2.1.0",
"hkdf",
"parity-scale-codec",
- "rand",
+ "rand 0.8.5",
"scale-info",
"sha2 0.10.7",
"sp-api",
@@ -19251,7 +19961,7 @@ dependencies = [
"parity-scale-codec",
"tracing",
"tracing-core",
- "tracing-subscriber 0.2.25",
+ "tracing-subscriber 0.3.18",
]
[[package]]
@@ -19281,14 +19991,14 @@ version = "29.0.0"
dependencies = [
"ahash 0.8.8",
"array-bytes 6.1.0",
- "criterion 0.4.0",
+ "criterion 0.5.1",
"hash-db",
"lazy_static",
"memory-db",
"nohash-hasher",
"parity-scale-codec",
"parking_lot 0.12.1",
- "rand",
+ "rand 0.8.5",
"scale-info",
"schnellru",
"sp-core",
@@ -19323,8 +20033,8 @@ name = "sp-version-proc-macro"
version = "13.0.0"
dependencies = [
"parity-scale-codec",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"sp-version",
"syn 2.0.53",
]
@@ -19408,11 +20118,11 @@ checksum = "5e6915280e2d0db8911e5032a5c275571af6bdded2916abd691a659be25d3439"
dependencies = [
"Inflector",
"num-format",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"serde",
"serde_json",
- "unicode-xid",
+ "unicode-xid 0.2.4",
]
[[package]]
@@ -19433,8 +20143,8 @@ version = "0.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f07d54c4d01a1713eb363b55ba51595da15f6f1211435b71466460da022aa140"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -19446,7 +20156,7 @@ checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3"
[[package]]
name = "staging-chain-spec-builder"
-version = "2.0.0"
+version = "3.0.0"
dependencies = [
"clap 4.5.3",
"log",
@@ -19493,7 +20203,7 @@ dependencies = [
"pallet-treasury",
"parity-scale-codec",
"platforms",
- "rand",
+ "rand 0.8.5",
"regex",
"sc-authority-discovery",
"sc-basic-authorship",
@@ -19541,6 +20251,7 @@ dependencies = [
"sp-core",
"sp-crypto-hashing",
"sp-externalities 0.25.0",
+ "sp-genesis-builder",
"sp-inherents",
"sp-io",
"sp-keyring",
@@ -19562,7 +20273,6 @@ dependencies = [
"tempfile",
"tokio",
"tokio-util",
- "try-runtime-cli",
"wait-timeout",
"wat",
]
@@ -19701,11 +20411,31 @@ checksum = "70a2595fc3aa78f2d0e45dd425b22282dd863273761cc77780914b2cf3003acf"
dependencies = [
"cfg_aliases",
"memchr",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
+[[package]]
+name = "str0m"
+version = "0.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ee48572247f422dcbe68630c973f8296fbd5157119cd36a3223e48bf83d47727"
+dependencies = [
+ "combine",
+ "crc",
+ "hmac 0.12.1",
+ "once_cell",
+ "openssl",
+ "openssl-sys",
+ "rand 0.8.5",
+ "sctp-proto",
+ "serde",
+ "sha-1 0.10.1",
+ "thiserror",
+ "tracing",
+]
+
[[package]]
name = "strobe-rs"
version = "0.8.1"
@@ -19719,6 +20449,12 @@ dependencies = [
"zeroize",
]
+[[package]]
+name = "strsim"
+version = "0.8.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8ea5119cdb4c55b55d432abb513a0429384878c15dde60cc77b1c99de1a95a6a"
+
[[package]]
name = "strsim"
version = "0.10.0"
@@ -19731,6 +20467,30 @@ version = "0.11.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5ee073c9e4cd00e28217186dbe12796d692868f432bf2e97ee73bed0c56dfa01"
+[[package]]
+name = "structopt"
+version = "0.3.26"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0c6b5c64445ba8094a6ab0c3cd2ad323e07171012d9c98b0b15651daf1787a10"
+dependencies = [
+ "clap 2.34.0",
+ "lazy_static",
+ "structopt-derive",
+]
+
+[[package]]
+name = "structopt-derive"
+version = "0.4.18"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "dcb5ae327f9cc13b68763b5749770cb9e048a99bd9dfdfa58d0cf05d5f64afe0"
+dependencies = [
+ "heck 0.3.3",
+ "proc-macro-error",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
+ "syn 1.0.109",
+]
+
[[package]]
name = "strum"
version = "0.24.1"
@@ -19746,6 +20506,15 @@ version = "0.25.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "290d54ea6f91c969195bdbcd7442c8c2a2ba87da8bf60a7ee86a235d4bc1e125"
+[[package]]
+name = "strum"
+version = "0.26.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "5d8cec3501a5194c432b2b7976db6b7d10ec95c253208b45f83f7136aa985e29"
+dependencies = [
+ "strum_macros 0.26.2",
+]
+
[[package]]
name = "strum_macros"
version = "0.24.3"
@@ -19753,8 +20522,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1e385be0d24f186b4ce2f9982191e7101bb737312ad61c1f2f984f34bcf85d59"
dependencies = [
"heck 0.4.1",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"rustversion",
"syn 1.0.109",
]
@@ -19766,8 +20535,21 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "23dc1fa9ac9c169a78ba62f0b841814b7abae11bdd047b9c58f893439e309ea0"
dependencies = [
"heck 0.4.1",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
+ "rustversion",
+ "syn 2.0.53",
+]
+
+[[package]]
+name = "strum_macros"
+version = "0.26.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c6cf59daf282c0a494ba14fd21610a0325f9f90ec9d1231dea26bcb1d696c946"
+dependencies = [
+ "heck 0.4.1",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"rustversion",
"syn 2.0.53",
]
@@ -19877,6 +20659,49 @@ dependencies = [
"tokio",
]
+[[package]]
+name = "substrate-relay-helper"
+version = "0.1.0"
+dependencies = [
+ "anyhow",
+ "async-std",
+ "async-trait",
+ "bp-header-chain",
+ "bp-messages",
+ "bp-parachains",
+ "bp-polkadot-core",
+ "bp-relayers",
+ "bp-runtime",
+ "bridge-runtime-common",
+ "equivocation-detector",
+ "finality-grandpa",
+ "finality-relay",
+ "frame-support",
+ "frame-system",
+ "futures",
+ "hex",
+ "log",
+ "messages-relay",
+ "num-traits",
+ "pallet-balances",
+ "pallet-bridge-grandpa",
+ "pallet-bridge-messages",
+ "pallet-bridge-parachains",
+ "pallet-grandpa",
+ "pallet-transaction-payment",
+ "parachains-relay",
+ "parity-scale-codec",
+ "rbtag",
+ "relay-substrate-client",
+ "relay-utils",
+ "sp-consensus-grandpa",
+ "sp-core",
+ "sp-runtime",
+ "structopt",
+ "strum 0.26.2",
+ "thiserror",
+]
+
[[package]]
name = "substrate-rpc-client"
version = "0.33.0"
@@ -19944,6 +20769,7 @@ dependencies = [
"frame-system",
"frame-system-rpc-runtime-api",
"futures",
+ "hex-literal",
"log",
"pallet-babe",
"pallet-balances",
@@ -20037,7 +20863,7 @@ dependencies = [
"parity-wasm",
"polkavm-linker",
"sp-maybe-compressed-blob",
- "strum 0.24.1",
+ "strum 0.26.2",
"tempfile",
"toml 0.8.8",
"walkdir",
@@ -20153,14 +20979,25 @@ dependencies = [
"symbolic-common",
]
+[[package]]
+name = "syn"
+version = "0.15.44"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9ca4b3b69a77cbe1ffc9e198781b7acb0c7365a883670e8f1c1bc66fba79a5c5"
+dependencies = [
+ "proc-macro2 0.4.30",
+ "quote 0.6.13",
+ "unicode-xid 0.1.0",
+]
+
[[package]]
name = "syn"
version = "1.0.109"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"unicode-ident",
]
@@ -20170,8 +21007,8 @@ version = "2.0.53"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7383cd0e49fff4b6b90ca5670bfd3e9d6a733b3f90c686605aa7eec8c4996032"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"unicode-ident",
]
@@ -20182,8 +21019,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "86b837ef12ab88835251726eb12237655e61ec8dc8a280085d1961cdc3dfd047"
dependencies = [
"paste",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -20193,10 +21030,25 @@ version = "0.12.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f36bdaa60a83aca3921b5259d5400cbf5e90fc51931376a9bd4a0eb79aa7210f"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
- "unicode-xid",
+ "unicode-xid 0.2.4",
+]
+
+[[package]]
+name = "sysinfo"
+version = "0.30.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1fb4f3438c8f6389c864e61221cbc97e9bca98b4daf39a5beb7bea660f528bb2"
+dependencies = [
+ "cfg-if",
+ "core-foundation-sys",
+ "libc",
+ "ntapi",
+ "once_cell",
+ "rayon",
+ "windows 0.52.0",
]
[[package]]
@@ -20406,6 +21258,15 @@ dependencies = [
"westend-runtime-constants",
]
+[[package]]
+name = "textwrap"
+version = "0.11.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d326610f408c7a4eb6f51c37c330e496b08506c9457c9d34287ecc38809fb060"
+dependencies = [
+ "unicode-width",
+]
+
[[package]]
name = "textwrap"
version = "0.16.0"
@@ -20436,8 +21297,8 @@ version = "1.0.38"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "10ac1c5050e43014d16b2f94d0d2ce79e65ffdd8b38d8048f9c8f6a8a6da62ac"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 1.0.109",
]
@@ -20447,8 +21308,8 @@ version = "1.0.50"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -20529,6 +21390,8 @@ checksum = "0bb39ee79a6d8de55f48f2293a830e040392f1c5f16e336bdd1788cd0aadce07"
dependencies = [
"deranged",
"itoa",
+ "libc",
+ "num_threads",
"serde",
"time-core",
"time-macros",
@@ -20585,9 +21448,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20"
[[package]]
name = "tokio"
-version = "1.33.0"
+version = "1.37.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4f38200e3ef7995e5ef13baec2f432a6da0aa9ac495b2c0e8f3b7eec2c92d653"
+checksum = "1adbebffeca75fcfd058afa480fb6c0b81e165a0323f9c9d39c9697e37c46787"
dependencies = [
"backtrace",
"bytes",
@@ -20597,19 +21460,19 @@ dependencies = [
"parking_lot 0.12.1",
"pin-project-lite 0.2.12",
"signal-hook-registry",
- "socket2 0.5.3",
+ "socket2 0.5.6",
"tokio-macros",
"windows-sys 0.48.0",
]
[[package]]
name = "tokio-macros"
-version = "2.1.0"
+version = "2.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e"
+checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -20620,7 +21483,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7f57eb36ecbe0fc510036adff84824dd3c24bb781e21bfa67b69d556aa85214f"
dependencies = [
"pin-project",
- "rand",
+ "rand 0.8.5",
"tokio",
]
@@ -20679,7 +21542,22 @@ dependencies = [
"futures-util",
"log",
"tokio",
- "tungstenite",
+ "tungstenite 0.17.3",
+]
+
+[[package]]
+name = "tokio-tungstenite"
+version = "0.20.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "212d5dcb2a1ce06d81107c3d0ffa3121fe974b73f068c8282cb1c32328113b6c"
+dependencies = [
+ "futures-util",
+ "log",
+ "rustls 0.21.6",
+ "rustls-native-certs 0.6.3",
+ "tokio",
+ "tokio-rustls 0.24.1",
+ "tungstenite 0.20.1",
]
[[package]]
@@ -20798,11 +21676,10 @@ checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52"
[[package]]
name = "tracing"
-version = "0.1.37"
+version = "0.1.40"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8"
+checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef"
dependencies = [
- "cfg-if",
"log",
"pin-project-lite 0.2.12",
"tracing-attributes",
@@ -20811,12 +21688,12 @@ dependencies = [
[[package]]
name = "tracing-attributes"
-version = "0.1.26"
+version = "0.1.27"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5f4f31f56159e98206da9efd823404b79b6ef3143b4a7ab76e67b1751b25a4ab"
+checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -20857,8 +21734,8 @@ dependencies = [
"assert_matches",
"expander 2.0.0",
"proc-macro-crate 3.0.0",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -20904,7 +21781,6 @@ dependencies = [
"chrono",
"lazy_static",
"matchers 0.0.1",
- "parking_lot 0.11.2",
"regex",
"serde",
"serde_json",
@@ -20923,9 +21799,11 @@ version = "0.3.18"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ad0f048c97dbd9faa9b7df56362b8ebcaa52adb06b498c050d2f4e32f90a7a8b"
dependencies = [
+ "chrono",
"matchers 0.1.0",
"nu-ansi-term",
"once_cell",
+ "parking_lot 0.12.1",
"regex",
"sharded-slab",
"smallvec",
@@ -20937,11 +21815,11 @@ dependencies = [
[[package]]
name = "trie-bench"
-version = "0.38.0"
+version = "0.39.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a4680cb226e31d2a096592d0edecdda91cc371743002f80c0f8cf80219819b3b"
+checksum = "3092f400e9f7e3ce8c1756016a8b6287163ab7a11dd47d82169260cb4cc2d680"
dependencies = [
- "criterion 0.4.0",
+ "criterion 0.5.1",
"hash-db",
"keccak-hasher",
"memory-db",
@@ -20953,12 +21831,11 @@ dependencies = [
[[package]]
name = "trie-db"
-version = "0.28.0"
+version = "0.29.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ff28e0f815c2fea41ebddf148e008b077d2faddb026c9555b29696114d602642"
+checksum = "65ed83be775d85ebb0e272914fff6462c39b3ddd6dc67b5c1c41271aad280c69"
dependencies = [
"hash-db",
- "hashbrown 0.13.2",
"log",
"rustc-hex",
"smallvec",
@@ -20992,14 +21869,14 @@ dependencies = [
"async-trait",
"cfg-if",
"data-encoding",
- "enum-as-inner",
+ "enum-as-inner 0.5.1",
"futures-channel",
"futures-io",
"futures-util",
"idna 0.2.3",
"ipnet",
"lazy_static",
- "rand",
+ "rand 0.8.5",
"smallvec",
"socket2 0.4.9",
"thiserror",
@@ -21009,6 +21886,31 @@ dependencies = [
"url",
]
+[[package]]
+name = "trust-dns-proto"
+version = "0.23.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3119112651c157f4488931a01e586aa459736e9d6046d3bd9105ffb69352d374"
+dependencies = [
+ "async-trait",
+ "cfg-if",
+ "data-encoding",
+ "enum-as-inner 0.6.0",
+ "futures-channel",
+ "futures-io",
+ "futures-util",
+ "idna 0.4.0",
+ "ipnet",
+ "once_cell",
+ "rand 0.8.5",
+ "smallvec",
+ "thiserror",
+ "tinyvec",
+ "tokio",
+ "tracing",
+ "url",
+]
+
[[package]]
name = "trust-dns-resolver"
version = "0.22.0"
@@ -21026,56 +21928,36 @@ dependencies = [
"thiserror",
"tokio",
"tracing",
- "trust-dns-proto",
+ "trust-dns-proto 0.22.0",
]
[[package]]
-name = "try-lock"
-version = "0.2.4"
+name = "trust-dns-resolver"
+version = "0.23.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed"
-
-[[package]]
-name = "try-runtime-cli"
-version = "0.38.0"
+checksum = "10a3e6c3aff1718b3c73e395d1f35202ba2ffa847c6a62eea0db8fb4cfe30be6"
dependencies = [
- "assert_cmd",
- "async-trait",
- "clap 4.5.3",
- "frame-remote-externalities",
- "frame-try-runtime",
- "hex",
- "log",
- "node-primitives",
- "parity-scale-codec",
- "regex",
- "sc-cli",
- "sc-executor",
- "serde",
- "serde_json",
- "sp-api",
- "sp-consensus-aura",
- "sp-consensus-babe",
- "sp-core",
- "sp-debug-derive 14.0.0",
- "sp-externalities 0.25.0",
- "sp-inherents",
- "sp-io",
- "sp-keystore",
- "sp-rpc",
- "sp-runtime",
- "sp-state-machine",
- "sp-timestamp",
- "sp-transaction-storage-proof",
- "sp-version",
- "sp-weights",
- "substrate-cli-test-utils",
- "substrate-rpc-client",
- "tempfile",
+ "cfg-if",
+ "futures-util",
+ "ipconfig",
+ "lru-cache",
+ "once_cell",
+ "parking_lot 0.12.1",
+ "rand 0.8.5",
+ "resolv-conf",
+ "smallvec",
+ "thiserror",
"tokio",
- "zstd 0.12.4",
+ "tracing",
+ "trust-dns-proto 0.23.2",
]
+[[package]]
+name = "try-lock"
+version = "0.2.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed"
+
[[package]]
name = "trybuild"
version = "1.0.89"
@@ -21110,13 +21992,33 @@ dependencies = [
"http",
"httparse",
"log",
- "rand",
+ "rand 0.8.5",
"sha-1 0.10.1",
"thiserror",
"url",
"utf-8",
]
+[[package]]
+name = "tungstenite"
+version = "0.20.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9e3dac10fd62eaf6617d3a904ae222845979aec67c615d1c842b4002c7666fb9"
+dependencies = [
+ "byteorder",
+ "bytes",
+ "data-encoding",
+ "http",
+ "httparse",
+ "log",
+ "rand 0.8.5",
+ "rustls 0.21.6",
+ "sha1",
+ "thiserror",
+ "url",
+ "utf-8",
+]
+
[[package]]
name = "twox-hash"
version = "1.6.3"
@@ -21125,7 +22027,7 @@ checksum = "97fee6b57c6a41524a810daee9286c02d7752c4253064d0b05472833a438f675"
dependencies = [
"cfg-if",
"digest 0.10.7",
- "rand",
+ "rand 0.8.5",
"static_assertions",
]
@@ -21180,12 +22082,24 @@ dependencies = [
"tinyvec",
]
+[[package]]
+name = "unicode-segmentation"
+version = "1.11.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202"
+
[[package]]
name = "unicode-width"
version = "0.1.10"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c0edd1e5b14653f783770bce4a4dabb4a5108a5370a5f5d8cfe8710c361f6c8b"
+[[package]]
+name = "unicode-xid"
+version = "0.1.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "fc72304796d0818e357ead4e000d19c9c174ab23dc11093ac919054d20a6a7fc"
+
[[package]]
name = "unicode-xid"
version = "0.2.4"
@@ -21220,14 +22134,15 @@ checksum = "673aac59facbab8a9007c7f6108d11f63b603f7cabff99fabf650fea5c32b861"
[[package]]
name = "unsigned-varint"
-version = "0.7.1"
+version = "0.7.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d86a8dc7f45e4c1b0d30e43038c38f274e77af056aa5f74b93c2cf9eb3c1c836"
+checksum = "6889a77d49f1f013504cec6bf97a2c730394adedaeb1deb5ea08949a50541105"
dependencies = [
"asynchronous-codec",
"bytes",
"futures-io",
"futures-util",
+ "tokio-util",
]
[[package]]
@@ -21319,6 +22234,12 @@ version = "0.2.15"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426"
+[[package]]
+name = "vec_map"
+version = "0.8.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f1bddf1187be692e79c5ffeab891132dfb0f236ed36a43c7ed39f1165ee20191"
+
[[package]]
name = "version_check"
version = "0.9.4"
@@ -21346,7 +22267,7 @@ dependencies = [
"arrayref",
"constcat",
"digest 0.10.7",
- "rand",
+ "rand 0.8.5",
"rand_chacha 0.3.1",
"rand_core 0.6.4",
"sha2 0.10.7",
@@ -21422,8 +22343,8 @@ dependencies = [
"bumpalo",
"log",
"once_cell",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
"wasm-bindgen-shared",
]
@@ -21446,7 +22367,7 @@ version = "0.2.87"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d"
dependencies = [
- "quote",
+ "quote 1.0.35",
"wasm-bindgen-macro-support",
]
@@ -21456,8 +22377,8 @@ version = "0.2.87"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
"wasm-bindgen-backend",
"wasm-bindgen-shared",
@@ -21489,8 +22410,8 @@ version = "0.3.37"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ecb993dd8c836930ed130e020e77d9b2e65dd0fbab1b67c790b0f5d80b11a575"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
]
[[package]]
@@ -21791,7 +22712,7 @@ dependencies = [
"memfd",
"memoffset 0.8.0",
"paste",
- "rand",
+ "rand 0.8.5",
"rustix 0.36.15",
"wasmtime-asm-macros",
"wasmtime-environ",
@@ -21919,7 +22840,6 @@ dependencies = [
"pallet-fast-unstake",
"pallet-grandpa",
"pallet-identity",
- "pallet-im-online",
"pallet-indices",
"pallet-membership",
"pallet-message-queue",
@@ -21994,6 +22914,7 @@ dependencies = [
"tiny-keccak",
"tokio",
"westend-runtime-constants",
+ "xcm-fee-payment-runtime-api",
]
[[package]]
@@ -22104,6 +23025,40 @@ dependencies = [
"windows-targets 0.48.5",
]
+[[package]]
+name = "windows"
+version = "0.52.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e48a53791691ab099e5e2ad123536d0fff50652600abaf43bbf952894110d0be"
+dependencies = [
+ "windows-core",
+ "windows-targets 0.52.0",
+]
+
+[[package]]
+name = "windows-core"
+version = "0.52.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "33ab640c8d7e35bf8ba19b884ba838ceb4fba93a4e8c65a9059d08afcfc683d9"
+dependencies = [
+ "windows-targets 0.52.0",
+]
+
+[[package]]
+name = "windows-sys"
+version = "0.42.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7"
+dependencies = [
+ "windows_aarch64_gnullvm 0.42.2",
+ "windows_aarch64_msvc 0.42.2",
+ "windows_i686_gnu 0.42.2",
+ "windows_i686_msvc 0.42.2",
+ "windows_x86_64_gnu 0.42.2",
+ "windows_x86_64_gnullvm 0.42.2",
+ "windows_x86_64_msvc 0.42.2",
+]
+
[[package]]
name = "windows-sys"
version = "0.45.0"
@@ -22401,6 +23356,23 @@ dependencies = [
"time",
]
+[[package]]
+name = "x509-parser"
+version = "0.15.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7069fba5b66b9193bd2c5d3d4ff12b839118f6bcbef5328efafafb5395cf63da"
+dependencies = [
+ "asn1-rs",
+ "data-encoding",
+ "der-parser",
+ "lazy_static",
+ "nom",
+ "oid-registry",
+ "rusticata-macros",
+ "thiserror",
+ "time",
+]
+
[[package]]
name = "xattr"
version = "1.0.1"
@@ -22467,13 +23439,27 @@ dependencies = [
"staging-xcm-executor",
]
+[[package]]
+name = "xcm-fee-payment-runtime-api"
+version = "0.1.0"
+dependencies = [
+ "frame-support",
+ "parity-scale-codec",
+ "scale-info",
+ "sp-api",
+ "sp-runtime",
+ "sp-std 14.0.0",
+ "sp-weights",
+ "staging-xcm",
+]
+
[[package]]
name = "xcm-procedural"
version = "7.0.0"
dependencies = [
"Inflector",
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"staging-xcm",
"syn 2.0.53",
"trybuild",
@@ -22561,7 +23547,7 @@ dependencies = [
"log",
"nohash-hasher",
"parking_lot 0.12.1",
- "rand",
+ "rand 0.8.5",
"static_assertions",
]
@@ -22595,8 +23581,8 @@ version = "0.7.32"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -22615,8 +23601,8 @@ version = "1.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69"
dependencies = [
- "proc-macro2",
- "quote",
+ "proc-macro2 1.0.75",
+ "quote 1.0.35",
"syn 2.0.53",
]
@@ -22632,7 +23618,7 @@ dependencies = [
"serde_json",
"thiserror",
"tokio",
- "tokio-tungstenite",
+ "tokio-tungstenite 0.17.2",
"tracing-gum",
"url",
]
diff --git a/Cargo.toml b/Cargo.toml
index 94024e3a1c9b67ed824ad8f81077d444941ef6d9..019e26786780f632cc5ec67d769be9e5bc39157a 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -10,24 +10,26 @@ resolver = "2"
members = [
"bridges/bin/runtime-common",
+ "bridges/chains/chain-asset-hub-rococo",
+ "bridges/chains/chain-asset-hub-westend",
+ "bridges/chains/chain-bridge-hub-cumulus",
+ "bridges/chains/chain-bridge-hub-kusama",
+ "bridges/chains/chain-bridge-hub-polkadot",
+ "bridges/chains/chain-bridge-hub-rococo",
+ "bridges/chains/chain-bridge-hub-westend",
+ "bridges/chains/chain-kusama",
+ "bridges/chains/chain-polkadot",
+ "bridges/chains/chain-polkadot-bulletin",
+ "bridges/chains/chain-rococo",
+ "bridges/chains/chain-westend",
+ "bridges/modules/beefy",
"bridges/modules/grandpa",
"bridges/modules/messages",
"bridges/modules/parachains",
"bridges/modules/relayers",
"bridges/modules/xcm-bridge-hub",
"bridges/modules/xcm-bridge-hub-router",
- "bridges/primitives/chain-asset-hub-rococo",
- "bridges/primitives/chain-asset-hub-westend",
- "bridges/primitives/chain-bridge-hub-cumulus",
- "bridges/primitives/chain-bridge-hub-kusama",
- "bridges/primitives/chain-bridge-hub-polkadot",
- "bridges/primitives/chain-bridge-hub-rococo",
- "bridges/primitives/chain-bridge-hub-westend",
- "bridges/primitives/chain-kusama",
- "bridges/primitives/chain-polkadot",
- "bridges/primitives/chain-polkadot-bulletin",
- "bridges/primitives/chain-rococo",
- "bridges/primitives/chain-westend",
+ "bridges/primitives/beefy",
"bridges/primitives/header-chain",
"bridges/primitives/messages",
"bridges/primitives/parachains",
@@ -37,6 +39,13 @@ members = [
"bridges/primitives/test-utils",
"bridges/primitives/xcm-bridge-hub",
"bridges/primitives/xcm-bridge-hub-router",
+ "bridges/relays/client-substrate",
+ "bridges/relays/equivocation",
+ "bridges/relays/finality",
+ "bridges/relays/lib-substrate-relay",
+ "bridges/relays/messages",
+ "bridges/relays/parachains",
+ "bridges/relays/utils",
"bridges/snowbridge/pallets/ethereum-client",
"bridges/snowbridge/pallets/ethereum-client/fixtures",
"bridges/snowbridge/pallets/inbound-queue",
@@ -214,6 +223,7 @@ members = [
"polkadot/xcm/xcm-builder",
"polkadot/xcm/xcm-executor",
"polkadot/xcm/xcm-executor/integration-tests",
+ "polkadot/xcm/xcm-fee-payment-runtime-api",
"polkadot/xcm/xcm-simulator",
"polkadot/xcm/xcm-simulator/example",
"polkadot/xcm/xcm-simulator/fuzzer",
@@ -259,13 +269,13 @@ members = [
"substrate/client/mixnet",
"substrate/client/network",
"substrate/client/network-gossip",
- "substrate/client/network/bitswap",
"substrate/client/network/common",
"substrate/client/network/light",
"substrate/client/network/statement",
"substrate/client/network/sync",
"substrate/client/network/test",
"substrate/client/network/transactions",
+ "substrate/client/network/types",
"substrate/client/offchain",
"substrate/client/proposer-metrics",
"substrate/client/rpc",
@@ -331,6 +341,7 @@ members = [
"substrate/frame/examples/dev-mode",
"substrate/frame/examples/frame-crate",
"substrate/frame/examples/kitchensink",
+ "substrate/frame/examples/multi-block-migrations",
"substrate/frame/examples/offchain-worker",
"substrate/frame/examples/single-block-migrations",
"substrate/frame/examples/split",
@@ -491,12 +502,12 @@ members = [
"substrate/utils/frame/frame-utilities-cli",
"substrate/utils/frame/generate-bags",
"substrate/utils/frame/generate-bags/node-runtime",
+ "substrate/utils/frame/omni-bencher",
"substrate/utils/frame/remote-externalities",
"substrate/utils/frame/rpc/client",
"substrate/utils/frame/rpc/state-trie-migration-rpc",
"substrate/utils/frame/rpc/support",
"substrate/utils/frame/rpc/system",
- "substrate/utils/frame/try-runtime/cli",
"substrate/utils/prometheus",
"substrate/utils/substrate-bip39",
"substrate/utils/wasm-builder",
@@ -557,6 +568,7 @@ serde_json = { version = "1.0.114", default-features = false }
serde_yaml = { version = "0.9" }
syn = { version = "2.0.53" }
thiserror = { version = "1.0.48" }
+tracing-subscriber = { version = "0.3.18" }
[profile.release]
# Polkadot runtime requires unwinding.
diff --git a/bridges/.gitignore b/bridges/.gitignore
deleted file mode 100644
index 5d10cfa41a4487247e2c331144d3dabf0ec5e6f7..0000000000000000000000000000000000000000
--- a/bridges/.gitignore
+++ /dev/null
@@ -1,26 +0,0 @@
-**/target/
-**/.env
-**/.env2
-**/rust-toolchain
-hfuzz_target
-hfuzz_workspace
-**/Cargo.lock
-
-**/*.rs.bk
-
-*.o
-*.so
-*.rlib
-*.dll
-.gdb_history
-
-*.exe
-
-.DS_Store
-
-.cargo
-.idea
-.vscode
-*.iml
-*.swp
-*.swo
diff --git a/bridges/README.md b/bridges/README.md
index a2ce213d2541c346361eb28125a06e3079e1c269..8bfa39841f51e7824d0f1169540342c2bd88b664 100644
--- a/bridges/README.md
+++ b/bridges/README.md
@@ -38,10 +38,10 @@ cargo test --all
```
Also you can build the repo with [Parity CI Docker
-image](https://github.com/paritytech/scripts/tree/master/dockerfiles/bridges-ci):
+image](https://github.com/paritytech/scripts/tree/master/dockerfiles/ci-unified):
```bash
-docker pull paritytech/bridges-ci:production
+docker pull paritytech/ci-unified:latest
mkdir ~/cache
chown 1000:1000 ~/cache #processes in the container runs as "nonroot" user with UID 1000
docker run --rm -it -w /shellhere/parity-bridges-common \
@@ -49,7 +49,7 @@ docker run --rm -it -w /shellhere/parity-bridges-common \
-v "$(pwd)":/shellhere/parity-bridges-common \
-e CARGO_HOME=/cache/cargo/ \
-e SCCACHE_DIR=/cache/sccache/ \
- -e CARGO_TARGET_DIR=/cache/target/ paritytech/bridges-ci:production cargo build --all
+ -e CARGO_TARGET_DIR=/cache/target/ paritytech/ci-unified:latest cargo build --all
#artifacts can be found in ~/cache/target
```
diff --git a/bridges/bin/runtime-common/Cargo.toml b/bridges/bin/runtime-common/Cargo.toml
index fac88b20ca57901d4116e147bd9363a41ff35e36..67b91a16a302d6214830241082b21c407b04c6d1 100644
--- a/bridges/bin/runtime-common/Cargo.toml
+++ b/bridges/bin/runtime-common/Cargo.toml
@@ -11,10 +11,10 @@ license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
workspace = true
[dependencies]
-codec = { package = "parity-scale-codec", version = "3.1.5", default-features = false, features = ["derive"] }
+codec = { package = "parity-scale-codec", version = "3.6.1", default-features = false, features = ["derive"] }
hash-db = { version = "0.16.0", default-features = false }
log = { workspace = true }
-scale-info = { version = "2.10.0", default-features = false, features = ["derive"] }
+scale-info = { version = "2.11.1", default-features = false, features = ["derive"] }
static_assertions = { version = "1.1", optional = true }
# Bridge dependencies
diff --git a/bridges/bin/runtime-common/src/extensions/check_obsolete_extension.rs b/bridges/bin/runtime-common/src/extensions/check_obsolete_extension.rs
new file mode 100644
index 0000000000000000000000000000000000000000..4b0c052df8008410cb531c21d173ead2c4fdd450
--- /dev/null
+++ b/bridges/bin/runtime-common/src/extensions/check_obsolete_extension.rs
@@ -0,0 +1,205 @@
+// 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 .
+
+//! Transaction extension that rejects bridge-related transactions, that include
+//! obsolete (duplicated) data or do not pass some additional pallet-specific
+//! checks.
+
+use crate::messages_call_ext::MessagesCallSubType;
+use pallet_bridge_grandpa::CallSubType as GrandpaCallSubType;
+use pallet_bridge_parachains::CallSubType as ParachainsCallSubtype;
+use sp_runtime::transaction_validity::TransactionValidity;
+
+/// A duplication of the `FilterCall` trait.
+///
+/// We need this trait in order to be able to implement it for the messages pallet,
+/// since the implementation is done outside of the pallet crate.
+pub trait BridgeRuntimeFilterCall {
+ /// Checks if a runtime call is valid.
+ fn validate(call: &Call) -> TransactionValidity;
+}
+
+impl BridgeRuntimeFilterCall for pallet_bridge_grandpa::Pallet
+where
+ T: pallet_bridge_grandpa::Config,
+ T::RuntimeCall: GrandpaCallSubType,
+{
+ fn validate(call: &T::RuntimeCall) -> TransactionValidity {
+ GrandpaCallSubType::::check_obsolete_submit_finality_proof(call)
+ }
+}
+
+impl BridgeRuntimeFilterCall
+ for pallet_bridge_parachains::Pallet
+where
+ T: pallet_bridge_parachains::Config,
+ T::RuntimeCall: ParachainsCallSubtype,
+{
+ fn validate(call: &T::RuntimeCall) -> TransactionValidity {
+ ParachainsCallSubtype::::check_obsolete_submit_parachain_heads(call)
+ }
+}
+
+impl, I: 'static> BridgeRuntimeFilterCall
+ for pallet_bridge_messages::Pallet
+where
+ T::RuntimeCall: MessagesCallSubType,
+{
+ /// Validate messages in order to avoid "mining" messages delivery and delivery confirmation
+ /// transactions, that are delivering outdated messages/confirmations. Without this validation,
+ /// even honest relayers may lose their funds if there are multiple relays running and
+ /// submitting the same messages/confirmations.
+ fn validate(call: &T::RuntimeCall) -> TransactionValidity {
+ call.check_obsolete_call()
+ }
+}
+
+/// Declares a runtime-specific `BridgeRejectObsoleteHeadersAndMessages` signed extension.
+///
+/// ## Example
+///
+/// ```nocompile
+/// generate_bridge_reject_obsolete_headers_and_messages!{
+/// Call, AccountId
+/// BridgeRococoGrandpa, BridgeRococoMessages,
+/// BridgeRococoParachains
+/// }
+/// ```
+///
+/// The goal of this extension is to avoid "mining" transactions that provide outdated bridged
+/// headers and messages. Without that extension, even honest relayers may lose their funds if
+/// there are multiple relays running and submitting the same information.
+#[macro_export]
+macro_rules! generate_bridge_reject_obsolete_headers_and_messages {
+ ($call:ty, $account_id:ty, $($filter_call:ty),*) => {
+ #[derive(Clone, codec::Decode, Default, codec::Encode, Eq, PartialEq, sp_runtime::RuntimeDebug, scale_info::TypeInfo)]
+ pub struct BridgeRejectObsoleteHeadersAndMessages;
+ impl sp_runtime::traits::SignedExtension for BridgeRejectObsoleteHeadersAndMessages {
+ const IDENTIFIER: &'static str = "BridgeRejectObsoleteHeadersAndMessages";
+ type AccountId = $account_id;
+ type Call = $call;
+ type AdditionalSigned = ();
+ type Pre = ();
+
+ fn additional_signed(&self) -> sp_std::result::Result<
+ (),
+ sp_runtime::transaction_validity::TransactionValidityError,
+ > {
+ Ok(())
+ }
+
+ fn validate(
+ &self,
+ _who: &Self::AccountId,
+ call: &Self::Call,
+ _info: &sp_runtime::traits::DispatchInfoOf,
+ _len: usize,
+ ) -> sp_runtime::transaction_validity::TransactionValidity {
+ let valid = sp_runtime::transaction_validity::ValidTransaction::default();
+ $(
+ let valid = valid
+ .combine_with(<$filter_call as $crate::extensions::check_obsolete_extension::BridgeRuntimeFilterCall<$call>>::validate(call)?);
+ )*
+ Ok(valid)
+ }
+
+ fn pre_dispatch(
+ self,
+ who: &Self::AccountId,
+ call: &Self::Call,
+ info: &sp_runtime::traits::DispatchInfoOf,
+ len: usize,
+ ) -> Result {
+ self.validate(who, call, info, len).map(drop)
+ }
+ }
+ };
+}
+
+#[cfg(test)]
+mod tests {
+ use super::*;
+ use frame_support::{assert_err, assert_ok};
+ use sp_runtime::{
+ traits::SignedExtension,
+ transaction_validity::{InvalidTransaction, TransactionValidity, ValidTransaction},
+ };
+
+ pub struct MockCall {
+ data: u32,
+ }
+
+ impl sp_runtime::traits::Dispatchable for MockCall {
+ type RuntimeOrigin = ();
+ type Config = ();
+ type Info = ();
+ type PostInfo = ();
+
+ fn dispatch(
+ self,
+ _origin: Self::RuntimeOrigin,
+ ) -> sp_runtime::DispatchResultWithInfo {
+ unimplemented!()
+ }
+ }
+
+ struct FirstFilterCall;
+ impl BridgeRuntimeFilterCall for FirstFilterCall {
+ fn validate(call: &MockCall) -> TransactionValidity {
+ if call.data <= 1 {
+ return InvalidTransaction::Custom(1).into()
+ }
+
+ Ok(ValidTransaction { priority: 1, ..Default::default() })
+ }
+ }
+
+ struct SecondFilterCall;
+ impl BridgeRuntimeFilterCall for SecondFilterCall {
+ fn validate(call: &MockCall) -> TransactionValidity {
+ if call.data <= 2 {
+ return InvalidTransaction::Custom(2).into()
+ }
+
+ Ok(ValidTransaction { priority: 2, ..Default::default() })
+ }
+ }
+
+ #[test]
+ fn test() {
+ generate_bridge_reject_obsolete_headers_and_messages!(
+ MockCall,
+ (),
+ FirstFilterCall,
+ SecondFilterCall
+ );
+
+ assert_err!(
+ BridgeRejectObsoleteHeadersAndMessages.validate(&(), &MockCall { data: 1 }, &(), 0),
+ InvalidTransaction::Custom(1)
+ );
+
+ assert_err!(
+ BridgeRejectObsoleteHeadersAndMessages.validate(&(), &MockCall { data: 2 }, &(), 0),
+ InvalidTransaction::Custom(2)
+ );
+
+ assert_ok!(
+ BridgeRejectObsoleteHeadersAndMessages.validate(&(), &MockCall { data: 3 }, &(), 0),
+ ValidTransaction { priority: 3, ..Default::default() }
+ )
+ }
+}
diff --git a/bridges/bin/runtime-common/src/extensions/mod.rs b/bridges/bin/runtime-common/src/extensions/mod.rs
new file mode 100644
index 0000000000000000000000000000000000000000..3f1b506aaae3ef66fe6f44379258356a2074464c
--- /dev/null
+++ b/bridges/bin/runtime-common/src/extensions/mod.rs
@@ -0,0 +1,21 @@
+// 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 .
+
+//! Bridge-specific transaction extensions.
+
+pub mod check_obsolete_extension;
+pub mod priority_calculator;
+pub mod refund_relayer_extension;
diff --git a/bridges/bin/runtime-common/src/priority_calculator.rs b/bridges/bin/runtime-common/src/extensions/priority_calculator.rs
similarity index 99%
rename from bridges/bin/runtime-common/src/priority_calculator.rs
rename to bridges/bin/runtime-common/src/extensions/priority_calculator.rs
index c2737128e3422dd72ca3b49d66151268d719e0bc..5035553f508dfea94a0cb5ddf9b916dd7d9b4ea5 100644
--- a/bridges/bin/runtime-common/src/priority_calculator.rs
+++ b/bridges/bin/runtime-common/src/extensions/priority_calculator.rs
@@ -163,7 +163,7 @@ mod integrity_tests {
{
// just an estimation of extra transaction bytes that are added to every transaction
// (including signature, signed extensions extra and etc + in our case it includes
- // all call arguments extept the proof itself)
+ // all call arguments except the proof itself)
let base_tx_size = 512;
// let's say we are relaying similar small messages and for every message we add more trie
// nodes to the proof (x0.5 because we expect some nodes to be reused)
diff --git a/bridges/bin/runtime-common/src/refund_relayer_extension.rs b/bridges/bin/runtime-common/src/extensions/refund_relayer_extension.rs
similarity index 99%
rename from bridges/bin/runtime-common/src/refund_relayer_extension.rs
rename to bridges/bin/runtime-common/src/extensions/refund_relayer_extension.rs
index 8e901d72821fe1dfb749f4227c2875f1d807fccc..f97b23ecaaa99fdaed0a54d00b2b89c14847750a 100644
--- a/bridges/bin/runtime-common/src/refund_relayer_extension.rs
+++ b/bridges/bin/runtime-common/src/extensions/refund_relayer_extension.rs
@@ -520,8 +520,9 @@ where
}
// compute priority boost
- let priority_boost =
- crate::priority_calculator::compute_priority_boost::(bundled_messages);
+ let priority_boost = crate::extensions::priority_calculator::compute_priority_boost::<
+ T::Priority,
+ >(bundled_messages);
let valid_transaction = ValidTransactionBuilder::default().priority(priority_boost);
log::trace!(
@@ -1538,7 +1539,7 @@ mod tests {
}
#[test]
- fn validate_boosts_priority_of_message_delivery_transactons() {
+ fn validate_boosts_priority_of_message_delivery_transactions() {
run_test(|| {
initialize_environment(100, 100, 100);
@@ -1568,7 +1569,7 @@ mod tests {
}
#[test]
- fn validate_does_not_boost_priority_of_message_delivery_transactons_with_too_many_messages() {
+ fn validate_does_not_boost_priority_of_message_delivery_transactions_with_too_many_messages() {
run_test(|| {
initialize_environment(100, 100, 100);
diff --git a/bridges/bin/runtime-common/src/lib.rs b/bridges/bin/runtime-common/src/lib.rs
index 2722f6f1c6d14f09ab215f8f020f2c449eda4d4b..5679acd6006ccb8540f940f0f90363f902d643f7 100644
--- a/bridges/bin/runtime-common/src/lib.rs
+++ b/bridges/bin/runtime-common/src/lib.rs
@@ -19,11 +19,7 @@
#![warn(missing_docs)]
#![cfg_attr(not(feature = "std"), no_std)]
-use crate::messages_call_ext::MessagesCallSubType;
-use pallet_bridge_grandpa::CallSubType as GrandpaCallSubType;
-use pallet_bridge_parachains::CallSubType as ParachainsCallSubtype;
-use sp_runtime::transaction_validity::TransactionValidity;
-
+pub mod extensions;
pub mod messages;
pub mod messages_api;
pub mod messages_benchmarking;
@@ -31,8 +27,6 @@ pub mod messages_call_ext;
pub mod messages_generation;
pub mod messages_xcm_extension;
pub mod parachains_benchmarking;
-pub mod priority_calculator;
-pub mod refund_relayer_extension;
mod mock;
@@ -40,184 +34,3 @@ mod mock;
pub mod integrity;
const LOG_TARGET_BRIDGE_DISPATCH: &str = "runtime::bridge-dispatch";
-
-/// A duplication of the `FilterCall` trait.
-///
-/// We need this trait in order to be able to implement it for the messages pallet,
-/// since the implementation is done outside of the pallet crate.
-pub trait BridgeRuntimeFilterCall {
- /// Checks if a runtime call is valid.
- fn validate(call: &Call) -> TransactionValidity;
-}
-
-impl BridgeRuntimeFilterCall for pallet_bridge_grandpa::Pallet
-where
- T: pallet_bridge_grandpa::Config,
- T::RuntimeCall: GrandpaCallSubType,
-{
- fn validate(call: &T::RuntimeCall) -> TransactionValidity {
- GrandpaCallSubType::::check_obsolete_submit_finality_proof(call)
- }
-}
-
-impl BridgeRuntimeFilterCall
- for pallet_bridge_parachains::Pallet
-where
- T: pallet_bridge_parachains::Config,
- T::RuntimeCall: ParachainsCallSubtype,
-{
- fn validate(call: &T::RuntimeCall) -> TransactionValidity {
- ParachainsCallSubtype::::check_obsolete_submit_parachain_heads(call)
- }
-}
-
-impl, I: 'static> BridgeRuntimeFilterCall
- for pallet_bridge_messages::Pallet
-where
- T::RuntimeCall: MessagesCallSubType,
-{
- /// Validate messages in order to avoid "mining" messages delivery and delivery confirmation
- /// transactions, that are delivering outdated messages/confirmations. Without this validation,
- /// even honest relayers may lose their funds if there are multiple relays running and
- /// submitting the same messages/confirmations.
- fn validate(call: &T::RuntimeCall) -> TransactionValidity {
- call.check_obsolete_call()
- }
-}
-
-/// Declares a runtime-specific `BridgeRejectObsoleteHeadersAndMessages` signed extension.
-///
-/// ## Example
-///
-/// ```nocompile
-/// generate_bridge_reject_obsolete_headers_and_messages!{
-/// Call, AccountId
-/// BridgeRococoGrandpa, BridgeRococoMessages,
-/// BridgeRococoParachains
-/// }
-/// ```
-///
-/// The goal of this extension is to avoid "mining" transactions that provide outdated bridged
-/// headers and messages. Without that extension, even honest relayers may lose their funds if
-/// there are multiple relays running and submitting the same information.
-#[macro_export]
-macro_rules! generate_bridge_reject_obsolete_headers_and_messages {
- ($call:ty, $account_id:ty, $($filter_call:ty),*) => {
- #[derive(Clone, codec::Decode, Default, codec::Encode, Eq, PartialEq, sp_runtime::RuntimeDebug, scale_info::TypeInfo)]
- pub struct BridgeRejectObsoleteHeadersAndMessages;
- impl sp_runtime::traits::SignedExtension for BridgeRejectObsoleteHeadersAndMessages {
- const IDENTIFIER: &'static str = "BridgeRejectObsoleteHeadersAndMessages";
- type AccountId = $account_id;
- type Call = $call;
- type AdditionalSigned = ();
- type Pre = ();
-
- fn additional_signed(&self) -> sp_std::result::Result<
- (),
- sp_runtime::transaction_validity::TransactionValidityError,
- > {
- Ok(())
- }
-
- fn validate(
- &self,
- _who: &Self::AccountId,
- call: &Self::Call,
- _info: &sp_runtime::traits::DispatchInfoOf,
- _len: usize,
- ) -> sp_runtime::transaction_validity::TransactionValidity {
- let valid = sp_runtime::transaction_validity::ValidTransaction::default();
- $(
- let valid = valid
- .combine_with(<$filter_call as $crate::BridgeRuntimeFilterCall<$call>>::validate(call)?);
- )*
- Ok(valid)
- }
-
- fn pre_dispatch(
- self,
- who: &Self::AccountId,
- call: &Self::Call,
- info: &sp_runtime::traits::DispatchInfoOf,
- len: usize,
- ) -> Result {
- self.validate(who, call, info, len).map(drop)
- }
- }
- };
-}
-
-#[cfg(test)]
-mod tests {
- use crate::BridgeRuntimeFilterCall;
- use frame_support::{assert_err, assert_ok};
- use sp_runtime::{
- traits::SignedExtension,
- transaction_validity::{InvalidTransaction, TransactionValidity, ValidTransaction},
- };
-
- pub struct MockCall {
- data: u32,
- }
-
- impl sp_runtime::traits::Dispatchable for MockCall {
- type RuntimeOrigin = ();
- type Config = ();
- type Info = ();
- type PostInfo = ();
-
- fn dispatch(
- self,
- _origin: Self::RuntimeOrigin,
- ) -> sp_runtime::DispatchResultWithInfo {
- unimplemented!()
- }
- }
-
- struct FirstFilterCall;
- impl BridgeRuntimeFilterCall for FirstFilterCall {
- fn validate(call: &MockCall) -> TransactionValidity {
- if call.data <= 1 {
- return InvalidTransaction::Custom(1).into()
- }
-
- Ok(ValidTransaction { priority: 1, ..Default::default() })
- }
- }
-
- struct SecondFilterCall;
- impl BridgeRuntimeFilterCall for SecondFilterCall {
- fn validate(call: &MockCall) -> TransactionValidity {
- if call.data <= 2 {
- return InvalidTransaction::Custom(2).into()
- }
-
- Ok(ValidTransaction { priority: 2, ..Default::default() })
- }
- }
-
- #[test]
- fn test() {
- generate_bridge_reject_obsolete_headers_and_messages!(
- MockCall,
- (),
- FirstFilterCall,
- SecondFilterCall
- );
-
- assert_err!(
- BridgeRejectObsoleteHeadersAndMessages.validate(&(), &MockCall { data: 1 }, &(), 0),
- InvalidTransaction::Custom(1)
- );
-
- assert_err!(
- BridgeRejectObsoleteHeadersAndMessages.validate(&(), &MockCall { data: 2 }, &(), 0),
- InvalidTransaction::Custom(2)
- );
-
- assert_ok!(
- BridgeRejectObsoleteHeadersAndMessages.validate(&(), &MockCall { data: 3 }, &(), 0),
- ValidTransaction { priority: 3, ..Default::default() }
- )
- }
-}
diff --git a/bridges/bin/runtime-common/src/messages_api.rs b/bridges/bin/runtime-common/src/messages_api.rs
index ccf1c754041ed84dc302f0660fdd5bde8dc8d533..7fbdeb366124778b36c77725be8ca8778020be1b 100644
--- a/bridges/bin/runtime-common/src/messages_api.rs
+++ b/bridges/bin/runtime-common/src/messages_api.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with Parity Bridges Common. If not, see .
-//! Helpers for implementing various message-related runtime API mthods.
+//! Helpers for implementing various message-related runtime API methods.
use bp_messages::{
InboundMessageDetails, LaneId, MessageNonce, MessagePayload, OutboundMessageDetails,
diff --git a/bridges/bin/runtime-common/src/messages_xcm_extension.rs b/bridges/bin/runtime-common/src/messages_xcm_extension.rs
index e3da6155f08a198d5469adbfc64e40213eddf8eb..46ed4da0d85481fcc7223740084945924f9c710f 100644
--- a/bridges/bin/runtime-common/src/messages_xcm_extension.rs
+++ b/bridges/bin/runtime-common/src/messages_xcm_extension.rs
@@ -248,7 +248,7 @@ impl LocalXcmQueueManager {
sender_and_lane: &SenderAndLane,
enqueued_messages: MessageNonce,
) {
- // skip if we dont want to handle congestion
+ // skip if we don't want to handle congestion
if !H::supports_congestion_detection() {
return
}
diff --git a/bridges/bin/runtime-common/src/mock.rs b/bridges/bin/runtime-common/src/mock.rs
index deee4524e8586d45c01f08126e84b9c619cfeba2..ad71cd0d456d827d3757433d214f7ea794406fca 100644
--- a/bridges/bin/runtime-common/src/mock.rs
+++ b/bridges/bin/runtime-common/src/mock.rs
@@ -166,7 +166,7 @@ impl pallet_balances::Config for TestRuntime {
#[derive_impl(pallet_transaction_payment::config_preludes::TestDefaultConfig)]
impl pallet_transaction_payment::Config for TestRuntime {
- type OnChargeTransaction = pallet_transaction_payment::CurrencyAdapter;
+ type OnChargeTransaction = pallet_transaction_payment::FungibleAdapter;
type OperationalFeeMultiplier = ConstU8<5>;
type WeightToFee = IdentityFee;
type LengthToFee = ConstantMultiplier;
@@ -379,7 +379,7 @@ impl Chain for BridgedUnderlyingChain {
impl ChainWithGrandpa for BridgedUnderlyingChain {
const WITH_CHAIN_GRANDPA_PALLET_NAME: &'static str = "";
const MAX_AUTHORITIES_COUNT: u32 = 16;
- const REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY: u32 = 8;
+ const REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY: u32 = 8;
const MAX_MANDATORY_HEADER_SIZE: u32 = 256;
const AVERAGE_HEADER_SIZE: u32 = 64;
}
diff --git a/bridges/primitives/chain-asset-hub-rococo/Cargo.toml b/bridges/chains/chain-asset-hub-rococo/Cargo.toml
similarity index 69%
rename from bridges/primitives/chain-asset-hub-rococo/Cargo.toml
rename to bridges/chains/chain-asset-hub-rococo/Cargo.toml
index 4dfa149e0ea9ab4e0ac1804844a0c128f15bd5bb..9a6419a5b4055be348f4f8813e3c1301f14f7142 100644
--- a/bridges/primitives/chain-asset-hub-rococo/Cargo.toml
+++ b/bridges/chains/chain-asset-hub-rococo/Cargo.toml
@@ -5,19 +5,20 @@ version = "0.4.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
[dependencies]
-codec = { package = "parity-scale-codec", version = "3.1.5", default-features = false }
-scale-info = { version = "2.10.0", default-features = false, features = ["derive"] }
+codec = { package = "parity-scale-codec", version = "3.6.1", default-features = false }
+scale-info = { version = "2.11.1", default-features = false, features = ["derive"] }
# Substrate Dependencies
frame-support = { path = "../../../substrate/frame/support", default-features = false }
# Bridge Dependencies
-bp-xcm-bridge-hub-router = { path = "../xcm-bridge-hub-router", default-features = false }
+bp-xcm-bridge-hub-router = { path = "../../primitives/xcm-bridge-hub-router", default-features = false }
[features]
default = ["std"]
diff --git a/bridges/primitives/chain-asset-hub-rococo/src/lib.rs b/bridges/chains/chain-asset-hub-rococo/src/lib.rs
similarity index 100%
rename from bridges/primitives/chain-asset-hub-rococo/src/lib.rs
rename to bridges/chains/chain-asset-hub-rococo/src/lib.rs
diff --git a/bridges/primitives/chain-asset-hub-westend/Cargo.toml b/bridges/chains/chain-asset-hub-westend/Cargo.toml
similarity index 69%
rename from bridges/primitives/chain-asset-hub-westend/Cargo.toml
rename to bridges/chains/chain-asset-hub-westend/Cargo.toml
index c9bd437562b86a97cdf2807c18b4905e695d1a5e..1c08ee28e417cb50ce9ef9ded5f17163e1bb30d4 100644
--- a/bridges/primitives/chain-asset-hub-westend/Cargo.toml
+++ b/bridges/chains/chain-asset-hub-westend/Cargo.toml
@@ -5,19 +5,20 @@ version = "0.3.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
[dependencies]
-codec = { package = "parity-scale-codec", version = "3.1.5", default-features = false }
-scale-info = { version = "2.10.0", default-features = false, features = ["derive"] }
+codec = { package = "parity-scale-codec", version = "3.6.1", default-features = false }
+scale-info = { version = "2.11.1", default-features = false, features = ["derive"] }
# Substrate Dependencies
frame-support = { path = "../../../substrate/frame/support", default-features = false }
# Bridge Dependencies
-bp-xcm-bridge-hub-router = { path = "../xcm-bridge-hub-router", default-features = false }
+bp-xcm-bridge-hub-router = { path = "../../primitives/xcm-bridge-hub-router", default-features = false }
[features]
default = ["std"]
diff --git a/bridges/primitives/chain-asset-hub-westend/src/lib.rs b/bridges/chains/chain-asset-hub-westend/src/lib.rs
similarity index 100%
rename from bridges/primitives/chain-asset-hub-westend/src/lib.rs
rename to bridges/chains/chain-asset-hub-westend/src/lib.rs
diff --git a/bridges/primitives/chain-bridge-hub-cumulus/Cargo.toml b/bridges/chains/chain-bridge-hub-cumulus/Cargo.toml
similarity index 78%
rename from bridges/primitives/chain-bridge-hub-cumulus/Cargo.toml
rename to bridges/chains/chain-bridge-hub-cumulus/Cargo.toml
index d35eefa1c45c3f7cf479dcea2ee4da87dbc31627..4b900002a4d81abb9d7364f555a150a2af6c839c 100644
--- a/bridges/primitives/chain-bridge-hub-cumulus/Cargo.toml
+++ b/bridges/chains/chain-bridge-hub-cumulus/Cargo.toml
@@ -5,6 +5,7 @@ version = "0.7.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
@@ -12,9 +13,9 @@ workspace = true
[dependencies]
# Bridge Dependencies
-bp-polkadot-core = { path = "../polkadot-core", default-features = false }
-bp-messages = { path = "../messages", default-features = false }
-bp-runtime = { path = "../runtime", default-features = false }
+bp-polkadot-core = { path = "../../primitives/polkadot-core", default-features = false }
+bp-messages = { path = "../../primitives/messages", default-features = false }
+bp-runtime = { path = "../../primitives/runtime", default-features = false }
# Substrate Based Dependencies
diff --git a/bridges/primitives/chain-bridge-hub-cumulus/src/lib.rs b/bridges/chains/chain-bridge-hub-cumulus/src/lib.rs
similarity index 100%
rename from bridges/primitives/chain-bridge-hub-cumulus/src/lib.rs
rename to bridges/chains/chain-bridge-hub-cumulus/src/lib.rs
diff --git a/bridges/primitives/chain-bridge-hub-kusama/Cargo.toml b/bridges/chains/chain-bridge-hub-kusama/Cargo.toml
similarity index 83%
rename from bridges/primitives/chain-bridge-hub-kusama/Cargo.toml
rename to bridges/chains/chain-bridge-hub-kusama/Cargo.toml
index 8d71b3f5eb7646a81af55c0030814c604ead82ef..ff6dd8849abe3897f1c3eb3cb1de8b7d89af5ca7 100644
--- a/bridges/primitives/chain-bridge-hub-kusama/Cargo.toml
+++ b/bridges/chains/chain-bridge-hub-kusama/Cargo.toml
@@ -5,6 +5,7 @@ version = "0.6.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
@@ -13,8 +14,8 @@ workspace = true
# Bridge Dependencies
bp-bridge-hub-cumulus = { path = "../chain-bridge-hub-cumulus", default-features = false }
-bp-runtime = { path = "../runtime", default-features = false }
-bp-messages = { path = "../messages", default-features = false }
+bp-runtime = { path = "../../primitives/runtime", default-features = false }
+bp-messages = { path = "../../primitives/messages", default-features = false }
# Substrate Based Dependencies
diff --git a/bridges/primitives/chain-bridge-hub-kusama/src/lib.rs b/bridges/chains/chain-bridge-hub-kusama/src/lib.rs
similarity index 100%
rename from bridges/primitives/chain-bridge-hub-kusama/src/lib.rs
rename to bridges/chains/chain-bridge-hub-kusama/src/lib.rs
diff --git a/bridges/primitives/chain-bridge-hub-polkadot/Cargo.toml b/bridges/chains/chain-bridge-hub-polkadot/Cargo.toml
similarity index 83%
rename from bridges/primitives/chain-bridge-hub-polkadot/Cargo.toml
rename to bridges/chains/chain-bridge-hub-polkadot/Cargo.toml
index 4e89e8a5c9a173bc9a084af9e7c609a6bae287a8..da8b8a82fa702eeab719335fa9968b78ee965163 100644
--- a/bridges/primitives/chain-bridge-hub-polkadot/Cargo.toml
+++ b/bridges/chains/chain-bridge-hub-polkadot/Cargo.toml
@@ -5,6 +5,7 @@ version = "0.6.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
@@ -14,8 +15,8 @@ workspace = true
# Bridge Dependencies
bp-bridge-hub-cumulus = { path = "../chain-bridge-hub-cumulus", default-features = false }
-bp-runtime = { path = "../runtime", default-features = false }
-bp-messages = { path = "../messages", default-features = false }
+bp-runtime = { path = "../../primitives/runtime", default-features = false }
+bp-messages = { path = "../../primitives/messages", default-features = false }
# Substrate Based Dependencies
diff --git a/bridges/primitives/chain-bridge-hub-polkadot/src/lib.rs b/bridges/chains/chain-bridge-hub-polkadot/src/lib.rs
similarity index 100%
rename from bridges/primitives/chain-bridge-hub-polkadot/src/lib.rs
rename to bridges/chains/chain-bridge-hub-polkadot/src/lib.rs
diff --git a/bridges/primitives/chain-bridge-hub-rococo/Cargo.toml b/bridges/chains/chain-bridge-hub-rococo/Cargo.toml
similarity index 83%
rename from bridges/primitives/chain-bridge-hub-rococo/Cargo.toml
rename to bridges/chains/chain-bridge-hub-rococo/Cargo.toml
index 1643d934a982ec0795fc370b221dc35d36d3b492..f7672df012f2fc2a21cfc987468427a3222317ea 100644
--- a/bridges/primitives/chain-bridge-hub-rococo/Cargo.toml
+++ b/bridges/chains/chain-bridge-hub-rococo/Cargo.toml
@@ -5,6 +5,7 @@ version = "0.7.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
@@ -13,8 +14,8 @@ workspace = true
# Bridge Dependencies
bp-bridge-hub-cumulus = { path = "../chain-bridge-hub-cumulus", default-features = false }
-bp-runtime = { path = "../runtime", default-features = false }
-bp-messages = { path = "../messages", default-features = false }
+bp-runtime = { path = "../../primitives/runtime", default-features = false }
+bp-messages = { path = "../../primitives/messages", default-features = false }
# Substrate Based Dependencies
diff --git a/bridges/primitives/chain-bridge-hub-rococo/src/lib.rs b/bridges/chains/chain-bridge-hub-rococo/src/lib.rs
similarity index 99%
rename from bridges/primitives/chain-bridge-hub-rococo/src/lib.rs
rename to bridges/chains/chain-bridge-hub-rococo/src/lib.rs
index c4e697fbe9526b85c7f10cf739c6893d50190fe9..abce872d7ba35cf24b013aa26b4b1f1d796b5785 100644
--- a/bridges/primitives/chain-bridge-hub-rococo/src/lib.rs
+++ b/bridges/chains/chain-bridge-hub-rococo/src/lib.rs
@@ -107,5 +107,5 @@ frame_support::parameter_types! {
/// Transaction fee that is paid at the Rococo BridgeHub for delivering single outbound message confirmation.
/// (initially was calculated by test `BridgeHubRococo::can_calculate_fee_for_complex_message_confirmation_transaction` + `33%`)
- pub const BridgeHubRococoBaseConfirmationFeeInRocs: u128 = 5_380_829_647;
+ pub const BridgeHubRococoBaseConfirmationFeeInRocs: u128 = 5_380_901_781;
}
diff --git a/bridges/primitives/chain-bridge-hub-westend/Cargo.toml b/bridges/chains/chain-bridge-hub-westend/Cargo.toml
similarity index 83%
rename from bridges/primitives/chain-bridge-hub-westend/Cargo.toml
rename to bridges/chains/chain-bridge-hub-westend/Cargo.toml
index 32a7850c5392fd892ec40e9968fa365ec59cbba3..ec74c4b947d693dba92d4da5051526e49349e0a5 100644
--- a/bridges/primitives/chain-bridge-hub-westend/Cargo.toml
+++ b/bridges/chains/chain-bridge-hub-westend/Cargo.toml
@@ -5,6 +5,7 @@ version = "0.3.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
@@ -14,8 +15,8 @@ workspace = true
# Bridge Dependencies
bp-bridge-hub-cumulus = { path = "../chain-bridge-hub-cumulus", default-features = false }
-bp-runtime = { path = "../runtime", default-features = false }
-bp-messages = { path = "../messages", default-features = false }
+bp-runtime = { path = "../../primitives/runtime", default-features = false }
+bp-messages = { path = "../../primitives/messages", default-features = false }
# Substrate Based Dependencies
diff --git a/bridges/primitives/chain-bridge-hub-westend/src/lib.rs b/bridges/chains/chain-bridge-hub-westend/src/lib.rs
similarity index 100%
rename from bridges/primitives/chain-bridge-hub-westend/src/lib.rs
rename to bridges/chains/chain-bridge-hub-westend/src/lib.rs
diff --git a/bridges/primitives/chain-kusama/Cargo.toml b/bridges/chains/chain-kusama/Cargo.toml
similarity index 71%
rename from bridges/primitives/chain-kusama/Cargo.toml
rename to bridges/chains/chain-kusama/Cargo.toml
index 0660f34602389d1cf9e1ec88b57d1a9aeb9a3830..66061ff2793cbdd3419fa8894ab78e37486102ea 100644
--- a/bridges/primitives/chain-kusama/Cargo.toml
+++ b/bridges/chains/chain-kusama/Cargo.toml
@@ -5,6 +5,7 @@ version = "0.5.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
@@ -13,9 +14,9 @@ workspace = true
# Bridge Dependencies
-bp-header-chain = { path = "../header-chain", default-features = false }
-bp-polkadot-core = { path = "../polkadot-core", default-features = false }
-bp-runtime = { path = "../runtime", default-features = false }
+bp-header-chain = { path = "../../primitives/header-chain", default-features = false }
+bp-polkadot-core = { path = "../../primitives/polkadot-core", default-features = false }
+bp-runtime = { path = "../../primitives/runtime", default-features = false }
# Substrate Based Dependencies
diff --git a/bridges/primitives/chain-kusama/src/lib.rs b/bridges/chains/chain-kusama/src/lib.rs
similarity index 95%
rename from bridges/primitives/chain-kusama/src/lib.rs
rename to bridges/chains/chain-kusama/src/lib.rs
index e3b4d0520f61c858b54d78dfa4a45f57bac411fb..a81004afe8127b556211d0207d2bc1f9ecc02955 100644
--- a/bridges/primitives/chain-kusama/src/lib.rs
+++ b/bridges/chains/chain-kusama/src/lib.rs
@@ -53,8 +53,8 @@ impl Chain for Kusama {
impl ChainWithGrandpa for Kusama {
const WITH_CHAIN_GRANDPA_PALLET_NAME: &'static str = WITH_KUSAMA_GRANDPA_PALLET_NAME;
const MAX_AUTHORITIES_COUNT: u32 = MAX_AUTHORITIES_COUNT;
- const REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY: u32 =
- REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY;
+ const REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY: u32 =
+ REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY;
const MAX_MANDATORY_HEADER_SIZE: u32 = MAX_MANDATORY_HEADER_SIZE;
const AVERAGE_HEADER_SIZE: u32 = AVERAGE_HEADER_SIZE;
}
diff --git a/bridges/primitives/chain-polkadot-bulletin/Cargo.toml b/bridges/chains/chain-polkadot-bulletin/Cargo.toml
similarity index 68%
rename from bridges/primitives/chain-polkadot-bulletin/Cargo.toml
rename to bridges/chains/chain-polkadot-bulletin/Cargo.toml
index 15c824fcbdb31c2c84f63bd56d4d0b3f90efc5b1..2db16a00e92492e3a167458343a88a24c2186748 100644
--- a/bridges/primitives/chain-polkadot-bulletin/Cargo.toml
+++ b/bridges/chains/chain-polkadot-bulletin/Cargo.toml
@@ -5,20 +5,21 @@ version = "0.4.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
[dependencies]
-codec = { package = "parity-scale-codec", version = "3.1.5", default-features = false, features = ["derive"] }
-scale-info = { version = "2.10.0", default-features = false, features = ["derive"] }
+codec = { package = "parity-scale-codec", version = "3.6.1", default-features = false, features = ["derive"] }
+scale-info = { version = "2.11.1", default-features = false, features = ["derive"] }
# Bridge Dependencies
-bp-header-chain = { path = "../header-chain", default-features = false }
-bp-messages = { path = "../messages", default-features = false }
-bp-polkadot-core = { path = "../polkadot-core", default-features = false }
-bp-runtime = { path = "../runtime", default-features = false }
+bp-header-chain = { path = "../../primitives/header-chain", default-features = false }
+bp-messages = { path = "../../primitives/messages", default-features = false }
+bp-polkadot-core = { path = "../../primitives/polkadot-core", default-features = false }
+bp-runtime = { path = "../../primitives/runtime", default-features = false }
# Substrate Based Dependencies
diff --git a/bridges/primitives/chain-polkadot-bulletin/src/lib.rs b/bridges/chains/chain-polkadot-bulletin/src/lib.rs
similarity index 96%
rename from bridges/primitives/chain-polkadot-bulletin/src/lib.rs
rename to bridges/chains/chain-polkadot-bulletin/src/lib.rs
index f2eebf9312470a42e1d3a1c7d67ab8b7a38af189..f3d300567f2b4f92cec272e0929a3c53d718c823 100644
--- a/bridges/primitives/chain-polkadot-bulletin/src/lib.rs
+++ b/bridges/chains/chain-polkadot-bulletin/src/lib.rs
@@ -43,7 +43,7 @@ use sp_runtime::{traits::DispatchInfoOf, transaction_validity::TransactionValidi
pub use bp_polkadot_core::{
AccountAddress, AccountId, Balance, Block, BlockNumber, Hash, Hasher, Header, Nonce, Signature,
SignedBlock, UncheckedExtrinsic, AVERAGE_HEADER_SIZE, EXTRA_STORAGE_PROOF_SIZE,
- MAX_MANDATORY_HEADER_SIZE, REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY,
+ MAX_MANDATORY_HEADER_SIZE, REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY,
};
/// Maximal number of GRANDPA authorities at Polkadot Bulletin chain.
@@ -62,7 +62,7 @@ const NORMAL_DISPATCH_RATIO: Perbill = Perbill::from_percent(90);
// Re following constants - we are using the same values at Cumulus parachains. They are limited
// by the maximal transaction weight/size. Since block limits at Bulletin Chain are larger than
-// at the Cumulus Bridgeg Hubs, we could reuse the same values.
+// at the Cumulus Bridge Hubs, we could reuse the same values.
/// Maximal number of unrewarded relayer entries at inbound lane for Cumulus-based parachains.
pub const MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX: MessageNonce = 1024;
@@ -207,8 +207,8 @@ impl Chain for PolkadotBulletin {
impl ChainWithGrandpa for PolkadotBulletin {
const WITH_CHAIN_GRANDPA_PALLET_NAME: &'static str = WITH_POLKADOT_BULLETIN_GRANDPA_PALLET_NAME;
const MAX_AUTHORITIES_COUNT: u32 = MAX_AUTHORITIES_COUNT;
- const REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY: u32 =
- REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY;
+ const REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY: u32 =
+ REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY;
const MAX_MANDATORY_HEADER_SIZE: u32 = MAX_MANDATORY_HEADER_SIZE;
const AVERAGE_HEADER_SIZE: u32 = AVERAGE_HEADER_SIZE;
}
diff --git a/bridges/primitives/chain-polkadot/Cargo.toml b/bridges/chains/chain-polkadot/Cargo.toml
similarity index 71%
rename from bridges/primitives/chain-polkadot/Cargo.toml
rename to bridges/chains/chain-polkadot/Cargo.toml
index 6421b7f40106e404eeba04be72f5448fd5f65159..c700935f3083b5f287277c7d9975be53352b2506 100644
--- a/bridges/primitives/chain-polkadot/Cargo.toml
+++ b/bridges/chains/chain-polkadot/Cargo.toml
@@ -5,6 +5,7 @@ version = "0.5.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
@@ -13,9 +14,9 @@ workspace = true
# Bridge Dependencies
-bp-header-chain = { path = "../header-chain", default-features = false }
-bp-polkadot-core = { path = "../polkadot-core", default-features = false }
-bp-runtime = { path = "../runtime", default-features = false }
+bp-header-chain = { path = "../../primitives/header-chain", default-features = false }
+bp-polkadot-core = { path = "../../primitives/polkadot-core", default-features = false }
+bp-runtime = { path = "../../primitives/runtime", default-features = false }
# Substrate Based Dependencies
diff --git a/bridges/primitives/chain-polkadot/src/lib.rs b/bridges/chains/chain-polkadot/src/lib.rs
similarity index 95%
rename from bridges/primitives/chain-polkadot/src/lib.rs
rename to bridges/chains/chain-polkadot/src/lib.rs
index fc5e10308a8e33463a74c041f157daaef09cc9c8..00d35783a9b61844bab7701fdb60711125447ca3 100644
--- a/bridges/primitives/chain-polkadot/src/lib.rs
+++ b/bridges/chains/chain-polkadot/src/lib.rs
@@ -55,8 +55,8 @@ impl Chain for Polkadot {
impl ChainWithGrandpa for Polkadot {
const WITH_CHAIN_GRANDPA_PALLET_NAME: &'static str = WITH_POLKADOT_GRANDPA_PALLET_NAME;
const MAX_AUTHORITIES_COUNT: u32 = MAX_AUTHORITIES_COUNT;
- const REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY: u32 =
- REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY;
+ const REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY: u32 =
+ REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY;
const MAX_MANDATORY_HEADER_SIZE: u32 = MAX_MANDATORY_HEADER_SIZE;
const AVERAGE_HEADER_SIZE: u32 = AVERAGE_HEADER_SIZE;
}
diff --git a/bridges/primitives/chain-rococo/Cargo.toml b/bridges/chains/chain-rococo/Cargo.toml
similarity index 71%
rename from bridges/primitives/chain-rococo/Cargo.toml
rename to bridges/chains/chain-rococo/Cargo.toml
index de373f0ae64b8d9a8124dbcdfcca3c2bf05e2787..5a5613bb376a5a4f75c773b3350993262149f973 100644
--- a/bridges/primitives/chain-rococo/Cargo.toml
+++ b/bridges/chains/chain-rococo/Cargo.toml
@@ -5,6 +5,7 @@ version = "0.6.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
@@ -13,9 +14,9 @@ workspace = true
# Bridge Dependencies
-bp-header-chain = { path = "../header-chain", default-features = false }
-bp-polkadot-core = { path = "../polkadot-core", default-features = false }
-bp-runtime = { path = "../runtime", default-features = false }
+bp-header-chain = { path = "../../primitives/header-chain", default-features = false }
+bp-polkadot-core = { path = "../../primitives/polkadot-core", default-features = false }
+bp-runtime = { path = "../../primitives/runtime", default-features = false }
# Substrate Based Dependencies
diff --git a/bridges/primitives/chain-rococo/src/lib.rs b/bridges/chains/chain-rococo/src/lib.rs
similarity index 95%
rename from bridges/primitives/chain-rococo/src/lib.rs
rename to bridges/chains/chain-rococo/src/lib.rs
index f1b256f0f090f048cc8db3a16c112ed8b938f6ce..2385dd2cbb250181ce5f46aef9f1e76f8fd010d2 100644
--- a/bridges/primitives/chain-rococo/src/lib.rs
+++ b/bridges/chains/chain-rococo/src/lib.rs
@@ -53,8 +53,8 @@ impl Chain for Rococo {
impl ChainWithGrandpa for Rococo {
const WITH_CHAIN_GRANDPA_PALLET_NAME: &'static str = WITH_ROCOCO_GRANDPA_PALLET_NAME;
const MAX_AUTHORITIES_COUNT: u32 = MAX_AUTHORITIES_COUNT;
- const REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY: u32 =
- REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY;
+ const REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY: u32 =
+ REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY;
const MAX_MANDATORY_HEADER_SIZE: u32 = MAX_MANDATORY_HEADER_SIZE;
const AVERAGE_HEADER_SIZE: u32 = AVERAGE_HEADER_SIZE;
}
diff --git a/bridges/primitives/chain-westend/Cargo.toml b/bridges/chains/chain-westend/Cargo.toml
similarity index 71%
rename from bridges/primitives/chain-westend/Cargo.toml
rename to bridges/chains/chain-westend/Cargo.toml
index e55a8d649a88b88d84f4f3547c23709cef67d872..10b06d76507ef95bbff00f5560b705ecee1ec4ce 100644
--- a/bridges/primitives/chain-westend/Cargo.toml
+++ b/bridges/chains/chain-westend/Cargo.toml
@@ -5,6 +5,7 @@ version = "0.3.0"
authors.workspace = true
edition.workspace = true
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
[lints]
workspace = true
@@ -13,9 +14,9 @@ workspace = true
# Bridge Dependencies
-bp-header-chain = { path = "../header-chain", default-features = false }
-bp-polkadot-core = { path = "../polkadot-core", default-features = false }
-bp-runtime = { path = "../runtime", default-features = false }
+bp-header-chain = { path = "../../primitives/header-chain", default-features = false }
+bp-polkadot-core = { path = "../../primitives/polkadot-core", default-features = false }
+bp-runtime = { path = "../../primitives/runtime", default-features = false }
# Substrate Based Dependencies
diff --git a/bridges/primitives/chain-westend/src/lib.rs b/bridges/chains/chain-westend/src/lib.rs
similarity index 95%
rename from bridges/primitives/chain-westend/src/lib.rs
rename to bridges/chains/chain-westend/src/lib.rs
index f03fd2160a700eb3817a6feb629e9d366cc366aa..b344b7f4bf93392c08502446513a9ae39296b512 100644
--- a/bridges/primitives/chain-westend/src/lib.rs
+++ b/bridges/chains/chain-westend/src/lib.rs
@@ -53,8 +53,8 @@ impl Chain for Westend {
impl ChainWithGrandpa for Westend {
const WITH_CHAIN_GRANDPA_PALLET_NAME: &'static str = WITH_WESTEND_GRANDPA_PALLET_NAME;
const MAX_AUTHORITIES_COUNT: u32 = MAX_AUTHORITIES_COUNT;
- const REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY: u32 =
- REASONABLE_HEADERS_IN_JUSTIFICATON_ANCESTRY;
+ const REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY: u32 =
+ REASONABLE_HEADERS_IN_JUSTIFICATION_ANCESTRY;
const MAX_MANDATORY_HEADER_SIZE: u32 = MAX_MANDATORY_HEADER_SIZE;
const AVERAGE_HEADER_SIZE: u32 = AVERAGE_HEADER_SIZE;
}
diff --git a/bridges/docs/bridge-relayers-claim-rewards.png b/bridges/docs/bridge-relayers-claim-rewards.png
new file mode 100644
index 0000000000000000000000000000000000000000..d56b8dd871e8445e7cab49517123b0092ce09137
Binary files /dev/null and b/bridges/docs/bridge-relayers-claim-rewards.png differ
diff --git a/bridges/docs/bridge-relayers-deregister.png b/bridges/docs/bridge-relayers-deregister.png
new file mode 100644
index 0000000000000000000000000000000000000000..e7706cee78916d7e2bbcfd7ee4a1a046a0450f87
Binary files /dev/null and b/bridges/docs/bridge-relayers-deregister.png differ
diff --git a/bridges/docs/bridge-relayers-register.png b/bridges/docs/bridge-relayers-register.png
new file mode 100644
index 0000000000000000000000000000000000000000..e9e3e1b5ac87c5c9d31477c696912fcbc93b0c78
Binary files /dev/null and b/bridges/docs/bridge-relayers-register.png differ
diff --git a/bridges/docs/running-relayer.md b/bridges/docs/running-relayer.md
new file mode 100644
index 0000000000000000000000000000000000000000..710810a476e4df5e4b80fde31f9576be5ad26391
--- /dev/null
+++ b/bridges/docs/running-relayer.md
@@ -0,0 +1,343 @@
+# Running your own bridge relayer
+
+:warning: :construction: Please read the [Disclaimer](#disclaimer) section first :construction: :warning:
+
+## Disclaimer
+
+There are several things you should know before running your own relayer:
+
+- initial bridge version (we call it bridges v1) supports any number of relayers, but **there's no guaranteed
+compensation** for running a relayer and/or submitting valid bridge transactions. Most probably you'll end up
+spending more funds than getting from rewards - please accept this fact;
+
+- even if your relayer has managed to submit a valid bridge transaction that has been included into the bridge
+hub block, there's no guarantee that you will be able to claim your compensation for that transaction. That's
+because compensations are paid from the account, controlled by relay chain governance and it could have no funds
+to compensate your useful actions. We'll be working on a proper process to resupply it on-time, but we can't
+provide any guarantee until that process is well established.
+
+## A Brief Introduction into Relayers and our Compensations Scheme
+
+Omitting details, relayer is an offchain process that is connected to both bridged chains. It looks at the
+outbound bridge messages queue and submits message delivery transactions to the target chain. There's a lot
+of details behind that simple phrase - you could find more info in the
+[High-Level Bridge Overview](./high-level-overview.md) document.
+
+Reward that is paid to relayer has two parts. The first part static and is controlled by the governance.
+It is rather small initially - e.g. you need to deliver `10_000` Kusama -> Polkadot messages to gain single
+KSM token.
+
+The other reward part is dynamic. So to deliver an XCM message from one BridgeHub to another, we'll need to
+submit two transactions on different chains. Every transaction has its cost, which is:
+
+- dynamic, because e.g. message size can change and/or fee factor of the target chain may change;
+
+- quite large, because those transactions are quite heavy (mostly in terms of size, not weight).
+
+We are compensating the cost of **valid**, **minimal** and **useful** bridge-related transactions to
+relayer, that has submitted such transaction. Valid here means that the transaction doesn't fail. Minimal
+means that all data within transaction call is actually required for the transaction to succeed. Useful
+means that all supplied data in transaction is new and yet unknown to the target chain.
+
+We have implemented a relayer that is able to craft such transactions. The rest of document contains a detailed
+information on how to deploy this software on your own node.
+
+## Relayers Concurrency
+
+As it has been said above, we are not compensating cost of transactions that are not **useful**. For
+example, if message `100` has already been delivered from Kusama Bridge Hub to Polkadot Bridge Hub, then another
+transaction that delivers the same message `100` won't be **useful**. Hence, no compensation to relayer that
+has submitted that second transaction.
+
+But what if there are several relayers running? They are noticing the same queued message `100` and
+simultaneously submit identical message delivery transactions. You may expect that there'll be one lucky
+relayer, whose transaction would win the "race" and which will receive the compensation and reward. And
+there'll be several other relayers, losing some funds on their unuseful transactions.
+
+But actually, we have a solution that invalidates transactions of "unlucky" relayers before they are
+included into the block. So at least you may be sure that you won't waste your funds on duplicate transactions.
+
+
+Some details?
+
+All **unuseful** transactions are rejected by our
+[transaction extension](https://github.com/paritytech/polkadot-sdk/blob/master/bridges/bin/runtime-common/src/refund_relayer_extension.rs),
+which also handles transaction fee compensations. You may find more info on unuseful (aka obsolete) transactions
+by lurking in the code.
+
+We also have the WiP prototype of relayers coordination protocol, where relayers will get some guarantee
+that their transactions will be prioritized over other relayers transactions at their assigned slots.
+That is planned for the future version of bridge and the progress is
+[tracked here](https://github.com/paritytech/parity-bridges-common/issues/2486).
+
+
+
+## Prerequisites
+
+Let's focus on the bridge between Polkadot and Kusama Bridge Hubs. Let's also assume that we want to start
+a relayer that "serves" an initial lane [`0x00000001`](https://github.com/polkadot-fellows/runtimes/blob/9ce1bbbbcd7843b3c76ba4d43c036bc311959e9f/system-parachains/bridge-hubs/bridge-hub-kusama/src/bridge_to_polkadot_config.rs#L54).
+
+
+Lane?
+
+Think of lane as a queue of messages that need to be delivered to the other/bridged chain. The lane is
+bidirectional, meaning that there are four "endpoints". Two "outbound" endpoints (one at every chain), contain
+messages that need to be delivered to the bridged chain. Two "inbound" are accepting messages from the bridged
+chain and also remember the relayer, who has delivered message(s) to reward it later.
+
+
+
+The same steps may be performed for other lanes and bridges as well - you'll just need to change several parameters.
+
+So to start your relayer instance, you'll need to prepare:
+
+- an address of ws/wss RPC endpoint of the Kusama relay chain;
+
+- an address of ws/wss RPC endpoint of the Polkadot relay chain;
+
+- an address of ws/wss RPC endpoint of the Kusama Bridge Hub chain;
+
+- an address of ws/wss RPC endpoint of the Polkadot Bridge Hub chain;
+
+- an account on Kusama Bridge Hub;
+
+- an account on Polkadot Bridge Hub.
+
+For RPC endpoints, you could start your own nodes, or use some public community nodes. Nodes are not meant to be
+archive or provide access to insecure RPC calls.
+
+To create an account on Bridge Hubs, you could use XCM teleport functionality. E.g. if you have an account on
+the relay chain, you could use the `teleportAssets` call of `xcmPallet` and send asset
+`V3 { id: Concrete(0, Here), Fungible: }` to beneficiary `V3(0, X1(AccountId32()))`
+on destination `V3(0, X1(Parachain(1002)))`. To estimate amounts you need, please refer to the [Costs](#costs)
+section of the document.
+
+## Registering your Relayer Account (Optional, But Please Read)
+
+Bridge transactions are quite heavy and expensive. We want to minimize block space that can be occupied by
+invalid bridge transactions and prioritize valid transactions over invalid. That is achieved by **optional**
+relayer registration. Transactions, signed by relayers with active registration, gain huge priority boost.
+In exchange, such relayers may be slashed if they submit **invalid** or **non-minimal** transaction.
+
+Transactions, signed by relayers **without** active registration, on the other hand, receive no priority
+boost. It means that if there is active registered relayer, most likely all transactions from unregistered
+will be counted as **unuseful**, not included into the block and unregistered relayer won't get any reward
+for his operations.
+
+Before registering, you should know several things about your funds:
+
+- to register, you need to hold significant amount of funds on your relayer account. As of now, it is
+ [100 KSM](https://github.com/polkadot-fellows/runtimes/blob/9ce1bbbbcd7843b3c76ba4d43c036bc311959e9f/system-parachains/bridge-hubs/bridge-hub-kusama/src/bridge_to_polkadot_config.rs#L71C14-L71C43)
+ for registration on Kusama Bridge Hub and
+ [500 DOT](https://github.com/polkadot-fellows/runtimes/blob/9ce1bbbbcd7843b3c76ba4d43c036bc311959e9f/system-parachains/bridge-hubs/bridge-hub-polkadot/src/bridge_to_kusama_config.rs#L71C14-L71C43)
+ for registration on Polkadot Bridge Hub;
+
+- when you are registered, those funds are reserved on relayer account and you can't transfer them.
+
+The registration itself, has three states: active, inactive or expired. Initially, it is active, meaning that all
+your transactions that are **validated** on top of block, where it is active get priority boost. Registration
+becomes expired when the block with the number you have specified during registration is "mined". It is the
+`validTill` parameter of the `register` call (see below). After that `validTill` block, you may unregister and get
+your reserved funds back. There's also an intermediate point between those blocks - it is the `validTill - LEASE`,
+where `LEASE` is the the chain constant, controlled by the governance. Initially it is set to `300` blocks.
+All your transactions, **validated** between the `validTill - LEASE` and `validTill` blocks do not get the
+priority boost. Also, it is forbidden to specify `validTill` such that the `validTill - currentBlock` is less
+than the `LEASE`.
+
+
+Example?
+
+| Bridge Hub Block | Registration State | Comment |
+| ----------------- | ------------------ | ------------------------------------------------------ |
+| 100 | Active | You have submitted a tx with the `register(1000)` call |
+| 101 | Active | Your message delivery transactions are boosted |
+| 102 | Active | Your message delivery transactions are boosted |
+| ... | Active | Your message delivery transactions are boosted |
+| 700 | Inactive | Your message delivery transactions are not boosted |
+| 701 | Inactive | Your message delivery transactions are not boosted |
+| ... | Inactive | Your message delivery transactions are not boosted |
+| 1000 | Expired | Your may submit a tx with the `deregister` call |
+
+
+
+So once you have enough funds on your account and have selected the `validTill` parameter value, you
+could use the Polkadot JS apps to submit an extrinsic. If you want priority boost for your transactions
+on the Kusama Bridge Hub, open the
+[Polkadot JS Apps](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fkusama-bridge-hub-rpc.polkadot.io#/extrinsics)
+and submit the `register` extrinsic from the `bridgeRelayers` pallet:
+
+![Register Extrinsic](./bridge-relayers-register.png)
+
+To deregister, submit the simple `deregister` extrinsic when registration is expired:
+
+![Deregister Extrinsic](./bridge-relayers-deregister.png)
+
+At any time, you can prolong your registration by calling the `register` with the larger `validTill`.
+
+## Costs
+
+Your relayer account (on both Bridge Hubs) must hold enough funds to be able to pay costs of bridge
+transactions. If your relayer behaves correctly, those costs will be compensated and you will be
+able to claim it later.
+
+**IMPORTANT**: you may add tip to your bridge transactions to boost their priority. But our
+compensation mechanism never refunds transaction tip, so all tip tokens will be lost.
+
+
+Types of bridge transactions
+
+There are two types of bridge transactions:
+
+- message delivery transaction brings queued message(s) from one Bridge Hub to another. We record
+ the fact that this specific (your) relayer has delivered those messages;
+
+- message confirmation transaction confirms that some message have been delivered and also brings
+ back information on how many messages (your) relayer has delivered. We use this information later
+ to register delivery rewards on the source chain.
+
+Several messages/confirmations may be included in a single bridge transaction. Apart from this
+data, bridge transaction may include finality and storage proofs, required to prove authenticity of
+this data.
+
+
+
+To deliver and get reward for a single message, the relayer needs to submit two transactions. One
+at the source Bridge Hub and one at the target Bridge Hub. Below are costs for Polkadot <> Kusama
+messages (as of today):
+
+- to deliver a single Polkadot -> Kusama message, you would need to pay around `0.06 KSM` at Kusama
+ Bridge Hub and around `1.62 DOT` at Polkadot Bridge Hub;
+
+- to deliver a single Kusama -> Polkadot message, you would need to pay around `1.70 DOT` at Polkadot
+ Bridge Hub and around `0.05 KSM` at Kusama Bridge Hub.
+
+Those values are not constants - they depend on call weights (that may change from release to release),
+on transaction sizes (that depends on message size and chain state) and congestion factor. In any
+case - it is your duty to make sure that the relayer has enough funds to pay transaction fees.
+
+## Claiming your Compensations and Rewards
+
+Hopefully you have successfully delivered some messages and now can claim your compensation and reward.
+This requires submitting several transactions. But first, let's check that you actually have something to
+claim. For that, let's check the state of the pallet that tracks all rewards.
+
+To check your rewards at the Kusama Bridge Hub, go to the
+[Polkadot JS Apps](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fkusama-bridge-hub-rpc.polkadot.io#/chainstate)
+targeting Kusama Bridge Hub, select the `bridgeRelayers` pallet, choose `relayerRewards` map and
+your relayer account. Then:
+
+- set the `laneId` to `0x00000001`
+
+- set the `bridgedChainId` to `bhpd`;
+
+- check the both variants of the `owner` field: `ThisChain` is used to pay for message delivery transactions
+ and `BridgedChain` is used to pay for message confirmation transactions.
+
+If check shows that you have some rewards, you can craft the claim transaction, with similar parameters.
+For that, go to `Extrinsics` tab of the
+[Polkadot JS Apps](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fkusama-bridge-hub-rpc.polkadot.io#/extrinsics)
+and submit the following transaction (make sure to change `owner` before):
+
+![Claim Rewards Extrinsic](./bridge-relayers-claim-rewards.png)
+
+To claim rewards on Polkadot Bridge Hub you can follow the same process. The only difference is that you
+need to set value of the `bridgedChainId` to `bhks`.
+
+## Starting your Relayer
+
+### Starting your Rococo <> Westend Relayer
+
+You may find the relayer image reference in the
+[Releases](https://github.com/paritytech/parity-bridges-common/releases)
+of this repository. Make sure to check supported (bundled) versions
+of release there. For Rococo <> Westend bridge, normally you may use the
+latest published release. The release notes always contain the docker
+image reference and source files, required to build relayer manually.
+
+Once you have the docker image, update variables and run the following script:
+```sh
+export DOCKER_IMAGE=
+
+export ROCOCO_HOST=
+export ROCOCO_PORT=
+# or set it to '--rococo-secure' if wss is used above
+export ROCOCO_IS_SECURE=
+export BRIDGE_HUB_ROCOCO_HOST=
+export BRIDGE_HUB_ROCOCO_PORT=
+# or set it to '--bridge-hub-rococo-secure' if wss is used above
+export BRIDGE_HUB_ROCOCO_IS_SECURE=
+export BRIDGE_HUB_ROCOCO_KEY_FILE=
+
+export WESTEND_HOST=
+export WESTEND_PORT=
+# or set it to '--westend-secure' if wss is used above
+export WESTEND_IS_SECURE=
+export BRIDGE_HUB_WESTEND_HOST=
+export BRIDGE_HUB_WESTEND_PORT=
+# or set it to '--bridge-hub-westend-secure ' if wss is used above
+export BRIDGE_HUB_WESTEND_IS_SECURE=
+export BRIDGE_HUB_WESTEND_KEY_FILE=
+
+# you can get extended relay logs (e.g. for debugging issues) by passing `-e RUST_LOG=bridge=trace`
+# argument to the `docker` binary
+docker run \
+ -v $BRIDGE_HUB_ROCOCO_KEY_FILE:/bhr.key \
+ -v $BRIDGE_HUB_WESTEND_KEY_FILE:/bhw.key \
+ $DOCKER_IMAGE \
+ relay-headers-and-messages bridge-hub-rococo-bridge-hub-westend \
+ --rococo-host $ROCOCO_HOST \
+ --rococo-port $ROCOCO_PORT \
+ $ROCOCO_IS_SECURE \
+ --rococo-version-mode Auto \
+ --bridge-hub-rococo-host $BRIDGE_HUB_ROCOCO_HOST \
+ --bridge-hub-rococo-port $BRIDGE_HUB_ROCOCO_PORT \
+ $BRIDGE_HUB_ROCOCO_IS_SECURE \
+ --bridge-hub-rococo-version-mode Auto \
+ --bridge-hub-rococo-signer-file /bhr.key \
+ --bridge-hub-rococo-transactions-mortality 16 \
+ --westend-host $WESTEND_HOST \
+ --westend-port $WESTEND_PORT \
+ $WESTEND_IS_SECURE \
+ --westend-version-mode Auto \
+ --bridge-hub-westend-host $BRIDGE_HUB_WESTEND_HOST \
+ --bridge-hub-westend-port $BRIDGE_HUB_WESTEND_PORT \
+ $BRIDGE_HUB_WESTEND_IS_SECURE \
+ --bridge-hub-westend-version-mode Auto \
+ --bridge-hub-westend-signer-file /bhw.key \
+ --bridge-hub-westend-transactions-mortality 16 \
+ --lane 00000002
+```
+
+### Starting your Polkadot <> Kusama Relayer
+
+*Work in progress, coming soon*
+
+### Watching your relayer state
+
+Our relayer provides some Prometheus metrics that you may convert into some fancy Grafana dashboards
+and alerts. By default, metrics are exposed at port `9616`. To expose endpoint to the localhost, change
+the docker command by adding following two lines:
+
+```sh
+docker run \
+ ..
+ -p 127.0.0.1:9616:9616 \ # tell Docker to bind container port 9616 to host port 9616
+ # and listen for connections on the host' localhost interface
+ ..
+ $DOCKER_IMAGE \
+ relay-headers-and-messages bridge-hub-rococo-bridge-hub-westend \
+ --prometheus-host 0.0.0.0 \ # tell `substrate-relay` binary to accept Prometheus endpoint
+ # connections from everywhere
+ ..
+```
+
+You can find more info on configuring Prometheus and Grafana in the
+[Monitor your node](https://wiki.polkadot.network/docs/maintain-guides-how-to-monitor-your-node)
+guide from Polkadot wiki.
+
+We have our own set of Grafana dashboards and alerts. You may use them for inspiration.
+Please find them in this folder:
+
+- for Rococo <> Westend bridge: [rococo-westend](https://github.com/paritytech/parity-bridges-common/tree/master/deployments/bridges/rococo-westend).
+
+- for Polkadot <> Kusama bridge: *work in progress, coming soon*
diff --git a/bridges/modules/beefy/Cargo.toml b/bridges/modules/beefy/Cargo.toml
new file mode 100644
index 0000000000000000000000000000000000000000..438f32fb146042f2704deb3092381a2b5cc68394
--- /dev/null
+++ b/bridges/modules/beefy/Cargo.toml
@@ -0,0 +1,63 @@
+[package]
+name = "pallet-bridge-beefy"
+version = "0.1.0"
+description = "Module implementing BEEFY on-chain light client used for bridging consensus of substrate-based chains."
+authors.workspace = true
+edition.workspace = true
+license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
+repository.workspace = true
+publish = false
+
+[lints]
+workspace = true
+
+[dependencies]
+codec = { package = "parity-scale-codec", version = "3.6.1", default-features = false }
+log = { workspace = true }
+scale-info = { version = "2.11.1", default-features = false, features = ["derive"] }
+serde = { optional = true, workspace = true }
+
+# Bridge Dependencies
+
+bp-beefy = { path = "../../primitives/beefy", default-features = false }
+bp-runtime = { path = "../../primitives/runtime", default-features = false }
+
+# Substrate Dependencies
+
+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-runtime = { path = "../../../substrate/primitives/runtime", default-features = false }
+sp-std = { path = "../../../substrate/primitives/std", default-features = false }
+
+[dev-dependencies]
+sp-consensus-beefy = { path = "../../../substrate/primitives/consensus/beefy" }
+mmr-lib = { package = "ckb-merkle-mountain-range", version = "0.5.2" }
+pallet-beefy-mmr = { path = "../../../substrate/frame/beefy-mmr" }
+pallet-mmr = { path = "../../../substrate/frame/merkle-mountain-range" }
+rand = "0.8.5"
+sp-io = { path = "../../../substrate/primitives/io" }
+bp-test-utils = { path = "../../primitives/test-utils" }
+
+[features]
+default = ["std"]
+std = [
+ "bp-beefy/std",
+ "bp-runtime/std",
+ "codec/std",
+ "frame-support/std",
+ "frame-system/std",
+ "log/std",
+ "scale-info/std",
+ "serde/std",
+ "sp-core/std",
+ "sp-runtime/std",
+ "sp-std/std",
+]
+try-runtime = [
+ "frame-support/try-runtime",
+ "frame-system/try-runtime",
+ "pallet-beefy-mmr/try-runtime",
+ "pallet-mmr/try-runtime",
+ "sp-runtime/try-runtime",
+]
diff --git a/bridges/modules/beefy/src/lib.rs b/bridges/modules/beefy/src/lib.rs
new file mode 100644
index 0000000000000000000000000000000000000000..27c83921021bb4299b18cbf2d3216427f8c89ccc
--- /dev/null
+++ b/bridges/modules/beefy/src/lib.rs
@@ -0,0 +1,651 @@
+// Copyright 2021 Parity Technologies (UK) Ltd.
+// This file is part of Parity Bridges Common.
+
+// Parity Bridges Common is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+
+// Parity Bridges Common is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+
+// You should have received a copy of the GNU General Public License
+// along with Parity Bridges Common. If not, see .
+
+//! BEEFY bridge pallet.
+//!
+//! This pallet is an on-chain BEEFY light client for Substrate-based chains that are using the
+//! following pallets bundle: `pallet-mmr`, `pallet-beefy` and `pallet-beefy-mmr`.
+//!
+//! The pallet is able to verify MMR leaf proofs and BEEFY commitments, so it has access
+//! to the following data of the bridged chain:
+//!
+//! - header hashes
+//! - changes of BEEFY authorities
+//! - extra data of MMR leafs
+//!
+//! Given the header hash, other pallets are able to verify header-based proofs
+//! (e.g. storage proofs, transaction inclusion proofs, etc.).
+
+#![warn(missing_docs)]
+#![cfg_attr(not(feature = "std"), no_std)]
+
+use bp_beefy::{ChainWithBeefy, InitializationData};
+use sp_std::{boxed::Box, prelude::*};
+
+// Re-export in crate namespace for `construct_runtime!`
+pub use pallet::*;
+
+mod utils;
+
+#[cfg(test)]
+mod mock;
+#[cfg(test)]
+mod mock_chain;
+
+/// The target that will be used when publishing logs related to this pallet.
+pub const LOG_TARGET: &str = "runtime::bridge-beefy";
+
+/// Configured bridged chain.
+pub type BridgedChain = >::BridgedChain;
+/// Block number, used by configured bridged chain.
+pub type BridgedBlockNumber = bp_runtime::BlockNumberOf>;
+/// Block hash, used by configured bridged chain.
+pub type BridgedBlockHash = bp_runtime::HashOf>;
+
+/// Pallet initialization data.
+pub type InitializationDataOf =
+ InitializationData, bp_beefy::MmrHashOf>>;
+/// BEEFY commitment hasher, used by configured bridged chain.
+pub type BridgedBeefyCommitmentHasher = bp_beefy::BeefyCommitmentHasher>;
+/// BEEFY validator id, used by configured bridged chain.
+pub type BridgedBeefyAuthorityId = bp_beefy::BeefyAuthorityIdOf>;
+/// BEEFY validator set, used by configured bridged chain.
+pub type BridgedBeefyAuthoritySet = bp_beefy::BeefyAuthoritySetOf>;
+/// BEEFY authority set, used by configured bridged chain.
+pub type BridgedBeefyAuthoritySetInfo = bp_beefy::BeefyAuthoritySetInfoOf>;
+/// BEEFY signed commitment, used by configured bridged chain.
+pub type BridgedBeefySignedCommitment = bp_beefy::BeefySignedCommitmentOf>;
+/// MMR hashing algorithm, used by configured bridged chain.
+pub type BridgedMmrHashing = bp_beefy::MmrHashingOf>;
+/// MMR hashing output type of `BridgedMmrHashing`.
+pub type BridgedMmrHash = bp_beefy::MmrHashOf>;
+/// The type of the MMR leaf extra data used by the configured bridged chain.
+pub type BridgedBeefyMmrLeafExtra = bp_beefy::BeefyMmrLeafExtraOf>;
+/// BEEFY MMR proof type used by the pallet
+pub type BridgedMmrProof = bp_beefy::MmrProofOf>;
+/// MMR leaf type, used by configured bridged chain.
+pub type BridgedBeefyMmrLeaf = bp_beefy::BeefyMmrLeafOf>;
+/// Imported commitment data, stored by the pallet.
+pub type ImportedCommitment = bp_beefy::ImportedCommitment<
+ BridgedBlockNumber,
+ BridgedBlockHash,
+ BridgedMmrHash,
+>;
+
+/// Some high level info about the imported commitments.
+#[derive(codec::Encode, codec::Decode, scale_info::TypeInfo)]
+pub struct ImportedCommitmentsInfoData {
+ /// Best known block number, provided in a BEEFY commitment. However this is not
+ /// the best proven block. The best proven block is this block's parent.
+ best_block_number: BlockNumber,
+ /// The head of the `ImportedBlockNumbers` ring buffer.
+ next_block_number_index: u32,
+}
+
+#[frame_support::pallet(dev_mode)]
+pub mod pallet {
+ use super::*;
+ use bp_runtime::{BasicOperatingMode, OwnedBridgeModule};
+ use frame_support::pallet_prelude::*;
+ use frame_system::pallet_prelude::*;
+
+ #[pallet::config]
+ pub trait Config: frame_system::Config {
+ /// The upper bound on the number of requests allowed by the pallet.
+ ///
+ /// A request refers to an action which writes a header to storage.
+ ///
+ /// Once this bound is reached the pallet will reject all commitments
+ /// until the request count has decreased.
+ #[pallet::constant]
+ type MaxRequests: Get;
+
+ /// Maximal number of imported commitments to keep in the storage.
+ ///
+ /// The setting is there to prevent growing the on-chain state indefinitely. Note
+ /// the setting does not relate to block numbers - we will simply keep as much items
+ /// in the storage, so it doesn't guarantee any fixed timeframe for imported commitments.
+ #[pallet::constant]
+ type CommitmentsToKeep: Get;
+
+ /// The chain we are bridging to here.
+ type BridgedChain: ChainWithBeefy;
+ }
+
+ #[pallet::pallet]
+ #[pallet::without_storage_info]
+ pub struct Pallet(PhantomData<(T, I)>);
+
+ #[pallet::hooks]
+ impl, I: 'static> Hooks> for Pallet {
+ fn on_initialize(_n: BlockNumberFor) -> frame_support::weights::Weight {
+ >::mutate(|count| *count = count.saturating_sub(1));
+
+ Weight::from_parts(0, 0)
+ .saturating_add(T::DbWeight::get().reads(1))
+ .saturating_add(T::DbWeight::get().writes(1))
+ }
+ }
+
+ impl, I: 'static> OwnedBridgeModule for Pallet {
+ const LOG_TARGET: &'static str = LOG_TARGET;
+ type OwnerStorage = PalletOwner;
+ type OperatingMode = BasicOperatingMode;
+ type OperatingModeStorage = PalletOperatingMode;
+ }
+
+ #[pallet::call]
+ impl, I: 'static> Pallet
+ where
+ BridgedMmrHashing: 'static + Send + Sync,
+ {
+ /// Initialize pallet with BEEFY authority set and best known finalized block number.
+ #[pallet::call_index(0)]
+ #[pallet::weight((T::DbWeight::get().reads_writes(2, 3), DispatchClass::Operational))]
+ pub fn initialize(
+ origin: OriginFor,
+ init_data: InitializationDataOf,
+ ) -> DispatchResult {
+ Self::ensure_owner_or_root(origin)?;
+
+ let is_initialized = >::exists();
+ ensure!(!is_initialized, >::AlreadyInitialized);
+
+ log::info!(target: LOG_TARGET, "Initializing bridge BEEFY pallet: {:?}", init_data);
+ Ok(initialize::(init_data)?)
+ }
+
+ /// Change `PalletOwner`.
+ ///
+ /// May only be called either by root, or by `PalletOwner`.
+ #[pallet::call_index(1)]
+ #[pallet::weight((T::DbWeight::get().reads_writes(1, 1), DispatchClass::Operational))]
+ pub fn set_owner(origin: OriginFor, new_owner: Option) -> DispatchResult {
+ >::set_owner(origin, new_owner)
+ }
+
+ /// Halt or resume all pallet operations.
+ ///
+ /// May only be called either by root, or by `PalletOwner`.
+ #[pallet::call_index(2)]
+ #[pallet::weight((T::DbWeight::get().reads_writes(1, 1), DispatchClass::Operational))]
+ pub fn set_operating_mode(
+ origin: OriginFor,
+ operating_mode: BasicOperatingMode,
+ ) -> DispatchResult {
+ >::set_operating_mode(origin, operating_mode)
+ }
+
+ /// Submit a commitment generated by BEEFY authority set.
+ ///
+ /// It will use the underlying storage pallet to fetch information about the current
+ /// authority set and best finalized block number in order to verify that the commitment
+ /// is valid.
+ ///
+ /// If successful in verification, it will update the underlying storage with the data
+ /// provided in the newly submitted commitment.
+ #[pallet::call_index(3)]
+ #[pallet::weight(0)]
+ pub fn submit_commitment(
+ origin: OriginFor,
+ commitment: BridgedBeefySignedCommitment,
+ validator_set: BridgedBeefyAuthoritySet,
+ mmr_leaf: Box>,
+ mmr_proof: BridgedMmrProof,
+ ) -> DispatchResult
+ where
+ BridgedBeefySignedCommitment: Clone,
+ {
+ Self::ensure_not_halted().map_err(Error::::BridgeModule)?;
+ ensure_signed(origin)?;
+
+ ensure!(Self::request_count() < T::MaxRequests::get(), >::TooManyRequests);
+
+ // Ensure that the commitment is for a better block.
+ let commitments_info =
+ ImportedCommitmentsInfo::::get().ok_or(Error::::NotInitialized)?;
+ ensure!(
+ commitment.commitment.block_number > commitments_info.best_block_number,
+ Error::::OldCommitment
+ );
+
+ // Verify commitment and mmr leaf.
+ let current_authority_set_info = CurrentAuthoritySetInfo::::get();
+ let mmr_root = utils::verify_commitment::(
+ &commitment,
+ ¤t_authority_set_info,
+ &validator_set,
+ )?;
+ utils::verify_beefy_mmr_leaf::(&mmr_leaf, mmr_proof, mmr_root)?;
+
+ // Update request count.
+ RequestCount::::mutate(|count| *count += 1);
+ // Update authority set if needed.
+ if mmr_leaf.beefy_next_authority_set.id > current_authority_set_info.id {
+ CurrentAuthoritySetInfo::::put(mmr_leaf.beefy_next_authority_set);
+ }
+
+ // Import commitment.
+ let block_number_index = commitments_info.next_block_number_index;
+ let to_prune = ImportedBlockNumbers::::try_get(block_number_index);
+ ImportedCommitments::::insert(
+ commitment.commitment.block_number,
+ ImportedCommitment:: {
+ parent_number_and_hash: mmr_leaf.parent_number_and_hash,
+ mmr_root,
+ },
+ );
+ ImportedBlockNumbers::::insert(
+ block_number_index,
+ commitment.commitment.block_number,
+ );
+ ImportedCommitmentsInfo::::put(ImportedCommitmentsInfoData {
+ best_block_number: commitment.commitment.block_number,
+ next_block_number_index: (block_number_index + 1) % T::CommitmentsToKeep::get(),
+ });
+ if let Ok(old_block_number) = to_prune {
+ log::debug!(
+ target: LOG_TARGET,
+ "Pruning commitment for old block: {:?}.",
+ old_block_number
+ );
+ ImportedCommitments::::remove(old_block_number);
+ }
+
+ log::info!(
+ target: LOG_TARGET,
+ "Successfully imported commitment for block {:?}",
+ commitment.commitment.block_number,
+ );
+
+ Ok(())
+ }
+ }
+
+ /// The current number of requests which have written to storage.
+ ///
+ /// If the `RequestCount` hits `MaxRequests`, no more calls will be allowed to the pallet until
+ /// the request capacity is increased.
+ ///
+ /// The `RequestCount` is decreased by one at the beginning of every block. This is to ensure
+ /// that the pallet can always make progress.
+ #[pallet::storage]
+ #[pallet::getter(fn request_count)]
+ pub type RequestCount, I: 'static = ()> = StorageValue<_, u32, ValueQuery>;
+
+ /// High level info about the imported commitments.
+ ///
+ /// Contains the following info:
+ /// - best known block number of the bridged chain, finalized by BEEFY
+ /// - the head of the `ImportedBlockNumbers` ring buffer
+ #[pallet::storage]
+ pub type ImportedCommitmentsInfo, I: 'static = ()> =
+ StorageValue<_, ImportedCommitmentsInfoData>>;
+
+ /// A ring buffer containing the block numbers of the commitments that we have imported,
+ /// ordered by the insertion time.
+ #[pallet::storage]
+ pub(super) type ImportedBlockNumbers, I: 'static = ()> =
+ StorageMap<_, Identity, u32, BridgedBlockNumber>;
+
+ /// All the commitments that we have imported and haven't been pruned yet.
+ #[pallet::storage]
+ pub type ImportedCommitments, I: 'static = ()> =
+ StorageMap<_, Blake2_128Concat, BridgedBlockNumber, ImportedCommitment>;
+
+ /// The current BEEFY authority set at the bridged chain.
+ #[pallet::storage]
+ pub type CurrentAuthoritySetInfo, I: 'static = ()> =
+ StorageValue<_, BridgedBeefyAuthoritySetInfo, ValueQuery>;
+
+ /// Optional pallet owner.
+ ///
+ /// Pallet owner has the right to halt all pallet operations and then resume it. If it is
+ /// `None`, then there are no direct ways to halt/resume pallet operations, but other
+ /// runtime methods may still be used to do that (i.e. `democracy::referendum` to update halt
+ /// flag directly or calling `halt_operations`).
+ #[pallet::storage]
+ pub type PalletOwner, I: 'static = ()> =
+ StorageValue<_, T::AccountId, OptionQuery>;
+
+ /// The current operating mode of the pallet.
+ ///
+ /// Depending on the mode either all, or no transactions will be allowed.
+ #[pallet::storage]
+ pub type PalletOperatingMode, I: 'static = ()> =
+ StorageValue<_, BasicOperatingMode, ValueQuery>;
+
+ #[pallet::genesis_config]
+ #[derive(frame_support::DefaultNoBound)]
+ pub struct GenesisConfig, I: 'static = ()> {
+ /// Optional module owner account.
+ pub owner: Option,
+ /// Optional module initialization data.
+ pub init_data: Option>,
+ }
+
+ #[pallet::genesis_build]
+ impl, I: 'static> BuildGenesisConfig for GenesisConfig {
+ fn build(&self) {
+ if let Some(ref owner) = self.owner {
+ >::put(owner);
+ }
+
+ if let Some(init_data) = self.init_data.clone() {
+ initialize::(init_data)
+ .expect("invalid initialization data of BEEFY bridge pallet");
+ } else {
+ // Since the bridge hasn't been initialized we shouldn't allow anyone to perform
+ // transactions.
+ >::put(BasicOperatingMode::Halted);
+ }
+ }
+ }
+
+ #[pallet::error]
+ pub enum Error {
+ /// The pallet has not been initialized yet.
+ NotInitialized,
+ /// The pallet has already been initialized.
+ AlreadyInitialized,
+ /// Invalid initial authority set.
+ InvalidInitialAuthoritySet,
+ /// There are too many requests for the current window to handle.
+ TooManyRequests,
+ /// The imported commitment is older than the best commitment known to the pallet.
+ OldCommitment,
+ /// The commitment is signed by unknown validator set.
+ InvalidCommitmentValidatorSetId,
+ /// The id of the provided validator set is invalid.
+ InvalidValidatorSetId,
+ /// The number of signatures in the commitment is invalid.
+ InvalidCommitmentSignaturesLen,
+ /// The number of validator ids provided is invalid.
+ InvalidValidatorSetLen,
+ /// There aren't enough correct signatures in the commitment to finalize the block.
+ NotEnoughCorrectSignatures,
+ /// MMR root is missing from the commitment.
+ MmrRootMissingFromCommitment,
+ /// MMR proof verification has failed.
+ MmrProofVerificationFailed,
+ /// The validators are not matching the merkle tree root of the authority set.
+ InvalidValidatorSetRoot,
+ /// Error generated by the `OwnedBridgeModule` trait.
+ BridgeModule(bp_runtime::OwnedBridgeModuleError),
+ }
+
+ /// Initialize pallet with given parameters.
+ pub(super) fn initialize, I: 'static>(
+ init_data: InitializationDataOf,
+ ) -> Result<(), Error> {
+ if init_data.authority_set.len == 0 {
+ return Err(Error::::InvalidInitialAuthoritySet)
+ }
+ CurrentAuthoritySetInfo::::put(init_data.authority_set);
+
+ >::put(init_data.operating_mode);
+ ImportedCommitmentsInfo::::put(ImportedCommitmentsInfoData {
+ best_block_number: init_data.best_block_number,
+ next_block_number_index: 0,
+ });
+
+ Ok(())
+ }
+}
+
+#[cfg(test)]
+mod tests {
+ use super::*;
+ use bp_runtime::{BasicOperatingMode, OwnedBridgeModuleError};
+ use bp_test_utils::generate_owned_bridge_module_tests;
+ use frame_support::{assert_noop, assert_ok, traits::Get};
+ use mock::*;
+ use mock_chain::*;
+ use sp_consensus_beefy::mmr::BeefyAuthoritySet;
+ use sp_runtime::DispatchError;
+
+ fn next_block() {
+ use frame_support::traits::OnInitialize;
+
+ let current_number = frame_system::Pallet::::block_number();
+ frame_system::Pallet::::set_block_number(current_number + 1);
+ let _ = Pallet::::on_initialize(current_number);
+ }
+
+ fn import_header_chain(headers: Vec) {
+ for header in headers {
+ if header.commitment.is_some() {
+ assert_ok!(import_commitment(header));
+ }
+ }
+ }
+
+ #[test]
+ fn fails_to_initialize_if_already_initialized() {
+ run_test_with_initialize(32, || {
+ assert_noop!(
+ Pallet::::initialize(
+ RuntimeOrigin::root(),
+ InitializationData {
+ operating_mode: BasicOperatingMode::Normal,
+ best_block_number: 0,
+ authority_set: BeefyAuthoritySet {
+ id: 0,
+ len: 1,
+ keyset_commitment: [0u8; 32].into()
+ }
+ }
+ ),
+ Error::::AlreadyInitialized,
+ );
+ });
+ }
+
+ #[test]
+ fn fails_to_initialize_if_authority_set_is_empty() {
+ run_test(|| {
+ assert_noop!(
+ Pallet::::initialize(
+ RuntimeOrigin::root(),
+ InitializationData {
+ operating_mode: BasicOperatingMode::Normal,
+ best_block_number: 0,
+ authority_set: BeefyAuthoritySet {
+ id: 0,
+ len: 0,
+ keyset_commitment: [0u8; 32].into()
+ }
+ }
+ ),
+ Error::::InvalidInitialAuthoritySet,
+ );
+ });
+ }
+
+ #[test]
+ fn fails_to_import_commitment_if_halted() {
+ run_test_with_initialize(1, || {
+ assert_ok!(Pallet::::set_operating_mode(
+ RuntimeOrigin::root(),
+ BasicOperatingMode::Halted
+ ));
+ assert_noop!(
+ import_commitment(ChainBuilder::new(1).append_finalized_header().to_header()),
+ Error::::BridgeModule(OwnedBridgeModuleError::Halted),
+ );
+ })
+ }
+
+ #[test]
+ fn fails_to_import_commitment_if_too_many_requests() {
+ run_test_with_initialize(1, || {
+ let max_requests = <::MaxRequests as Get>::get() as u64;
+ let mut chain = ChainBuilder::new(1);
+ for _ in 0..max_requests + 2 {
+ chain = chain.append_finalized_header();
+ }
+
+ // import `max_request` headers
+ for i in 0..max_requests {
+ assert_ok!(import_commitment(chain.header(i + 1)));
+ }
+
+ // try to import next header: it fails because we are no longer accepting commitments
+ assert_noop!(
+ import_commitment(chain.header(max_requests + 1)),
+ Error::::TooManyRequests,
+ );
+
+ // when next block is "started", we allow import of next header
+ next_block();
+ assert_ok!(import_commitment(chain.header(max_requests + 1)));
+
+ // but we can't import two headers until next block and so on
+ assert_noop!(
+ import_commitment(chain.header(max_requests + 2)),
+ Error::::TooManyRequests,
+ );
+ })
+ }
+
+ #[test]
+ fn fails_to_import_commitment_if_not_initialized() {
+ run_test(|| {
+ assert_noop!(
+ import_commitment(ChainBuilder::new(1).append_finalized_header().to_header()),
+ Error::::NotInitialized,
+ );
+ })
+ }
+
+ #[test]
+ fn submit_commitment_works_with_long_chain_with_handoffs() {
+ run_test_with_initialize(3, || {
+ let chain = ChainBuilder::new(3)
+ .append_finalized_header()
+ .append_default_headers(16) // 2..17
+ .append_finalized_header() // 18
+ .append_default_headers(16) // 19..34
+ .append_handoff_header(9) // 35
+ .append_default_headers(8) // 36..43
+ .append_finalized_header() // 44
+ .append_default_headers(8) // 45..52
+ .append_handoff_header(17) // 53
+ .append_default_headers(4) // 54..57
+ .append_finalized_header() // 58
+ .append_default_headers(4); // 59..63
+ import_header_chain(chain.to_chain());
+
+ assert_eq!(
+ ImportedCommitmentsInfo::::get().unwrap().best_block_number,
+ 58
+ );
+ assert_eq!(CurrentAuthoritySetInfo::::get().id, 2);
+ assert_eq!(CurrentAuthoritySetInfo::::get().len, 17);
+
+ let imported_commitment = ImportedCommitments::::get(58).unwrap();
+ assert_eq!(
+ imported_commitment,
+ bp_beefy::ImportedCommitment {
+ parent_number_and_hash: (57, chain.header(57).header.hash()),
+ mmr_root: chain.header(58).mmr_root,
+ },
+ );
+ })
+ }
+
+ #[test]
+ fn commitment_pruning_works() {
+ run_test_with_initialize(3, || {
+ let commitments_to_keep = >::CommitmentsToKeep::get();
+ let commitments_to_import: Vec = ChainBuilder::new(3)
+ .append_finalized_headers(commitments_to_keep as usize + 2)
+ .to_chain();
+
+ // import exactly `CommitmentsToKeep` commitments
+ for index in 0..commitments_to_keep {
+ next_block();
+ import_commitment(commitments_to_import[index as usize].clone())
+ .expect("must succeed");
+ assert_eq!(
+ ImportedCommitmentsInfo::::get().unwrap().next_block_number_index,
+ (index + 1) % commitments_to_keep
+ );
+ }
+
+ // ensure that all commitments are in the storage
+ assert_eq!(
+ ImportedCommitmentsInfo::::get().unwrap().best_block_number,
+ commitments_to_keep as TestBridgedBlockNumber
+ );
+ assert_eq!(
+ ImportedCommitmentsInfo::::get().unwrap().next_block_number_index,
+ 0
+ );
+ for index in 0..commitments_to_keep {
+ assert!(ImportedCommitments::::get(
+ index as TestBridgedBlockNumber + 1
+ )
+ .is_some());
+ assert_eq!(
+ ImportedBlockNumbers::::get(index),
+ Some(Into::into(index + 1)),
+ );
+ }
+
+ // import next commitment
+ next_block();
+ import_commitment(commitments_to_import[commitments_to_keep as usize].clone())
+ .expect("must succeed");
+ assert_eq!(
+ ImportedCommitmentsInfo::::get().unwrap().next_block_number_index,
+ 1
+ );
+ assert!(ImportedCommitments::::get(
+ commitments_to_keep as TestBridgedBlockNumber + 1
+ )
+ .is_some());
+ assert_eq!(
+ ImportedBlockNumbers::::get(0),
+ Some(Into::into(commitments_to_keep + 1)),
+ );
+ // the side effect of the import is that the commitment#1 is pruned
+ assert!(ImportedCommitments::::get(1).is_none());
+
+ // import next commitment
+ next_block();
+ import_commitment(commitments_to_import[commitments_to_keep as usize + 1].clone())
+ .expect("must succeed");
+ assert_eq!(
+ ImportedCommitmentsInfo::::get().unwrap().next_block_number_index,
+ 2
+ );
+ assert!(ImportedCommitments::::get(
+ commitments_to_keep as TestBridgedBlockNumber + 2
+ )
+ .is_some());
+ assert_eq!(
+ ImportedBlockNumbers::::get(1),
+ Some(Into::into(commitments_to_keep + 2)),
+ );
+ // the side effect of the import is that the commitment#2 is pruned
+ assert!(ImportedCommitments::::get(1).is_none());
+ assert!(ImportedCommitments::::get(2).is_none());
+ });
+ }
+
+ generate_owned_bridge_module_tests!(BasicOperatingMode::Normal, BasicOperatingMode::Halted);
+}
diff --git a/bridges/modules/beefy/src/mock.rs b/bridges/modules/beefy/src/mock.rs
new file mode 100644
index 0000000000000000000000000000000000000000..c99566b6b06d1855319d614f4f4ddfbf2fb1918b
--- /dev/null
+++ b/bridges/modules/beefy/src/mock.rs
@@ -0,0 +1,193 @@
+// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// This file is part of Parity Bridges Common.
+
+// Parity Bridges Common is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+
+// Parity Bridges Common is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+
+// You should have received a copy of the GNU General Public License
+// along with Parity Bridges Common. If not, see .
+
+use crate as beefy;
+use crate::{
+ utils::get_authorities_mmr_root, BridgedBeefyAuthoritySet, BridgedBeefyAuthoritySetInfo,
+ BridgedBeefyCommitmentHasher, BridgedBeefyMmrLeafExtra, BridgedBeefySignedCommitment,
+ BridgedMmrHash, BridgedMmrHashing, BridgedMmrProof,
+};
+
+use bp_beefy::{BeefyValidatorSignatureOf, ChainWithBeefy, Commitment, MmrDataOrHash};
+use bp_runtime::{BasicOperatingMode, Chain, ChainId};
+use codec::Encode;
+use frame_support::{construct_runtime, derive_impl, weights::Weight};
+use sp_core::{sr25519::Signature, Pair};
+use sp_runtime::{
+ testing::{Header, H256},
+ traits::{BlakeTwo256, Hash},
+};
+
+pub use sp_consensus_beefy::ecdsa_crypto::{AuthorityId as BeefyId, Pair as BeefyPair};
+use sp_core::crypto::Wraps;
+use sp_runtime::traits::Keccak256;
+
+pub type TestAccountId = u64;
+pub type TestBridgedBlockNumber = u64;
+pub type TestBridgedBlockHash = H256;
+pub type TestBridgedHeader = Header;
+pub type TestBridgedAuthoritySetInfo = BridgedBeefyAuthoritySetInfo;
+pub type TestBridgedValidatorSet = BridgedBeefyAuthoritySet;
+pub type TestBridgedCommitment = BridgedBeefySignedCommitment;
+pub type TestBridgedValidatorSignature = BeefyValidatorSignatureOf;
+pub type TestBridgedCommitmentHasher = BridgedBeefyCommitmentHasher;
+pub type TestBridgedMmrHashing = BridgedMmrHashing;
+pub type TestBridgedMmrHash = BridgedMmrHash;
+pub type TestBridgedBeefyMmrLeafExtra = BridgedBeefyMmrLeafExtra;
+pub type TestBridgedMmrProof = BridgedMmrProof;
+pub type TestBridgedRawMmrLeaf = sp_consensus_beefy::mmr::MmrLeaf<
+ TestBridgedBlockNumber,
+ TestBridgedBlockHash,
+ TestBridgedMmrHash,
+ TestBridgedBeefyMmrLeafExtra,
+>;
+pub type TestBridgedMmrNode = MmrDataOrHash;
+
+type Block = frame_system::mocking::MockBlock;
+
+construct_runtime! {
+ pub enum TestRuntime
+ {
+ System: frame_system::{Pallet, Call, Config, Storage, Event},
+ Beefy: beefy::{Pallet},
+ }
+}
+
+#[derive_impl(frame_system::config_preludes::TestDefaultConfig as frame_system::DefaultConfig)]
+impl frame_system::Config for TestRuntime {
+ type Block = Block;
+}
+
+impl beefy::Config for TestRuntime {
+ type MaxRequests = frame_support::traits::ConstU32<16>;
+ type BridgedChain = TestBridgedChain;
+ type CommitmentsToKeep = frame_support::traits::ConstU32<16>;
+}
+
+#[derive(Debug)]
+pub struct TestBridgedChain;
+
+impl Chain for TestBridgedChain {
+ const ID: ChainId = *b"tbch";
+
+ type BlockNumber = TestBridgedBlockNumber;
+ type Hash = H256;
+ type Hasher = BlakeTwo256;
+ type Header = sp_runtime::testing::Header;
+
+ type AccountId = TestAccountId;
+ type Balance = u64;
+ type Nonce = u64;
+ type Signature = Signature;
+
+ fn max_extrinsic_size() -> u32 {
+ unreachable!()
+ }
+ fn max_extrinsic_weight() -> Weight {
+ unreachable!()
+ }
+}
+
+impl ChainWithBeefy for TestBridgedChain {
+ type CommitmentHasher = Keccak256;
+ type MmrHashing = Keccak256;
+ type MmrHash = ::Output;
+ type BeefyMmrLeafExtra = ();
+ type AuthorityId = BeefyId;
+ type AuthorityIdToMerkleLeaf = pallet_beefy_mmr::BeefyEcdsaToEthereum;
+}
+
+/// Run test within test runtime.
+pub fn run_test(test: impl FnOnce() -> T) -> T {
+ sp_io::TestExternalities::new(Default::default()).execute_with(test)
+}
+
+/// Initialize pallet and run test.
+pub fn run_test_with_initialize(initial_validators_count: u32, test: impl FnOnce() -> T) -> T {
+ run_test(|| {
+ let validators = validator_ids(0, initial_validators_count);
+ let authority_set = authority_set_info(0, &validators);
+
+ crate::Pallet::::initialize(
+ RuntimeOrigin::root(),
+ bp_beefy::InitializationData {
+ operating_mode: BasicOperatingMode::Normal,
+ best_block_number: 0,
+ authority_set,
+ },
+ )
+ .expect("initialization data is correct");
+
+ test()
+ })
+}
+
+/// Import given commitment.
+pub fn import_commitment(
+ header: crate::mock_chain::HeaderAndCommitment,
+) -> sp_runtime::DispatchResult {
+ crate::Pallet::::submit_commitment(
+ RuntimeOrigin::signed(1),
+ header
+ .commitment
+ .expect("thou shall not call import_commitment on header without commitment"),
+ header.validator_set,
+ Box::new(header.leaf),
+ header.leaf_proof,
+ )
+}
+
+pub fn validator_pairs(index: u32, count: u32) -> Vec {
+ (index..index + count)
+ .map(|index| {
+ let mut seed = [1u8; 32];
+ seed[0..8].copy_from_slice(&(index as u64).encode());
+ BeefyPair::from_seed(&seed)
+ })
+ .collect()
+}
+
+/// Return identifiers of validators, starting at given index.
+pub fn validator_ids(index: u32, count: u32) -> Vec {
+ validator_pairs(index, count).into_iter().map(|pair| pair.public()).collect()
+}
+
+pub fn authority_set_info(id: u64, validators: &[BeefyId]) -> TestBridgedAuthoritySetInfo {
+ let merkle_root = get_authorities_mmr_root::(validators.iter());
+
+ TestBridgedAuthoritySetInfo { id, len: validators.len() as u32, keyset_commitment: merkle_root }
+}
+
+/// Sign BEEFY commitment.
+pub fn sign_commitment(
+ commitment: Commitment,
+ validator_pairs: &[BeefyPair],
+ signature_count: usize,
+) -> TestBridgedCommitment {
+ let total_validators = validator_pairs.len();
+ let random_validators =
+ rand::seq::index::sample(&mut rand::thread_rng(), total_validators, signature_count);
+
+ let commitment_hash = TestBridgedCommitmentHasher::hash(&commitment.encode());
+ let mut signatures = vec![None; total_validators];
+ for validator_idx in random_validators.iter() {
+ let validator = &validator_pairs[validator_idx];
+ signatures[validator_idx] =
+ Some(validator.as_inner_ref().sign_prehashed(commitment_hash.as_fixed_bytes()).into());
+ }
+
+ TestBridgedCommitment { commitment, signatures }
+}
diff --git a/bridges/modules/beefy/src/mock_chain.rs b/bridges/modules/beefy/src/mock_chain.rs
new file mode 100644
index 0000000000000000000000000000000000000000..c83907f8395684d03cc62892e519565fb72237f7
--- /dev/null
+++ b/bridges/modules/beefy/src/mock_chain.rs
@@ -0,0 +1,299 @@
+// Copyright 2019-2021 Parity Technologies (UK) Ltd.
+// This file is part of Parity Bridges Common.
+
+// Parity Bridges Common is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+
+// Parity Bridges Common is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+
+// You should have received a copy of the GNU General Public License
+// along with Parity Bridges Common. If not, see .
+
+//! Utilities to build bridged chain and BEEFY+MMR structures.
+
+use crate::{
+ mock::{
+ sign_commitment, validator_pairs, BeefyPair, TestBridgedBlockNumber, TestBridgedCommitment,
+ TestBridgedHeader, TestBridgedMmrHash, TestBridgedMmrHashing, TestBridgedMmrNode,
+ TestBridgedMmrProof, TestBridgedRawMmrLeaf, TestBridgedValidatorSet,
+ TestBridgedValidatorSignature, TestRuntime,
+ },
+ utils::get_authorities_mmr_root,
+};
+
+use bp_beefy::{BeefyPayload, Commitment, ValidatorSetId, MMR_ROOT_PAYLOAD_ID};
+use codec::Encode;
+use pallet_mmr::NodeIndex;
+use rand::Rng;
+use sp_consensus_beefy::mmr::{BeefyNextAuthoritySet, MmrLeafVersion};
+use sp_core::Pair;
+use sp_runtime::traits::{Hash, Header as HeaderT};
+use std::collections::HashMap;
+
+#[derive(Debug, Clone)]
+pub struct HeaderAndCommitment {
+ pub header: TestBridgedHeader,
+ pub commitment: Option,
+ pub validator_set: TestBridgedValidatorSet,
+ pub leaf: TestBridgedRawMmrLeaf,
+ pub leaf_proof: TestBridgedMmrProof,
+ pub mmr_root: TestBridgedMmrHash,
+}
+
+impl HeaderAndCommitment {
+ pub fn customize_signatures(
+ &mut self,
+ f: impl FnOnce(&mut Vec